yashsingh1/xdaforums huggingface dataset:
[Adam Android Development] tmckenn2:
web05 any news on the script i posted?

most importantly what roms have you successfully gotten this to work on?
[Adam Android Development] webs05:
Sry, working on it. Give me a few more days.
[Adam Android Development] clockcycle:
Love the Avatar ;)

-CC
[Adam Android Development] tmckenn2:
Its fine I understand if your busy.... I did get it to go a step further

By adding .txt to everything in Ubuntu.sh and running the command bootubuntu.txt instead of bootubuntu.... it still fails to run the actual ubuntu, ill post the error code later today. It would seem that loop2 is already in use... probably by data2sd, maybewe could change the loop device?

Have you gotten this to work on any particular rom? I'm on beast but I think I will also try beast without data2sd enables later.
[Adam Android Development] tillum:
Rayman84, where are you at with graphics acceleration? You mentioned a few posts back that it worked, but broke sdcard access and stuffed up the resolution. What have you gotten working so far, and how? Not to familiar with hkw android works, but is it possible to somehow modify the android drivers? It's based on Linux, right?
[Adam Android Development] webs05:
From where are you running the scripts? These are script files that need to be run from Android, specifically the ADB shell. I'm not sure that adding .txt to any files or command lines would give you more luck in getting Android to process them.

I'm going to play around tonight and see what I can get, hang tight...
[Adam Android Development] webs05:
You have to run "su" before attempting to run these scripts as you need to be root to run them. Please verify this step and then report back with issues or tell me you did that already.
[Adam Android Development] tmckenn2:
I. Re-ran with su command and no joy. I mainly run it from terminal emulator but also from adb shell(the stuff I posted is from adb shell). If you look, it has the # symbol which means I. Have root access.

My main reasoning behind adding .txt was because the files from your website had .txt on them and the errors seem to tell me that it could not find bootubuntu... once I ran it with bootubuntu.txt it found the file and ran the command. Now the problem is with the bootubuntu script and mounting the image.

Ill try to get you what the script spits out but I may need to wait until I get home

EDIT: here it is. I ran it with su, I then ran bootubuntu which could not be found, then bootubuntu.txt which gave me this(note I did change your code, loop device is now 5... I changed it back to loop2 and it gave me the same thing, and yes I ran sh ./Ubuntu.sh after each change):

export PATH=/data/local/bin:$PATH

sh-4.1$ export PATH=/data/local/bin:$PATH

sh-4.1$ su

sh-4.1# bootubuntu

sh: bootubuntu: command not found

sh-4.1# bootubuntu.txt

ioctl LOOP_SET_FD failed: Device or resource busy

mount: No such file or directory

mount: No such file or directory

mount: No such file or directory

net.ipv4.ip_forward = 1

Setting /etc/resolv.conf to Google Open DNS 8.8.8.8 and 8.8.4.4

/system/bin/bootubuntu.txt: line 16: /data/local/mnt/etc/resolv.conf: No such file or directory

/system/bin/bootubuntu.txt: line 17: /data/local/mnt/etc/resolv.conf: No such file or directory

Setting localhost on /etc/hosts

/system/bin/bootubuntu.txt: line 19: /data/local/mnt/etc/hosts: No such file or directory

READY TO ROCK AND ROLL BABY!

Brought to you by NexusOneHacks.net and the open source community!

Modified by Webs05 - XDA Forums :)

chroot: can't execute '/bin/bash': No such file or directory

Shutting down Ubuntu

failed.

failed.

failed.

failed.

sh-4.1#
[Adam Android Development] tmckenn2:
I'll try later tonight with data2sd off but itrequires me reflashing my Adam. Also note I did alot of experimenting with my aandroid phone and couldn't get it to work but thatwas with a backflip... which blows. It was generally considered to be a problems with loop devices with most phones and there is a script out there that checks to see which loop devices are free and uses that one but I can't find it.maybe you could add that. To your scripts (I wouldn't know how to)...
[Adam Android Development] webs05:
The output you are posting and what I have in my directions are two COMPLETELY different things. Also, stop with your modifications to what I have, they are not helping you. ;)

Re-read my first post and copy/paste what I have into the ADB shell. This may sound harsh, but if you do not follow the directions I posted I cannot help you troubleshoot.:confused:
[Adam Android Development] tmckenn2:
Have you ever run this on an android device?... this is it;)

I followed your instructions with your files to the t... promise, and I'm telling you it wont run with the commands given, with .txt. added it goes further... now the stuff that was spat out and that I posted was your code... the bootubuntu file generates that stuff, errors and all... to prove this to you ill make a movie step by step of what I do, ill have it up later.

EDIT: ok i made the video you can view it here:

http://www.youtube.com/watch?v=0iCNLYcgzYg

i apologize in advance, i was tired and was acting a little like an ass:o but ignore that and watch it for content. i did realize an error that had to do with the .txt, google chrome and the built in browser in the adam append .txt to the files:o, i dont know why, in the video i suggest packaging them as a zip.

also here is the output from the shell that you see in the video, copied and pasted:

Microsoft Windows [Version 6.0.6002]

Copyright (c) 2006 Microsoft Corporation. All rights reserved.

C:\Users\Thomas>cd/

C:\>cd androidsdk/tools

C:\androidsdk\tools>adb shell

sh-4.1# su

su

sh-4.1# cd /sdcard/ubuntu

cd /sdcard/ubuntu

sh-4.1# sh ./ubuntu.sh

sh ./ubuntu.sh

modprobe: chdir(/lib/modules): No such file or directory

