Got My Xoom running Debain native (without chroot)

Search This thread

LIV2

Member
May 26, 2011
37
62
Sydney
Hey all,

I've installed Debian on my Xoom with the help of a few kernel patches applied to the Tiamat Sources and thought I'd share.

I can't post in the development section because I don't have enough posts. (Admin edit: Now in Development!)



I've got a full writeup of the process of installation from the ground up below
I'll be uploading the rootfs and boot.img for it when I get a chance, but i just thought some people would be interested to know that it is indeed possible (without VNC or Chroot...)

WiFi works under linux when you manually run wpasupplicant, the modem is detected by network-manager automatically and I've gotten the touchscreen working so it's actually pretty usable. no sound or graphics acceleration though as they rely on binary blobs from Nvidia.

Cheers,
Matt
 
Last edited by a moderator:

LIV2

Member
May 26, 2011
37
62
Sydney
Hey all,

I've seen a lot of people running linux on their android devices but chrooted under android and using a VNC client to make use of the chrooted install. quite messy and less than efficient IMHO, so I set out to install it natively on my Xoom

I've managed to get Debian installed on my Xoom with the only issues being no sound and no Bluetooth, this is due to the proprietary nature of the sound drivers for the Tegra, and the lack of documentation for the BCM4329 Bluetooth under linux. if anyone has any tips with these I'd love to hear them.

Anyway, since the Xoom is an android device with an unlockable bootloader from the factory this wasn't too difficult. the only issues were with the TegraFB and Touchscreen drivers. Thankfully Lilstevie from GalaxyLinux helped me out with the touchscreen driver and Robert Morell from NVidia provided a patch to Chromium for the FB which is here http://codereview.chromium.org/6672056

(Todo: Add guide for using WIFI, upload prebuilt images)
(Update: Fixed the links)

Basically all you need to do is build a root fs and a kernel for your Debian install. this is actually quite easy. here's how..

Contents:

Requirements
Building the RootFS
Building the Kernel
Preparing the SDCard
Putting it all together
Rolling back to Android
Acknowledgements

Disclaimer

YOU DO THIS AT YOUR OWN RISK! I TAKE NO RESPONSIBILITY FOR ANY DAMAGES TO YOU, YOUR DEVICE,
YOUR COMPUTER, OR ANY OF YOUR PROPERTY OR SOMEONE ELSE'S PROPERTY


Requirements

  1. A Rooted Xoom with ClockWorkRecovery Installed
    [*] Make sure you have a nandroid backup. you will need this to boot back into Android!
  2. A running install of Debian, Ubuntu might work too
  3. An SDCard with at least 4GB for the install, preferably separate from your main SDCard and an SDCard reader for your PC
  4. Android–SDK
  5. An Arm–linux toolchain to compile the kernel, if you're lazy like me you can just use the one that comes with the Android NDK
  6. This Xorg Config
  7. Kernel sources
  8. Fastboot tool
  9. mkbootimg

Building the RootFS

Before we do anything we'll need to get the Wifi Firmware off the default install of Android

To do this run the following commands
Code:
    # adb pull /system/vendor/firmware/fw_bcm4329.bin
    # adb pull /system/etc/firmware/bcm4329.hcd

MAKE A BACKUP OF YOUR SDCARD AND YOUR XOOM USING CLOCKWORK RECOVERY BEFORE CONTINUING AND KEEP IT SOMEWHERE SAFE!

Now lets install the tools you'll need to create the rootfs

Code:
    # apt–get install binfmt–support qemu qemu–user–static debootstrap

Once that's done, make a directory for the rootfs to sit in until it's ready for the SDCard and start installing the debian base

Code:
  # cd ~
    # mkdir deb_arm
    # mkdir deb_arm/boot
    # sudo /usr/sbin/debootstrap ––foreign ––arch armel squeeze deb_arm/ [url]http://ftp.au.debian.org/debian[/url]
Once that's done you'll need to copy across some qemu files so you can chroot into the deb_arm folder and finish the installation of the base system

Code:
    # sudo cp /usr/bin/qemu–arm–static deb_arm/usr/bin
    # sudo chroot deb_arm
    # export LC_ALL=C
    # export LANGUAGE=C
    # export LANG=C
    # cd /debootstrap
    # ./debootstrap ––second–stage

once that's done you'll need to edit your apt sources, to do so run the following

Code:
    # echo debandroid > /etc/hostname
    # echo "deb [url]http://ftp.debian.org/debian/[/url] squeeze main contrib non–free" > /etc/apt/sources.list
    # apt–get update
And then install any of the apps you'll want to run on your xoom, I'd recommend at least xorg, gdm3 and gnome, so

Code:
    # apt–get install xserver–xorg–video–fbdev xserver–xorg–input–evdev gdm3 gnome initramfs–tools wpa-supplicant
You may find that you get an error like the following

Errors were encountered while processing: bluez gnome–bluetooth gnome–user–share gnome–desktop–environment

If you do, it's safe to ignore this for now. you can always complete the installation of any non–critical packages on the device. it seems to be something weird with the chroot or the qemu emulation of ARM (if anyone knows a way to fix this I'd be glad to hear it!)

Once that's done, you'll not only want to set your root password but you'll want to add a standard user account too
Code:
    # passwd root
    # adduser liv2
    # addgroup ––gid 3003 inet
    # usermod –aG 3003 liv2
The addgroup and usermod are especially important, the android kernel doesn't normally allow network access to non–root accounts. so we have to add the special group then give the user access to that group (or you could compile the kernel to not use the android paranoid network settings)

Once that's done, exit out of the chroot by hitting CTRL+D and copy the xorg config to deb_arm/etc/X11/ and copy in the wireless firmware you copied at the start

Code:
# mkdir ~/deb_arm/lib/firmware
# cp ~/fw_bcm4329.bin ~/deb_arm/lib/firmware
# cp ~/bcm4329.cal ~/deb_arm/lib/firmware


Building the Kernel

For this part, make sure you've extracted the kernel sources, and the android–ndk to somewhere, in my case they've been extracted in ~/Downloads
Code:
    # cd ~/Downloads/Tiamat–AOSP–Tiamat–Xoom–798572c/
    # export CROSS_COMPILE=~/Downloads/android–ndk–r5b/toolchains/arm–eabi–4.4.0/prebuilt/linux–x86/bin/arm–eabi–

    # export ARCH=arm
    # export INSTALL_PATH=~/deb_arm/boot
    # export INSTALL_MOD_PATH=~/deb_arm
    # make tiamat_defconfig
    # make menuconfig

Once you've got the menuconfig screen up, go to Device Drivers > Character Devices > and enable "Virtual Terminal"
go to Device Drivers > Graphics Support > Console Display Driver support > enable "Framebuffer Console Support"

once you've enabled that, exit out and save the changes

Build the kernel and prepare it for use

Code:
    # make –j2
    # sudo make modules_install
    # sudo cp arch/arm/boot/zImage ~/deb_arm/boot
    # cp System.map ~/deb_arm/boot/
    # chroot ~/deb_arm
    # mkinitramfs –o /boot/initrd.img.gz `ls /lib/modules`

mkinitramfs may show some warnings like "warning: can't open /etc/mtab:" and "pkg: version '2.6.36.4Tiamat_Xoom–v1.4.4–Full_Throttle' has bad syntax: invalid character in version number" but it doesn't seem to have caused any issues for me.
Preparing the SDCard

Plug your SDCard reader into your computer and insert the card, you'll then need to partition and format it so make sure you've backed up the content of the card.

Partition it so you have two partitions, the first one being a FAT32 Partition for CWR and for anything you might want to use it for under Android.

Your second partition will need to be EXT3 and big enough to fit your debian install with some room to breathe (about 4GB in my case), you can check how much space you'll need for this by running du -sh ~/deb_arm

Once you've partitioned it, format the first partition as FAT32 and the second partition as EXT3. once you've done that you should put the SDCard back in your Xoom and make a new nandroid backup just to be sure
Code:
    # sudo mkfs.ext3 /dev/sdb2
    # sudo mkfs.msdos /dev/sdb1

Putting it all together

First we'll mount the SDCard on your PC and copy across the Root FS

# sudo mkdir /mnt/sdcard
# sudo mount /dev/sdb2 /mnt/sdcard
# sudo cp -arv ~/deb_arm/* /mnt/sdcard/
# umount /mnt/sdcard

Go to the folder you unpacked mkbootimg to and copy in the boot.img from your CWR backup.

Once you've done that, follow the below steps to create the new boot.img for Debian to use

Code:
    # cd ~/Downloads/mkbootimg
    # cp ~/deb_arm/boot/zImage .
    # cp ~/deb_arm/boot/initrd.img.gz .
    # mkdir out
    # ./unpackbootimg –i boot.img –o out/
    # ./mkbootimg ––kernel zImage ––ramdisk initrd.img.gz ––base "`cat out/boot.img–base`" \
    ––cmdline "root=/dev/mmcblk0p2 console=tty0" –o newimg.img

Now reboot your Xoom into Fastboot mode and insert the SDCard, this can be done by holding power + volume up until the screen goes black, then power it back on and hold down the volume down key
Code:
    # cp ~/Downloads/fastboot .
    # ./fastboot flash boot newimg.img
    # ./fastboot reboot

Your Xoom should now boot up into Debian, on the login screen select the accessibility options and enable on-screen keyboard to log in.
Alternatively, if you happen to have a USB-OTG adapter you can just use a keyboard and mouse to interact with the system.
Going Back to Android

To Roll back to Android, simply boot into Clockwork Recovery, go to Backup/Restore > Advanced Restore and restore boot.img only, reboot and you'll be back in Android

Acknowledgements

Lopi from the IX Project was a great help, and so was everyone from #IX
Lilstevie from @GalaxyLinux provided the Touchscreen patches
Framebuffer Patch was originally provided by Robert Morell for the Chromium Project
RootFS instructions are based on info at the Debian Wiki
 
Last edited:
G

gqstatus0685

Guest
Reserved. Awesome. Hey OP just bump this thread to get your post count up so you can post this in developement. I was looking for an alternative that didn't require vnc.



Sent from my PC36100 using XDA App
 

LIV2

Member
May 26, 2011
37
62
Sydney
I've asked a mod to move it now, I think I have the required postcount now anyway.

Just to note, you should be able to install Ubuntu, Gentoo, Fedora etc as long as you can build the root and the initrd for it.

If you do go through with this, be sure to post here! I'd love to see some ubuntu or gentoo or anything running on people's xooms really.

Also, I'm currently uploading a video I made showing how usable it really is
Cheers
 
  • Like
Reactions: cmsman13

Kippui

Senior Member
Jan 1, 2011
595
37
Another reason xoom is a great tablet. I'm not linux savvy so I hope this becomes much easier in the future.
 

Kippui

Senior Member
Jan 1, 2011
595
37
Actually, you kinda can!

If you don't need 3G support under Linux, you can flash the boot.img to the recovery partition and boot it that way.

If you need to use CWR later you can just restore the partition from a backup

Can you post a pre configured build for users that dont know much about linux can use once you get sound working?
 

LIV2

Member
May 26, 2011
37
62
Sydney
Unfortunately it's not likely I'll get the sound working due to the proprietary nature of the sound drivers. I should be able to upload the prebuilt packages soon though.
 

kuroguy

Senior Member
Apr 28, 2011
89
28
Isn't sound support typically built into the kernel or at least built as a kernel module? Is there something i'm missing?
 
Last edited:
  • Like
Reactions: swbf2lord

LIV2

Member
May 26, 2011
37
62
Sydney
Hey,

The problem with the sound is the same reason there is no GPU Acceleration, it requires proprietary support from NVidia binary blobs that I don't have.

It's possible I will be able to get it going properly once they release the next Linux4Tegra, but I'm not sure.
 

equid0x

Senior Member
Jan 18, 2009
60
15
I've tried to get this going with Gentoo all weekend. I can't seem to get any boot.img to boot on the Xoom once flashed (just stays frozen at the Moto logo). Apparently fastboot boot is locked out as well so I am unable to get any debug info on screen...
 

LIV2

Member
May 26, 2011
37
62
Sydney
Hey equid0x

I'd be glad to help

Did you make sure to enable vt support in your kernel and set console=tty0 in your boot parameters?

Is it rebooting itself when you try to use your boot.img? if so make sure your initrd is being stored in the SRV4 format, you can do this by gunziping it then type file initramdisk.img which will tell you the version.

if that doesn't help let me know
 

LIV2

Member
May 26, 2011
37
62
Sydney
looks like i left out a step in the kernel config section

which is "go to Device Drivers > Graphics Support > Console Display Driver support > enable "Framebuffer Console Support" " after enabling VT Support

I've updated the OP now.
 

ruqqq

Senior Member
Oct 12, 2008
526
1,255
hi LIV2, interesting stuff you're working on here. i'm not sure if you're aware, if you aren't this is gonna be a good news most likely: http://phoronix.com/forums/showthread.php?56505-Linux-for-Tegra-release-12-alpha-1-Released

I believed there are binary blobs inside the package (haven't got the time to look at it), but there might be kernel changes needed to make it work too. I'm not sure as I'm not an expert in this area. But hopefully, this would realize a full blown linux OS on our Xoom.
 

Hyperion82

Senior Member
Apr 26, 2010
118
6
Adelaide
Hebrew + Easy Dual Boot + Awesomeness :)

Well aint this something !!!

Have been waiting for this type of functionality for a long time !!! This absolutely awesome !! :)

So first of all - THANK YOU !
Second of all - Is there any chance you could include hebrew package with the RTL support ?

