Debian on G1
From Android Wiki
See also Installing_Debian.
It's possible to install the existing Arm port of Debian to an SD card and get access to all available Debian applications while still also having the original Android software available. Jay Freeman (saurik) has been pioneering this work and provides a very detailed document, Debian & Android Together on G1.
Saurik has written an updated post to the g1-hackers list describing various changes he has already made and possible future directions for this work. If you encounter any issues or would like to help resolve something, please describe it below.
Working hardware for Debian on /
Saurik says "the hardware obviously needs to work" but also suggests that this should be easy. It's not clear what things aren't working yet, but saurik (or someone who replicates his setup) should be able to describe that here.
Working /sdcard when the second partition is mounted
This is another issue that saurik mentioned in his emailed udpate. He also says "can be put off" so perhaps this issue isn't urgent yet.
What we need here is an NSS module for doing DNS against normal Android DNS stuff. See code in bionic marked with #ifdef ANDROID_CHANGES.
We need something to connect the Android and Debian init systems so that Debian's daemons get started.
Permission denied errors
If you are finding that even after running 'su' you are running into 'permission denied' errors, this is because the 'su' included on the G1 is broke. You'll need to either run all these commands via adb (in the android SDK), or download the fixed version of 'su'.
(09:38:29 PM) JesusFreke: http://www.jesusfreke.com/su.zip (09:39:00 PM) JesusFreke: download, unzip, and suid it
Sockets for non-root users:
New users within the debian root cannot by default do anything that involves the network. Adding said users (as root) to a group with an id of 3003 will give them this access.
# groupadd -g 3003 sockets usermod -G sockets username