[DEV] - Dual-boot Linux on the Asus Infinity TF700t - JB-4.2[Thread closed] - Asus Transformer TF700

This was the development thread for the "Dual-boot Linux on the Asus Infinity TF700t - JB-4.2" (now called "Kexecboot Linux on the TF700t").
Any and all developments are in Kexecboot Linux on the TF700t here
JoinTheRealms source is up here https://github.com/JoinTheRealms/TF7...oot-stockbased.
Recovery flashable Kexecboot and Kernels Installer
I have made a flashable zip to do the work for me(and you). This zip is a modified version of _that's kernel installer. It will install the kexec blob, boot.cfg, and the Andriod kernel of your choice - CROMi-X, that10 or CROMBi-KK, that-cm112. The that10 installer also includes the needed modules (I will see what is needed for CROMBi-KK at a later date).
Flash the proper zip file below using the newest TWRP:
Please make sure you have a BACKUP (also dd backup your mmcblk0p5 partition for safety) and have either the stand alone that10 kernel installer or CROMi-X/CROMBi-KK ROM's on your tablet as a safety net.
I am including the md5's on these files until I figure out how to sign them... :silly:Done, thanks _that!
CROMi-X 5.4 - kexecboot_installer_for_CROMBi-X5.4_v1.0_Signed.zip -
CROMBi-X - kexecboot_installer_for_CROMBi-KK_v1.0_Signed.zip -
Change log:
5/23/2014
v.1.0 Installs kexec blob, boot.cfg, Android kernels (that10 and that-cm112) and modules(that10 only)
Click to expand...
Click to collapse
Manual kexec blob, Android and Linux kernel install info
1. Android Kernel
You must have a fully stable CROMi-X 4+(TWRP 2.5+) or CROMBi-KK (trwrp_that-2.6.3 or TWRP 2.7) install to use any of the following (See this forum, here, for ROM details)
(If you are on stock rooted only, see rabits old thread as this is your only option, here).
The example boot.cfg is usable as is (if you read the file and have use of any of the common choices it describes.)
---CROMi-X (Remember this is only for _that stock. No f2fs,rom2sd or data2sd)
1)From Android "Terminal Emulator" mount /system r/w and make dir /system/boot and extract that9oc-kexecboot-android-05082014.zip or that10-kexecboot-android.zip to /system/boot/
The following assumes you copied or downloaded that9oc-kexecboot-android-5082014.zip to the Download folder
Code:
su
mount -o remount,rw -t ext4 /dev/block/mmcblk0p1 /system
mkdir /system/boot
cd /system/boot
unzip /data/media/0/Download/that9oc-kexecboot-android-5082014.zip
mount -o remount,ro -t ext4 /dev/block/mmcblk0p1 /system
2) Reboot into TWRP
3) From TWRP, flash kernel-10.6.1.14.10-that9-oc.zip or kernel-that10.zip and reboot to Android (See _thats thread for kernel details)
4) Back in Android, mount mmcblk0p5 as root and copy your this example boot.cfg into /mmcblk0p5/multiboot -
BIG RED WARNING - Do not mess with any other files on this partition or you will most likely have yourself a paperweight...
The following assumes you downloaded or copied boot.cfg the the Download folder
Example Code:
Code:
su
cd /data/media/0/Download
mkdir kexectemp
mount -t vfat /dev/block/mmcblk0p5 kexectemp/
mkdir kexectemp/multiboot/
cp boot.cfg kexectemp/multiboot/
umount kexectemp/
---CROMBi-KK (Remember this is only for _that stock. No f2fs,rom2sd or data2sd)
1) From Android "Terminal Emulator" mount /system r/w and make dir /system/boot and extract that-cm112-kexecboot-android-4272014.zip to it
The following assumes you copied or downloaded that-cm112-kexecboot-android-4272014.zip to the Download folder
Code:
su
mount -o remount,rw -t ext4 /dev/block/mmcblk0p1 /system
mkdir /system/boot
cd /system/boot
unzip /data/media/0/Download/that-cm112-kexecboot-android-4272014.zip
mount -o remount,ro -t ext4 /dev/block/mmcblk0p1 /system
2) Mount mmcblk0p5 as root (ex. mkdir somewhere/temp, mount -t vfat /dev/block/mmcblk0p5 temp/) and copy your this example boot.cfg into /mmcblk0p5/multiboot -
BIG RED WARNING - Do not mess with any other files on this partition or you will most likely have yourself a paperweight...
The following assumes you downloaded or copied boot.cfg the the Download folder
Example Code:
Code:
su
cd /data/media/0/Download
mkdir kexectemp
mount -t vfat /dev/block/mmcblk0p5 kexectemp/
mkdir kexectemp/multiboot/
cp boot.cfg kexectemp/multiboot/
umount kexectemp/
2. Linux Kernel - This step is only needed if you aren't using one of the example rootfs below.
Be sure to read the readme files included in the zip file by conago.
1) Mount your Linux .img file or extract your rootfs as root on your Linux PC to a temp directory
2) Extract linux-kernel-tf700-kexec-that10-cogano3.zip ,by conago,to a temp directory
3) Copy the /boot and /lib folders to the root of your rootfs
4) Unmount the image or zip up your rootfs files.
Hint: Running the following commands will result in a new rootfs.tar.lzma that can be installed with the rootfs only installer above.
1) cd into partition mount
2)arch - sudo tar cp --exclude=lost+found --exclude='proc/*' --exclude='proc/.*' --exclude='sys/*' --exclude='sys/.*' --exclude='dev/*' --exclude='dev/.*' --exclude='tmp/*' --exclude='tmp/.*' --exclude='var/cache/pacman/pkg/*' $excludes . | lzma -9 > ../imgagename.tar.lzma
or
ubuntu - sudo tar cp --exclude=lost+found --exclude='proc/*' --exclude='proc/.*' --exclude='sys/*' --exclude='sys/.*' --exclude='dev/*' --exclude='dev/.*' --exclude='tmp/*' --exclude='tmp/.*' --exclude='var/cache/apt/archives/*.deb' $excludes . | lzma -9 > ../imgagename.tar.lzma
Click to expand...
Click to collapse
3. Flashing the kexecboot kernel blob - (done from Android using "Terminal Emulator") with 10 second time out by conago
1) Extract kexec-host-2014-05-22.zip to a temp dir, cd into it and then carefully type the following as root:
Again - BIG RED WARNING - Type carefully or you will leave your tablet unbootable or WORSE. And please read the README file in the zip.
Code:
dd if=blob of=/dev/block/mmcblk0p4
Reboot and profit!
Post install
Now included in the menu driven Android kexecboot Installer
Use the following script from Android AFTER you have a working install to modify the
boot.cfg file to your setup. It helps to rename the labels to something you can remember.
Extract to your favorite place and see the readme file.
modify_boot.cfg_v1.0.zip
Old, Old thread content here:
Great kexecboot tutorial by @cogano (here) - This gives some good background for the regular installer as well.
For those running CROMBi-KK w/_that9-oc+(modded for cm112 by @lj50036 ), I have a quick rundown of what you need to do and the necessary files (ie cm112 android kernel) here
Disclaimer! This is very experimental and may damage your device.
Suggested Requirements - TWRP 2.5+ and CROMi-Xenogenisis 4+
If you are on CleanROMv3x see rabits old thread - http://forum.xda-developers.com/showthread.php?t=2014759
Known issues:
1) Try to start or restart lightdm and it says - read-only filesystem. You need to fix this from Android, terminal emulator
Code:
su
Code:
e2fsck /data/media/linux/rootfs.img
This happens when you force restart or shutdown linux sometimes
You will find links below to the latest (still beta!) installer and some rootfs images.
For both Ubuntu and Lubuntu - Username: ubuntu Password:ubuntu
Lubuntu rootfs:
FYI - The Lubuntu rootfs is a work in progress and has been stripped for YOU to customize. Even though the download size is larger (install is 2.6gb), this runs way faster and uses less ram.
To see what has been installed (not much) or removed (a lot):
Code:
cat /var/log/apt/history.log | less
- The Lubuntu rootfs has the apt lists removed to reduce download size. Run this from lxterminal:
Code:
sudo apt-get update
Lubuntu To Do:
1) Remove xfce4-notifyd to get rid of the multiple notification errors... (Sorry about that one. I like Thunar and that was a dependency...)
2) No shutdown or restart in Lubuntu, also fails to start lightdm (tf700 prompt). Work around is to insert "sudo service lightdm start" (no quotes) into the file /etc/rc.local BEFORE exit0.
3) Version number shows as 12.10, it is really 13.04
4) Remove Unity
5) Update Tegra4Linux Drivers
6) Create updater scripts for version updates (Allows using your current install instead of starting with a fresh rootfs each time I update stuff)
7) Find out what is eating up space - rootfs still too large (734mb download - 2.5gb installed)
8)
Lubuntu Change log:
8-19-2013
- Removed xfce4-notify and Thunar
- Fixed lightdm errors and loads on boot now
- Fixed Lubuntu version number
- Removed overlay scrollbar - Most are usable by touch now.
- Removed password for sudo
- Other little things...
8-20-2013
- Removed Unity
- Added new wallpaper and conky (Thanks kennyMC)
- Cleaned up some clutter and sped things up...On hold...
Turns out that removing Unity did remove something that broke the framebuffer (honestly don't know much about that). I checked the logs and didn't see anything that got removed that should have affected X.
Anyhow, for now I am going to stick with the 8-19-2013 version as a base. I'm going to just spend some time using it and see what I can...
8-22-2013
- Removed Unity (if using v8-19-2013 run this in a terminal window as root - remove-unity.sh)
- Added new wallpaper and conky (Thanks kennyMC)
- Cleaned up some clutter and sped things up... Feels smoother!
- Removed some icon sets (HighContrast, LowContrast, Elementary), saved 100+mb on rootfs
Click to expand...
Click to collapse
Here is the modified .conkyrc and conky-draw.lua and my new wallpaper (definitely amateur).
conky-wallpaper2.tar (Fixed per JoinTheRealms - added - own_window_argb_visual) Just untar in the root of your home directory. (tar xf conky-wallpaer.tar) And use desktop preferences to change wallpaper.
{
"lightbox_close": "Close",
"lightbox_next": "Next",
"lightbox_previous": "Previous",
"lightbox_error": "The requested content cannot be loaded. Please try again later.",
"lightbox_start_slideshow": "Start slideshow",
"lightbox_stop_slideshow": "Stop slideshow",
"lightbox_full_screen": "Full screen",
"lightbox_thumbnails": "Thumbnails",
"lightbox_download": "Download",
"lightbox_share": "Share",
"lightbox_zoom": "Zoom",
"lightbox_new_window": "New window",
"lightbox_toggle_sidebar": "Toggle sidebar"
}
Install
1) In Android Terminal Emulator:
Code:
# su
# mkdir /data/media/linux
2) copy installerV6.7.zip and rootfs-ubuntu-12.10-0.8.0.tar.lzma (12.10) or rootfs-lubuntutf700t-8-22-2013.tar.lzma (13.04)
to Dock SDcard (/Removable/SD), MicroSD (/Removable/MicroSD) or /data/media
3) Boot to recovery
4) NANDROID BACKUP!!!
5) Install installerV6.zip
6) READ and follow the aroma installer instructions (it will stop at 90% for as long as an hour or more while it is decompressing the rootfs)
7) Enjoy dual-boot Linux Again...
Files:
rootfs-ubuntu-12.10-0.8.0.tar.lzma (687 Mb) MD5: 6dbf50fe8623ceef3e5771e01ba52938
NEW! - rootfs-lubuntu-tf700t-8-22-2013.tar.lzma (722 MB) MD5: 92399b0541235a53b94844bacb06d866
NEW! 10/2013 - installerV6.7.zip (13mb) MD5: f2961cd02c6770dea369c3728fa13201
conky-wallpaper2.tar (316k)
Dualboot Linux - rootfs only installers.
These NO NOT install the kernels needed for hybrid or kexec dualbooting. These are only for unpacking the rootfs files from above. They are custom Aroma based installers and allow your /home directories to be on mccblk0p8 if you choose.
These are Aroma based installed from recovery:
arch-rootfs-installer-v.1.zip
lubuntu-rootfs-installer-v.1.1.zip
ubuntu-rootfs-installer-v.1.1.zip

KEXECBOOT with CROMBi-KK
These files are for those who want to kexecboot using CROMBi-KK 4/3, 4/27 or CROMi-X 5.4running on internal sd (NO rom2sd, f2fs or data2sd) with the "stock" _that9-oc+ (cm112 is modded by lj20036). You must have a good running CROMBi-KK install because i am not including the modules needed, only the zImage and initrd.img I extracted from the 4/3 zip file. CROMi-X should also be running stable. You will be flashing _thats newest _that9oc+ using his installer.
THIS IS VERY SIMPLISTIC IT ASSUMES YOU KNOW WHAT ALL THE FOLLOWING MEANS AND HAVE EITHER DONE THE KEXECBOOT WITH EARLIER CROMI VERSIONS OR HAVE COMPLETELY READ COGANO'S TUTORIAL
Also remember DO NOT use the regular rootfs installers. The regular installers will install a JellyBean kernel and render your tablet unusable. Only use the one of the following to extract your rootfs to the tablet:
arch-rootfs-installer-v.1.zip
lubuntu-rootfs-installer-v.1.1.zip
ubuntu-rootfs-installer-v.1.1.zip
All of the following is done on your tablet
1) Android
a) Mount /system r/w and make dir /system/boot​b) - Extract that-cm112-kexecboot-android.zip to /system/boot/ for 4/3/2014 CROMBi-KK Release
- Extract that-cm112-kexecboot-android-4272014.zip to /system/boot/ for 4/27/2014 CROMBi-KK Release
**** FOR CROMi-X flash _thats9oc+ kernel in TWRP and reboot into CROMi-X and then extract that9oc-kexecboot-android-05082014.zip to /system/boot/​c) Mount mmcblk0p5 and modify/copy your boot.cfg in /mmcblk0p5/multiboot to include CROMBi-KK at least to start (at least you will get back into Android ) - Example config - boot.cfg​2) Linuxa) Mount your Linux image and extract _that-linux-kexec.zip to /boot​3) Flashing the kexecboot bloba) Extract kexec-host.zip to a temp dir, cd into it and then carefully type the following as root:​
Code:
dd if=blob of=/dev/block/mmcblk0p4
Reboot and profit!
Credits:
rabits
JoinTheRealms
moreD_cn
_that
lj50036
cogano
and many more

