Paolo Sammicheli’s Blog

Sex, Ubuntu and Rock and Roll!

Jaunty under Android.

Posted by Paolo Sammicheli on May 3, 2009

About one month ago I bought an HTC Dream aka G1. I started to play with Android and I think it’s pretty cool.

After few hours I had it in my hands I started to look for information about how to hack it, and I found a lot of useful sources. I got Root on it, and then I installed the Jesus Freke’s version of Android. I was also able to install Debian on the Micro SD Card, and it was a lot of fun. Now Jaunty is out, and we have ARM port available, so I was wondering if it’s possible to install Ubuntu under Android like Debian does. With an useful explanation about how to build an ARM image using debootstrap with Debian I started to build mine with Ubuntu repository.


Warning: I suggest to try it only if you’re an experienced user with Android Hacking.

What you need:

  • You need a Rooted G1 with a community build of Android.
  • I tested it with JesusFreke’s v1.50 but it should works with any Apps_to_SD version
  • You need an Apps_to_SD version. In other words you need to make an ext2 partition on your Micro SD Card. Further info.

Go on my site and download the two files:

unpack the tar.gz on your ext2 partition. If you have a JF or an Haykuro version it should be mounted on /system/sd

Now you will have a /system/sd/ubuntu folder with a Jaunty ARM image. That Ubuntu image is built with ubuntu-minimal package.

Then copy startubuntu script in/system/sd folder. Umount SDCard from computer and move on the phone keyboard.

With terminal emulator type:

  • cd /system/sd
  • su
  • ./startubuntu

Now you will have an Ubuntu Minimal enviroment chrooted under Android’s Linux kernel. You can go ahead installing a full Desktop Enviroment. You can also use abd shell from your computer for a better typing. 😉

Note: probably the image should be polished. Patches are welcome! 🙂