←[H←[Jrm failed for -f, No such file or directory

rm failed for -f, No such file or directory

rm failed for -f, No such file or directory

rm failed for -f, No such file or directory

rm failed for -f, No such file or directory

mkdir failed for /data/local/mnt, File exists

←[H←[Jrm failed for -/system/bin/mountonly, No such file or directory

Unable to chmod bootubuntu: Operation not permitted

←[H←[J

Ubuntu Chroot Bootloader v0.1

Ubuntu Bootloader is now installed!

This process does NOT damage Android OS!

Original Installer by Charan Singh

Modified for Ubuntu Chroot by Max Lee at NexusOneHacks.net

To enter the Debian Linux console just type 'bootubuntu'

sh-4.1# bootubuntu

bootubuntu

mknod: /dev/loop2: File exists

ioctl LOOP_SET_FD failed: Device or resource busy

mount: No such file or directory

mount: No such file or directory

mount: No such file or directory

net.ipv4.ip_forward = 1

Setting /etc/resolv.conf to Google Open DNS 8.8.8.8 and 8.8.4.4

/system/bin/bootubuntu: line 16: /data/local/mnt/etc/resolv.conf: No such file o

r directory

/system/bin/bootubuntu: line 17: /data/local/mnt/etc/resolv.conf: No such file o

r directory

Setting localhost on /etc/hosts

/system/bin/bootubuntu: line 19: /data/local/mnt/etc/hosts: No such file or dire

ctory

READY TO ROCK AND ROLL BABY!

Brought to you by NexusOneHacks.net and the open source community!

Modified by Webs05 - XDA Forums :)

chroot: can't execute '/bin/bash': No such file or directory

Shutting down Ubuntu

failed.

failed.

failed.

failed.

sh-4.1# Killed

sh-4.1#

C:\androidsdk\tools>
[Adam Android Development] tillum:
The issue there is that your /dev/loop2 device is already in use by some other process. You could probably hack the script to use another loop if you can work out what's free. Otherwise, have a look at the latest script for running Ubuntu on the Nexus One, it uses a similar method. Last time I tried it (3 months ago?) some bright spark had created another script to free up the loop devices from borked attempts. You can also usually just restart the device... assuming the loop you're using is free ti begin with. Finding the script to kill loop processes would probably be your best bet, then hacking the boot script further if you need to. Text editors are your friend.

My Adam (pixel qi+3g) came yesterday. My next big essay is due tonight. Then another one next week. It's going to be about 3 weeks until I'm free to play with this. As for Eden...meh... buggy and pretty uninspiring, but can see the potential. Personally, Ubuntu's new Unity interface, even without graphics acceleration is more interesting. Eden doesnt come close. Good luck.

Edit: sorry, just realized from previous posts you knew about the loop device. My guess is your best way forward is to hack into the script... see if you can change it to another loop. Also, try searching some Linux forums for a command to check which loop devices are free. Android is mostly linux, and chances are you'll find something that helps. Good luck.
[Adam Android Development] webs05:
Okay, I updated the bootubuntu file. Download "bootubuntu1.1" and change its name to just "bootubuntu". Then try running it.
[Adam Android Development] webs05:
If download failed, try again. I did some ninja editing... :D
[Adam Android Development] tmckenn2:
Well I tried with the latest bootubuntu, yes I ran with su and I reran ubuntu.sh to replace the files.... no dice this is the output(its different... but not better, there seems to be also a problem with the mounting of the files, the stuff right below te loop device):

Ubuntu Chroot Bootloader v0.1

Ubuntu Bootloader is now installed!

This process does NOT damage Android OS!

Original Installer by Charan Singh

Modified for Ubuntu Chroot by Max Lee at NexusOneHacks.net

To enter the Debian Linux console just type 'bootubuntu'

sh-4.1# bootubuntu

losetup: /dev/block/loop1

mount: Device or resource busy

mount: No such file or directory

mount: No such file or directory

mount: No such file or directory

net.ipv4.ip_forward = 1

Setting /etc/resolv.conf to Google Open DNS 8.8.8.8 and 8.8.4.4

/system/bin/bootubuntu: line 22: /data/local/ubuntu/etc/resolv.conf: No such file or directory

/system/bin/bootubuntu: line 23: /data/local/ubuntu/etc/resolv.conf: No such file or directory

Setting localhost on /etc/hosts

/system/bin/bootubuntu: line 25: /data/local/ubuntu/etc/hosts: No such file or directory

READY TO ROCK AND ROLL BABY!

Brought to you by NexusOneHacks.net and the open source community!

Modified by Webs05 - XDA Forums :)

chroot: can't execute '/bin/bash': No such file or directory

Shutting down Ubuntu

failed.

failed.

failed.

failed.

losetup: /dev/loop1: Device or resource busy

sh-4.1#
[Adam Android Development] webs05:
First please verify you are not running any apps from SD. If you are, that may be causing problems. Using this method, any and all apps need to be installed internally.

I updated the bootubuntu file again. Try it and see what happens... :D
[Adam Android Development] tmckenn2:
WE'RE IN HAHA!!!!!!!!

I removed all apps from SD then used the most recent bootubuntu and I'm in whoooooooo. Nice work man, I had a crazy weekend so I probably wont do much until tomorrow, but. Ill try and get the GUI up on vnc .... and get a video up :)
[Adam Android Development] tmckenn2:
Ok well after a nap I decided to do some toying around... here are the results

1)Vnc works with full GUI

2)Firefox runs as well As open office but open office takes a while to load(it is a little slow)

3)keymappings are F'd, this is a known issue of the Vnc server and I believe I've found a fix, will work more on this tomorrow

4)the bootubuntu script does not exit properly... it shows one of the exit unmounts failing(doesn't say which one) and loop device busy (I can get more info on which one Is failing tomorrow after I add some debug lines to the file, I cannot for the life of me understand the loop device part)

5)the point about not having apps on SD was spot on and the cause for all evil in the world... haha jk, just it not running. With the new script and apps on SD it failed but with them on phone it ran.... cut and dry)

6) I have a distinct feeling there was something else but I can't remember... soooooo

I hope to figure out this vnc thing and provide you, web05, with a Ubuntu.Img with everything it needs pre installed. Ill also zip that up in a zip with the rest of the stuff so its an easy unzip to Ubuntu and run. Ill also try and provide a few scripts or something to do the installing for you.... oh I also remembered internet works...

Great progress man see if you can get the exit command to work and ill work on the rest of this stuff. Also so you know I ran the exit command and then checked Vnc and it still was running so I'm not just baiseing this off of a failed command.... finally, a full shut down of the Adam does shut down Ubuntu fully, so it's not running in the background.
[Adam Android Development] webs05:
Awesome man! I should have some time to look at the scripts again and see what we can get. :)