Installer/ kernel guide
Ill be keeping this post updated as much as possible with the latest stuff to save people crawling through multiple threads
-Installer-
The installer is an Aroma package responsible for extracting the linux distros filesystem(compressed into a .lzma file) into a virtual image (.img), you can define the size of this image with the installer. It also prepares and flashes a kernel and initrd based on the preferences you define within the installer.
Downloads:
Version 6.5: https://www.dropbox.com/s/oksatawl4wxo290/installerV6.5.zip (Hunds 3.3.6 based)
Version 6.8: https://www.dropbox.com/s/0q01ijw1vkbokw1/installerV6.8.zip (Stock based, patches from _thatv5)
Note:
Code:
-As of 03/10/2013 the kernel in the installer is up to date, i wont be updating the kernel inside the installer anymore.
-Only Stock based ROMs are supported in the installer (Stock, Cromi 4.x, Cromi 5.x etc).
-Kernels-
We now have a flashable .zip (I stole _that's), To flash a .blob file the best method is using dd. From terminal emulator or adb shell, run "dd if=*name of blob* of=/dev/block/mmcblk0p4" (obviously without quotation marks and replace *name of blob* with the file name:silly
Downloads:
Stock based(blobs):
--Stock/ _that https://www.dropbox.com/s/86o9vt3b10digqr/blob04 0.4
--Hundsbuah https://www.dropbox.com/s/h2waysfz3bzaqy4/blob04 0.4
Stock based(zip)
--Stock/ _that https://www.dropbox.com/s/ndasx56839hsoud/kernel-Linux-that_based2.zip 0.4
--Hundsbuah https://www.dropbox.com/s/nh6s3yvmk1uszng/kernel-Linux-hunds_based2.zip 0.4
Changelog:
Code:
Version 0.1
-enabled cleancache
-testing cm10.2 dualboot
Version 0.2
-Added a repair (e2fsck)to main init menu
Version 0.3
-Another initrd update, better repair, streamlined the kernel selection, added a option to choose
the default OS, started adding support for kexecboot.
Version 0.4
-Some more init tweaks and updated kexecboot binary
Source:
https://github.com/JoinTheRealms
https://github.com/moreD
-MISC-
Some fixes and improvements
Suspend Workaround
http://forum.xda-developers.com/showpost.php?p=44764722&postcount=6
Backlight Control
Code:
sudo add-apt-repository ppa:indicator-brightness/ppa
sudo apt-get update && sudo apt-get install indicator-brightness
Overclock Management(only for Hundsbuah kernels)
https://www.dropbox.com/s/hkqhog4gjqw0lef/overclock.tar.gz(extarct to /home)
Install XBMC
https://www.dropbox.com/s/e21vys5a0c11u0e/installxbmc.sh
Credits
rabits (For his original init scrits and installer)
Hundsbuah (For his kernel and help)
_that (For his kernel and help)
moreD_cn (For fixing everything)
workdowg (for his rootfs's)
And lots more+

Hey guys you're doing great jobs! :good:
since there's a dev thread and i've got enough posts to reply here I think I'll reply here from now on
As i won't have much time for at least a month, I'll focus on building a kexec kernel for linux.
@JoinTheRealms mentioned that after removing wakelocks screen left blank while waking up. I looked into it yesterday but didn't find any solution it seems to relate to something about tegradc and earlysuspend I tried disabling and then re-enabling tegradc.0 (the one for LVDS) the issue appeared with wakelock support. but i cannot figure out how to resolve it.
another thing is bcmsdh_sdmmc keeps waking up my device regularily even without wakelock. however if I use rfkill to block wifi and bluetooth before suspending it works fine. it suspended for over 30k seconds without waking up last night
since we're having problem disabling wakelock, I have an idea that should we just leave it enabled and write a pm daemon for linux to control power state? actually i've implemented a basic one and it works as expected.

moreD_cn said:
Hey guys you're doing great jobs! :good:
since there's a dev thread and i've got enough posts to reply here I think I'll reply here from now on
As i won't have much time for at least a month, I'll focus on building a kexec kernel for linux.
@JoinTheRealms mentioned that after removing wakelocks screen left blank while waking up. I looked into it yesterday but didn't find any solution it seems to relate to something about tegradc and earlysuspend I tried disabling and then re-enabling tegradc.0 (the one for LVDS) the issue appeared with wakelock support. but i cannot figure out how to resolve it.
another thing is bcmsdh_sdmmc keeps waking up my device regularily even without wakelock. however if I use rfkill to block wifi and bluetooth before suspending it works fine. it suspended for over 30k seconds without waking up last night
since we're having problem disabling wakelock, I have an idea that should we just leave it enabled and write a pm daemon for linux to control power state? actually i've implemented a basic one and it works as expected.
Click to expand...
Click to collapse
Are able to post your pm daemon? Id love to give it a try, any attempts of me writing c code usually end in disaster .
Im still trying to fully understand this wakelock stuff ( when im daring enough im gonna start reading this), im guessing something in the linux userspace is holding wakelocks, explaining why it immdatly wakes up again?
I actually successfully got the system to suspend then wakeup with a script with wakelocks enabled, it simply put the device to sleep and 30 seconds later echo'ed on > /sys/power/state like 20 times with a 2 second delay lol no idea how this worked.

JoinTheRealms said:
Are able to post your pm daemon? Id love to give it a try, any attempts of me writing c code usually end in disaster .
Im still trying to fully understand this wakelock stuff ( when im daring enough im gonna start reading this), im guessing something in the linux userspace is holding wakelocks, explaining why it immdatly wakes up again?
I actually successfully got the system to suspend then wakeup with a script with wakelocks enabled, it simply put the device to sleep and 30 seconds later echo'ed on > /sys/power/state like 20 times with a 2 second delay lol no idea how this worked.
Click to expand...
Click to collapse
My daemon depends on a patch which providing "current power state" so i've modify it a bit. I think it's easy to understand.. but with very limited functions. note that press power button over a sec for force wake up.
looks like that sometimes it was kept from suspending by userspace wakelocks but it also occured that a wifi interrupt wake suspended device up. still don't know why but disable wifi before suspend seems to resolve it.
EDIT: seems i've made a mistake:silly: please redownload source file...
EDIT2: I've re-uploaded one that supports lid open/close event

To Do:
- Modify installer for rootfs only - workdowg?
- Kexec
- Multiboot?

@JoinTheRealms - CROMi-X 5 is right around the corner... Are we going to be ok with the kernel. I have to check but I think sbdags stock and Hunds are using a new base... I may just try CROMi-X beta3 to see what's up (if it boots with yours). I'm kind of looking forward to checking out the fixed dock power drain issue and trying the cache2sd though, so I may stick to his stock for a couple days...

workdowg said:
@JoinTheRealms - CROMi-X 5 is right around the corner... Are we going to be ok with the kernel. I have to check but I think sbdags stock and Hunds are using a new base... I may just try CROMi-X beta3 to see what's up (if it boots with yours). I'm kind of looking forward to checking out the fixed dock power drain issue and trying the cache2sd though, so I may stick to his stock for a couple days...
Click to expand...
Click to collapse
Kernel should be fine, I cant find any new kernel source from Asus. I doubt they changed much that would affect us, but we will see

workdowg said:
@JoinTheRealms - CROMi-X 5 is right around the corner... Are we going to be ok with the kernel. I have to check but I think sbdags stock and Hunds are using a new base... I may just try CROMi-X beta3 to see what's up (if it boots with yours). I'm kind of looking forward to checking out the fixed dock power drain issue and trying the cache2sd though, so I may stick to his stock for a couple days...
Click to expand...
Click to collapse
Can you elaborate on this dock power drain issue? I'm curious if it describes a problem I've been having since upgrading to 4.2.

yoda-sama said:
Can you elaborate on this dock power drain issue? I'm curious if it describes a problem I've been having since upgrading to 4.2.
Click to expand...
Click to collapse
Anytime you plug or unplug the tablet from the dock while in android (maybe linux), the dock discharges quickly to keep the tab charged. This is supposedly fixed in the new Asus jb base.
Sent from my ASUS Transformer Pad TF700t - CROMi-X 4.7.0 ODEX

JoinTheRealms said:
Kernel should be fine, I cant find any new kernel source from Asus. I doubt they changed much that would affect us, but we will see
Click to expand...
Click to collapse
Boots fine. HORRIBLE Quadrant scores... 3500 in performance.... Don't knowhow real world use feel yet.
Sent from my ASUS Transformer Pad TF700t - CROMi-X 5-Beta3-DEODEX

workdowg said:
Boots fine. HORRIBLE Quadrant scores... 3500 in performance.... Don't knowhow real world use feel yet.
Sent from my ASUS Transformer Pad TF700t - CROMi-X 5-Beta3-DEODEX
Click to expand...
Click to collapse
strange, didnt you report good scores on cromi 4.7? i wonder whats changed. Hope nothings broken on the linux side

JoinTheRealms said:
strange, didnt you report good scores on cromi 4.7? i wonder whats changed. Hope nothings broken on the linux side
Click to expand...
Click to collapse
Yeah, I got 6000. Might need to let the rom "settle" a bit before trying this testing. I also enabled the cache2sd which may have muddled with the results. Like I said I'll put it though some real world tests. I seems way snappier now.
Sent from my HTCEVOV4G using Tapatalk 4

@JoinTheRealms - Is there an easy way to compile the kernel for VT support (tty0). Xorg in Android is complaining about no tty0, which of course there isn't. Don't bang your head on this because it is for my pet project, using Linux Deploy to run my rootfs chrooted in the framebuffer under Android. This would help a lot when I don't have a pc in front of me to search out things while developing the rootfs....
Edit - or @_that your stock Android kernel?

@moreD_cn In the previous kexec kernel is posted with wakelocks disabled, we had an issue with the screen remaining blank after a suspend (although the backlight functions normally)
This might not having as be as an issue as i thought and hoping you can help me If i suspend the tablet and wake it up again (the screen is blank at this point) i can ssh into it and if i run "sudo service lightdm restart" and the display returns! so we have a semi-functioning native suspend it seems xserver(or something) isn't re-initialising LVDS1 properly, but im at a loss on how to fix (my linux knowledge still isn't great) but i feel our options expanded.

JoinTheRealms said:
@moreD_cn In the previous kexec kernel is posted with wakelocks disabled, we had an issue with the screen remaining blank after a suspend (although the backlight functions normally)
This might not having as be as an issue as i thought and hoping you can help me If i suspend the tablet and wake it up again (the screen is blank at this point) i can ssh into it and if i run "sudo service lightdm restart" and the display returns! so we have a semi-functioning native suspend it seems xserver(or something) isn't re-initialising LVDS1 properly, but im at a loss on how to fix (my linux knowledge still isn't great) but i feel our options expanded.
Click to expand...
Click to collapse
I have looked into it and don't know how to fix neither. But if we can get display back by restarting X, it's great progress. I'll try again!
btw how is multiboot going? I spent some time last days to port something called kexecboot and it has replaced rabits' one on my pad. Still have some problems but it works, mainly..

moreD_cn said:
I have looked into it and don't know how to fix neither. But if we can get display back by restarting X, it's great progress. I'll try again!
btw how is multiboot going? I spent some time last days to port something called kexecboot and it has replaced rabits' one on my pad. Still have some problems but it works, mainly..
Click to expand...
Click to collapse
Yeah its strange,after i restart x, input devices stop working, also when i run lightdm from ssh it wont start, just falls back to terminal. I havnt had much time too play with it, but atleast its seemingly not a display driver issue.
Multiboot should be very easy to port over(Im all talk, since i have zero experience doing that kinda thing ) The developer has recently put alot of work into making it easy to port to other devices. Now that we have nvflash, i feel a bit safer experimenting.
kexecboot looks awesome! in fact ive been planning a grub-like multiboot, using twrp or cwm, im trying to figure out how to strip all the recovery stuff off it and just use it as a multiboot interface, and have boot from kexec. I need linux booting from a directory first though..... lol

Hmm just updated my source with the latest Asus kernel source, and im not getting framebuffer console..... I know they patched the motochopper root exploit hopefully it didn't affect the fb patch.
---------- Post added at 01:56 AM ---------- Previous post was at 01:24 AM ----------
Either im doing something really dumb or Asus broke fb console.... its V10.6.1.14.10 with _thats pmc and ril patches and the fb patch. After splash screen it stays blank for about 5 seconds before booting straight into android

Hey guys, i originally missed this post, but it seems to have completely fixed the issue with the tablet locking up due to heavy I.O:
pvka13 said:
I was able to solve the random-freeze-during-heavy-I/O issue. The culprit is that large amount of memory is used as buffer cache to hold dirty pages. When the dirty page threshold is hit, all buffer cache is written out at once, without allowing other processes to do much I/O.
The solution is to add the following to /etc/sysctl.conf
Code:
vm.dirty_bytes=2048000
vm.dirty_background_bytes=1024000
The configuration can be reloaded without a reboot by running "sysctl -p" as root
Click to expand...
Click to collapse
With it i was about to extract a 200mb file while installing 100mb of packages while browsing xda many thanks to pvka13

Related

[DEV] Native Ubuntu (Lubuntu, LXDE) or (Unity2D,Gnome) on TF700T

This is an early alpha of ubuntu precise pangolin (12.04) running on the TF700T. You can choose from openbox, LXDE, and Lubuntu configurations. It is based on Nvidia Linux 4 Tegra R16 (armhf).
Added unity2d/gnome rootfs. 13-NOV
THIS IS NOT A SUPPORT THREAD, THIS THREAD IS FOR DEVELOPMENT RELATED POSTS ONLY. IF YOU DON'T HAVE SOME LINUX BACKGROUND/EXPERIENCE, THIS IS PROBABLY NOT THE PLACE FOR YOU.
There are four files on goo available for this setup:
precise-armhf.tgz - lubuntu/lxde rootfs (~590MB)
unity2d-rootfs.tgz - unity2d/gnome rootfs (~615MB)
precise-bootimg.zip - boot image for booting linux from /data/ubuntu
pa-tf700t-bootimg.zip - boot image for restoring to ParanoidAndroid ROM
This configuration uses internal storage (/data/ubuntu) for the root file system. You will need to have a custom recovery (I use TWRP) and a working adb setup.To install, take the following steps:
Copy the bootimg and rootfs of your choice (lubuntu/lxde or unity2d/gnome) to your /sdcard folder
Boot into recovery
Bring up a root shell with ADB
Create the folder for file extract "mkdir /data/ubuntu"
Change to the folder you created "cd /data/ubuntu"
Extract the files "busybox tar -zxvf /sdcard/precise-armhf.tgz" OR "busybox tar -zxvf /sdcard/unity2d-rootfs.tgz"
Flash the boot image (precise-bootimg.zip)
Reboot
To get back to your android setup (if you are running ParanoidAndroid) flash the PA boot image (pa-tf700t-bootimg.zip). If you are running a different ROM, replace the boot blob in the zip file with the one from your distribution. The naming is important, it has to match.
Thanks to the development communities from Linux, Ubuntu, and NVidia, and to lilstevie, Jhinta, cb22, and many others who have blazed the trail that provided guidance and insight.
This thread is intended for the use and contributions of developers who have the interest and capacity to move this along. It is not intended for spoon feeding and hand holding.
Please use the thread HERE for general q&a, discussion, and support.
Issues & Fixes
Issue: Onboard virtual keyboard displays all black
Fix: apt-get install python-gi-cairo
Reserved 2
This is sweet can't wait to try this out!! Awesome work !!!
Sent from my ASUS Transformer Pad TF700T using xda app-developers app
Cool! Where are the sources for precise-bootimg.zip?
_that said:
Cool! Where are the sources for precise-bootimg.zip?
Click to expand...
Click to collapse
I am using the CyanogenMod JB kernel sources. Still working on the config, but you can always extract the current version from zImage or proc.
Question
I'm not a developer, but I have some (limited) linux experience. I'm just wondering if it has been considered (and presumably deemed unfeasible) to make an install that boots from SD using a modified bootloader? I have an OpenPandora and generally linux distributions are installed and run from SD, which is extremely practical and would undoubtedly offer many benefits on the TF700. Ubuntu has been ported to that device, so it may be worthwhile looking into some of the work done there if this is of interest (I understand the problem would be creating a bootloader that offers such an option though).
Thanks for this, I may try it out at some point.
TitanUranus said:
I understand the problem would be creating a bootloader that offers such an option though
Click to expand...
Click to collapse
The TF700 bootloader is closed source (and cryptographically signed), so that's a very hard problem.
Putting the userspace stuff onto the SD card should be easy, just modify the mount options in the initrd.
For the kernel, we might be able to do something like chainloading a different kernel via kexec.
If I understand correctly, then a ROM based on a JB bootloader is needed.
Is there any chace of using a ROM based on an ICS bootloader (Baked Black Bean)?
THX
Added Unity2d/Gnome rootfs
Link to Unity2d/Gnome rootfs added to OP for those who prefer that interface.
Awesome work jaybob!
Is there any reason why you are using /data/ubuntu as the root? Typically, people tend to wipe data when flashing ROMs, at least for major changes. Using something like /sdcard/ubuntu for the root would mean that the install survives ROM hopping, etc.
I realize I can tweak it myself, but thought I would just recommend it for incorporation...
Do you know if your ubuntu implementation works for the tf300t?
Thanks!
---------- Post added at 10:07 PM ---------- Previous post was at 09:54 PM ----------
Valantur said:
Do you know if your ubuntu implementation works for the tf300t?
Thanks!
Click to expand...
Click to collapse
What I meant is: Do you think it's possible to use cb22's kernel (used to boot his arch implementation) and ramdisk on the tf300 and chroot to this ubuntu's init?
Valantur said:
Do you know if your ubuntu implementation works for the tf300t?
Thanks!
What I meant is: Do you think it's possible to use cb22's kernel (used to boot his arch implementation) and ramdisk on the tf300 and chroot to this ubuntu's init?
Click to expand...
Click to collapse
I believe that it should work with minor changes. My rootfs zips are built straight from Nvidia's Tegra3 L4T distribution, with LKM and firmware updates from the TF700T. My guess would be that if you copied the lib/modules/.... folder and put the appropriate firmware in lib/firmware (fw*.bin, nvram.txt, bcm*.hcd, etc.) it should work. You would probably want to extract into /data/linux instead of /data/ubuntu as that is what that initramfs uses. I know that I have been able to boot into that rootfs on the TF700T with those changes.
I hacked together a small shell script that can be used in Android to enter the Ubuntu installation as chroot and run console programs like apt-get in it. Maybe it is of use to someone.
Code:
GNU_ROOT=/data/ubuntu
mount -o bind /dev $GNU_ROOT/dev
mount -o bind /dev/pts $GNU_ROOT/dev/pts
mount -o bind /sys $GNU_ROOT/sys
mount -o bind /proc $GNU_ROOT/proc
mkdir $GNU_ROOT/run/resolvconf
rm $GNU_ROOT/run/resolvconf/resolv.conf
for i in 1 2 3 4; do
ns=`getprop dhcp.wlan0.dns$i`
if [ $ns ]; then
echo nameserver $ns >> $GNU_ROOT/run/resolvconf/resolv.conf
fi
done
chroot $GNU_ROOT /usr/bin/env PATH=/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin /bin/bash -l
umount $GNU_ROOT/proc
umount $GNU_ROOT/sys
umount $GNU_ROOT/dev/pts
umount $GNU_ROOT/dev
Save e.g as /data/enter-ubuntu and chmod 700. Feel free to use it or to post improvements.
Sweet! Been looking forward to this!
Now, I don't have any experience with dualboot.. Is there anyone who can assemble a guide, setting up dualboot along with this Debian version on the device?
Cheers..
edit: I'm afraid of bricking the device..
_that said:
I hacked together a small shell script that can be used in Android to enter the Ubuntu installation as chroot and run console programs like apt-get in it. Maybe it is of use to someone.
Code:
GNU_ROOT=/data/ubuntu
mount -o bind /dev $GNU_ROOT/dev
mount -o bind /dev/pts $GNU_ROOT/dev/pts
mount -o bind /sys $GNU_ROOT/sys
mount -o bind /proc $GNU_ROOT/proc
rm $GNU_ROOT/run/resolvconf/resolv.conf
for i in 1 2 3 4; do
ns=`getprop dhcp.wlan0.dns$i`
if [ $ns ]; then
echo nameserver $ns >> $GNU_ROOT/run/resolvconf/resolv.conf
fi
done
chroot $GNU_ROOT /usr/bin/env PATH=/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin /bin/bash -l
umount $GNU_ROOT/proc
umount $GNU_ROOT/sys
umount $GNU_ROOT/dev/pts
umount $GNU_ROOT/dev
Save e.g as /data/enter-ubuntu and chmod 700. Feel free to use it or to post improvements.
Click to expand...
Click to collapse
this requires that you was allready one time logged in or?
pingaan said:
Sweet! Been looking forward to this!
Now, I don't have any experience with dualboot.. Is there anyone who can assemble a guide, setting up dualboot along with this Debian version on the device?
Cheers..
edit: I'm afraid of bricking the device..
Click to expand...
Click to collapse
+1
maxal said:
+1
Click to expand...
Click to collapse
Agreed
Hundsbuah said:
this requires that you was allready one time logged in or?
Click to expand...
Click to collapse
that script didnt work for me, complained about couldnt find resolv.conf and something with chroot :/
---------- Post added at 11:32 PM ---------- Previous post was at 11:30 PM ----------
Password for this install?
Keeps asking for password when i try to login and i dont have a onboard keyboard it seems so i cant enter or try any password...
Hundsbuah said:
this requires that you was allready one time logged in or?
Click to expand...
Click to collapse
I tried it only after playing around a bit with Ubuntu, and then flashing back to the Android kernel, so I don't know. But in theory it should also work on a freshly unpacked installation - did you try it, and if if failed, what did it say?
l1nuxfre4k said:
that script didnt work for me, complained about couldnt find resolv.conf and something with chroot :/
Click to expand...
Click to collapse
I forgot to add a mkdir command... add before the "rm" line:
Code:
mkdir $GNU_ROOT/run/resolvconf
About "something with chroot" ...
I tested my script under CleanROM 2.3 and obviously it worked for me ... I assumed that everyone with a rooted Android device also has BusyBox installed, do you?
Remember guys, this is a development thread (read the red sections of the OP again), so if something doesn't work, either fix it yourself and tell us how you did it, or at least post exact error messages. Every post should contribute to the project in some way. If you just need help, use the related support thread.