P.S : the dual boot idea is cool, but is there a way to make the device just boot into linux with a click on an icon ? (I mean run an app from android that'll reboot the tab into debian)
 

eldarerathis

Senior Member
Jun 21, 2010
159
316
Firstly: this is awesome. Thank you for putting this how-to together. I've been wanting to boot Linux natively off my Xoom pretty much since the day I got it.

I originally tried to set up the chroot environment on Fedora and had all kinds of weird issues with the packages. I'm not sure if it was me or Fedora, but I ended up doing it in an Ubuntu VM instead and it worked out fine. Ultimately I'd like to actually get Fedora on the Xoom (maybe Ubuntu if I can get Unity to behave; the interface could be nice with a touchscreen).

Also, a question: How did you get your wifi set up? You noted that wpa_supplicant would work but I don't even seem to have a wifi interface present unless it has a name other than wlanX. It's not the usb0 interface, is it? My 3G adapter seems like it's recognized in the NM applet but I don't have a data plan, so it doesn't do me much good.

Lastly, I'll add a picture to the collection. Nothing super exciting - this is XFCE running on top of Debian. I've never been a big fan of GNOME and I figured it might be a little snappier :p

IMG_20110628_170358.jpg
 

LIV2

Member
May 26, 2011
37
62
Sydney
hi LIV2, interesting stuff you're working on here. i'm not sure if you're aware, if you aren't this is gonna be a good news most likely: http://phoronix.com/forums/showthread.php?56505-Linux-for-Tegra-release-12-alpha-1-Released

I believed there are binary blobs inside the package (haven't got the time to look at it), but there might be kernel changes needed to make it work too. I'm not sure as I'm not an expert in this area. But hopefully, this would realize a full blown linux OS on our Xoom.

Awesome :)

I've compiled a kernel with the audio components from the L4T Kernel sources but they don't seem to include codec support for the Xoom, I'm still playing around with this
However that is going to hopefully help with GPU support :D

Well aint this something !!!

Second of all - Is there any chance you could include hebrew package with the RTL support ?

P.S : the dual boot idea is cool, but is there a way to make the device just boot into linux with a click on an icon ? (I mean run an app from android that'll reboot the tab into debian)

I'll see what I can find re: language. shouldn't be too difficult, it'd just be a few different steps
As for the dualboot idea, it'd be possible to do so but I'm no coder :p
All it'd require is dding the boot img from within android, not sure how the NAND would hold up to constant rewrites though

Firstly: this is awesome. Thank you for putting this how-to together. I've been wanting to boot Linux natively off my Xoom pretty much since the day I got it.

I originally tried to set up the chroot environment on Fedora and had all kinds of weird issues with the packages. I'm not sure if it was me or Fedora, but I ended up doing it in an Ubuntu VM instead and it worked out fine. Ultimately I'd like to actually get Fedora on the Xoom (maybe Ubuntu if I can get Unity to behave; the interface could be nice with a touchscreen).

Also, a question: How did you get your wifi set up? You noted that wpa_supplicant would work but I don't even seem to have a wifi interface present unless it has a name other than wlanX. It's not the usb0 interface, is it? My 3G adapter seems like it's recognized in the NM applet but I don't have a data plan, so it doesn't do me much good.

Lastly, I'll add a picture to the collection. Nothing super exciting - this is XFCE running on top of Debian. I've never been a big fan of GNOME and I figured it might be a little snappier :p


Awesome!

Something I have to add to the guide is the wifi, to do this you should have the module for bcm4329 in your /lib/modules somewhere
so to use it, run modprobe bcm4329 nvram_path=/lib/firmware/bcm4329.cal firmware_path=/lib/firmware/fw_bcm4329.bin

then you should see the interface as eth0

you'll need to make sure your wpa_supplicant conf has ap_scan=1 and fast_reauth=1 set, otherwise it won't find any APs
 

eldarerathis

Senior Member
Jun 21, 2010
159
316
Awesome!

Something I have to add to the guide is the wifi, to do this you should have the module for bcm4329 in your /lib/modules somewhere
so to use it, run modprobe bcm4329 nvram_path=/lib/firmware/bcm4329.cal firmware_path=/lib/firmware/fw_bcm4329.bin

then you should see the interface as eth0

you'll need to make sure your wpa_supplicant conf has ap_scan=1 and fast_reauth=1 set, otherwise it won't find any APs

D'oh, I didn't even think to try running modprobe, I just assumed it was loaded :eek: That was the ticket, and wireless is working great (posting from the Debian install now!).

Looks like it's play time for me...thanks again!
 

Top Liked Posts

  • There are no posts matching your filters.
  • 31
    Hey all,

    I've installed Debian on my Xoom with the help of a few kernel patches applied to the Tiamat Sources and thought I'd share.

    I can't post in the development section because I don't have enough posts. (Admin edit: Now in Development!)



    I've got a full writeup of the process of installation from the ground up below
    I'll be uploading the rootfs and boot.img for it when I get a chance, but i just thought some people would be interested to know that it is indeed possible (without VNC or Chroot...)

    WiFi works under linux when you manually run wpasupplicant, the modem is detected by network-manager automatically and I've gotten the touchscreen working so it's actually pretty usable. no sound or graphics acceleration though as they rely on binary blobs from Nvidia.

    Cheers,
    Matt
    20
    Hey all,

    I've seen a lot of people running linux on their android devices but chrooted under android and using a VNC client to make use of the chrooted install. quite messy and less than efficient IMHO, so I set out to install it natively on my Xoom

    I've managed to get Debian installed on my Xoom with the only issues being no sound and no Bluetooth, this is due to the proprietary nature of the sound drivers for the Tegra, and the lack of documentation for the BCM4329 Bluetooth under linux. if anyone has any tips with these I'd love to hear them.

    Anyway, since the Xoom is an android device with an unlockable bootloader from the factory this wasn't too difficult. the only issues were with the TegraFB and Touchscreen drivers. Thankfully Lilstevie from GalaxyLinux helped me out with the touchscreen driver and Robert Morell from NVidia provided a patch to Chromium for the FB which is here http://codereview.chromium.org/6672056

    (Todo: Add guide for using WIFI, upload prebuilt images)
    (Update: Fixed the links)

    Basically all you need to do is build a root fs and a kernel for your Debian install. this is actually quite easy. here's how..

    Contents:

    Requirements
    Building the RootFS
    Building the Kernel
    Preparing the SDCard
    Putting it all together
    Rolling back to Android
    Acknowledgements

    Disclaimer

    YOU DO THIS AT YOUR OWN RISK! I TAKE NO RESPONSIBILITY FOR ANY DAMAGES TO YOU, YOUR DEVICE,
    YOUR COMPUTER, OR ANY OF YOUR PROPERTY OR SOMEONE ELSE'S PROPERTY


    Requirements

    1. A Rooted Xoom with ClockWorkRecovery Installed
      [*] Make sure you have a nandroid backup. you will need this to boot back into Android!
    2. A running install of Debian, Ubuntu might work too
    3. An SDCard with at least 4GB for the install, preferably separate from your main SDCard and an SDCard reader for your PC
    4. Android–SDK
    5. An Arm–linux toolchain to compile the kernel, if you're lazy like me you can just use the one that comes with the Android NDK
    6. This Xorg Config
    7. Kernel sources
    8. Fastboot tool
    9. mkbootimg

    Building the RootFS

    Before we do anything we'll need to get the Wifi Firmware off the default install of Android

    To do this run the following commands
    Code:
        # adb pull /system/vendor/firmware/fw_bcm4329.bin
        # adb pull /system/etc/firmware/bcm4329.hcd

    MAKE A BACKUP OF YOUR SDCARD AND YOUR XOOM USING CLOCKWORK RECOVERY BEFORE CONTINUING AND KEEP IT SOMEWHERE SAFE!

    Now lets install the tools you'll need to create the rootfs

    Code:
        # apt–get install binfmt–support qemu qemu–user–static debootstrap

    Once that's done, make a directory for the rootfs to sit in until it's ready for the SDCard and start installing the debian base

    Code:
      # cd ~
        # mkdir deb_arm
        # mkdir deb_arm/boot
        # sudo /usr/sbin/debootstrap ––foreign ––arch armel squeeze deb_arm/ [url]http://ftp.au.debian.org/debian[/url]
    Once that's done you'll need to copy across some qemu files so you can chroot into the deb_arm folder and finish the installation of the base system

    Code:
        # sudo cp /usr/bin/qemu–arm–static deb_arm/usr/bin
        # sudo chroot deb_arm
        # export LC_ALL=C
        # export LANGUAGE=C
        # export LANG=C
        # cd /debootstrap
        # ./debootstrap ––second–stage

    once that's done you'll need to edit your apt sources, to do so run the following

    Code:
        # echo debandroid > /etc/hostname
        # echo "deb [url]http://ftp.debian.org/debian/[/url] squeeze main contrib non–free" > /etc/apt/sources.list
        # apt–get update
    And then install any of the apps you'll want to run on your xoom, I'd recommend at least xorg, gdm3 and gnome, so

    Code:
        # apt–get install xserver–xorg–video–fbdev xserver–xorg–input–evdev gdm3 gnome initramfs–tools wpa-supplicant
    You may find that you get an error like the following

    Errors were encountered while processing: bluez gnome–bluetooth gnome–user–share gnome–desktop–environment

    If you do, it's safe to ignore this for now. you can always complete the installation of any non–critical packages on the device. it seems to be something weird with the chroot or the qemu emulation of ARM (if anyone knows a way to fix this I'd be glad to hear it!)

    Once that's done, you'll not only want to set your root password but you'll want to add a standard user account too
    Code:
        # passwd root
        # adduser liv2
        # addgroup ––gid 3003 inet
        # usermod –aG 3003 liv2
    The addgroup and usermod are especially important, the android kernel doesn't normally allow network access to non–root accounts. so we have to add the special group then give the user access to that group (or you could compile the kernel to not use the android paranoid network settings)

    Once that's done, exit out of the chroot by hitting CTRL+D and copy the xorg config to deb_arm/etc/X11/ and copy in the wireless firmware you copied at the start

    Code:
    # mkdir ~/deb_arm/lib/firmware
    # cp ~/fw_bcm4329.bin ~/deb_arm/lib/firmware
    # cp ~/bcm4329.cal ~/deb_arm/lib/firmware


    Building the Kernel

    For this part, make sure you've extracted the kernel sources, and the android–ndk to somewhere, in my case they've been extracted in ~/Downloads
    Code:
        # cd ~/Downloads/Tiamat–AOSP–Tiamat–Xoom–798572c/
        # export CROSS_COMPILE=~/Downloads/android–ndk–r5b/toolchains/arm–eabi–4.4.0/prebuilt/linux–x86/bin/arm–eabi–
    
        # export ARCH=arm
        # export INSTALL_PATH=~/deb_arm/boot
        # export INSTALL_MOD_PATH=~/deb_arm
        # make tiamat_defconfig
        # make menuconfig

    Once you've got the menuconfig screen up, go to Device Drivers > Character Devices > and enable "Virtual Terminal"
    go to Device Drivers > Graphics Support > Console Display Driver support > enable "Framebuffer Console Support"

    once you've enabled that, exit out and save the changes

    Build the kernel and prepare it for use

    Code:
        # make –j2
        # sudo make modules_install
        # sudo cp arch/arm/boot/zImage ~/deb_arm/boot
        # cp System.map ~/deb_arm/boot/
        # chroot ~/deb_arm
        # mkinitramfs –o /boot/initrd.img.gz `ls /lib/modules`

    mkinitramfs may show some warnings like "warning: can't open /etc/mtab:" and "pkg: version '2.6.36.4Tiamat_Xoom–v1.4.4–Full_Throttle' has bad syntax: invalid character in version number" but it doesn't seem to have caused any issues for me.
    Preparing the SDCard

    Plug your SDCard reader into your computer and insert the card, you'll then need to partition and format it so make sure you've backed up the content of the card.

    Partition it so you have two partitions, the first one being a FAT32 Partition for CWR and for anything you might want to use it for under Android.

    Your second partition will need to be EXT3 and big enough to fit your debian install with some room to breathe (about 4GB in my case), you can check how much space you'll need for this by running du -sh ~/deb_arm

    Once you've partitioned it, format the first partition as FAT32 and the second partition as EXT3. once you've done that you should put the SDCard back in your Xoom and make a new nandroid backup just to be sure
    Code:
        # sudo mkfs.ext3 /dev/sdb2
        # sudo mkfs.msdos /dev/sdb1

    Putting it all together

    First we'll mount the SDCard on your PC and copy across the Root FS

    # sudo mkdir /mnt/sdcard
    # sudo mount /dev/sdb2 /mnt/sdcard
    # sudo cp -arv ~/deb_arm/* /mnt/sdcard/
    # umount /mnt/sdcard

    Go to the folder you unpacked mkbootimg to and copy in the boot.img from your CWR backup.

    Once you've done that, follow the below steps to create the new boot.img for Debian to use

    Code:
        # cd ~/Downloads/mkbootimg
        # cp ~/deb_arm/boot/zImage .
        # cp ~/deb_arm/boot/initrd.img.gz .
        # mkdir out
        # ./unpackbootimg –i boot.img –o out/
        # ./mkbootimg ––kernel zImage ––ramdisk initrd.img.gz ––base "`cat out/boot.img–base`" \
        ––cmdline "root=/dev/mmcblk0p2 console=tty0" –o newimg.img

    Now reboot your Xoom into Fastboot mode and insert the SDCard, this can be done by holding power + volume up until the screen goes black, then power it back on and hold down the volume down key
    Code:
        # cp ~/Downloads/fastboot .
        # ./fastboot flash boot newimg.img
        # ./fastboot reboot

    Your Xoom should now boot up into Debian, on the login screen select the accessibility options and enable on-screen keyboard to log in.
    Alternatively, if you happen to have a USB-OTG adapter you can just use a keyboard and mouse to interact with the system.
    Going Back to Android

    To Roll back to Android, simply boot into Clockwork Recovery, go to Backup/Restore > Advanced Restore and restore boot.img only, reboot and you'll be back in Android

    Acknowledgements

    Lopi from the IX Project was a great help, and so was everyone from #IX
    Lilstevie from @GalaxyLinux provided the Touchscreen patches
    Framebuffer Patch was originally provided by Robert Morell for the Chromium Project
    RootFS instructions are based on info at the Debian Wiki
    2
    Hey all,

    I've seen a lot of people running linux on their android devices but chrooted under android and using a VNC client to make use of the chrooted install. quite messy and less than efficient IMHO, so I set out to install it natively on my Xoom

    I've managed to get Debian installed on my Xoom with the only issues being no sound and no Bluetooth, this is due to the proprietary nature of the sound drivers for the Tegra, and the lack of documentation for the BCM4329 Bluetooth under linux. if anyone has any tips with these I'd love to hear them.

    Anyway, since the Xoom is an android device with an unlockable bootloader from the factory this wasn't too difficult. the only issues were with the TegraFB and Touchscreen drivers. Thankfully Lilstevie from GalaxyLinux helped me out with the touchscreen driver and Robert Morell from NVidia provided a patch to Chromium for the FB which is here http://codereview.chromium.org/6672056

    (Todo: Add guide for using WIFI, upload prebuilt images)
    (Update: Fixed the links)

    Basically all you need to do is build a root fs and a kernel for your Debian install. this is actually quite easy. here's how..

    Contents:

    Requirements
    Building the RootFS
    Building the Kernel
    Preparing the SDCard
    Putting it all together
    Rolling back to Android
    Acknowledgements

    Disclaimer

    YOU DO THIS AT YOUR OWN RISK! I TAKE NO RESPONSIBILITY FOR ANY DAMAGES TO YOU, YOUR DEVICE,
    YOUR COMPUTER, OR ANY OF YOUR PROPERTY OR SOMEONE ELSE'S PROPERTY


    Requirements

    1. A Rooted Xoom with ClockWorkRecovery Installed
      [*] Make sure you have a nandroid backup. you will need this to boot back into Android!
    2. A running install of Debian, Ubuntu might work too
    3. An SDCard with at least 4GB for the install, preferably separate from your main SDCard and an SDCard reader for your PC
    4. Android–SDK
    5. An Arm–linux toolchain to compile the kernel, if you're lazy like me you can just use the one that comes with the Android NDK
    6. This Xorg Config
    7. Kernel sources
    8. Fastboot tool
    9. mkbootimg

    Building the RootFS

    Before we do anything we'll need to get the Wifi Firmware off the default install of Android

    To do this run the following commands
    Code:
        # adb pull /system/vendor/firmware/fw_bcm4329.bin
        # adb pull /system/etc/firmware/bcm4329.hcd

    MAKE A BACKUP OF YOUR SDCARD AND YOUR XOOM USING CLOCKWORK RECOVERY BEFORE CONTINUING AND KEEP IT SOMEWHERE SAFE!

    Now lets install the tools you'll need to create the rootfs

    Code:
        # apt–get install binfmt–support qemu qemu–user–static debootstrap

    Once that's done, make a directory for the rootfs to sit in until it's ready for the SDCard and start installing the debian base

    Code:
      # cd ~
        # mkdir deb_arm
        # mkdir deb_arm/boot
        # sudo /usr/sbin/debootstrap ––foreign ––arch armel squeeze deb_arm/ [url]http://ftp.au.debian.org/debian[/url]
    Once that's done you'll need to copy across some qemu files so you can chroot into the deb_arm folder and finish the installation of the base system

    Code:
        # sudo cp /usr/bin/qemu–arm–static deb_arm/usr/bin
        # sudo chroot deb_arm
        # export LC_ALL=C
        # export LANGUAGE=C
        # export LANG=C
        # cd /debootstrap
        # ./debootstrap ––second–stage

    once that's done you'll need to edit your apt sources, to do so run the following

    Code:
        # echo debandroid > /etc/hostname
        # echo "deb [url]http://ftp.debian.org/debian/[/url] squeeze main contrib non–free" > /etc/apt/sources.list
        # apt–get update
    And then install any of the apps you'll want to run on your xoom, I'd recommend at least xorg, gdm3 and gnome, so

    Code:
        # apt–get install xserver–xorg–video–fbdev xserver–xorg–input–evdev gdm3 gnome initramfs–tools wpa-supplicant
    You may find that you get an error like the following

    Errors were encountered while processing: bluez gnome–bluetooth gnome–user–share gnome–desktop–environment

    If you do, it's safe to ignore this for now. you can always complete the installation of any non–critical packages on the device. it seems to be something weird with the chroot or the qemu emulation of ARM (if anyone knows a way to fix this I'd be glad to hear it!)

    Once that's done, you'll not only want to set your root password but you'll want to add a standard user account too
    Code:
        # passwd root
        # adduser liv2
        # addgroup ––gid 3003 inet
        # usermod –aG 3003 liv2
    The addgroup and usermod are especially important, the android kernel doesn't normally allow network access to non–root accounts. so we have to add the special group then give the user access to that group (or you could compile the kernel to not use the android paranoid network settings)

    Once that's done, exit out of the chroot by hitting CTRL+D and copy the xorg config to deb_arm/etc/X11/ and copy in the wireless firmware you copied at the start

    Code:
    # mkdir ~/deb_arm/lib/firmware
    # cp ~/fw_bcm4329.bin ~/deb_arm/lib/firmware
    # cp ~/bcm4329.cal ~/deb_arm/lib/firmware


    Building the Kernel

    For this part, make sure you've extracted the kernel sources, and the android–ndk to somewhere, in my case they've been extracted in ~/Downloads
    Code:
        # cd ~/Downloads/Tiamat–AOSP–Tiamat–Xoom–798572c/
        # export CROSS_COMPILE=~/Downloads/android–ndk–r5b/toolchains/arm–eabi–4.4.0/prebuilt/linux–x86/bin/arm–eabi–
    
        # export ARCH=arm
        # export INSTALL_PATH=~/deb_arm/boot
        # export INSTALL_MOD_PATH=~/deb_arm
        # make tiamat_defconfig
        # make menuconfig

    Once you've got the menuconfig screen up, go to Device Drivers > Character Devices > and enable "Virtual Terminal"
    go to Device Drivers > Graphics Support > Console Display Driver support > enable "Framebuffer Console Support"

    once you've enabled that, exit out and save the changes

    Build the kernel and prepare it for use

    Code:
        # make –j2
        # sudo make modules_install
        # sudo cp arch/arm/boot/zImage ~/deb_arm/boot
        # cp System.map ~/deb_arm/boot/
        # chroot ~/deb_arm
        # mkinitramfs –o /boot/initrd.img.gz `ls /lib/modules`

    mkinitramfs may show some warnings like "warning: can't open /etc/mtab:" and "pkg: version '2.6.36.4Tiamat_Xoom–v1.4.4–Full_Throttle' has bad syntax: invalid character in version number" but it doesn't seem to have caused any issues for me.
    Preparing the SDCard

    Plug your SDCard reader into your computer and insert the card, you'll then need to partition and format it so make sure you've backed up the content of the card.

    Partition it so you have two partitions, the first one being a FAT32 Partition for CWR and for anything you might want to use it for under Android.

    Your second partition will need to be EXT3 and big enough to fit your debian install with some room to breathe (about 4GB in my case), you can check how much space you'll need for this by running du -sh ~/deb_arm

    Once you've partitioned it, format the first partition as FAT32 and the second partition as EXT3. once you've done that you should put the SDCard back in your Xoom and make a new nandroid backup just to be sure
    Code:
        # sudo mkfs.ext3 /dev/sdb2
        # sudo mkfs.msdos /dev/sdb1

    Putting it all together

    First we'll mount the SDCard on your PC and copy across the Root FS



    Go to the folder you unpacked mkbootimg to and copy in the boot.img from your CWR backup.

    Once you've done that, follow the below steps to create the new boot.img for Debian to use

    Code:
        # cd ~/Downloads/mkbootimg
        # cp ~/deb_arm/boot/zImage .
        # cp ~/deb_arm/boot/initrd.img.gz .
        # mkdir out
        # ./unpackbootimg –i boot.img –o out/
        # ./mkbootimg ––kernel zImage ––ramdisk initrd.img.gz ––base "`cat out/boot.img–base`" \
        ––cmdline "root=/dev/mmcblk0p2 console=tty0" –o newimg.img

    Now reboot your Xoom into Fastboot mode and insert the SDCard, this can be done by holding power + volume up until the screen goes black, then power it back on and hold down the volume down key
    Code:
        # cp ~/Downloads/fastboot .
        # ./fastboot flash boot newimg.img
        # ./fastboot reboot

    Your Xoom should now boot up into Debian, on the login screen select the accessibility options and enable on-screen keyboard to log in.
    Alternatively, if you happen to have a USB-OTG adapter you can just use a keyboard and mouse to interact with the system.
    Going Back to Android

    To Roll back to Android, simply boot into Clockwork Recovery, go to Backup/Restore > Advanced Restore and restore boot.img only, reboot and you'll be back in Android

    Acknowledgements

    Lopi from the IX Project was a great help, and so was everyone from #IX
    Lilstevie from @GalaxyLinux provided the Touchscreen patches
    Framebuffer Patch was originally provided by Robert Morell for the Chromium Project
    RootFS instructions are based on info at the Debian Wiki


    Please write the current script. to install in windows environment. Update links. The links are dead. and the topic is still being followed.
    2
    hi LIV2, interesting stuff you're working on here. i'm not sure if you're aware, if you aren't this is gonna be a good news most likely: http://phoronix.com/forums/showthread.php?56505-Linux-for-Tegra-release-12-alpha-1-Released

    I believed there are binary blobs inside the package (haven't got the time to look at it), but there might be kernel changes needed to make it work too. I'm not sure as I'm not an expert in this area. But hopefully, this would realize a full blown linux OS on our Xoom.

    Awesome :)

    I've compiled a kernel with the audio components from the L4T Kernel sources but they don't seem to include codec support for the Xoom, I'm still playing around with this
    However that is going to hopefully help with GPU support :D

    Well aint this something !!!

    Second of all - Is there any chance you could include hebrew package with the RTL support ?

    P.S : the dual boot idea is cool, but is there a way to make the device just boot into linux with a click on an icon ? (I mean run an app from android that'll reboot the tab into debian)

    I'll see what I can find re: language. shouldn't be too difficult, it'd just be a few different steps
    As for the dualboot idea, it'd be possible to do so but I'm no coder :p
    All it'd require is dding the boot img from within android, not sure how the NAND would hold up to constant rewrites though

    Firstly: this is awesome. Thank you for putting this how-to together. I've been wanting to boot Linux natively off my Xoom pretty much since the day I got it.

    I originally tried to set up the chroot environment on Fedora and had all kinds of weird issues with the packages. I'm not sure if it was me or Fedora, but I ended up doing it in an Ubuntu VM instead and it worked out fine. Ultimately I'd like to actually get Fedora on the Xoom (maybe Ubuntu if I can get Unity to behave; the interface could be nice with a touchscreen).

    Also, a question: How did you get your wifi set up? You noted that wpa_supplicant would work but I don't even seem to have a wifi interface present unless it has a name other than wlanX. It's not the usb0 interface, is it? My 3G adapter seems like it's recognized in the NM applet but I don't have a data plan, so it doesn't do me much good.

    Lastly, I'll add a picture to the collection. Nothing super exciting - this is XFCE running on top of Debian. I've never been a big fan of GNOME and I figured it might be a little snappier :p


    Awesome!

    Something I have to add to the guide is the wifi, to do this you should have the module for bcm4329 in your /lib/modules somewhere
    so to use it, run modprobe bcm4329 nvram_path=/lib/firmware/bcm4329.cal firmware_path=/lib/firmware/fw_bcm4329.bin

    then you should see the interface as eth0

    you'll need to make sure your wpa_supplicant conf has ap_scan=1 and fast_reauth=1 set, otherwise it won't find any APs
    1
    Wow fantastic work, soon as I have some time to dedicate to this, I"m going to have a crack at it.