Also, sorry if I came off a little strong on Fri. I wasn't having as good of a Fri as Rebecca Black.
[Adam Android Development] tmckenn2:
Its all good, we all have our days.

the exit part that is failing is the line with just mnt$... the last unmount, i dont know why but thats it. also losetup fails... is there by chance an override for unmounting, like a forces unmount option? i disconnected vnc but that didnt help. also shutdown in ubuntu doesnt do anything.

i have an ubuntu.img with lxde installed and vnc server running, ill try and post that when its done uploading!

we have a lot of momentum, lets keep it going!

EDIT:i was looking at the ubuntu.img provided and 9.10 is a little old now. im going to try my hand at getting 11.04 up and running, should be as simple as getting it in an arm form and using the scripts you made... ill still upload what i have to play with and will work on this in the next couple of days.
[Adam Android Development] tillum:
Great work folks! Please take a look at this thread about getting ubuntu 10.10 running on the Nexus One: http://xdaforums.com/showthread.php?t=892877

It involves modified scripts from the original project, involving scripts to cleanly kill running loop devices. This should go some way to solving issues with stopping vnc and having the Ubuntu process still running in the background.

From memory, that is an extra script that you run, and should be easily ported over to the adam. I haven't had time to test this, will let you know if that changes. Thanks for all the work everyone has been doing, sorry I haven't been able to take more of an active part.

Just got my adam a few days ago... not much time to play. Bought it with a friend, with the general idea of 'hacking it until one of us breaks it'... laughing, then trying again. Due to my business it's off to his place for a couple weeks, but on it's return I'm hoping to have more time to put into hacking projects.

Anyway, will post back once I get a chance to try this out... might be awhile. Cheers.

~Tillum (aka dinky)
[Adam Android Development] tmckenn2:
i may have spoken too soon... it looks like 11.04 is a lot harder / borderline impossible. i will copy the 10.10 img and try that and hopefully work on compiling my own rootfs ver of ubuntu 10.10...

Thanks tillium, i looked through the posts and its really good stuff, ill try the fix for ending the session to try and fix the device busy... also he has -lfr on his unmounts but all it does is return unmount<path> idk what that means and there is a chance i did it wrong.

i just finished my first rootfs and ill try that tonight, maybe i can get a better one made tomorrow.

i think one thing we need to add it usb support for usb disks... i dont know how you'd do this... maybe mount android mount point to the ubuntu mount point or something... also i think im going to see if i can get vnc file transfer to be a temp stand in...

i tried to upload the files but my internet blows and it failed to upload twice... ill work on a different method tomorrow.

as to the whole 11.04 thing... i can create a custom rootfs but i need a debootstraped/cross compiled kernel.... unfortunately they dont have those on the public repo like they do for 10.10. i have the arm image they created under the ubuntu netbook name but im not convinced it will work ( made for omap4 or 3 but im not sure how it fits into the rootfs process, also i keep getting it corrupted) ill keep working, if i can reliably get rootfs to work and i get good at it ill take a stab at debootstrap, but that is a whole different ballpark.
[Adam Android Development] tillum:
We're in! I just got 10.10 running in VNC using these scripts, plus the rootfs image from the link I posted. Works, but using it through vnc isn't great. Will have to play around with it more. For some reason, the desktop doesn't have write access, not sure why, and haven't checked other folders. In am running as root, and can install software, so its very strange.

I'm not that clear abou what needs to happen with the kernels to get this workin with 11.04. I woul guess though we will need to custom create a rootfs filesystem through roostock though. What did you try with 11.04? My understanding is that you need to run rootstock with a particular command to include the kernel. Not too sure what needs to happen other than that, will read up on it.

Re using Ubuntu from the terminal, can't seem to hit ctrl and another key at the same time... Makes using nano, or even cat, impossble, as there is no way to exit the process. We might need to post a modified version of the rootfs I used that has the other scripts included. Happy to do it, but lets see about a workin Natty first. Cheers.
[Adam Android Development] tmckenn2:
Right the command would be seed but it seeds using a image repo online. That report contained a bunch of bootstrapped images all the way up to 10.10... anyways I'm going to attempt to make my own which will hopefully run better!