[Multiboot][Mountloop][No Pc] Transformazing

Transformazing
This is for tf101 only and i do not take any warranty, means when you destroy your device with that it is your fault !
I did not find this method, nor i developed the kernel, the only thing i did was that i packed the newest jintha kernel into cwm flashable packages and had the idea to install more than
one linux system because i was pretty nerved because i had arch, ubuntu and 13.04 installed and always had to rename one to ubuntu.img. So i put the kernel into 3 (maybe make more)
packages, which look for the files /mnt/sdcard/.linux1, (/dev/mmcblk0p7 rw loop=/media/.linux1.img), .linux2.img and .linux3.img. The point is to hide the files, so you dont see them
for default if you boot to android.
Installation:
Download a armel/armhf image, rename it to .linux1/.linux2,/.linux3 and put it to internal sd(under android /mnt/sdcard or /storage/sdcard0(or 1, roms differ.)(i suggest tubuntu v 1..1, 1.2 has more bugs lol)
Flash the kernel in cwm (linux1 kernel for .linux1, linux2 kernel for .linux2, ... easy, isnt it?
To go back to android flash one of these (http://www.mediafire.com/?labcx60jowrdx), or extract the kernelblob form your rom, or just flashing your kernel should also work(not tested by me).
Any questions?
Changelog:
There is no changelog and there wont be one because i only put the kernels into mountloop packages, but i will try to get a stable 2.6 kernel into a mountloop package(no luck until now)
Advanages of this and other mehods:
Mountloop:More than one Linux os possible
No Pc needed
Easy to remove linux
Easy to give more space to linux/android
Faster to flash
Sl101/tf101g should work too
Option to boot linux from microsd
Olife, tubuntu:Chose os on boot
2.6 kernels and kernels greater than 8 mb possible (only 2.6)
Whats up with these Kernels:
.linux1: 3.1.10: Jintha Kernel, working : Sound, Hw acceleration, Sd, microsd, usb(if a dev is connected at boot), ...
sometimes freezes, use tubuntu v 1.1 and not 1.2
.linux2: 3.1.10: same as above
.linux3: 3.1.10:: dont know which, better touchpad, sound, hw acceleration, sd, microsd, usb(if something is connected at boot), stable, does not work with tubuntu and raring images
.linux4: 2.6.36.4: sound only headphones, no hw acceleration, working with nearly every image
kernelexternal: boots the os installed on micro sd(explained in 2nd post)
Images:
Archlinux and Raring: http://goo.im/devs/x3maniac
Ubuntu 11.10: http://www.ulozto.net/xyFaPBA/ubuntu-img-gz
Tubuntu v1.1(lubuntu 12.10): http://www.novaspirit.com/tubuntu/tubuntu.php
Debian: http://forum.xda-developers.com/showthread.php?t=1476835
Ubuntu 12.04 netinstall: http://forum.xda-developers.com/showthread.php?t=1852702
Lubuntu 12.04. http://www.ulozto.net/xauaj1b/ubuntu-img-gz
If this thread should be in general, pls move it!
The video quality is really bad(really really really bad), so i suggest only watch it if you dont understand it.​
I added the kernels for android 4.2 file system
The .linux .img s have to be placed on /storage/sdcard0 on first user
then flash the packages for your img name (.linux1.img or .linux2.img) and you boot to linux,
flash your kernel (kat, for exmple), to boot back to android
Linux tips and instructions
nstructions for linux:
get flash:
working on both firefox and chromium:
sudo apt-get install gnash gnash-common browser-plugin-gnash
perforance is bad, sound is perfect on youtube many videos can be watched in html5, their performance is way better( full framerate)
Get multitouch working:
On 11.10: sudo apt-get install touchegg and add it to startupapplications
on arch: yaourt -S touchegg (i think xD)
on others: compile touchegg
Put an image to microsd:​(will erase files on sdcard)
dd if=/sdcard/linux.img of=/dev/block/mmcblk1p1
How to get sound(if not working)​sudo usermod -a -G audio yourusername
sudo chmod -R 777 /dev/snd
enable every dacl and dacr
disable dac and adc companding(if sound is choppy)
How to get network-manager working on systems with wpa supplicant installed(arch, raring, netinstall)
look at your modules: is there 3.1.10-g8c2655b-dirty? if not, i suggest downloading it from here
sudo apt-get install netwrok-manager network-manager-gnome
sudo leafpad /etc/NetworkManager/NetworkManager.conf: change false to true
sudo leafpad /etc/network/interfaces should look like this:
# interfaces(5) file used by ifup(8) and ifdown(8)
auto lo
iface lo inet loopback
and remove /etc/wpa_supplicant. (sudo pcmanfm or sudo nautilus and then you have a fm with root.)
Mount internal:
sudo mkdir /media/internal
sudo mount /dev/mmcblk0p7 /media/internal
internal is now on /media/internal, you can select any folder.
Get opengl:
install tegra drivers(find a deb, if in 12.10 you ca just enable it through software-sources.)
sudo apt-get install libgl1-mesa-swrast
How to resize img files:
From another linux image or from a linux pc: (i will show it with image called ubuntu.img)
cd /to/the/folder/of/the/image
e2fsck ubuntu.img -f
resize2fs ubuntu.img 3500M (3500M is new size, M means MB, G means GB...)
e2fsck ubuntu.img
How to get touchpad working:
sudo apt-get install xserver-xorg-input-mtrack
and add to xorg.conf this at the end:
Section "InputClass
Identifier "elantech_touchscreen"
Matchproduct "elantech_touchscreen"
MatchDevicePath "/dev/input/event*"
Driver "mtrack"
EndSection
set keyboard layout:
add to startup programs this:
setxkbkmap de/en/fr
mount/chroot into an image from an otherinstall programs to an image with no network manager)
sudo mount /dev/mmcblk0p7 /media/int (mount internal)
sudo mount /media/int/media/.linux123.img /media/int (not linux 123, but .linux1, .linux2...)(now .linux123.img is on /media/int)
(sudo chroot /media/int) (now you are in the image)(internet connection should be there with 2.6 kernel)
Desktop tips:
Lubuntu/lxde:
Pro: The fastest and freakin light
Very customizeable
Beautiful
Easy to use with other components (etc/xdg/lxsession/LXDE(or lubuntu)/autostart)
Con:Cant think of anything bad
Xubuntu/xfce4
Pro: Very fast
Costumizeable
Con:I dont Like it
no hw acceleration
xfwm4 didnt work with touch on an image
ugly?
kubuntu/kde4
Pro:Customizable
Looks good
Con:Slow
e17
Pro: touchoptimiced
fast
con: Ugly(download themes)
Not easy to use with other components
ubuntu
Pro: Looks cool
con: Sloooow
gnome: Doesnt work right on our device
gnome-classic/gnome-session-fallback:
Pro:nearly as fast as lxde
supercool look
good with touch and with keyboard
con: cant think of anything bad
plasma-active/kde-plasma: Not tested
I suggest installing sudo apt-get install gnome-session-fallback, it is very fast, volume buttons are working and you can set brightness.(also install gnome-tweak-tool and gnome-themes-standard)
Use Components from other desktops in lxde/xfce:
(to have a supercool looking fast desktop)
add to startupapplications the stuff you want or just run it:
in lxde: /etc/xdg/lxsession/LXDE/autostart
in lubuntu:/etc/xdg/lxsession/lubuntu/autostart
in xfce/gnome/kde: i think there is a app for that: startup-applications i think
Docks:
Docky: works best(not working on all images)
Cairo-dock:not that smooth
Avant: not tested
unity-2d-launcher: the default unityy launcher you can see on the left in ubuntu-desktop
Panels:
lxpanel: Highly customizeable, fast, light
unity-2d-panel: love it, it is the top panel of ubuntu
xfce4-panel: little better than lxpanel
Use other Windor-managers in different desktops:
Add to startupapplications too or run te comand.
metacity --replace
openbox --replace
xfwm4 --replace
Credits to:
Jintha
Lilstevie
x3maniac
shaola​
Post screenshots please
Sent from my GT-S7562 using xda premium
akshay007dhore said:
Post screenshots please
Sent from my GT-S7562 using xda premium
Click to expand...
Click to collapse
The screenshots are from whatever image you use, you can see them for example in the tubuntu thread, but i will make some of ubuntu 12.10 or arch( the ones i use) and post them
Btw, anyone knows how to add images to a post? xD
I must be missing something fundamental lol, i downloaded the tubuntu.img in your post, extracted and renamed it to .linux1 then flashed the linux1 mount-loop then restarted, and end up at busybox terminal (every single thing ive tried ends there)
i'll to download a different image and see how it goes.
---------- Post added at 08:48 AM ---------- Previous post was at 08:46 AM ----------
bottom line 6th button in from the right in the message box, or the attachments button up and slightly to the left :good:
JoinTheRealms said:
I must be missing something fundamental lol, i downloaded the tubuntu.img in your post, extracted and renamed it to .linux1 then flashed the linux1 mount-loop then restarted, and end up at busybox terminal (every single thing ive tried ends there)
i'll to download a different image and see how it goes.
---------- Post added at 08:48 AM ---------- Previous post was at 08:46 AM ----------
bottom line 6th button in from the right in the message box, or the attachments button up and slightly to the left :good:
Click to expand...
Click to collapse
You are doing it righ, strange...
Is it called .linux1 or .linux1.img? Because right now i am using the linux1 kernel. What happens if you try the linux3 kernel for example?
And: Try to recopy the tubuntu image a second time, maybe it is corrupt(had exactly this problem yesterday xD)
Tell me how it goes
And: what are you talking from left and right?
transformador said:
You are doing it righ, strange...
Is it called .linux1 or .linux1.img? Because right now i am using the linux1 kernel. What happens if you try the linux3 kernel for example?
And: Try to recopy the tubuntu image a second time, maybe it is corrupt(had exactly this problem yesterday xD)
Tell me how it goes
And: what are you talking from left and right?
Click to expand...
Click to collapse
Cool, lol and i was trying to direct you to the "insert image" button
JoinTheRealms said:
Cool, lol and i was trying to direct you to the "insert image" button
Click to expand...
Click to collapse
Oh, thanks )
Is it working now?
transformador said:
Oh, thanks )
Is it working now?
Click to expand...
Click to collapse
Sorry my tf101's power buttons broken, and the tab froze inside of cwm6 so had to angrly disasemble my tf101 just to restart it :crying: lol anyway havn't downloaded a new image yet, whats your recommendation? im mainly intreasted in trying these multitouch gestures but also the 3.1 kernel NEVER worked for me anytime i tried to install it, if this works with hwaccelation ill be stoked(youtube etc work well?)
btw i renamed the image ".linux1" without .img @ the end ...ill add it an try
Heres the output messges i get with both images(tried to make it short to save sometime writing it out, also i took a photo of the output with a terrible camera and couldnt the rest of it so ill retry and update)
tegra_init_mmc memory not recongnised, memory scaling disabled
uipi_phy_power_on: timeout waiting for phy clock to
uipi_phy_power_on: uipi write failed
tegra-echi tegra-echi.1: failed to power on phy
fsi-tegra-udc fsi-tegra-udc: can't get charge...........
...._config_settings
power_supply dock_battery: failed to report
sdhc1-tegra sdhc1-tegra.2:vddio_sd_slot
:vddio_sd_slot regulator.......
tegra.0
:vddio_sd_slot regulator........
tegra protected aperture disabled becouse nvmmc..........
if you have the the distro in an .img folder it will slow down becouse if has to work instie that folder, where if you extract the image in your ubuntu distro folder it would run a bit faster, don't know if ou are doing that or not but it is my 50 cent
Awsome work and thank you, i can use current roms and dual boot without thincking about the nightmare of trying to figure out how to nvflash buckup a rom, back one ub, and then see it update.
Can someone make a video tutorial on this? Would be really grateful
Sent from my Transformer TF101 using Tapatalk HD
Well been trying to get this to work all day, seems the mount loop doesn't work on my tf101 currently (b60 sbk1) i get the same output messages whether then .linux1 image is in /sdcard/ or not. I could be doing something wrong but ive tried soooooo many combinations of things i would have fixed it by mistake lol.
Never mind , its great to see ubuntu getting better and easier for the tf101. Many thanks to transformador and the rest of you guys working on ubuntu:good::good:
JoinTheRealms said:
Heres the output messges i get with both images(tried to make it short to save sometime writing it out, also i took a photo of the output with a terrible camera and couldnt the rest of it so ill retry and update)
tegra_init_mmc memory not recongnised, memory scaling disabled
uipi_phy_power_on: timeout waiting for phy clock to
uipi_phy_power_on: uipi write failed
tegra-echi tegra-echi.1: failed to power on phy
fsi-tegra-udc fsi-tegra-udc: can't get charge...........
...._config_settings
power_supply dock_battery: failed to report
sdhc1-tegra sdhc1-tegra.2:vddio_sd_slot
:vddio_sd_slot regulator.......
tegra.0
:vddio_sd_slot regulator........
tegra protected aperture disabled becouse nvmmc..........
Click to expand...
Click to collapse
Thats exactly the error when i boot it without .linux1.img (yes theres an .img behind it), try to recopy it there.
Suggestions: Delete .linux1.img and copy it there a secound time (do you have it on /sdcard or on another location? has to be /sdcard, it is a symbolic link to /media on mmcblk0p7, but the /media on android is something other)
Try another .img file. Maybe try netinstall? It has an option to enable multitouch , tegra drivers and you can select desktop. (resize it before installing desktop)
Try linux2 kernel and call the image .linux2.img.
If nothing works, i will download the kernel and see what its wrong (would be stupid because i am booting it with EXACTLY the same kernel i uploaded(did not even copy it to another location )
Dont really understand your next post, is it working now or not? XD
alizafar said:
Can someone make a video tutorial on this? Would be really grateful
Sent from my Transformer TF101 using Tapatalk HD
Click to expand...
Click to collapse
If crappy quality is enough, for shure, but i only have a ****ing 320x240 phone camera xD
But if i can borrow my sisters phone, or my dads camera, i will do a video tutorial.
2 other things:
Who rated my thread 1 star? lol
Edit: forget what i wrote before xD
Video is up, but crappy quality...
plasmastrike said:
if you have the the distro in an .img folder it will slow down becouse if has to work instie that folder, where if you extract the image in your ubuntu distro folder it would run a bit faster, don't know if ou are doing that or not but it is my 50 cent
Awsome work and thank you, i can use current roms and dual boot without thincking about the nightmare of trying to figure out how to nvflash buckup a rom, back one ub, and then see it update.
Click to expand...
Click to collapse
The slowdown is minimal, i dont really recognice a speed difference between my mates tubuntu and mymethod.
Tried your suggestions, not working yet although the output messages have changed ill post them up later on. basically tried multiple roms/ recoverys, renamed the .img 1,2,3,4 etc. The last thing i can think of is my partition structures messed up or something from an earlier ubuntu nvflash, ill re-partition and re-try.
JoinTheRealms said:
Tried your suggestions, not working yet although the output messages have changed ill post them up later on. basically tried multiple roms/ recoverys, renamed the .img 1,2,3,4 etc. The last thing i can think of is my partition structures messed up or something from an earlier ubuntu nvflash, ill re-partition and re-try.
Click to expand...
Click to collapse
Does this method work for you? It is looking for ubuntu.img on /sdcard. It is from here:
http://forum.xda-developers.com/showthread.php?t=1537566
http://www.mediafire.com/?7f5fpatmgmg01ha
The kernel posted does NOT work with tubuntu, but it is 3.1
Also: you have it on internal, not external, right? has to be on internal
transformador said:
Does this method work for you? It is looking for ubuntu.img on /sdcard. It is from here:
http://forum.xda-developers.com/showthread.php?t=1537566
http://www.mediafire.com/?7f5fpatmgmg01ha
The kernel posted does NOT work with tubuntu, but it is 3.1
Also: you have it on internal, not external, right? has to be on internal
Click to expand...
Click to collapse
So far ive tried the net installer image and tubuntu(i thought the kernel might be an issue with it) ill try the older tubuntu. Ive tried x3maniac and shaola's versions. x3maniac's didnt do anything(after flashing it just booted into android) and shaola's had simular output messages as yours. And yeah its on /sdcard (internel) although was tempted to try externel but only got a class 4. I appreciate the help mate:good:
JoinTheRealms said:
So far ive tried the net installer image and tubuntu(i thought the kernel might be an issue with it) ill try the older tubuntu. Ive tried x3maniac and shaola's versions. x3maniac's didnt do anything(after flashing it just booted into android) and shaola's had simular output messages as yours. And yeah its on /sdcard (internel) although was tempted to try externel but only got a class 4. I appreciate the help mate:good:
Click to expand...
Click to collapse
I have got the same issue. tried all linux1, 2, 3, 4.zip files. On linux4.zip I get the following error meassage:
/host/media/.linux4.img does not exist
But the file is on /sdcard

[KERNEL/MOD] [LINUX] [Rootbind] [Native EMMC/all TF101&TF101G/fast/tested] [2-Jul-13]

[KERNEL/MOD] [LINUX] [Rootbind] [Native EMMC/all TF101&TF101G/fast/tested] [2-Jul-13]
UPDATE 2013/11/08: New kernel released with USB and framebuffer fixed. See post #3.
UPDATE 2014/05/16: New Ubuntu 14.04 filesystem. See point #2 below under Installation.
UPDATE 2014/06/03: New kernel released with USB and framebuffer fixed, OC to 1.5 GHz. See post #3 and #326.
UPDATE 2014/07/09: New kernel released with OC to 1.5 GHz fully working, boots every time. See post #3 and #334.
This is a kernel/initrd mod that allows you to run Linux (Ubuntu, Debian, Arch,...) on your TF101 from the internal EMMC (/data partition in Android) without repartitioning your tab.
Disclaimer:
This works on my tablet and I use it daily. However, I am not responsible for any bricks or if you damage your beloved TF. YOU ARE DOING THIS AT YOUR OWN RISK!
Features and advantages:
Fast (and I mean about as fast as it's gonna get on this device). See post #2 for benchmarks.
No need to repartition to get this. Previously TF101 users could run Linux on EMMC but they had to repartition with wheelie/nvflash, but it wasn't available to TF101G users (of which I'm one).
Any free space on your /data partition is available to both Linux and Android. When you delete stuff on either operating system, the free space is available for both again, as they are running off the same partition. Previously, when you re-partitioned e.g. with OLiFE you had to allocate a certain space (8GB by default) for Linux, then this was not available for Android even if you're not using all of it in Linux.
Way faster than loopmount, especially for disk writes.
Way faster than running Linux off a MicroSD card ext4 partition (even with class 10).
Dualboot is achieved just by flashing either the Android or the Linux kernel.
So how does this work?
The kernel/initrd is modded to take an extra parameter "bind=/path/to/linux/rootfs" on the command line. This will then bind-mound that path to the Linux root mount. It works pretty similar to the way a loop-mounted linux image is loaded and set up during boot, except that now bind-mount is used, not a loop-mount. This is possible because both Android and Linux use the ext4 filesystem, so they can actually share the same partition.
N.B. This thread is not a guide on how to get Ubuntu running on your TF101. There are plenty of guides for that, e.g.
http://forum.xda-developers.com/wiki/ASUS_Eee_Pad_Transformer/How_to_install_Ubuntu
http://forum.xda-developers.com/wiki/ASUS_Eee_Pad_Transformer/How_to_install_Ubuntu/Ubuntu_Install
Tubuntu by x3maniac - http://forum.xda-developers.com/showthread.php?t=1995157
Net-Install by NoDiskNoFun - http://forum.xda-developers.com/showthread.php?t=1852702
Transformazing by transformador - http://forum.xda-developers.com/showthread.php?t=2167224
Make sure to read those threads to get an idea of how this works.
READ THESE INSTRUCTIONS CAREFULLY!
Installation:
Take a Nandroid backup, just in case something goes wrong.
Get a Linux root filesystem if you don't already have one.
See this thread for a discussion of various filesystems available for rootbind.
Alternatively roll your own using debootstrap as described by shaola:
http://forum.xda-developers.com/showthread.php?t=1476835
NEW! For a fully working Kubuntu 14.04 image (with graphics acceleration using the Nvidia drivers) see this post: http://forum.xda-developers.com/showpost.php?p=52697775&postcount=303
This is already an image in a tar file so it doesn't need to be mounted, so instead of the code below you can merely do the following:
Code:
mkdir -p /data/linuxroot
busybox chmod 755 /data/linuxroot
cd /data/linuxroot
tar -xpjf /path/to/my/saved/kubuntu-14.04.tar.bz2
Running Android, copy the root filesystem to a directory on your /data partition, preserving the permissions. The easiest is with the "tar" command (see below). The default install assumes that Linux lives in /data/linuxroot under Android.
For a Linux image in a file that is used for loop-mount (assume it is in /sdcard/ubuntu.img, or edit accordingly), run the following in a terminal when running Android (make sure you are root):
Code:
busybox mount -o remount,rw /
mkdir -p /data/linuxroot
busybox chmod 755 /data/linuxroot
mkdir -p /mnt/ubuntu
busybox mount -o loop /sdcard/ubuntu.img /mnt/ubuntu
cd /mnt/ubuntu
tar -cvp * | tar -C /data/linuxroot -xp
cd /
busybox umount /mnt/ubuntu
rmdir /mnt/ubuntu
busybox mount -o remount,ro /
(note in tar command first -c is lowercase, second -C is uppercase)
For a Linux rootfs that lives on a separate partition (e.g. 2nd part. on MicroSD), run the following (assumes linux is in /dev/block/mmcblk1p2, otherwise edit accordingly):
Code:
busybox mount -o remount,rw /
mkdir -p /data/linuxroot
busybox chmod 755 /data/linuxroot
mkdir -p /mnt/ubuntu
busybox mount -t ext4 /dev/block/mmcblk1p2 /mnt/ubuntu
cd /mnt/ubuntu
tar -cvp * | tar -C /data/linuxroot -xp
cd /
busybox umount /mnt/ubuntu
rmdir /mnt/ubuntu
busybox mount -o remount,ro /
Copy kernel modules to your rootfs. Download modules-3.1.10-9.tar.gz to your /sdcard. then:
Code:
cd /data/linuxroot/lib/modules
tar -xzf /sdcard/modules-3.1.10-9.tar.gz
Flash the Linux kernel. Either flash the zip from recovery or copy the kernelblob directly to the staging partition with dd (if you don't know what I'm talking about here, then use the recovery method).
Reboot 'n enjoy! Remember to run "sudo depmod -a" after the first Linux boot, and reboot. Otherwise your modules won't load and wifi, etc., won't work.
To re-boot into Android, simply flash the boot image/kernelblob from your Android ROM.
Notes:
The kernel is compiled from Jhinta's source with a few modifications to the config - http://forum.xda-developers.com/showthread.php?t=1683145
Make sure not to have a /host directory in your Linux rootfs - this interferes with the bind mount!
The Linux rootfs can live anywhere on your Android /data partition (the default is /data/linuxroot). If you want to change this, then you'll have to blobunpack the kernelblob-rootbind, unpack the boot image (kernelblob-rootbind.LNX) with abootimg, change the command line as desired, re-pack the boot image with abootimg, and re-pack the blob for flashing.
The "bind" cmdline argument is the location of your Linux rootfs without the initial "/data". So if your Linux rootfs lives on /data/my/linux/path under Android, then you'd have to change the cmdline parameter to "bind=/my/linux/path".
Make sure, however, not to put the Linux rootfs to the "internal storage" (/data/media) or any subdirectories thereof. This plays havoc with the Android media scanner when re-booting into Android and your tablet may slow down to a crawl.
Under Android your EMMC partitions are /dev/block/mmcblk0p1,2,3,....
Under Linux, this is /dev/mmcblk0p1,2,3....
Thanks to:
lilstevie - for bringing Ubuntu to our tablet
Jhinta - for his 3.1.10 kernel
shaola - for his debootstrap guide
x3maniac - for his Tubuntu installer
transformador - for his mountloop instructions
TomTcom - for all his Ubuntu-related guides on xda
Kingzak34 - for his dualboot guide and general help/discussion
DjDill - for putting together the collection of rootbind filesystem images
(if your name should be here and I have forgotten you, please PM me...)
Benchmarks
Using "fio" (available from Ubuntu repos). All speeds in kB/s.
In the below, loopmount refers to a loopmounted image on internal storage, MicroSD refers to running linux from an ext4 partition off a class-10 MicroSD card, and rootbind refers to the method described in this thread.
Test: sequential read (64 MB)
rootbind 31906
loopmount 29088
MicroSD 15312
Test: random read (64 MB)
rootbind 5605
loopmount 11340
MicroSD 1620
Test: sequential write (8 MB)
rootbind 9694
loopmount 1373
MicroSD 3040
Test: random write (8 MB)
rootbind 4659
loopmount 1102
MicroSD 722
New kernel
New kernel for Linux rootbind:
based on kernel source from @Sni
See here: http://forum.xda-developers.com/showpost.php?p=43203818&postcount=569
N.B. If you use this kernel you will have to copy new firmware for the wifi driver into /lib/firmware. Get it from Sni's post (link above).
USB hotplug fixed and fully working!
framebuffer fixed (Ctrl-Alt-F1 to F6 for console access)
hardware graphics acceleration now fully working with the latest Nvidia Linux-4-tegra drivers. es2gears no longer throws errors.
Two versions: one clocked to standard 1.0 GHz, the other one overclocked to 1.2GHz. Remember to extract the relevant modules to your linux root filesystem. For installation, I have provided a CWM or TWRP flashable zip, or a blob that you can flash directly with dd to the staging partition (if you don't know how to do this, use the recovery method).
I have tried at great length to overclock to higher frequencies but could not succeed. For some reason the TF just froze with a black screen after booting. I tried many combinations of voltages and frequencies. At least it's oc'ed to 1.2 and stable (in my hands), but if you are experiencing problems you can revert to the 1.0GHz or keep using the previous kernel which is oc'ed to 1.6 but USB is broken.
If anyone wants to take a stab at this you are more than welcome
My sources: https://github.com/jmrohwer/TF101-GNU-kernel
EDIT: New kernel 3.1.10-15 overclocked to 1.5GHz. Boots every time! Needs configuration of your overlock speeds with cpufrequtils. Read this post:
http://forum.xda-developers.com/showpost.php?p=54031885&postcount=334
MD5SUM:
3aee8cacf9037dfc3c8ef0363780254f Ubuntu-3.1.10-15-rootbind-oc1.5.zip
Seems to be great, and very very easy to dual boot, as TWTR will be always avaible to flash the kernels.
The reason I left linux behind on my TF is that team EOS has a plenty of updates and I like to keep up with the devs and the dual boot method i used overwrites the custom recovery.
Now it seems to be perfect forme.
Simply amazing, an other victory for TF101 ! And in addition of more speed than mountloop it's even easier to manage.
Thanks once again, I think my mounltoop will became a full install
Forgive my ignorance, but I've googled and searched the TF101 forums to no avail; what is TWTR? With Google I only found a video of someone running what looked like regular CWM touch on a TF101...
Edit: Nevermind, I figured out that it must be referring to the TeamWin recovery, which until now I've only ever seen referred to as "TWRP".
Thanks! I will test this tomorrow.
smokesignals said:
Forgive my ignorance, but I've googled and searched the TF101 forums to no avail; what is TWTR? With Google I only found a video of someone running what looked like regular CWM touch on a TF101...
Edit: Nevermind, I figured out that it must be referring to the TeamWin recovery, which until now I've only ever seen referred to as "TWRP".
Click to expand...
Click to collapse
It is TWRP, but I guess TWTR = Team Win Touch Recovery
---------- Post added at 11:52 PM ---------- Previous post was at 11:23 PM ----------
I am root, but this command says read only file system
mkdir -p /mnt/ubuntu
Made the folder using a file manager instead
Next step
mount -o loop /sdcard/ubuntu.img /mnt/ubuntu
Fails and just gives me a list of possible options for the mount command
*Detection* said:
It is TWRP, but I guess TWTR = Team Win Touch Recovery
---------- Post added at 11:52 PM ---------- Previous post was at 11:23 PM ----------
I am root, but this command says read only file system
mkdir -p /mnt/ubuntu
Made the folder using a file manager instead
Next step
mount -o loop /sdcard/ubuntu.img /mnt/ubuntu
Fails and just gives me a list of possible options for the mount command
Click to expand...
Click to collapse
I had that problem too. Not sure how to fix it on the tablet, I just copied the image I wanted to use (in this case the Arch Linux ARM one -- about which more later) to my Linux box, loop mounted it, tar'd up the files there, copied that to an SD card, and extracted it on the tablet.
However, about Arch Linux ARM, I learned not to bother using the image from the Tubuntu thread and instead just get the latest version from the ALARM downloads page. Use the "NVIDIA Tegra2 TrimSlice" one. The default root password is "root".
The reason not to use the one from the Tubuntu thread is that it is out of date -- Arch has merged /bin and /sbin into /usr, but the image in the Tubuntu thread predates that, and it's a huge pain to upgrade it properly.
smokesignals said:
I had that problem too. Not sure how to fix it on the tablet, I just copied the image I wanted to use (in this case the Arch Linux ARM one -- about which more later) to my Linux box, loop mounted it, tar'd up the files there, copied that to an SD card, and extracted it on the tablet.
However, about Arch Linux ARM, I learned not to bother using the image from the Tubuntu thread and instead just get the latest version from the ALARM downloads page. Use the "NVIDIA Tegra2 TrimSlice" one. The default root password is "root".
The reason not to use the one from the Tubuntu thread is that it is out of date -- Arch has merged /bin and /sbin into /usr, but the image in the Tubuntu thread predates that, and it's a huge pain to upgrade it properly.
Click to expand...
Click to collapse
Thanks for that, at least I know I'm not doing something wrong my end, I was trying the Ubuntu 12.04 netinstall from the Transformazing thread, I`ll no doubt try a few until I find one I like
I don't have a Linux box atm, but a quick fix with a wubi or VM install tomorrow and I`ll give your method a shot
Cheers
Hey jrohwer can you have a look at this ? It may interest you
http://forum.xda-developers.com/showpost.php?p=43203818&postcount=569
A silly question.... But do i need pre installed mountloop?
I am kinda confused though lol.
Kingzak34 said:
Hey jrohwer can you have a look at this ? It may interest you
http://forum.xda-developers.com/showpost.php?p=43203818&postcount=569
Click to expand...
Click to collapse
Looks interesting, I can see whether I can compile his sources, but it will have to wait a while (don't have a lot of time atm).
*Detection* said:
It is TWRP, but I guess TWTR = Team Win Touch Recovery
---------- Post added at 11:52 PM ---------- Previous post was at 11:23 PM ----------
I am root, but this command says read only file system
mkdir -p /mnt/ubuntu
Click to expand...
Click to collapse
Yes, sorry for got to add the step to remount / in rw mode. OP is updated.
Made the folder using a file manager instead
Next step
mount -o loop /sdcard/ubuntu.img /mnt/ubuntu
Fails and just gives me a list of possible options for the mount command
Click to expand...
Click to collapse
Most probably you are using the Android mount command. The busybox mount command has more functionality. I added the OP to explicitly call the busybox mount/umount commands (I have mine aliased by default). Indeed I checked and the Android mount command does not work for loop mount.
vietchinh said:
A silly question.... But do i need pre installed mountloop?
I am kinda confused though lol.
Click to expand...
Click to collapse
No you just need a mountloop image which you can then mount as described in the OP, to copy the files over to /data/linuxroot.
jrohwer said:
Yes, sorry for got to add the step to remount / in rw mode. OP is updated.
Most probably you are using the Android mount command. The busybox mount command has more functionality. I added the OP to explicitly call the busybox mount/umount commands (I have mine aliased by default). Indeed I checked and the Android mount command does not work for loop mount.
Click to expand...
Click to collapse
Thanks, I`ll give this another shot tonight then with the new instructions
jrohwer said:
Looks interesting, I can see whether I can compile his sources, but it will have to wait a while (don't have a lot of time atm).
Click to expand...
Click to collapse
Yup of course take your time I think something good is coming
Tapatalké depuis mon Nexus 4 MIUI !
jrohwer said:
No you just need a mountloop image which you can then mount as described in the OP, to copy the files over to /data/linuxroot.
Click to expand...
Click to collapse
Thanks, but i have new problem. Uh i cant execute this line: tar -xzf /sdcard/modules-3.1.10-9.tar.gz. It give's me this:Tar invalid option bla bla bla ;3 SO CLOSE TO COMPLETING T.T.
vietchinh said:
Thanks, but i have new problem. Uh i cant execute this line: tar -xzf /sdcard/modules-3.1.10-9.tar.gz. It give's me this:Tar invalid option bla bla bla ;3
Click to expand...
Click to collapse
Leave the - off. so it would be
Code:
tar xvf /sdcard/modules-3.1.10-9.tar.gz
Usually works for me.
bfmetcalf said:
Leave the - off. so it would be
Code:
tar xvf /sdcard/modules-3.1.10-9.tar.gz
Usually works for me.
Click to expand...
Click to collapse
In valid tar magic ._.
i assume i need extract manually heh

[GUIDE] Ubuntu in a chroot on the Galaxy S4 - now with Native Booting!

Notice (4/16/14): I'm no longer here. I've said "goodbye" to AT&T and their locked bootloader schemes. I'm voting with my wallet - I've sold my I337 and switched to T-Mobile. My apologies to the community, but you're now on your own here.
Intro/About/Requirements:
This thread started as a guide for people who wanted to run Ubuntu in a chroot, and then connecting to it locally with a VNC client. This method has been used countless times on other devices, with many thanks to @zacthespack and his his group, LinuxonAndroid. Unfortunately, this method did not work out-of-the-box on my device, so I tweaked things to work with the Galaxy S4 and posted them here in this thread.
However, the most people immediately noticed that with this method the performance is not great, and some applications can't work in a headless environment. With a comment made by zackthespack, I began researching what it would take to get Ubuntu to write directly to the device's framebuffer. After a few months, I not only managed to accomplish this, but also developed a way to get the Galaxy S4 to boot directly into Ubuntu. As far as I have seen, both of these are a "first" for this handset.
All of these methods require root. The VNC Chroot does not require a custom kernel, but the other methods require a custom-built kernel. For the I337 (AT&T) handset, this can pose a problem if you have bootloaders that are MF3+. If you're using MDB/MDL bootloaders still, you shouldn't have a problem with this and you can Loki the custom kernel without issue.
Depending on your ROM and/or Kernel, you may also need a new version of BusyBox installed, even for the VNC method. You'll find a few apps on the Play Store that can do this for you. Beware that some of them are not easily reversible (such as TinyBox), so if you're stuck on MF3 with no way to create/restore a nandroid/system backup, you should be careful.
Click to expand...
Click to collapse
Disclaimers:
Following this guide and/or flashing anything I've provided to your device is your own responsibility. If something breaks, you break your device, or something explodes, I can't be held liable (I'll help correct any situations you may put yourself in, however). I claim no rights to any proprietary software or intellectual property included in this post or the packages contained herein. By using any of this software, you agree to whatever licenses/agreements that the creators may have included with their software. If you use any of this stuff in your own project, please provide credit where credit is due. For example, if you take my u.sh script and adapt it to some new device (i.e. Galaxy S 5), please at least mention where it came from.
Click to expand...
Click to collapse
VNC Chroot Method (original):
This method is loosely based on this thread for the Galaxy S3 and the ubuntu.sh script there. It didn't work for the S4, but I've made several tweaks to it, simplifying it a ton, and otherwise getting it to work perfectly on my S4. I've tried this using my AT&T Galaxy S4 (SGH-I337) on both the MDL build and the MF3 build - both seem to work great.
Instructions:
Download the Ubuntu 13.04 Small v1 image here.
Create a folder on your sdcard labeled "ubuntu" by whatever means you want to.
Extract the ubuntu.img from your downloaded zip into this folder.
Download my version of the ubuntu.sh and place it on the root of your sdcard.
Open the script in a text editor and read through it. Never run a script like this on your android without first knowing what it does - especially when the author is telling you that you need root. If you're happy with it, proceed.
Install an terminal emulator of your choice. I personally used this one, and technically an adb shell will work too (but you'll be tethered to your PC...).
Install a VNC Client of your choice. I personally used this one, but there might be better/faster ones out there.
Open the terminal emulator, and execute the following commands:
Code:
su
sh /sdcard/ubuntu.sh
If you see a bunch of errors and get dumped back at the "[email protected]:/ # " prompt, then something went wrong. Report your errors in this thread. Remember, this requires root (and the "su" command to get there, of course).
You'll be prompted for some setup parameters, which you can save at the end for later. Just answer each question and press Enter after each:
You'll need to provide a new password for the "ubuntu" user. A simple passwords like "ubuntu" works, unless you want some security.
Start VNC server? (y/n) - always choose "y". We need this to interact with the device.
SSH server? Optional. If you use it, you should enable it.
Screen size: Enter whatever you want. I personally used 960x540 (one quarter of the S4's screen size) so that I could actually interact with things using the touch screen.
Save settings as defaults? - You might not want to do this until you have a screen size that works best for you.
Once you see the prompt, "[email protected]:~# " - you're in! You now have Ubuntu running in a chroot. As the on-screen instructions suggest, type "exit" at this prompt to end the chroot and Ubuntu. It is recommended to do this when you are done so that the ubuntu.sh script can clean up after itself (unmounting things, etc.).
Leave your terminal emulator app running! Use your Home button to return home and leave it running.
Open you VNC client and connect with the following settings:
Nickname: (whatever you want)
Password: ubuntu
Address: localhost
Port: 5900 (default)
Username: (leave blank)
Color Format: 24-bit color (you can use lower if you want better performance)
Connect. For the VNC app I used, I had to zoom in to make the screen fit correctly (use pinch-to-zoom, and then use the "+" button on-screen). Also, you can play around with the Input Mode some if you wish.
Enjoy Ubuntu!
As you can see, it's not terribly complicated to get this up and running. Once you have set it up the first time, it's a lot smoother from then on out. The script is designed to allow you to use the external SDCard if you wish. Just use place the ubuntu.img in an "ubuntu" folder on your external SDCard, drop the ubuntu.sh on the root of the external SDCard, and use "sh /mnt/extSdCard/ubuntu.sh" instead (don't forget "su"!).
Click to expand...
Click to collapse
Freedreno Chroot Method (NEW):
This long-winded tutorial will explain how you can setup Xubuntu-desktop in a chroot. Before attempting any of this, you should read through all the steps and be sure you're comfortable performing the steps needed.
This requires roughly 2GB free space on your /data partition - the actual finished install is about 1.4GB, but it will require some extra space while it installs Freedreno and other components. HINT: Keep in mind that your /data partition is shared with your internal sdcard (your internal sdcard gets whatever space is leftover at the end of the /data partition), so you can get an idea how much free space you have by looking at how much space your internal sdcard has available.
Instructions:
Step 0 (option A) - Build Custom Kernel
You will need to install a custom kernel that has specific options enabled in the configuration, along with a few patched files in the source code. This list of changes is based on a delta from the stock I337 MF3 kernel, available at http://opensource.samsung.com/. You should be able to apply these changes to "any" kernel that you can build from source, so this documentation may apply to devices other than the I337.
Kernel Mods:
Required config changes:
Code:
CONFIG_DEVTMPFS=y
# CONFIG_DEVTMPFS_MOUNT is not set
CONFIG_DRM=y
CONFIG_MSM_KGSL_DRM=y
# CONFIG_KGSL_PER_PROCESS_PAGE_TABLE is not set
# CONFIG_MSM_KGSL_PAGE_TABLE_COUNT is not set
CONFIG_FB_MODE_HELPERS=y
CONFIG_FB_MSM_TRIPLE_BUFFER=y
CONFIG_FB_MSM_DEFAULT_DEPTH_BGRA8888=y
# CONFIG_FB_MSM_DEFAULT_DEPTH_RGBA8888 is not set
Fix for Wi-Fi problems when using MF3 kernel on UCUAMDL bootloaders (i.e. "unadulterated" or "neutered"):
Code:
CONFIG_PROC_AVC=y
Required Patches to kernel source code:
https://github.com/freedreno/kernel-msm/commit/4c0281745f8c85707be88acebb557aca0b8f1dba
https://github.com/freedreno/kernel-msm/commit/228f65d48d4855d903e3b4642179dfa14eedd040
https://github.com/freedreno/kernel-msm/commit/54b510b2e6bccf08fdf3a8ad00a62b27c2f8c1e6
Additional changes required for sudo to work (added 10-25-13 in v4):
Code:
# Samsung Rooting Restriction Feature
#
# CONFIG_SEC_RESTRICT_ROOTING is not set
# CONFIG_SEC_RESTRICT_SETUID is not set
# CONFIG_SEC_RESTRICT_FORK is not set
# CONFIG_SEC_RESTRICT_ROOTING_LOG is not set
Additional changes to the initramfs required for sudo to work (added 10-25-13 in v4):
Edit fstab.qcom, remove the nosuid, part of the line that references userdata.
Step 0 (option B) - Download Custom Kernel Instead
Don't want to compile your own kernel from source? If you have the I337, you can use mine! As mentioned above, this kernel is based on the original MF3 source from Samsung, with the modifications listed above. If you are stuck with MF3+ bootloaders on your I337, you will not be able to install this kernel directly (at the time of this writing). MDB/MDL bootloaders are fine, but you will need to flash loki-doki afterwards (this kernel is not pre-lokified!). This kernel might work with other similar variants (such as the M919), but I haven't tested this on anything except my own I337 daily-driver. YMMV. If you run into issues, you might need to wipe cache/dalvik. This will likely only work with TouchWiz-based ROMs (I have not tried it with AOSP). Here's some downloads for you:
mf3-freedreno-android-boot-v4.zip - CWM/TWRP flashable zip.
- Boots to android, allows Ubuntu with Freedreno to work in a chroot.
- Compiled with the original (slightly modified) MF3 initramfs and "mf3-freedreno-minimum-zImage-v4" (below).
- Includes minimal configuration changes described above, plus the WiFi fix part.
mf3-freedreno-minimum-zImage-v4 - Just the MF3 kernel itself with minimal changes to get the chroot to work.
mf3-freedreno-minimum-config-v4 - Yeah, that's right. I'm providing the .config files I used for all of this.
Step 0.5 - Install the Kernel
Before you can start up the chroot properly, you'll need to have the custom kernel installed. You don't want the "ubuntu-boot" version right now, because you don't have an Ubuntu install to boot to. If you're using my pre-built kernel, first flash mf3-freedreno-android-boot-v4.zip and then flash loki-doki.zip.
Step 1 - Companion Files
Download this file: mf3-freedreno-companions-v4.zip - Non-flashable zip. This includes the script files, which you should promptly read through both u.sh and launch.sh. It is always good practice to read through any script file you get from the internet, making sure it's doing what you would expect it to. Also check out CREDITS.txt, which includes information about the included upstart-dummy.tar.gz and start-stop-daemon files.
Extract the companion files .zip and place its contents on the root of your internal sdcard (/sdcard/). Don't extract the contents of upstart-dummy.tar.gz. This is your $src directory. You can change this if you wish (see script for details).
Step 2 - Install/Configure Ubuntu
Install an terminal emulator of your choice. I personally used this one, and technically an adb shell will work too (but you'll be tethered to your PC...). At the console/shell, type the following two commands:
Code:
su
sh /sdcard/u.sh bash
The script will download Ubuntu Core and install Freedreno, upstart-dummy, and lubuntu-desktop. Total download size will be around 425MB. Total install time will vary, but count on it taking at least 45 minutes to install and configure everything. At the very end, you'll be prompted to enter a password for the new user "ubuntu".
Step 2.5 - Exit ubuntu
When you see the message "Type 'exit' (without quotes) to leave ubuntu," the install is complete. You'll notice that your prompt changed to "[email protected]". This is the easiest way to confirm that you're actually inside the ubuntu chroot. Type exit and hit Enter to get back to android.
Step 3 - Fire it up!
From now on, you can start Ubuntu using u.sh in any of these three ways:
sh /sdcard/u.sh - This will make initial prep, STOP android (black screen), launch the chroot, install/configure if needed, and will execute "service lightdm start". This will give you the greeter and you can login as "ubuntu". If the lightdm service stops for whatever reason (see info about the home button below), the script will continue by exiting the chroot and rebooting your device.
[*]sh /sdcard/u.sh bash - Same as above, except that it will not stop android, not startx (will give bash shell instead), and will not reboot your phone when you exit the shell.
[*]sh /sdcard/u.sh destroy - This will do exactly as it sounds - destroy your ubuntu installation. This will unmount your /sdcard from ubuntu (if still mounted somehow) and then recursively delete your ubuntu installation. If you change the source or destination directories in the main script, you should be careful deleting things.
NOTE: Remember to ALWAYS run any these from a root shell, whether via terminal emulator, via adb shell, or using SManager (or similar).
Step 4 - Note the Home Button and Touchpad
Take note that any time you have X running via lightdm, the hardware Home button will kill the X server. This is intentional, and will exit the chroot and reboot your phone. You'll also notice that currently, the touchscreen acts like a giant touchpad (like on a laptop). Use two fingers to right-click or scroll. Direct touchscreen input is not available at this time due to a segmentation fault that evdev causes when used on this device in a chroot.
Step 5 - (optional) Make Changes and Do it All Over Again
Customize the crap out of it! Edit my u.sh, launch.sh or xorg.conf and have fun. If you find great improvements, please post them in this thread! In future revisions, I might include them. Things should be well documented within the scripts. You might even change the bit at the end of launch.sh that starts "service lightdm start&" instead of "startx" - this would give you the greeter and let you login as the user "ubuntu" if you want. Also note that those three files are the only ones that must remain in your $src directory if you wish to continue to run this as a chroot. By the way, booting directly to Ubuntu after it is installed does not require any of the companion files anymore.
Click to expand...
Click to collapse
Native Boot Method (NEW):
This part of the tutorial is for those who wish to take things a step further and boot your device directly into Xubuntu-desktop. This will require that you setup the Freedreno chroot properly, and then you'll be installing a new boot.img. While this doesn't replace your /system partition, you won't be able to boot directly into Android while you have this boot.img installed.
Instructions:
Step 1 - Install Ubuntu
Basically, you need to perform all the steps for the Freedreno Chroot method, and get that up and running first. All you're doing here is swapping out your kernel.
Step 2 (option A) - Build Custom Kernel
You'll need all of the kernel customizations included in the freedreno chroot method, plus these listed below:
NOTE: You will need some proprietary blobs, which can be found on your device in the /etc/firmware directory.
Config changes to enable booting directly into Ubuntu (beyond replacing the initramfs...):
Code:
CONFIG_EXTRA_FIRMWARE_="audience-es325-fw.bin a300_pm4.fw a300_pfp.fw vidc_1080p.fw"
CONFIG_CMDLINE="console=tty0 fbcon=vc:0-3"
# CONFIG_CMDLINE_FROM_BOOTLOADER is not set
CONFIG_CMDLINE_EXTEND=y
# CONFIG_CMDLINE_FORCE is not set
Optional config changes to enable the framebuffer console when booting directly into Ubuntu - useful for debugging.
Code:
CONFIG_VT_CONSOLE=y
CONFIG_VT_CONSOLE_SLEEP=y
CONFIG_VT_HW_CONSOLE_BINDING=y
CONFIG_DEVPTS_MULTIPLE_INSTANCES=y
CONFIG_FRAMEBUFFER_CONSOLE=m
CONFIG_FRAMEBUFFER_CONSOLE_DETECT_PRIMARY=y
# CONFIG_FRAMEBUFFER_CONSOLE_ROTATION is not set
# CONFIG_FONTS is not set
NOTE: You will need to grab some .ko files that are created, which must be loaded in the following order:
Code:
insmod /ko/font.ko
insmod /ko/softcursor.ko
insmod /ko/bitblit.ko
insmod /ko/fbcon.ko
I recommend that you include these four lines into the init script that is included in the ubuntu ramdisk. These can go pretty much anywhere after the ". /scripts/functions" part, but before it calls out to run-init. Also, don't forget to drop those .ko files into a new /ko directory in the initramfs. If you want to load these with modprobe, I'll leave that up to you (good luck).
Replace the entire ramdisk/initramfs:
At this time, I'm not going to provide instructions on how to do this. You'll need this mako boot.img straight from Ubuntu, repacked with the zImage created here. For what it's worth, the re-pack tool I'm using includes --cmdline 'androidboot.hardware=qcom user_debug=31 zcache', but I'm not sure if that's needed (especially considering our kernel seems to use qcache?). Anyways, good luck.
Step 2 (option B) - Download Custom Kernel Instead
Again, if you don't want to compile your own kernel from source, you can download mine and use it. The same warnings and restrictions apply as they do in Step 0 (option B) of the Freedreno Chroot method. And here's your downloads:
mf3-freedreno-ubuntu-boot-v4.zip - CWM/TWRP flashable zip.
- Boots to Ubuntu directly, but only if your Ubuntu install is located at /data/ubuntu (Default).
- Compiled with the original MF3 initramfs and "mf3-freedreno-everything-zImage-v4" (below).
- Includes all configuration changes described above.
mf3-freedreno-everything-zImage-v4 - Just the MF3 kernel itself with all changes for both chroot and direct booting to Ubuntu.
mf3-freedreno-everything-config-v4 - Yet again, I'm providing my complete .config file for this.
Step 3 - Install the Kernel
Here's the easy part. Flash your completed boot.img, flash loki-doki, and reboot. If you're using my pre-built kernel, first flash mf3-freedreno-ubuntu-boot-v4.zip and then flash loki-doki.zip.
Click to expand...
Click to collapse
Flashable Zip Method (NEWEST):
It's finally finished: a flashable .zip that you can use to dump a pre-built rootfs onto your data partition. This will still require that you flash one of the two custom kernels (whether for chroot or native booting), but it will allow you to skip the whole build/install process.
ubuntu-install-v4.zip - CWM/TWRP flashable .zip. Requires approx 2GB free space on your data partition during install, and the final install size is approximately 1.3GB (may want more free space to add your own programs/etc.). Output folder is /data/ubuntu. This can be changed in u.sh, but heed the warnings within!
Instructions:
Instructions for Chroot-style Ubuntu:
Download the "companions" .zip and extract its contents to the root of /sdcard.
Download the "ubuntu-install" .zip to your internal or external SDCard.
Download the "mf3-freedreno-android-boot" .zip to your internal or external SDCard.
Make a nandroid backup of your phone, and store it on an external SDCard or your computer. Always a good idea to have this.
Install the "ubuntu-install" and "mf3-freedreno-android-boot" .zip files, followed by loki-doki.zip if you need that for your device (e.g. I337).
Restart and resume with Step3 of the Freedreno Chroot Method.
Instructions for Native Boot Ubuntu:
Download the "ubuntu-install" .zip to your internal or external SDCard.
Download the "mf3-freedreno-ubuntu-boot" .zip to your internal or external SDCard.
Install the "ubuntu-install" and "mf3-freedreno-ubuntu-boot" .zip files, followed by loki-doki.zip if you need that for your device (e.g. I337).
Restart and let it start into Ubuntu!
NOTE: The username is "ubuntu" and the password is also "ubuntu" - it is highly recommended that you change this ASAP.
Click to expand...
Click to collapse
Known Issues/Bugs:
Below is the list of known issues that I can think of, from the top of my head. This will probably be updated later as everyone points stuff out. Some issues only apply to some of the methods, so the applicable methods are listed in parenthesis after each.
Sound has not been tested (freedreno/native)
3D graphics or OpenGL support has not been tested (all)
Some applications don't work in a headless environment (vnc)
Some applications don't like to run as root, such as chromium (freedreno) lightdm is working in companions-v3, so no need to login as root anymore
Onboard is not working (freedreno/native) fixed in companions-v3
sudo does not work (all) fixed in kernel-v4 for freedreno/native, but problem remains for (vnc) if you are not using a custom kernel
A few kernel Oops's (native)
Shutdown menu doesn't always work (freedreno/native) fixed partly in companions-v4 - proper locale settings seem to allow the shutdown menu to work once you are logged in
Performance issues due to VNC connection (vnc)
No 3G/WiFi/network connection that I'm aware of... (native)
No control over 3G/WiFi/network/bluetooth yet (all)
Xorg's normal touchscreen driver evdev causes segmentation faults (freedreno/native)
Working on a possibly trying to get fbdev to work natively without Freedreno for simplicity (freedreno/native)
Anything you'd normally expect from a phone does not exist (freedreno/native)
Screen rotation (with or without accelerometer) doesn't work yet (freedreno/native)
HDMI/MHL output remains untested at this time. I got it to briefly work once, but I need to revisit this. (freedreno/native)
Many more to come, I'm sure...
Click to expand...
Click to collapse
To-Do:
Add mirrors to the download links.
Add a CWM/TWRP-flashable .zip that just dumps a clean Ubuntu install onto your data partition. This should be easy enough. completed!
Fix some of the bugs above.
Simplify the launch.sh and xorg.conf files. The u.sh script seems pretty solid.
Develop a method that works with only fbdev. This method might eliminate the possibility of 3D acceleration, but should enable screen rotation and other nifty things.
Possibly look into getting kexec (or similar) to work on the Galaxy S4 to offer a dual-boot option. Low priority at the moment, because flashing a kernel back and forth is pretty easy stuff.
Get Ubuntu Touch to work. This would eliminate a lot of bugs. I mostly need to just buckle-down and build CM10.1 from source, and then slowly visit each step of the Ubuntu Touch boot process.... Ugh.
Rebuild Freedreno to try to get Mesa/Gallium3D working properly. I'm probably going to need a lot of help from Rob Clark on this one!
More to come...
Click to expand...
Click to collapse
Revision History:
[11-13] mf3-freedreno-companions-v2.zip - Updated launch.sh: added some error checking and fixed the Freedreno build process.
[11-15] mf3-freedreno-companions-v3.zip - Updated launch.sh to include onboard and English language. Removed florence and xvkbd. Removed .keyb script. Added sudo. Simplified upstart-dummy, and included new upstart-dummy.tar.gz. Prepped for new flashable .zip method.
[11-26] mf3-freedreno-companions-v4.zip - Updated launch.sh: included fix for onboard so that it should work anytime lightdm is launched, added some bits for sudo to work, and home button now kills lightdm (not just the Xsession); Updated u.sh: Added check for root, added notes about sudo and nosuid.
[11-26] mf3-freedreno-android-boot-v4.zip & mf3-freedreno-ubuntu-boot-v4.zip - Finally fixed sudo! See kernel mods sections for details.
[11-26] ubuntu-install-v4.zip - rebuilt with new companions.
Click to expand...
Click to collapse
Aou said:
Check out this app: SManager (Script Manager). It makes running the ubuntu.sh or u.sh a whole lot easier, plus you can send it into the background (vnc method only). Just remember to jump back into SManager later, use the Menu Key and open the console to be able to kill the ubuntu.sh. You can also add "bash" as an additional argument (freedreno method only). This seems to be an effective replacement for the Terminal Emulator. Don't forget to choose the "su" option to run either script as root.
Click to expand...
Click to collapse
I have literally spent hundreds of hours working on this project, and many more hours documenting it thoroughly - just so that I could share it with all of you. If you found this guide, custom kernel or scripts to be beneficial, please hit the THANKS button on this post.
This mostly works, but I think I may have made an error. I see it starting the sshd, but not VNC server. I can call vncserver, but when launching the vnc client app I just get stuck at "Establishing Handshake" until it times out. This differs from when I don't call vncserver, where I get immediately connection refused.
I'm going to redownload the image and start from scratch, but the image isn't very friendly when I'm trying to figure out how to rerun the initial configuration script...
On my S4 running OTA-MF3 with root, this didn't work for me until i used Busybox Installer from the market. Tried internal and external without it, neither worked. Only thing that looked like an error after that was
Code:
chown: cannot access '/external-sd/': no such file or directory
but this only showed the first time I ran it. Opened VNC connection just fine from my computer to the phone, and though there was slight graphics glitching (orange and red boxes on desktop) it worked just fine and they didn't interfere. Thanks for this!
Tsaukpaetra said:
This mostly works, but I think I may have made an error. I see it starting the sshd, but not VNC server. I can call vncserver, but when launching the vnc client app I just get stuck at "Establishing Handshake" until it times out. This differs from when I don't call vncserver, where I get immediately connection refused.
I'm going to redownload the image and start from scratch, but the image isn't very friendly when I'm trying to figure out how to rerun the initial configuration script...
Click to expand...
Click to collapse
It's not, I agree. I found that the easiest way to clear the configuration and start anew is to do the following from the "[email protected]" prompt (that is, within ubuntu):
Code:
rm /root/DONOTDELETE.txt
rm /root/cfg/linux.config
DeadlySin9 said:
On my S4 running OTA-MF3 with root, this didn't work for me until i used Busybox Installer from the market. Tried internal and external without it, neither worked. Only thing that looked like an error after that was
Code:
chown: cannot access '/external-sd/': no such file or directory
but this only showed the first time I ran it. Opened VNC connection just fine from my computer to the phone, and though there was slight graphics glitching (orange and red boxes on desktop) it worked just fine and they didn't interfere. Thanks for this!
Click to expand...
Click to collapse
Interesting. I looked through the image's init.sh, and found something that's relatively new (wasn't in beta):
Code:
# Fix for sdcard read/write permissions by Barry flanagan
chown ubuntu /external-sd/
As far as I can tell, that message is harmless. It's only included in the initial configuration, as it's in the section:
Code:
if [ ! -f /root/DONOTDELETE.txt ]
As for the need to download/install the BusyBox installer, that's not surprising at all. I've had so much trouble BusyBox ever since I switched to MF3. I might include this as an extra step in the OP - thank you.
You kidding right...does this really work? To cool, thanks Aou. Great work.
TheAxman said:
You kidding right...does this really work? To cool, thanks Aou. Great work.
Click to expand...
Click to collapse
Yessir, it does indeed work! The S4 handles it very nicely with the extra RAM & CPU it has to spare, so the only limiting factor is VNC. If someone could devise a way to get Ubuntu to draw directly on the screen from within that Chroot, that would be perfect. I don't think it's really possible by design, but this might be the closest we get to running native linux on the I337 until we see some unlocked bootloaders.
Thanks
Aou said:
Yessir, it does indeed work! The S4 handles it very nicely with the extra RAM & CPU it has to spare, so the only limiting factor is VNC. If someone could devise a way to get Ubuntu to draw directly on the screen from within that Chroot, that would be perfect. I don't think it's really possible by design, but this might be the closest we get to running native linux on the I337 until we see some unlocked bootloaders.
Thanks
Click to expand...
Click to collapse
In fact I am currently working on getting xorg to write to androids frame buffer which will mean no more vnc
Sent from my Nexus 4 using xda premium
zacthespack said:
In fact I am currently working on getting xorg to write to androids frame buffer which will mean no more vnc
Sent from my Nexus 4 using xda premium
Click to expand...
Click to collapse
You, sir, are the man. thank you so much for working on this! I threw $10 at you to help fund the skittles/cheetos/carrots/beer/pizza/whatever it takes to help you along.
Added a couple things to the OP. Looks like pure-stock roms will indeed need BusyBox installed, by some means or another. Also, found SManager, which makes executing the ubuntu.sh script much, much easier.
The second script that allows me to launch ubuntu, but the first that allows me to get a real X server on my vnc. Thank you so much !
PS: Why am I unable to install wine ?
"Package wine is not available, but is referred to by another package.
This may mean that the package is missing, has been obsoleted, or
is only available from another source"
This is working pretty good, slow though, do I have it setup right, or did I miss something?
TheAxman said:
This is working pretty good, slow though, do I have it setup right, or did I miss something?
Click to expand...
Click to collapse
I have found it to run a bit slow, and with regular crashing of GUI programs too. Is it just slow or unusable? You can always try closing other apps besides terminal and VNC, or try to VNC from a computer even.
tboss1995 said:
The second script that allows me to launch ubuntu, but the first that allows me to get a real X server on my vnc. Thank you so much !
PS: Why am I unable to install wine ?
"Package wine is not available, but is referred to by another package.
This may mean that the package is missing, has been obsoleted, or
is only available from another source"
Click to expand...
Click to collapse
Looks like you're not the only one. Check out this thread on the LinuxOnAndroid site:
http://forum.linuxonandroid.org/index.php?topic=268.0
TheAxman said:
This is working pretty good, slow though, do I have it setup right, or did I miss something?
Click to expand...
Click to collapse
DeadlySin9 said:
I have found it to run a bit slow, and with regular crashing of GUI programs too. Is it just slow or unusable? You can always try closing other apps besides terminal and VNC, or try to VNC from a computer even.
Click to expand...
Click to collapse
Most of the slowness comes from interacting with it via VNC, it would seem. Hard to compare to anything else, considering VNC is all we've got at the moment. I wonder if @zacthespack can shed some light on this. As he mentioned before, he's working on getting it to draw directly to the Android screen. I'm certainly not going to ask for any status updates, but I'm wondering if he can confirm that we'd see a speed increase without VNC...
EDIT: Also, as I use it more, I am noticing the app crashes too (such as Chromium). Could just be something in the 13.04 image, but also could be because we're running this all on ARM architecture.
Aou said:
Looks like you're not the only one. Check out this thread on the LinuxOnAndroid site:
http://forum.linuxonandroid.org/index.php?topic=268.0
Most of the slowness comes from interacting with it via VNC, it would seem. Hard to compare to anything else, considering VNC is all we've got at the moment. I wonder if @zacthespack can shed some light on this. As he mentioned before, he's working on getting it to draw directly to the Android screen. I'm certainly not going to ask for any status updates, but I'm wondering if he can confirm that we'd see a speed increase without VNC...
Click to expand...
Click to collapse
RE installing WINE, sure you can install the ARM verson but Wine is not a emulator (infact WINE stands for Wine Is Not a Emulator) so you can only run ARM compiled windows software.
Yest there is a good speed increase, as with VNC xorg writes to the vnc server and passes it to the vnc client to then render on the screen.
With the new method xorg just writes to Androids frame buffer, no inbetween man.
And it can get even faster once we have graphics accelerations although not all chip sets will get that.
zacthespack said:
RE installing WINE, sure you can install the ARM verson but Wine is not a emulator (infact WINE stands for Wine Is Not a Emulator) so you can only run ARM compiled windows software.
Click to expand...
Click to collapse
Good point, forgot about that. It's really just a big package of Windows dependencies, responding to API calls, etc. The software that Wine runs is still sending stuff to/from the processor directly, therefore it would have to be compiled for ARM.
I wonder what Windows8 programs are available that are compiled for ARM (because of the Microsoft Surface and all...).
Aou said:
Good point, forgot about that. It's really just a big package of Windows dependencies, responding to API calls, etc. The software that Wine runs is still sending stuff to/from the processor directly, therefore it would have to be compiled for ARM.
I wonder what Windows8 programs are available that are compiled for ARM (because of the Microsoft Surface and all...).
Click to expand...
Click to collapse
There's plenty or ARM software within the built in app store, but I'm not sure where they install to or how one would go about extracting them. I have it on desktop and it shows what processors it runs on. Can't wait for the straight to screen function though
Also, I'm going to see if a different image is more stable. Chromium was the most obvious crashing for me and others generally crashed.
DeadlySin9 said:
There's plenty or ARM software within the built in app store, but I'm not sure where they install to or how one would go about extracting them. I have it on desktop and it shows what processors it runs on. Can't wait for the straight to screen function though
Also, I'm going to see if a different image is more stable. Chromium was the most obvious crashing for me and others generally crashed.
Click to expand...
Click to collapse
I noticed that with 12.04, it doesn't seem to connect to Xorg or something, because when you use VNC, it only shows a grey screen with a cross cursor. Same for both "Lite" and "Full" packages. Haven't tried older (10.x) packages of Ubuntu.
The other Linux images should work just fine. Optionally, you can edit the ubuntu.sh script to be more appropriate, but it should theoretically work the same (unless the init.sh is located elsewhere inside the image...).
I tried the Ubuntu 10 image and the Debian image but ubuntu didn't run vnc (vncserver not found or something) and debian kept saying I didn't have permissions.
It appears chromium is incredibly unstable on this image, so I've uninstalled it.
I'm currently working on trying to get Minecraft to work, but ever since 1.6.2 and this new launcher, it's incredibly difficult to modify the client files and such. Something is going wrong with liblwjgl.so. I can get the launcher to work correctly, but when it goes to load the game, it can't find liblwjgl.so and says that it might be because of 32bit vs ARM. I did get lwjgl installed correctly, and pulled the ARM version of the .so and stuck it in [what I believe was] the right .jar file, but it still has the error.
I'll keep you all posted. If I can get this to work, and if zacthespack can get xorg to draw on the android screen, ... :good:
EDIT:
Found out that every time the launcher runs minecraft, it downloads several libraries and other crap to run the game, to keep itself current and to support multiple versions, yada, yada. Unfortunately, this means that it downloads https://s3.amazonaws.com/Minecraft..../2.9.0/lwjgl-platform-2.9.0-natives-linux.jar every time you click Play, and overwrites any custom one you might have (i.e. one with ARM libraries inside). I tried revoking write access to the file, but then the launcher aborts the launch because it can't overwrite the file.
Any suggestions?
EDIT #2:
Well, the easy solution was to modify the file, run the launcher, disconnect mobile data temporarily, and then launch the game ("couldn't connect to server .... have local copy of file .... assuming it's good...."). No more errors about that stupid library file. However, the game immediately crashes now with an error report. Investigating this now. PROGRESS!
Problem
I'm aware I may need to modify the script in order to accommodate my setup, but I figured I'd post here first before changing anything in case someone else had a similar problem and came up with the solution.
I followed all the instructions, except I want to boot from an external USB stick (mounted using StickMount).
I reviewed the script, dropped it on the root of the USB stick, and copied the unzipped image to a folder named ubuntu.
Here is the output when I run the script:
Making mount points and mounting to them...
mount: mounting /dev/loop20 on /data/local/ubmnt failed: Operation not supported
mount: mounting devpts on /data/local/ubmnt/dev/pts failed: No such file or directory
mount: mounting proc on /data/local/ubmnt/proc failed: No such file or directory
mount: mounting sysfs on /data/local/ubmnt/sys failed: No such file or directory
Connecting to /sdcard...
mount: mounting /sdcard on /data/local/ubmnt/sdcard failed: No such file or directory
Putting in some settings...
net.ipv4.ip_forward = 1
/sdcard/usbStorage/sda1/ubuntu.sh[19]: can't create /data/local/ubmnt/etc/resolv.conf: No such file or directory
/sdcard/usbStorage/sda1/ubuntu.sh[20]: can't create /data/local/ubmnt/etc/resolv.conf: No such file or directory
/sdcard/usbStorage/sda1/ubuntu.sh[21]: can't create /data/local/ubmnt/etc/hosts: No such file or directory
ubuntu is configured with SSH and VNC servers that can be accessed from the IP:
(You will see an error about wlan0 if your WiFi is disabled. Safe to ignore.)
----------------- OKAY, starting Ubuntu! -----------------
chroot: can't execute '/root/init.sh': No such file or directory
----------------- Ubuntu has exited! -----------------
Cleaning up - unmounting everything and removing what we made...
umount: can't forcibly umount /data/local/ubmnt/dev/pts: No such file or directory
umount: can't forcibly umount /data/local/ubmnt/sys: No such file or directory
umount: can't forcibly umount /data/local/ubmnt/proc: No such file or directory
umount: can't forcibly umount /data/local/ubmnt/sdcard: No such file or directory
umount: can't forcibly umount /data/local/ubmnt: Invalid argument
Welcome back to your android.
Click to expand...
Click to collapse
I am running as root, BusyBox free has been installed. My terminal app has been granted root privileges. The path to the USB stick is sdcard/usbStorage/sda1.
Any help/guidance would be greatly appreciated! :fingers-crossed:

[Q&A] [DEV][WIP] xubuntu on tf300tg 0.1.2 (updated 130408)

Q&A for [DEV][WIP] xubuntu on tf300tg 0.1.2 (updated 130408)
Some developers prefer that questions remain separate from their main development thread to help keep things organized. Placing your question within this thread will increase its chances of being answered by a member of the community or by the developer.
Before posting, please use the forum search and read through the discussion thread for [DEV][WIP] xubuntu on tf300tg 0.1.2 (updated 130408). If you can't find an answer, post it here, being sure to give as much information as possible (firmware version, steps to reproduce, logcat if available) so that you can get help.
Thanks for understanding and for helping to keep XDA neat and tidy!
cannot boot into xubuntu
Hello guys.
I'm having a problem trying to make everything working. I tried to follow the webdoctors instructions and somehow things went wrong.
First of all, I installed v2.2.9 kernel using TWRP. Then, I split my microSD cart into partitions under gparted, then I used dd to copy from img to first card's partition. To this point everything went well. I tried to boot into xubuntu - it worked. But I had no internet connection and couldn't run mod_update.sh under xubuntu. Then, I decided to reboot system. And I couldn't go back into xubuntu - I'm choosing linux [1], and then there are some lines and it looks like it's stuck on lines like
Code:
init avahi-deamon terminated (or something like that)
...
pad_get_pspval->inval=Not charging ret=0
pad_get_psp voltage_now=8060
pad_get_psp ...
asuspec: [asuspec_enter_s3_work_function] EC in S3
I can boot into android without any problem, but WiFi isn't working. I've tried to format my card, put files from rootfs for a couple of times, and it worked only twice, rest of it just shows lines of code I mentioned.
I hope I managed to write everything clearly I receive some help from you!
xubuntu 14.04 working
[It seems as a new member I cannot post to the dev thread directly, but to an associated Q&A thread. I hope the people that might be interested in this post can read it anyway.]
I have been running xubuntu 14.04 on my Asus TF300T for some months now. As other people seem to have difficulties with this I want to share how I got this to work. My own contribution in this is quite small. It mostly consists in combining in a particular way the great work others here on xda have done.
About my methodology: I am neither expert in the relevant hardware nor software. Also I like things to be reproducible and portable. So I try to start from the most standard ingredients (official sources, standard linux distrubtions etc.) and modify them in small independent and documented modular steps until I get things to work.
In this post I will present only a very brief outline of how I proceeded. I hope to present more details in later posts.
KERNEL:
I am using a boot menu setup with kexec hardboot. Thus, for linux I am using a dedicated linux kernel, not a dual purpose linux/android kernel. The kernel is based on the official Asus source with a few small patches. I am not sure the patches are relevant for 14.04 to work, but they might be. I will describe them in a later post.
ROOTFS + INITRAMFS:
The initial rootfs is simply the official ubuntu core 14.04 armhf image found at the official ubuntu site [cannot post link].
On top of this the kernel config in /boot and modules + firmware in /lib/modules and /lib/firmware have to be installed. Also a few other small files for wifi + bluetooth to work can be installed at this stage or later.
The initial initramfs is generated through a chroot from this image via the standard update-initramfs tool. For this to work properly only a tiny configuration file that indicates the linux root partition is needed in /etc/initramfs-tools/conf.d
In subsequent stages new versions of the initramfs can always be generated directly from the booted linux image via update-initramfs.
The chroot can also be used to download all required packages for the full install via
> apt-get -d install "packagename"
This requires having set /etc/apt/sources.list and possibly /etc/resolv.conf /etc/hosts /etc/hostname
X11:
As everybody knows X11 is a problem with tegra graphics. Fortunately, drivers are available at Nvidia's Linux for Tegra Site [cannot post link].
Unfortunately, these cover only X11 ABI up to version 14, while X11 in 14.04 is using ABI 15. What is more, I have experienced graphics corruption issues with the ABI 14 driver so I am actually using the ABI 13 driver. That means in addition to installing the relevant files from the nvidia site it is necessary to downgrade X11 for 14.04. I got this to work with the following packages:
- from 12.04:
libxi6 (this is more up to date than the 13.04 version)
- from 13.04:
xserver-xorg-core
libxfixes3
xserver-xorg-input-evdev
xserver-xorg-input-multitouch
xserver-xorg-video-dummy (might not be necessary)
- from 13.10:
libgl1-mesa-dri
Also you need the package xserver-xorg-input-mtev
sources are at rabits launchpad site [cannot post link]
SECOND STAGE:
After setting up a user, downloading desired packages (in particular "xubuntu-desktop"), making available the X11 packages etc. boot into the new system as the new user. Now install the X11 packages, set some of them on hold (apt-mark hold), for me it worked by marking xserver-xorg-core, libxfixes3 and libgl1-mesa-dri. Afterward you might need
> apt-get -f install
Then install xubuntu-desktop and possibly further required packages, then generate a new initramfs. Also further stuff needs to be / can be installed at this stage for audio, video, codecs, keyboard etc.
The next boot should then land you in a fully working xubuntu 14.04.
Good news! Could you upload your image xubuntu 14.04?
aurel33 said:
Good news! Could you upload your image xubuntu 14.04?
Click to expand...
Click to collapse
The image I am using myself is quite a mess now, after many months of use. Stripping this to the essentials and removing all personal stuff would be quite some work. What I rather want to do is share a procedure that should allow anybody to generate his/her own customized image. My previous post was extremely brief in this respect, but I hope to give more details in a follow up post. The next post, however, will be dedicated to the kernel I use as there are two patches that might (or might not) be relevant for 14.04 to work.
kernel for xubuntu 14.04
[I am sorry for not including the relevant links. As a new member I am not allowed to post links.]
As I said I am using a dedicated linux kernel, not a dual purpose linux/android kernel.
I am using the toolchain from ubuntu package "gcc-arm-linux-androideabi".
Instructions: Download the official Asus kernel source and get the toolchain ready.
Apply the following patches (attached):
toolchain/config patches:
- toolchain.patch : a minimal patch to solve toolchain dependent compliation issues
- modmake.patch : compile modules with option "-fno-pic"
- compressed_makefile.patch : also to solve toolchain issues (I found this in various places)
- bcm.patch : complete Kconfig for modules "bcmdhd_29" so none of "bcmdhd", "bcm43xx", "bcm4329" needs to be selected
proper kernel patches:
- mored.patch : patch to see console information at boot (from xda contributer "moreD")
- subreaper.patch : patch to update certain process information/signals to kernel 3.4 (from Lennart Poettering)
- 0001/2/3-AppArmor-... : update kernel to make apparmor work properly (from John Johansen)
- grouper-f2fs.patch : use this in case you want to add f2fs support (from Alex Page)
My kernel config file "config.txt" is also attached.
Now set environment variables:
KBUILD_OUTPUT=<outdir> directory for compilation output and config files
INSTALL_MOD_PATH=<libdir> directory for module and firmware installation
INSTALL_PATH=<bootdir> directory for kernel installation
In case of cross compilation set additionally:
ARCH=arm
CROSS_COMPILE=arm-linux-androideabi-
Now compile:
make -j4 all
make modules_install
make firmware_install
make zinstall
I am not sure if any of the above patches is essential to get xubuntu 14.04 running, but I suspect that the subreaper patch and the AppArmor patches might be important. The reason I use them is that I got errors in previous attempts of installing (x)ubuntu that after some research I found got fixed with these patches.
Happy compliling!
Can you please give me step by step instructions on how to install Ubuntu 14.04 on my TF300T?
Sent from my TF300T using XDA Free mobile app
rootfs for xubuntu 14.04 - PART 1
Here I describe in more detail the first part of the installation of the root file system (rootfs) for xubuntu 14.04 on the Asus TF300T. I will assume that the installation is to the root of an empty partition.
I. PREPARE ROOTFS:
1. CORE ROOTFS: Download the file
"ubuntu-core-14.04.1-core-armhf.tar.gz"
from the Ubuntu repositories. (Search for "ubuntu core" to find the site, I cannot post the link.) Extract this to the xubuntu partition. This is the initial rootfs.
This rootfs already works in a chroot, either from an existing linux installation or from Android. However, for this to be more useful we need to set up internet access and repositories.
2. INTERNET SETUP: Extract the attached file "inet-setup-trusty.tar.gz" into the rootfs. This sets up the relevant ubuntu repositories and fixes DNS lookup and gives the machine a name. Here I chose "tf300t-linux". To change the name, edit the files "/etc/hostname" and "/etc/hosts".
Before entering the rootfs via chroot, we set up more infrastructure for the ability to later run the rootfs stand alone. This requires a kernel.
3. KERNEL SETUP 1: Extract the kernel modules into "/lib/modules/..." and the kernel firmware into "/lib/firmware/...". If you compiled the kernel youself, these files will have been generated in the process. If you take the kernel from elsewhere these files have to be provided with the kernel.
4. KERNEL SETUP 2: To ensure relevant modules are loaded at boot, a file "/etc/modules" might be needed. This depends on the kernel. Assuming you compilde the kernel following my instructions in a previous post, just extract the attached file "initmodules.tar.gz" into the rootfs.
We shall later use "update-initramfs" to generate the initial ram file system, a file named "initrd.img". For this to work we need the following:
4. KERNEL SETUP 3: Put the kernel image into "/boot/". It should be called "vmlinuz-3.1.10" or similar. Also put "config-3.1.10" and "System.map-3.1.10" into this directory. These are also generated when compiling the kernel. I am not sure if "System.map-3.1.10" is required. "config-3.1.10" can be extracted from the kernel image if not provided. (See instructions elsewhere.)
5. INITRD CONFIG: For "update-initramfs" to work correctly a configuration file is needed indicating the root partition. This goes into "/etc/initramfs-tools/conf.d/". You might just extract the attached file "initramfs-mmcblk1p1.tar.gz". This assumes that xubuntu uses the partition "mmcblk1p1" with "ext4", i.e. the first partition on the external micro sd card and fomatted with the "ext4" file system. If you use a differnt partition and/or file system, edit the included file "/etc/initramfs-tools/conf.d/specify_root_device" accordingly.
6. WIFI: For wifi to work you need a file "nvram.txt". This is located under Android in "/data/misc/wifi/nvram.txt". Copy this to the rootfs at "/lib/firmware/nvram.txt" if you use the kernel I describe in a previous post. Otherwise the required location might be different. You can read it off in the kernel config file "config-3.1.10". (Search for "*NVRAM_PATH*".) Also you need firmware files. Under Android these should be under "/system/vendor/firmware/". Copy them to "/lib/firmware/" or see the location in the config file (search for "*FW_DIR*"). Note that these files include subdirectories, copy with subdirectories.
7. BLUETOOTH: You need a firmware file. This should be in Android under "/system/etc/firmware/". Its name should start with "BCM4329...". In the rootfs name this "/lib/firmware/BCM4329.2.hcd". You need an executable called "brcm_patchram_plus" which loads the firmware dynamically. This goes in the rootfs into "/usr/sbin/brcm_patchram_plus". Go to the site of the Linux for Tegra R16 project of Nvidia. Download "Tegra30_Linux_R16.4.0_armhf.tbz2". Inside look for "Linux_for_Tegra/nv_tegra/nvidia_drivers.tbz2". Inside this you find the executable "/usr/sbin/brcm_patchram_plus". You need a process that automatically calls this executable. It is convenient to integrate this with ubuntu's upstart. To this end just extract the attached file "nvbt.tar.gz". It yields a file "/etc/init/patchram.conf". I have adapted this file from previous work on xda on bluetooth for linux on the tf300t or tf700t (but can't find the post now). Modify this if you want to change the name or location of the firmware file.
8. GENERAL CONFIG: To fix some general configuration parameters for the tf300t extract the attached file "nvinit.tar.gz". This yields a file "/etc/init/nv.conf". Again, this is from prvious work on xda for the tf300t or tf700t (but I can't find the relevant post now).
II. ENTER ROOTFS:
I suppose you have mounted the partition for xubuntu at "/mnt/linux", either under an existing linux or under Android.
> LC_ALL=C sudo chroot /mnt/linux
update repositories:
> apt-get update
this is useful for a smooth installation of packages:
> apt-get install dialog
now install upgrades:
> apt-get dist-upgrade
create your user:
> adduser username
> addgroup username adm
> addgroup username sudo
generate initramfs and leave chroot:
> update-initramfs -c -k 3.1.10
> exit
This generates a file "/boot/initrd.img-3.1.10". This file together with the kernel image are needed to boot into the newly set up system.
III. BOOT ROOTFS:
You should now be able to boot into the system. How this is done depends on your set up. There are lots of threads on xda devoted to this subject. You should now have a functional minimal linux system based on ubuntu 14.04.
If you want to install packages it is convenient to download these from the chroot (where wifi is available) and before booting into the system as follows:
> apt-get -d install package1 package2 ...
Then after booting, install them via,
> sudo apt-get install package1 package2 ...
The details of the further set up of the GUI and of the full xubuntu 14.04 will be described in a subsequent post.
rootfs for xubuntu 14.04 - PART 2
Here I describe the second part of the installation of the root file system (rootfs) for xubuntu 14.04 on the Asus TF300T. I assume the rootfs has been prepared as described in this post, following the steps "I. PREPARE ROOTFS" and "II. ENTER ROOTFS", but not booted yet. If it has already been booted it might (or might not) be necessary to rewrite the file "/etc/resolv.conf" to the version contained in the file "inet-setup-trusty.tar.gz" from that post. This is to ensure internet access works correctly from chroot.
I. GET REQUIRED PACKAGES
The most complicated part of getting xubuntu 14.04 to work is in the graphics drivers and libraries. Mostly, the necessary files are found on the page of the "Linux for Tegra R16" project of nvidia. Look for the Tegra 30 "Cardhu" versions. As described in my first post, the problem with this and Ubuntu 14.04 is that this version of Ubuntu uses an X server with ABI version 15. An appropriate driver is not supplied by nvidia. The latest driver version supplied by nvidia is with ABI version 14. However, I had problems with graphics corruption with this driver, so I am using the one for ABI version 13. There is a ready made package containing this in the ubuntu 13.04 repository. Get this. The filename is:
"nvidia-tegra3_16.0-0ubuntu3_armhf.deb"
(I compiled a version of this with updated source files using nvidia's latest release "16.4" for my own use, but it is somewhat complicated to do this, so I wont put the details in this post. Anyway, this version should work for most purposes.)
Since we need the X server with ABI version 13, we need to install corresponding packages that are not from ubuntu 14.04, but from previous releases. Grab the following packages:
RELEASE PACKAGE FILENAME
12.04 libxi6 libxi6_1.7.1.901-1ubuntu1~precise1_armhf.deb
13.04 xserver-xorg-core xserver-xorg-core_1.13.3-0ubuntu6.2_armhf.deb
13.04 libxfixes3 libxfixes3_5.0-4ubuntu5.13.04.1_armhf.deb
13.04 xserver-xorg-input-evdev xserver-xorg-input-evdev_2.7.3-0ubuntu2b2_armhf.deb
13.04 xserver-xorg-input-multitouch xserver-xorg-input-multitouch_1.0~rc2+git20110312-2build3_armhf.deb
13.04 xserver-xorg-video-dummy xserver-xorg-video-dummy_0.3.6-0ubuntu1_armhf.deb (this might not be needed)
13.10 libgl1-mesa-dri libgl1-mesa-dri_9.2.1-1ubuntu3_armhf.deb
There is another package needed for the X server for the touchscreen to work. Build instructions can be found on the GitHub page of user "rabits" under "tf700". I have attached the resulting package "xserver-xorg-input-mtev". Uncompressing yields:
"xserver-xorg-input-mtev_0.1.13ubuntu2_armhf.deb"
II. PLACE PACKAGES
1. Put all the 9 package files for the x server into a directory in the rootfs.
2. Enter the rootfs via chroot from Linux or Android (supposing the parition of the rootfs is mounted at "/mnt/linux")
> LC_ALL=C sudo chroot /mnt/linux
3. Go to the directory with the X server packages. Then install them:
> dpkg -i filename1 filename2 ...
4. IMPORTANT! Prevent relevant packages from being updated:
> apt-mark hold xserver-xorg-core
> apt-mark hold libxfixes3
> apt-mark hold libgl1-mesa-dri
5. Pull in dependencies:
> apt-get -f install
6. Get xubuntu packages (this takes some time depending on the speed of your internet connection) and leave:
> apt-get -d install language-pack-en
> apt-get -d install xubuntu-desktop
> exit
III. XUBUNTU INSTALL
Now, boot the rootfs.
1. Set timezone
> sudo dpkg-reconfigure tzdata
2. Install language pack to avoid locale problems
> sudo apt-get install language-pack-en
3. Install xubuntu. (This takes some time)
> sudo apt-get install xubuntu-desktop
4. Produce a new initrd.img and exit
> sudo update-initramfs -c -k 3.1.10
> sudo shutdown now
Copy this from /boot/initrd.img-3.1.10 to where its needed for the boot process.
IV. FURTHER CONFIG
1. FIX AUDIO CONFIG PROBLEMS
Extract attached file "nvaudio.tar.gz" to the rootfs.
2. SET UP X INPUT DRIVERS
Extract attached file "xorg-input.tar.gz" to the rootfs.
V. BOOT XUBUNTU
Booting the rootfs should land you now in a fully working xubuntu 14.04.
There are further steps to improve the experience such as
- install nvidia codecs and player
- fix graphics corruption on resume from suspend
- install keymaps for a better keyboard experience with the dock
I hope to describe some of this in later posts in so far as it differs from solutions that other xda members have already proposed.
A final remark:
THE IDENTICAL PROCEDURE SHOULD WORK FOR INSTALLING LUBUNTU.
(Just replace "xubuntu-desktop" with "lubuntu-desktop", I have tested this once)
It does not work with standard Ubuntu (i.e. Unity) though, because that depends on the newer X server.
@Geometry
Is there any chance, that you would share your working rootfs (ofc fresh build) and others can use it? Or everyone has to follow your guide to have working rootfs and it cannot be shared?
mentosso said:
@Geometry
Is there any chance, that you would share your working rootfs (ofc fresh build) and others can use it? Or everyone has to follow your guide to have working rootfs and it cannot be shared?
Click to expand...
Click to collapse
I would certainly be happy to share a working rootfs (understandably not the one I have been using myself for the last couple of months though). Unfortunately, I can spend very little time on this. So it is a question of finding the time to prepare a new build, then finding a free file hosting service etc. I will try to make an effort to make this happen in the near future, but can't promise anyhing at this point...
can you go more in depth in how you installed the kernel? I get some of the basics but I don't understand how to install it.
phonegeekjr said:
can you go more in depth in how you installed the kernel? I get some of the basics but I don't understand how to install it.
Click to expand...
Click to collapse
Sorry for being very brief in this respect. One way to install the kernel would be to use the "abootimg" tool to combine the kernel with a initrd.img file into a boot image, then convert this to a blob file using "blobpack" and then flashing this to the tablet. However, this would leave you unable to run any other OS/ROM (such as any Android). So this is probably not what you want. Instead you want some multiboot/multirom system. What I use myself is a modified version of the boot kernel from the main thread which starts a script that gives me a menu and then boots the kernel/initrd.img I select via kexec-hardboot. To "install" a kernel/initrd.img you just have to store them at a place where this script can find them. If I have time I might describe my particular setup in more detail later. But for the moment my main intention is to have those that already have a setup like this be able to test a full xubuntu 14.04. Then, with the help of those experts it will be easier to generate a way to make this accessible to a large number of users.
test kernel
I provide here a test kernel, compiled as described in this post. There is one small difference compared to the description in the post. It turns out that instead of the "arm-linux-androideabi-" toolchain, the "arm-linux-gnueabihf-" toolchain works as well and I have used that. Note that the kernel is a linux only kernel that will not work with Android. The attached file can be decompressed directly into the rootfs, automatically providing all essential files (modules, config etc.) in the right place. The (compressed) kernel itself is the file "/boot/vmlinuz-3.1.10". This is the file that is often named "zImage". The kernel config file is "/boot/config-3.1.10".
The other news is that I have also built a working xubuntu 14.04 rootfs as described in his post. As soon as I find a suitable file hosting service I will make this available here.
xubuntu 14.04 rootfs
So, here is the rootfs as prepared according to this post and this post. There is one small difference in the preparation as compared to those posts. I have used a modified and updated version of the package "nvidia-tegra3", see attached file.
So the rootfs file is called "tf300t-xubuntu-rootfs.tar.gz" and can be found here. Expand this into the partition you want to use for xubuntu 14.04. It is recommendable that you replace the file "/lib/firmware/nvram.txt" with you own version from your own machine at "/data/misc/wifi/nvram.txt" in Android.
This associated kernel is also in the rootfs at "/boot/vmlinuz-3.1.10". The initial ramfs is the file "/boot/initrd.img-3.1.10". This assumes linux is in first partition "mmcblk1p1" of the external micro sd card. The username is "ubuntu" with password "ubuntu".
If you want to use a different kernel (I hope other kernels will work too, please report!) then replace the module files under "/lib/modules" and possibly some firmware files under "/lib/firmware" as necessary. Also (!) put the kernel config file in "/boot/config-3.1.10". Then enter the rootfs via chroot and generate a new initrd.img via "update-initramfs -c -k 3.1.10". It will be replace the provided one.
Also, if you want to put this on a different partition edit "/etc/initramfs-tools/conf.d/specify_root_device" accordingly and generate a new initrd.img as described above.
As before I assume here that you know what to do with the kernel and the initrd.img...
Happy testing!
---
md5sum for "tf300t-xubuntu-rootfs.tar.gz" is: 46639d3af438e9c856d5951a321e203b
---
UPDATE: Here is an alternative download link for the rootfs which might provide faster download speed. Thanks to Graiden05!
@Geometry
Thank you a lot for your effort! I have a question tho, is it possible to run your rootfs and have dualboot? The best way would be to use dualboot kernel posted somewhere in the topic. If it's possible, can you briefly write how to do it?
Geometry said:
Sorry for being very brief in this respect. One way to install the kernel would be to use the "abootimg" tool to combine the kernel with a initrd.img file into a boot image, then convert this to a blob file using "blobpack" and then flashing this to the tablet. However, this would leave you unable to run any other OS/ROM (such as any Android). So this is probably not what you want. Instead you want some multiboot/multirom system. What I use myself is a modified version of the boot kernel from the main thread which starts a script that gives me a menu and then boots the kernel/initrd.img I select via kexec-hardboot. To "install" a kernel/initrd.img you just have to store them at a place where this script can find them. If I have time I might describe my particular setup in more detail later. But for the moment my main intention is to have those that already have a setup like this be able to test a full xubuntu 14.04. Then, with the help of those experts it will be easier to generate a way to make this accessible to a large number of users.
Click to expand...
Click to collapse
thanks
actualy converting it all to a blob file really is what I want to do. what is this program blobpack? I have googled it and didn't get much.
phonegeekjr said:
thanks
actualy converting it all to a blob file really is what I want to do. what is this program blobpack? I have googled it and didn't get much.
Click to expand...
Click to collapse
OK, so I assume you know how to use "abootimg" to create a boot image. "blobpack" converts this into a blob file that you can flash to the staging partition. For the blob tools see this thread. However, I had problems with the version of "blobpack" from that thread. Instead, a different version of "blobpack" worked for me. I got this by going to the cyanogenmod web site and following the instructions to built cyanogenmod for the tf300t. In the build process not only cyanogenmod is built, but various tools as well. This includes a version of blobpack, called "blobpack_tfp". This worked for me. Note that I did this almost a year ago. So I am not sure an up to date version of cyanogenmod yields the same. If you are just after the blobpack tool, downloading the complete source and building cyanogenmod is a huge overkill of course. But I guess you could browse through their sources online and find exactly what you need. Hope this info helps!
mentosso said:
@Geometry
Thank you a lot for your effort! I have a question tho, is it possible to run your rootfs and have dualboot? The best way would be to use dualboot kernel posted somewhere in the topic. If it's possible, can you briefly write how to do it?
Click to expand...
Click to collapse
I don't know of the rootfs works with this dualboot kernel. Actually, it would be great if somebody could test this! How to adapt the rootfs to another kernel is sketched in the post. However, some of the patches described here and not included in that kernel might be necessary for xubuntu 14.04 to work. But I'm not sure...
Another possibility would be to modify the kernel I described here for dualboot (or multiboot). This would require an additional kexec-hardboot patch and a modification of the initrd.img to include the kexec binary and a script that offers the boot menu.
---------- Post added at 17:01 ---------- Previous post was at 16:18 ----------
I have now announced the xubuntu 14.04 rootfs described in previous posts on the main thread here. I would like to encourage people to continue discussion there as I think that is the more appropriate place.
Hi
i would like to install xubuntu on my tablet.
I have not yet figured out what the starting point.
I currently have installed a cm11 official rom.
what i can do now? which are the steps to make dualboot working?
I can install android on the internal memory and xubuntu in sd card?
How can i make this work? I've to many doubts to start flashing and install stuffs right now.
Thanks in advance.

Categories

Resources