Debian Installation on Kindle Touch

From MobileRead
Jump to: navigation, search


[edit] KUAL extensions


[edit] Setting up Base Image

dd if=/dev/zero of=/tmp/debian.ext3 bs=1M count=1280
mkfs.ext3 /tmp/debian.ext3
tune2fs -i 0 -c 0 /tmp/debian.ext3
mount -o loop -t ext3 /tmp/debian.ext3 /mnt/debian

[edit] If host architecture is same as target architecture

Debootstrap a basic debian on to your image if your PC has armel architecture too.

debootstrap --arch=armel testing /mnt/debian

[edit] If host architecture is different from target architecture

debootstrap --arch=armel --variant=minbase --foreign jessie /mnt/debian

Later, when you are on Kindle and when you have set up the chroot environment you have to start the second stage of the base installation:

debootstrap --second-stage

UPDATE: Currently, "testing" is the Debian Sid release. Debootstraping it and Chrooting on a kindle will result in FATAL: KERNEL TOO OLD. To fix this replace "testing" with "wheezy" or "jessie". NOTE: Using the argument --variant=minbase will significantly reduce the size of the debian installation.

[edit] Copy Image to Kindle

[edit] Setup Chroot Environment

mount -o loop -t ext3 /mnt/base-us/debian.ext3 /mnt/debian
mount -o bind /dev /mnt/debian/dev
mount -o bind /dev/pts /mnt/debian/dev/pts
mount -o bind /proc /mnt/debian/proc
mount -o bind /sys /mnt/debian/sys
cp /etc/hosts /mnt/debian/etc/hosts

Note: Quite a few people reported lock-ups when using apt-get with debian.ext3 mounted from /mnt/us and also seriously bricking the Kindle. Therefore /mnt/base-us is used here. This seems to be safe as long as userstore is not used as USB drive. Another option would be to Repartition the Kindle.

[edit] Continue Installation

Setup Internet access for Kindle via USB.

If you created debian.ext3 on a non-armel architecture:

debootstrap --second-stage

[edit] Usage of Chroot Debian


[edit] Getting a Chroot Shell

chroot /mnt/debian /bin/bash

Once you added a user to the Debian system you can login with that user account:

chroot /mnt/debian /bin/login

[edit] Other options

In case you want to have access to userstore from debian execute before chrooting:

mount -o bind /mnt/us /mnt/debian/mnt/us

[edit] Unsorted Links

Personal tools

MobileRead Networks