As to. He ctrl thing... I know... its a pain, I had to use adb shell to do it BC my PC has crept working....

My very of 10.10 is up and running... but it is verrrrrry alpha... I'm gonna remake one tonight with all the right. Packages...
[Adam Android Development] tillum:
Great! Glad to see you're on it. Will be interested to see how you rebuild the rootfs, as well as what packages you'll add, please let me know, am keen to play around with this more. My internet connection is VERY dodgy right now... not sure what I can build at this end. Good luck.
[Adam Android Development] webs05:
I'm at work now and wont be able to look at things till later tonight. But let me know if anyone wants access to the google code project to upload files, if you cannot upload already...

Also if you leave me links to your Ubuntu.img I will link to it in original post. Please verify it works first though. :) Great work everyone!
[Adam Android Development] littlemumford:
n00b!

Hey,

I have been having a read around on linux ports for android devices in general but with a specific eye on the Adam I dont have :p

I have a few questions:

The chroot method:

This method runs directly on top on the running Android kernel?

It therefore doesn't use any of androids system drivers?

It doesn't have or need any touchscreen driver support as it uses VNC?

A Native method:

If it is possible to run a ubuntu install on the installed android kernel then it should be possible to raw boot an ubuntu install using the same kernel?

Would have issues with driver support and other problems, tho with work these could be over come like they have been for the HD2.

And then the big question:

Does the Adam use fastboot and is it possible to get into it?

Stuart
[Adam Android Development] tmckenn2:
hey mumford... im a little confused by the questions as they seem to be more like statements. but in essence, you have a ubuntu file system stored on an img... aka a virtual hard drive. then you mount that in a runable place using loop devices... both ubuntu and android are running at the same time and the android file system is not affected. the vnc is the method used to bypass all sorts of drivers namely the video and touch drivers...

you are correct by saying that the ubuntu.img can be used in a native mode... in fact the 10.10 img referanced by tillium is one used on the HD2 as native. unfortunately it does require you to have all the drivers working including networking. not to mention the required boot loader.

the rootfs method builds the required file system to run ubuntu with the packages and an added kernel using the method "seed"which downloads a pre cross-compiled ver. of the linux kernel. i cannot recall if the adam uses fast boot but all android devices have some method of flashing the file system directly... that is the recovery process described in the unbrick posts.

the issues with drivers are being delt with by someone over at notion ink hacks by the name of rayman we alluded to him earlier in the thread. we have a post here on how to do it but do not currently have a method.

im going to do a video on how to do rootfs in the simplest manor later, since thats what im working on right now. also im not 100% on the packages i want to install, i know build essentials and tightvnc are a must then maybe just ubuntu-desktop... right now id like to try a ubuntu-netbook remix. (btw lxde may be fast but it sure stinks bc of its small buttons!)

the main goal is to create a ubutnu.img that will do the vnc server out of the box with keyboard fix. we can go anywhere from there!
[Adam Android Development] littlemumford:
Hey

Yeah, the questions were sort of conformations of what I was thinking!

So what is the status of the bootloader for the Adam? Is the only option for native booting flashing the new images through recovery, or is it possible to get into fastboot and potentially be able to dual boot linux off a memory card?

So you are creating a native bulid using rootfs?

I would recommend the netbook remix, I have the Ubuntu for the HD2 and its very shiny!

Stuart
[Adam Android Development] tillum:
Hey Stuart, welcome to this thread!

Re fastboot, it doesn't exist for the tegra 250 chipset that adam is based on. What we do have is something else (better imo), apx mode. This is entered by holding down the power and volume down button at the same time, and used with nvflash. Please search notioninkhacks.com for rayman's thread for more info. I thinkthe second or third page has a link to the developers section with some files to use.

It is possible to dualboot adam, but you loose recovery, currently. This seems easy enoughto restore. The netbook edition only exists for omap4 boards with a 2d interface for 11.04, but yes, some of us are aiming for something similar.

@webs05, would be great to have access to the google code project.

@tmckenn2, look forward to seeing that video.

Will have a go wth rootstock myself soon. Cheers. Mitchell