70 Responses to “Jaunty under Android.”

  1. coguar said

    Nice device, GL with Ubuntu port…

  2. drubin said

    Thanks. Always looking for info on Android

  3. […] la web de Paolo Sammicheli tenéis un par de fotografía más para los curiosos, así como las instrucciones para los más […]

  4. good job!

  5. […] Now Jaunty is out, and we have ARM port available, so I was wondering if it’s possible to install Ubuntu under Android like Debian does. With an useful explanation about how to build an ARM image using debootstrap with Debian I started to build mine with Ubuntu repository. Read more here […]

  6. AWESOME! I was struggling with the Debian install instructions out there. THIS was cake. I’d rather have Ubuntu anyway, as I’m eager to see if netbook remix works on the G1. Thanks for sharing this!

  7. […] Jaunty under Android. About one month ago I bought an HTC Dream aka G1. I started to play with Android and I think it’s pretty […] […]

  8. Ubuntu Jaunty 9.04 sur un HTC Dream…

    Paolo Sammicheli nous gratifie d’un billet[1] suite a ses essais avec le téléphone HTC Dream qui est livré d’origine sous le système de Google, Android. Forcément cet amoureux d’Ubuntu n’a pu résister longtemps et s’est immédiatement mis en tête d…

  9. Hi, cool post. I have been wondering about this topic,so thanks for writing. I will definitely be coming back to your site. Keep up the good work

  10. […] Paolo’s first root […]

  11. […] I followed this guide based on Debian and I installed LXDE over the Ubuntu Minimal installation I prepared yesterday. All it’s pretty easy to […]

  12. […] on you G1. If you’re feeling brave and you know what you’re doing, check out the how to here and here. The instructions seem pretty straight forward. If anyone else does this please comment […]

  13. Anonymous said

    How did you create the ubuntu tar file?


    • To creare the Ubuntu image I used this guide about debian and I adapted for Ubuntu.

      You just have to change the first debootstrap command with:

      debootstrap –verbose –arch armel –foreign jaunty ubuntu

      Btw, it’s not a newbie stuff, that’s why i published a ready tarball.

      Next week, if I found time, I will publish a full guide about how to build that image.

  14. […] on you G1. If you’re feeling brave and you know what you’re doing, check out the how to here and here. The instructions seem pretty straight forward. If anyone else does this please comment […]

  15. […] Sammicheli: Jaunty under Android. This Planet Ubuntu member got the latest version of Ubuntu working on his G1 phone. And as far as […]

  16. Enrique said

    Can you still use the phone after installing jaunty?

  17. Maxis said

    My opinion that Android is the most promising platform

  18. Academic said

    Nice work man, big thanks!

  19. When I run the last command (./startubuntu) I get the error: “Permission denied” (No, I didn’t forgot to use su)

    • Do startubuntu has permission for execution? Check with ls -l and add it in case with chmod. Let me know

      • I thought that root would have always all rights.
        Chmod 777 solved that problem, but now it shows other error:
        B3: not found
        ep: not found]6aoU1^o,y.+j~~x
        ./startubuntu: 1: Syntax error: Bad fd number

      • What strange problem. Check content of startubuntu scripts. It seems bad downloaded files. Try also the commands inside the script step by step. They are just few lines.
        Try shell from adb from easy typing.

        Sorry for typos but i’m from G1 right now 😉

    • markus said

      try “sh startubuntu” instead of ./startubuntu

  20. blake said

    this newbie is willing to brick his phone for jaunty on his g1. please give a guide. please.

    • Who is willing to brick is phone? I Answered all questions in this post.

      Btw I repeat my disclaimer: «Warning: I suggest to try it only if you’re an experienced user with Android Hacking.»

  21. blake said

    I’ve been here all the way since some one figured out root. I’ve done themese and all the good stuff. With the engineers bootloader, I’m fairly confident that whatever I may mess up I can fix. Plus I just dropped this thing in a cup of water lastweek and it still lives. I need a reason to. Buy the i7500 when it comes out. My problem is the tarbal. I’m trying like hell to extract it. I’m sure its something else. But I think ill be fine after that. Thanks.

  22. Andrew said

    Seems like your hosting of the files has gone down. Any idea when it’ll be back up so I can just grab the ready made tarball?

  23. mexedi said

    Good! Thx!

  24. […] für den Laien nicht unbedingt verständlich, hat er hier und hier ein paar Informationen zu seiner Vorgehensweise veröffentlicht. Tags: G1, Linux, […]

  25. thanks this post. I made some adjustments

  26. Eric said

    I decompressed the tar.gz, but my G1 can’t seem to boot ubuntu with the script. does ubuntu.tar need to be extracted?

    ran the scripts manually in term, after running “mount -t devpts devpts $mnt/dev/pts” I am returned with this error: “mount: mounting devpts on /system/sd/ubuntu/dev/pts failed: No such file or directory” when I looked inside /ubuntu/dev I don’t see a file named ‘pts’. I did see ‘ptmx’, is that what it’s looking for?
    What am I doing wrong here?

  27. alex said

    Now since you have ubuntu running can you use the skype client and the firefox with flash enabled?
    Thank you

  28. […] […]

  29. RichieDaze said

    I have Debian installed on my G1. Would I have to Uninstall Debian before Installing Ubuntu?

  30. Squel said

    I untar ubuntu to my ext2 partition, when I run a script startubuntu i get a strange error.
    Error: “chroot: cannot execute /bin/bash: Permission denied”

    • Are you doing it with root permitions? Also check that /bin/bash has execution attributes (It should have)

    • h3x said

      I myself was having problems with “startubuntu” and it was saying cannot execute /bin/bash. Im new to linux so i simply did some research and found that unzipping the files and moving them with windows was causing the problem. I logged into my Samurai webtesting framework (linux) Booted up console.. obtained root with the |sudo su| command.. used command line to extract tar with root permissions.. |cd Desktop| (where the ubuntu was extracted) and |mv -i ubuntu /media/android| now when i start ubuntu everything is nice and crisp. By the way it would be nice if someone could port something like neopwn to G1. maybe one of thses distros?? one has to be debian or ubuntu based so wouldnt be much work right?

  31. […] anyone tried running Ubuntu Jaunty, or any GNU/Linux distribution for that matter, on this phone? This post is very interesting, and this one has allot of good information. So, any luck doing this on the […]

  32. fei said

    Hi Paolo:

    I try to use qemu to simulate the arm cpu and use your tarball as filesystem, it pops up the user name and password, would you advise me the username and password for your tar ball

  33. Marbd said

    ./startubuntu: not found :S

  34. manu said

    Does it work with htc my touch?

    • It should work. I can’t confirm it because i haven’t that device.

      • manu said


        I just wanted to tell you that I’ve tried in my htc magic with cyanogenmod 4.1.5 and it works perfectly!!

        Good job mate!!

        btw apart of the vnc and desktop option…. has someone setup something “really good” on it’s htc?

        congrat again mate!


  35. Sturmeh said

    Works great on Cyanogenmod!

    Note you’ll need to kill any dameons you start manually even after exiting, or just reboot the phone… 🙂

    I installed openssh, and the dameon continued to run after I did an ‘exit’ and attempting to connect to it resulted in it instantly crashing the session, which is no problem because ubuntu had been unmounted.

    I’ve got a question though, if I run ./startubuntu and then close terminal without typing exit, with the intention of keeping the file system mounted, (for ssh) how do I return to the ubuntu shell? Should I just run ./startubuntu again and ignore the 3 mount errors?

    • After playing with it I suggest to reboot the phone to clean up everythings 🙂

      About the question: exactly, Startubuntu just mount file systems, so if you already did it you can ignore the warning and gain a new shell starting the script again. Or, if you want to do a clean shell start, doing the chroot command you find in the last line of startubuntu script.

      • Sturmeh said

        Yeah I seem to need to reboot after playing with it.

        I got gcc working on it, pretty cool how you have a c/++ compiler let alone a linux shell on it. 🙂

        Also I added universe repo and it took ages to apt-get update, but I managed to grab cmatrix and try running that, it displays green and and glorious but a bit laggy, oh well. 😛

        It’s not exactly fast ( or optimised? ) but it’s still pretty cool.

        I’ll keep it on my apps2sd partition until I need more space or I realise it’s taking up too much space haha.

  36. Sturmeh said

    I’m not describing any problems though… :\

    I was just saying the dameons run after I unmount ubuntu, so I need to be sure to kill them after exiting.

    Also how should I exit if I forgot to exit and I closed Terminal?

  37. Lakrymist said

    Can u re-add another .tar this one is corrupted. I have tried to manage it in both vista and ubuntu. Thanx.

    • Forget to make it working in Vista. No way to untar it in a Micro$oft file system without losing file attributes.

      Using Ubuntu you may notice a warning relating the creation of few nodes. Just ignore it, they are related to device directory that it’s not used while under Android (it will use Android Kernel, not Ubuntu Kernel).

      And again, if you’re not an *experienced* user with Ubuntu, shell, and so on, just don’t do it. It’s a more a haking proof-of-concept than a thing for end user.

  38. Lakrymist said

    its not that. the compressed folder is corrupted m8. i got that error on all unzippers. it ends up with 26mb less than its supposed to. 😦

  39. Lakrymist said

    Wicked man i got it to work using #sh startubuntu great work.

  40. markus said

    I have a question about this. Does anyone have problems when phone us using wifi connetion? Seems ubuntu cannot connect to internet while wifi is in use. I can do ifconfig, and it shows my lan IP address, but cannot even ping google etc… If i disconnect wifi, and use data connection from tmobile, it works fine but is slow (we havent got 3g yet)

    tightvnc and lxde taking forever to install :/

  41. […] […]

  42. […] […]

  43. mike said

    hi i installed it nice and easy on a tmobile pulse, i went to try install icewm desktop but when i try to apt-get install tightvncserver or apt-get install icewm i just get could not find package? is there a solution to this or another tutorial that will get it running ?

  44. almyz125 said

    hi, i downloaded the files and i get errors while extracting the archive, i am using ubuntu 9.10 to extract the archive. i went ahead and tried to run it even with the errors, and of course it did not work. i was just wondering if i am extracting the files wrong, or if the archive is corrupt?

  45. gzwalter79 said

    Ubuntu 9.04 runing on other HTC Device (like Rhodium)

  46. Dark Matter said

    Just got this working on a rooted Samsung Behold II running BH_MAN’s stock behold II tweaked ROM (1.6). Worked great!! Instructions are pretty much the same too. Next up is an ARM version of ubuntu 10.04…. that might take some time, but your blog got me on the right track. Thanks!!

Leave a Reply

Fill in your details below or click an icon to log in: Logo

You are commenting using your account. Log Out /  Change )

Google photo

You are commenting using your Google account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s

%d bloggers like this: