[UBUNTU][Testing] How-to install it on the Prime

Search This thread

elboo

Member
Feb 12, 2010
46
9
Do you have any idea how to get root?
Only access is by guest login.
Does anyone know how to get wifi working?

Questions questions questions

Jos
When chrooting ubuntu from android, you can create root password same as your user:

passwd su

where is your ubuntu installed ? in the root of the sdcard or a subdirectory of /data ?
btw, thanks to kexec we have made separate kernels, one for GNU/Linux and one for android.
using the lastest v5 zImage you will not need to create the 3003 and 3004 groups.
we have removed the paranoid network option.

cheers!
In the root of the first partition of sdcard, mmcblk1p1.
 
Last edited:

Snepscheut

Senior Member
Dec 17, 2005
107
15
Zwijndrecht
where is your ubuntu installed ? in the root of the sdcard or a subdirectory of /data ?
btw, thanks to kexec we have made separate kernels, one for GNU/Linux and one for android.
using the lastest v5 zImage you will not need to create the 3003 and 3004 groups.
we have removed the paranoid network option.

cheers!

---------- Post added at 10:18 PM ---------- Previous post was at 10:14 PM ----------



for the wifi you need to apply the root_patch.
for got root access:
from android as root:
# cd /Removable/SDcard/
# chroot . /bin/su
# useradd -G wheel your_username
# echo "your_username ALL = (ALL) ALL" >> /etc/sudoers
# exit
you should be able to see the new user from the login screen, if not search for a ubuntu related stuff ( i'm starting to hate this distro... lol )

good luck.

tux_mind,

My ubuntu is on the root (/) of my sd-card.
 

tux_mind

Senior Member
Mar 3, 2012
199
293
Tux_mind ea,

Thanks for the help for wifi and user/root but my android (cm 10.1 unofficial Kernel source: https://github.com/namidairo/android_kernel_asus_tf201) and it doesn't see my ext4 SD-card.

Do I have to reformat my card as ext2 or use an other kernel (which?)
You where working on a patch kernel for cm 10?

Thanks,

Jos

from android as root:
# cat /proc/filesystems
you will see a list of supported filesystems by the running kernel, check if ext2 is there
if it is format as ext2...otherwise you have to recompile the kernel.

eggy, an user on IRC, is working on that patch, i'll ask this asap.

keep us updated ;)
 

Snepscheut

Senior Member
Dec 17, 2005
107
15
Zwijndrecht
from android as root:
# cat /proc/filesystems
you will see a list of supported filesystems by the running kernel, check if ext2 is there
if it is format as ext2...otherwise you have to recompile the kernel.

eggy, an user on IRC, is working on that patch, i'll ask this asap.

keep us updated ;)

ext2 ext3 ext4 are all there.
I reformatted to ext3 and reinstalled ubuntu and this is running again but under android I can't mount the SD-card (empty card error)

darn maybe I must find the latest asus-rom again.

Jos.
 

tux_mind

Senior Member
Mar 3, 2012
199
293
ext2 ext3 ext4 are all there.
I reformatted to ext3 and reinstalled ubuntu and this is running again but under android I can't mount the SD-card (empty card error)

darn maybe I must find the latest asus-rom again.

Jos.

did you installed busybox ?
the problem must be the android userspace programs, if kernel support those filesystems.

try to install busybox and as root:
#mount -text4 /dev/block/mmcblk1p1 /mountpoint

time to sleep(),
good luck!

see you tomorrow.
 

dunfy23

Member
Aug 29, 2009
30
3
Hi Guys,

Great work by everybody!

I've been reading this thread for quite a few months now and following the progress on and off. I originally had Ubuntu running a while back using some of the old kernels and ubuntu images. I've left it for a while and now wanting to come back and set it up.

I've tried every single distro and all have failed:

Arch linux - No GUI, it just drops to a shell login.
Gentoo - Same as above. No GUI.
Ubuntu - Boots, get low graphics mode. Xorg reports: Failed to load /usr/lib/xorg/modules/drivers/tegra_drv.so: /usr/lib/xorg/modules/drivers/tegra_drv.so: file too short

I'm not too bothered with Arch or Gentoo, although if it's easier to set these up I'm willing to go with either one and learn how to use them. Can anyone offer any help?

I'm running the latest kernel_chooser v1. I can boot Android, and linux (as described above), so I know I have the initial set up done. Ubuntu has been extracted to a (root) ext4 partition on a class 10 micro sd card.

Cheers!

*Edit* I also want to point out that when booting Ubuntu, I cannot get to a shell, it just blank screens. Even when I select continue running in low graphics, it just blanks and I have to force/hard reboot.


*Edit 2 *
Managed to get the driver loaded by copying instead of symlinking the tegra_drv.so
Next error: (EE) module ABI major version (13) doesn't match the server's version (11)

I'm guessing ABI version error is fixed by:

cd /sdcard/usr/lib/xorg/modules/drivers
sudo cp tegra_drv.abi11.so tegra_drv.so

I originally used tegra_drv.abi13.so

* Edit 3 *

Well I'm out of ideas. Copying the correct ABI major version 11 solved all 'EE' errors in xorg. I still get low graphics mode. Here is my Xorg log output: http://pastebin.com/Lym2kDH5

* Edit 4 *

So I reinstalled from scratch and everything worked. I followed the guide here: http://www.hack-job.org/how-tos/primejb-getting-ubuntu-running-on-my-asus-transformer-prime-v2/

With the exception of "ln -s tegra_drv.abi13.so tegra_drv.so" I did "sudo cp tegra_drv.abi11.so tegra_drv.so"

Oh and don't forget to chroot from android to the fresh install and add your own user otherwise you won't be able to login!
 
Last edited:
  • Like
Reactions: zhekazheka

Snepscheut

Senior Member
Dec 17, 2005
107
15
Zwijndrecht
Hi Guys,

Great work by everybody!

I've been reading this thread for quite a few months now and following the progress on and off. I originally had Ubuntu running a while back using some of the old kernels and ubuntu images. I've left it for a while and now wanting to come back and set it up.

I've tried every single distro and all have failed:

Arch linux - No GUI, it just drops to a shell login.
Gentoo - Same as above. No GUI.
Ubuntu - Boots, get low graphics mode. Xorg reports: Failed to load /usr/lib/xorg/modules/drivers/tegra_drv.so: /usr/lib/xorg/modules/drivers/tegra_drv.so: file too short

I'm not too bothered with Arch or Gentoo, although if it's easier to set these up I'm willing to go with either one and learn how to use them. Can anyone offer any help?

I'm running the latest kernel_chooser v1. I can boot Android, and linux (as described above), so I know I have the initial set up done. Ubuntu has been extracted to a (root) ext4 partition on a class 10 micro sd card.

Cheers!

*Edit* I also want to point out that when booting Ubuntu, I cannot get to a shell, it just blank screens. Even when I select continue running in low graphics, it just blanks and I have to force/hard reboot.


*Edit 2 *
Managed to get the driver loaded by copying instead of symlinking the tegra_drv.so
Next error: (EE) module ABI major version (13) doesn't match the server's version (11)

I'm guessing ABI version error is fixed by:

cd /sdcard/usr/lib/xorg/modules/drivers
sudo cp tegra_drv.abi11.so tegra_drv.so

I originally used tegra_drv.abi13.so

* Edit 3 *

Well I'm out of ideas. Copying the correct ABI major version 11 solved all 'EE' errors in xorg. I still get low graphics mode. Here is my Xorg log output: http://pastebin.com/Lym2kDH5

* Edit 4 *

So I reinstalled from scratch and everything worked. I followed the guide here: http://www.hack-job.org/how-tos/primejb-getting-ubuntu-running-on-my-asus-transformer-prime-v2/

With the exception of "ln -s tegra_drv.abi13.so tegra_drv.so" I did "sudo cp tegra_drv.abi11.so tegra_drv.so"

Oh and don't forget to chroot from android to the fresh install and add your own user otherwise you won't be able to login!

Great to hear you got it working!

Maybe you can help me: I run cm 10.1 unofficial, and it impossible for me to mount the micro-sd card (empty card error) and so I cannot chroot to the sd-card.
Which android are you running and what else did you install to make this work?

Greetings Jos.
 

dunfy23

Member
Aug 29, 2009
30
3
Great to hear you got it working!

Maybe you can help me: I run cm 10.1 unofficial, and it impossible for me to mount the micro-sd card (empty card error) and so I cannot chroot to the sd-card.
Which android are you running and what else did you install to make this work?

Greetings Jos.

I'm not sure of this 'empty card error' but I use androwook and the standard kernel tux_mind posted on his tutorial and then chroot with Terminal IDE from the market. Have you checked which filesystems your kernel support? From android as root run "cat /proc/filesystems" and check which filesystems are returned. Eg. ext2, ext3, ext4, if ext4 isn't returned format your sd card as ext3, for example.

One other way I can think of, can you mount USB drives? Try copying everything to a usb drive, mount the usb drive, chroot and do what you need to, then copy all the files from the usb drive back to the sd card.

* Edit *

I'm guessing you've tried the obvious ?

as root: mkdir /data/mmc && mount /dev/block/mmcblk1p1 /data/mmc
or mkdir /data/mmc && mount -t ext4 /dev/block/mmcblk1p1 /data/mmc
 
Last edited:
  • Like
Reactions: Snepscheut

Snepscheut

Senior Member
Dec 17, 2005
107
15
Zwijndrecht
I'm not sure of this 'empty card error' but I use androwook and the standard kernel tux_mind posted on his tutorial and then chroot with Terminal IDE from the market. Have you checked which filesystems your kernel support? From android as root run "cat /proc/filesystems" and check which filesystems are returned. Eg. ext2, ext3, ext4, if ext4 isn't returned format your sd card as ext3, for example.

One other way I can think of, can you mount USB drives? Try copying everything to a usb drive, mount the usb drive, chroot and do what you need to, then copy all the files from the usb drive back to the sd card.

* Edit *

I'm guessing you've tried the obvious ?

as root: mkdir /data/mmc && mount /dev/block/mmcblk1p1 /data/mmc
or mkdir /data/mmc && mount -t ext4 /dev/block/mmcblk1p1 /data/mmc

Dunfy23,

Thanks for your reply/advise.

I have androwook 1.51 installed now with stock kernel.
But the strange thing is my prime mounts my micro-sd and usb as long as the are vfat formatted, but ext3 or 4 do not mount!
I have installed busybox and better terminal, can I format my sd-card while it is in my prime? if so how?
I'm going to copy ubuntu to my intern sd-card under /data/ubuntu do you know how te ubuntu-file under .kernel.d should read?

Thanks and greetings.

Jos.
 

tux_mind

Senior Member
Mar 3, 2012
199
293
Dunfy23,

Thanks for your reply/advise.

I have androwook 1.51 installed now with stock kernel.
But the strange thing is my prime mounts my micro-sd and usb as long as the are vfat formatted, but ext3 or 4 do not mount!
I have installed busybox and better terminal, can I format my sd-card while it is in my prime? if so how?
I'm going to copy ubuntu to my intern sd-card under /data/ubuntu do you know how te ubuntu-file under .kernel.d should read?

Thanks and greetings.

Jos.

ubuntu doesn't work from sub directories now.
we have to fix that mountall bug, can someone ask in the ubuntu forums ?

you can copy the ubuntu rootFS into /data/ubuntu => chroot in => mount you SDcard from there
note that you must mount -o bind /dev /data/ubuntu/dev for mount your SDcard.

btw, kernel_chooser2 is near. got ncurses working. now i'm changing the method for print messages.
bye!
 
  • Like
Reactions: Tempie007

Snepscheut

Senior Member
Dec 17, 2005
107
15
Zwijndrecht
ubuntu doesn't work from sub directories now.
we have to fix that mountall bug, can someone ask in the ubuntu forums ?

you can copy the ubuntu rootFS into /data/ubuntu => chroot in => mount you SDcard from there
note that you must mount -o bind /dev /data/ubuntu/dev for mount your SDcard.

btw, kernel_chooser2 is near. got ncurses working. now i'm changing the method for print messages.
bye!

Your back! how was your day?
any idea why my prime doesn't "see" my ext4 sd-card?

Jos
 

dunfy23

Member
Aug 29, 2009
30
3
Your back! how was your day?
any idea why my prime doesn't "see" my ext4 sd-card?

Jos

