Finally after a lot of endless nights tingering around I decided to post about my newly acquired Amazon Kindle 3. Since I study presentations and books from PDF files I thought a device like this would be really useful, and after reading somewhere that it could run Ubuntu Linux and even with X11 I knew exactly what I needed. Without wasting time I went to the local electronics store to check their prices. To my surprise they offered the previous generation for 350 euros (really wtf?) when you could order the latest version from Amazon for barely 120 euros with DHL shipping.
Day one, I literally took it apart, jailbroken, changed the boring wallpapers to something more cool and installed SSH. But it wasn’t enough.. Although it runs natively on some basic Linux install, it is very limiting. After studying some guides and forums I was up and running!
Here are the steps I followed to installed a Debian chroot on my Kindle device and some network tools.
NOTE: This is not an expert how to guide, just what I did to make it work, so it is not the best or most safe way to do it, I can’t have any responsibility if you brick your device. Please if you want to follow the steps make sure you know what you are doing.
First we have to create a file system image, the following commands create a 512MB ext3 image and mounts it on /mnt. To make it larger just change the count parameter.
dd if=/dev/zero of=/tmp/wheezy.ext3 bs=1M count=512 mkfs.ext3 /tmp/wheezy.ext3 tune2fs -i 0 -c 0 /tmp/wheezy.ext3 sudo mount -o loop -t ext3 /tmp/wheezy.ext3 /mnt/
Now we have to install and configure multistrap, its a debootstrap like utility that installs a Debian base system plus you can specify extra repositories and packets to install in the configuration file.
sudo apt-get install multistrap nano wheezy-config
Here is a simple configuration I used, more can be found at the previous links.
[General] unpack=true arch=armel directory=/mnt/ debootstrap=Grip Updates aptsources=Debian Grip Updates [Grip] packages=ntpdate udev lrzsz netcat telnetd apt source=http://www.emdebian.org/grip keyring=emdebian-archive-keyring suite=wheezy [Updates] packages=apt source=http://ftp.uk.debian.org/debian keyring=debian-archive-keyring suite=wheezy-proposed-updates [Debian] packages= source=http://ftp.uk.debian.org/debian keyring=debian-archive-keyring suite=wheezy
Next step is to finally install the chroot on our image, this should take a while.
sudo multistrap -f wheezy-config
After everything is done, unmount the image and copy it to your Kindle. Now you are ready to mount it on your Kindle and chroot into it. To make things easier here is a script by Xkid you could use.
#!/bin/sh echo "[*] Mounting Rootfs..." mount -o loop,noatime -t ext3 /mnt/us/debian.ext3 /mnt/debian echo "[*] Preparing Filesystem..." mount -o bind /dev /mnt/debian/dev mount -o bind /proc /mnt/debian/proc mount -o bind /sys /mnt/debian/sys echo "[*] Preparing Network Connections..." cp /etc/hosts /mnt/debian/etc/hosts cp /etc/resolv.conf /mnt/debian/etc/resolv.conf echo "[*] Starting Shell..." chroot /mnt/debian /bin/bash echo "[*]Unmounting Rootfs..." umount /mnt/debian/dev umount /mnt/debian/proc umount /mnt/debian/sys umount /mnt/debian
After you have sucessfully chrooted into your image, you have to configure dpkg by running
dpkg --configure -a
By this stage you should have a working apt-get, from there you can install pretty much anything else you want. Here are some packets you might find interesting.
net-tools – A collection of network programs like ifconfig, arp, route etc
netcat – Networking utility which reads and writes data across network connections
gcc, g++ – GNU C/C++ compilers
links – Terminal web browser
nano – Text editor
Plus I compiled a lot of custom networking tools from source. Also I tried nmap and aircrack-ng though with little success so far.
Have fun.
PS: Use Luigis terminal or Full Screen Terminal to mount and run Debian from within your kindle.
PS: For more information check out these links:
http://wiki.debian.org/Multistrap
http://www.mobileread.com/forums/showthread.php?t=96048
http://www.mobileread.com/forums/showthread.php?t=133005
thank you for the great howto,
it works fine from my pc over ssh, but how can I start the debian system from kindle?
thanks for the answer in advance,
you have to install full screen terminal or luigis terminal and after that just press Shift followed by “t” on your kindle to launch the terminal, from there on its the same as it would be from ssh, just navigate and run your mount commands.
Well – aircrack-ng is working, but what about airodump-ng or aireplay-ng (I thing there are more important than aircrack-ng)? How did you managed to switch wireless driver to monitor (rfmon) mode? I tried to do that, but with no success. Or did you compile own WiFi driver (AR6002) from (some) source? It would be very nice to have this feature :).
I’ve tried for ages to create this image in both Debian and Ubuntu. I’ve failed horribly both times. I’m not a newb to Linux, but I am to this 😛
If possible, can you please upload somewhere the image file for this so that I can just get to actually putting it on my Kindle? If so that would be really great of you 🙂
Thanks in advance,
-Cameron
I will take a look if I still have the image somewhere around! But I think if you follow my reference links, you might find a compiled image there!
Hello, how about “RadHat” (for example Mandrake, Mandriva)? 🙂
And where you can download the final image Debian for the Kindle?