From what I've found, Android WON'T auto mount an sdcard that is ext4. You will have to go to your terminal, with root, and type mount /dev/block/mmcblk1p1 /data/mmc (make sure the folder /data/mmc exists first!).

---------- Post added at 07:10 PM ---------- Previous post was at 07:05 PM ----------

ubuntu doesn't work from sub directories now.
we have to fix that mountall bug, can someone ask in the ubuntu forums ?

you can copy the ubuntu rootFS into /data/ubuntu => chroot in => mount you SDcard from there
note that you must mount -o bind /dev /data/ubuntu/dev for mount your SDcard.

btw, kernel_chooser2 is near. got ncurses working. now i'm changing the method for print messages.
bye!

Nice! What does kernel_chooser2 bring? Oh whilst I'm hear... with this fantastic kernel_chooser do you reckon it could be possible to boot two different versions of android whilst using root chooser too?
 

tux_mind

Senior Member
Mar 3, 2012
199
293
Your back! how was your day?
any idea why my prime doesn't "see" my ext4 sd-card?

Jos

From what I've found, Android WON'T auto mount an sdcard that is ext4. You will have to go to your terminal, with root, and type mount /dev/block/mmcblk1p1 /data/mmc (make sure the folder /data/mmc exists first!).

dunfy23 is right.
i remember that i have to do this from the terminal.
but Snepscheut said to had yet tried this.
are you sure to do this:
# mount -text4 /dev/block/mmcblk1p1 /mountpoint
as root ?
you can try to put ubuntu in a data folder ( as /data/ubuntu ) and use it's mount program.

---------- Post added at 06:24 PM ---------- Previous post was at 06:10 PM ----------

Nice! What does kernel_chooser2 bring? Oh whilst I'm hear... with this fantastic kernel_chooser do you reckon it could be possible to boot two different versions of android whilst using root chooser too?

not again ;)
i'm a quite scared from do this.
the /data partition layout has changed between 4.0 and 4.1.....and i'm not an android guru, maybe someone else can tell me how to going on.
my current idea is to have an android root as sub directory of /data, but that root will not mount /system and /data .
so, you will have your "ROM" in /data/cyanogenmod/system folder.

this could be very expensive for the internal sotrage....

btw, if this my idea it's right, i don't need to release a new version of root_chooser.
i just need to apply to your rom's kernel the kexec guest patch and release a specific android_initrd which doesn't mouont /system and /data.

bye!
 
Last edited:

dunfy23

Member
Aug 29, 2009
30
3
I'm not overly bothered, it just crossed my mind whilst setting up the android kernel config. The only thing that could be tricky is getting it installed. I'll have a play...


Sent from my Transformer Prime TF201 using Tapatalk 2
 

Snepscheut

Senior Member
Dec 17, 2005
107
15
Zwijndrecht
I have now mounted the sd-card (ext4) to /data/mmc .
cd /data/mmc, ls gives me the dir bin, etc , boot, home etc etc
but chroot /bin/su gives "can't change root directory to /bin/su: Not a directory" (yes i'm root #)

I'm afraid I'm not smart enough for this....

Jos.

Reading I found this: chroot /path/to/fs /bin/su and now I have root@localhost !
 
Last edited:

dunfy23

Member
Aug 29, 2009
30
3
Yes it needs to be chroot /data/mmc /bin/su. But it looks like you figured that out. Good luck!

Sent from my Transformer Prime TF201 using Tapatalk 2
 
  • Like
Reactions: Snepscheut

JoeyDelp

Senior Member
Jun 19, 2010
168
44
31
Stellenbosch
so anybody got any idea as to why it wont boot ubuntu from a sub-folder say /data/ubuntu?

dont wanna run off a SD since i move my prime alot and a sdcard comes out too easily
 

Top Liked Posts

  • There are no posts matching your filters.
  • 20
    -----------
    HOW-TO: Ubuntu on Asus Transformer Prime TF201

    Port by lilstevie (thank you for your hard work)
    --------

    DISCLAIMER:
    I wrote this how-to from my experience installing successfully Ubuntu on my Prime.
    I am in no way responsible for what you do with your Prime, even when you are following my instructions.
    There is always the risk of making it worse, hardbricking your device, and this risk is completely down to you !
    This is not a final version. This port is currently very unstable !
    Install Ubuntu on your TF201 for testing purposes only !


    HOW-TO Unbrick your Prime (or not...):
    http://xdaforums.com/showthread.php?t=1514088

    --------

    VERSION:
    v0.1: First version of the tutorial

    ABOUT:
    - Working:
    Wifi – Same patch as for the TF101
    Keyboard (if you have a dock)
    USB Host (if you have a dock)

    - Partially working:
    Graphics Acceleration (only 2D at this point)
    Touchscreen (it works but every few touches are off target by 1/2 the screen)

    - Not working:
    Bluetooth
    Trackpad
    Sound
    Sensors (ALS, Gyroscope, Accelerometer, GPS, magnetometer)
    Shutdown, Reboot, Suspend

    --------

    Links:
    Bootimage http://173.244.200.139/ports/prime-sdlinux.blob
    RootFS http://173.244.200.139/ports/ubuntu-prime.img.gz
    Fastboot http://alpharev.nl/wintools.zip

    MD5:
    9625d336062b2ff7eb9530dd5e48fb9e prime-sdlinux.blob
    1a59e7918c199a85f805cb62ca130dae ubuntu.img
    81238957a42b207213442cba7eeff684 wintools.zip

    --------

    Hardware:
    Asus Transformer Prime TF201 (bootloader unlocked & with data/charge cable)
    A computer with Linux installed
    MicroSD card of at least 4GB (a fast card is better)

    --------

    Pre-requisities:
    1. You need to have an already unlocked Prime.
    To unlock it, use the official Asus Bootloader Unlock Tool APK on Android.

    2. You need to have the latest ClockWorkMod (CWM) Recovery installed to easily backup & restore your device.
    To install it, you can use the Android tool 'ROM Manager' from Play Store if you system is already rooted.
    Otherwise, you can use the 'Fastboot' tool along with this tutorial (BE CAREFUL!):
    HOW-TO 1: http://www.theandroidsoul.com/install-cwm-5-8-2-0-on-transformer-prime/
    HOW-TO 2: http://xdaforums.com/showthread.php?t=1576937

    (You can also install the Touch version of CWM to avoid destroying your volume buttons while navigating :D)
    CLASSIC : http://download.clockworkmod.com/recoveries/recovery-clockwork-5.8.2.0-tf201.img
    TOUCH : http://download.clockworkmod.com/recoveries/recovery-clockwork-touch-5.8.1.8-tf201.img

    3. Before trying to do anything with your device, make a full nandroid backup of the current WORKING Android system.

    To do that:
    - Reboot on CWM (see the sticky, at the end)
    - Navigate to 'backup and restore', then 'backup'
    - Wait until the full backup is done...

    --------

    - INSTALL Ubuntu -

    Introduction:
    To have a working Ubuntu system on the Prime, you have to:
    - Extract the root file system on your MicroSD card
    - Flash the bootimage right on the device

    While installing Ubuntu, the only thing you modify about Android, is the bootimage. You leave the system intact,
    so you'll be able to do a pseudo-dualboot between Ubuntu, and Android (we'll see that later).

    HOW-TO:
    Extraction of the root filesystem:
    - Connect your MicroSD card on the computer running linux (ex: /dev/sdc)
    - Umount all current partitions from the card
    - Using fdisk, fully erase it, rebuild partition table, and create one partition (ex: /dev/sdc1)
    - Format it in 'ext4' (ex: $ mkfs.ext4 /dev/sdc1)
    - Using 'dd' command, extract the 'ubuntu.img' filesystem to the recently created partition
    (ex: $ dd if=ubuntu.img of=/dev/sdc1)
    - Wait until extraction completes... (It takes a while...)
    - Mount the partition to verify that the extraction completes successfully (ex: $ mount /dev/sdc1 folder)
    - Umount it, eject the card and put it on the Prime (ex: $ umount /dev/sdc1)
    - Your Ubuntu filesystem is ready to use !

    Flashing the bootimage (BE CAREFUL!):
    - Reboot in fastboot mode (see the sticky, at the end)
    - Connect the Prime to the computer, and be sure the drivers are correctly installed
    You can find the drivers here: http://xdaforums.com/showthread.php?t=1426502
    - Extract the fastboot archive 'wintools.zip' and move the file 'prime-sdlinux.blob' in the same folder
    - Execute the command: fastboot -i 0x0b05 flash boot prime-sdlinux.blob
    (WARNING! This command will overwrite the bootimage of your Prime! Be sure you know what you're doing!)
    - Wait until the flash completes... (it generally takes a few seconds...)
    - When the blue progress bar is full, on the Prime, hold the Power switch to reboot the device
    - Be sure that the MicroSD card is in the Prime
    - Your Prime is now booting on Ubuntu, you should see some text displaying on the screen
    - Wait until the system initializes... (It takes a while for the first boot...)
    You should see kernel verbose booting, displaying something saying the system is resizing a partition
    on the MicroSD card...
    - Your Ubuntu system is installed ! You can do the graphical basic setup, then do a hard reboot of the device !
    - Good luck with your freshly installed Ubuntu on your awsome Asus Transformer Prime !

    --------

    - RESTORE Android -

    Introduction:
    After installing Ubuntu, to have Android back on the Prime, you have to:
    - (OPTIONAL: Do a full nandroid backup to be able to restore the Ubuntu bootimage directly from the CWM later)
    - Simply restore the Android bootimage from the nandroid backup made before the installation of Ubuntu

    HOW-TO:
    To do that:
    - Reboot on CWM (see the sticky, at the end)
    - Go to 'backup and restore', then 'advanced restore'
    - Choose the Android backup made before installing Ubuntu
    - Choose 'Restore boot' option
    - Wait until the restore is done...
    - Choose 'reboot system now' to boot in Android

    --------

    - DUALBOOT Android/Ubuntu -

    Introduction:
    We can note that the both systems are installed on two different storage devices.
    Android is directly on the device and Ubuntu is on the MicroSD.
    The only thing that changes between the two systems is the bootimage.
    If you have a nandroid backup of each WORKING systems, you can do an advanced restore of the boot 'boot.img'
    of Ubuntu to boot it from the MicroSD card, or restore the boot of the Android backup to boot on Android !

    HOW-TO:
    To do that:
    - Reboot on CWM (see the sticky, at the end)
    - Go to 'backup and restore', then 'advanced restore'
    - Choose the correct backup (the Android one, or the Ubuntu one)
    - Choose 'Restore boot' option
    - Wait until the restore is done...

    --------

    STICKY:
    - Booting the Prime on recovery mode (CWM):
    1. Power off the device (using Android, or by a long press of the power switch)
    2. Power it on, by keeping simultaneously pressed the power switch and the volume down button
    3. When text displays on top of the screen, release all, and press the volume up button
    4. Wait a few seconds and CWM will appear on the Prime...

    - Booting the prime in fastboot mode:
    1. Power off the device (using Android, or by a long press of the power switch)
    2. Power it on, by keeping simultaneously pressed the power switch and the volume down button
    3. Wait until the message saying 'OS will coldboot in 10 seconds' etc... then release all buttons
    4. Use the volume down button to select the USB icon
    5. Validate with volume up
    6. You can connect your device to a computer to send fastboot commands...
    17
    Here is a video of the current status.


    There is a blog post coming soon.
    10
    You have pubblished new files ?
    We are anxiously awaiting :D

    there is a major bug with the 3.1 kernel which is holding things up at the moment, there is a race condition which means the boot needs to be broken out into an initrd shell and resumed to work
    10
    Can You write on How-to for install one distro complete ?

    no, and the reason will make you happy!
    just now i've got kexec works! :laugh:

    PLEASE STOP TESTING ROOT_CHOOSER v5.
    configuration files syntax will change for support external kernel loading.

    so, let me make root_chooser v6 and a custom kernel for boot everything.
    i'll update you soon!

    Cheers!
    9
    i did it!
    the touchpad WORKS!
    ensure to have xf86-input-synaptics package installed ( on ubuntu should be 'xserver-xorg-input-synaptics' ).

    as usually you can find everything here: https://github.com/tux-mind/tf201-dev
    for update your TF201 follow this guide: http://wiki.gentoo.org/wiki/Asus_Transformer_Prime#INSTALLING_THE_KERNEL

    we ALWAYS provide the source code, for now all our kernel changes are in the JB15.patch file.
    if you want to contribute i'll add you to the repository collaborators.

    cheers!