FORUMS
Remove All Ads from XDA

[GUIDE] [12/12/11] How to run Ubuntu within Android on Archos

2,888 posts
Thanks Meter: 1,818
 
Post Reply Email Thread
I will no longer be updating this guide, to keep up to date with the project please see the App thread HERE. The Free app can be downloaded HERE and the Paid HERE

First and for most this guide has been created from a mixture of a few guides to get it all working on the tablets, I do not take any credit for the methods all I have done is taken the time to work out how to get it working on our tablet. This guide is for windows or can be done all on the tablet. Anyway on with the guide

How To Install Ubuntu on the Desire S
Before we start you will need a ROM and kernel that supports loop devices.
This works best on UrukDroid but may well work on stock roms, due to the lack of RAM ubuntu isn't very fast but everything works unlike running it outside of ubuntu.

It is also recommend that you have the Android SDK install so that you can access adb however all commands can be done on the tablet via the terminal emulator

Also make sure that you have debugging mode enabled Go to Settings->Applications->Development and make sure USB Debugging is checked ON.

You will also need atleast 3.5GB of memory card space

Download and extract ubuntu.zip
Once you have a working ROM with loop support you must now download the special modified ubuntu image. I have hosted the file on my own server however if this is not quick enough feel free to mirror it or message me and I shall host else where as well.
There are now three versions to use as you wish, however the new 10.10 image has pretty much everything working, see change log at the bottom of the next post. the 11.10 image's UI does not work right and the 9.04 image is well rather old :P
Once you have downloaded this .zip file you will need to extract it to a folder on your sdcard name this folder "ubuntu".

Install and run Ubuntu!
If you do not have the android SDK install or wish to do all the commands via your tablet please skip to step 7

1) Connect your Desire S to your computer via your USB cable and make sure USB mode is set to “Just Charge”.

2) Your Android device should be recognized as “ADB Device” under Device Manager. If not, install appropriate drivers.

3) Now open a command window and navigate to the directory that you have installed the android SDK for example
Code:
cd c:\android-sdk
4) From here then navigate to the platform-tools directory
Code:
cd  platform-tools
5) Now type “adb devices” to double-check your Android device is recognized. It should display something along the lines of
Code:
Lists of devices attached
HT09SR204261 device
If not then you have not installed the drivers for your tablet or it is not in debugging mode.

6) Next type “adb shell” to enter the Android shell

7) Now type su to enter super user mode, then type cd /sdcard and then cd ubuntu to enter the directory on the SD card that you stored the ubuntu files.
Code:
su
cd /sdcard
cd ubuntu
8) Then type sh ubuntu.sh this will run the included script to ready your ubuntu image, do not worry about any error messages that are displayed!
Code:
sh ubuntu.sh
8.5) If running the 10.10 V2 image you should get this message 'please wait while booting the ubuntu img, please wait as this could take a while.' if you do get this then ubuntu is running and you just need to open vnc and connect to get into ubuntu. Please see the bug section on the second post for more information!

9) Now type bootubuntu to enter ubuntu (note in the future to start ubuntu simply type bootubuntu there is no need to run the script again)
Code:
bootubuntu
You should now see something along the lines of
If you don't then its likely the ROM your using does not support loop devices and you will need to install one of the ROMs from the top of this guide to get it working.

And thats it you now have a working ubuntu command line running within android! however this isnt really much use so lets now get a more useful system running

How to Install TightVNCserver
This is by far the best program to install first off as it will let you access the GUI of Ubuntu as it run on your Desire S. (note this is already included in the 10.10 (V1 and V2) image there is no need to carry out this step)

0) Before you install any program first we need to update by typing
Code:
apt-get update
1) Now type “apt-get install tightvncserver” to install the VNC server.

it shall then as you if you wish to install the program etc etc say yes and it will install, simples.

How to Install LXDE (optional but recommended)
only need to carry out this step if you are using the 9.04 image

1) Type “apt-get install lxde” and ubuntu will do the rest

Set up TightVNCServer and fix keyboard issues
(note on the 10.10 image this step has been included already! so no need to carry it out)
Before we launch the TightVNCServer we much make changes the the xstartup file to change to it uses LXDE if we want this and also to fix a big issue with the android keyboard not being mapped correctly.

1) Start off by typing
Code:
cat > /root/.vnc/xstartup
To open the file we need to make changes in
2) Now type
Code:
#!/bin/sh
xrdb $HOME/.Xresources
xsetroot -solid grey
export XKL_XMODMAP_DISABLE=1
icewm &
lxsession
The last two lines you will only want to type if you have installed LXDE if you want to use XFCE leave these lines off. The line above this (export XKL_XMODMAP_DISABLE=1) is what is needed to fix the keyboard mapping.

3) Now press ctrl+D twice and then press enter to the save the file, we are now ready to start up the VNCServer!

Start TightVNCServer
Now we are ready to start the server and connect our tablet or windows computer to the Ubuntu running within our tablet! (This step is not needed in the new 10.10 V2 image VNCserver now auto starts)

1) Start off by typing
Code:
export USER=root
vncserver -geometry 1024×800
you can change the resolution settings 1024×800 to the resolution of your liking. I find 800x480 does work well but limts your work space so its up to you.

2)TightVNCServer will then ask you for a password to connect to it, fill this in and your server will be then ready to accept any incoming connection from your tablet or computer! (on the 10.10 image it will not ask for this, the password is set to ubuntu)

Connect to VNC on your tablet
1) download the free app Android-VNC-viewer

2) open the app and set your IP address to 127.0.0.1 ( set this to localhost in 10.10 V2) and port number 5901 (5900 in 10.10 V2) and enter the password you set before (or ubuntu on 10.10 images) to then connect.

If all works right you will have a working GUI!!!

Connect to VNC on your computer

1)Start by downloading the desktop version of TightVNC Here
and install it

2) Open the TightVNC Viewer from the start menu it will ask for your tablets IP address, to find this type ifconfig in your ubuntu terminal it will display your IP.

3)Type this into TightVNC and remember to add the port 5901 (5900 in 10.10 V2), it will then ask you for the password ('ubuntu' on 10.10 image) , enter this and you should then have a fully working GUI on your computer!
The Following 4 Users Say Thank You to zacthespack For This Useful Post: [ View ] Gift zacthespack Ad-Free
 
 
24th November 2011, 10:58 AM |#2  
zacthespack's Avatar
OP Inactive Recognized Developer
Flag Likes: XDA,Coffee,Android,Beer Dislikes: No Beer
Thanks Meter: 1,818
 
Donate to Me
More
FAQ

How does Ubuntu look on our tablet?
Ubuntu 9.04

Ubuntu 10.10


What is Ubuntu? and why would I want it on my tablet
Ubuntu is a linux based operating system normally for the computer, however with this port we can run it on our tablet, this allows you to pretty much install any software available for linux and run it on your tablet.

What are the best settings for Android VNC Viewer?
I find full 24-bit colour works very well and there is no need to down step this, also Input Mode is best set to touchpad as the GUI is not very touch screen friendly when its this small! using touchpad makes the touch screen act just like the touch pad on a laptop and I find this very easy to use.





Updates

[12/12/11]
  • New 10.10 image update
  • New built in script in Ubuntu to start vncserver and other services on boot
  • SD card is accessible from within Ubuntu
  • Image changed to 3.5GB to fit if you have a 4GB SD Card
  • The ubuntu boot scripts are now on easy to use script!
  • More working programs (including software centre etc)
  • Default desktop changed back to LXDE
  • More apps for 'developing'
    Firefox, Thunderbird, openoffice.org suite, GIMP Image Editor, Emacs Text Editor (geared towards programming), C and C++ build-essential, Java JDK, Python, TeXlive and TeXmaker LaTeX editor, Transmission BitTorrent Client, eVince PDF Viewer, File Manager, Terminal, Image Viewer, Leafpad Text Editor, Synaptic Package Manager and Ubuntu Software Center with all repositories enabled (Ubuntu Software Center is pretty and well organized - but bloated and slow), SSH server, Gnash (GNU flash player/plugin for Firefox - as there is no official generla flash pluging for armel CPUs)

[23/11/11]
  • New 10.10 image
  • vncserver and bug fixes included in 10.10 image
  • New light weight UI in 10.10 image
  • 4GB image size for plenty of app space
  • More programs should be working in the 10.10 image please test!!
  • New image all icons in GUI don't load Fixed in 10.10 image
  • New Firefox crashes on start up now fixed in 10.10 image
  • +More that I cant remember

[05/11/11]
  • Old 9.04 image readded for those that want working GUI until new image is fixed

[24/10/11]
  • Java install guide added

[23/10/11]
  • New 11.10 ubuntu 4GB image
  • Changed guide for new image
  • +MUCH more (will add later)


Bugs
  • At the moment to use the new 10.10 V2 image you have to carry out steps 7 to 8.5 each time in order to get into the GUI, which means the only way to use terminal for ubuntu is within the GUI, this isnt to bad as the build is now very stable
  • At the moment once you start ubuntu it seems to prevent the sdcard being mounted and as there is no way to shut down the ubuntu session you must reboot if you wish to mount the sdcard via usb
  • Java might still not be working right please test!!
The Following 2 Users Say Thank You to zacthespack For This Useful Post: [ View ] Gift zacthespack Ad-Free
24th November 2011, 10:59 AM |#3  
zacthespack's Avatar
OP Inactive Recognized Developer
Flag Likes: XDA,Coffee,Android,Beer Dislikes: No Beer
Thanks Meter: 1,818
 
Donate to Me
More
Other Programs to Install
Ok so as I start working on testing more programs I will post here how well they work and what does and dosnt work. Most programs that run from terminal and don't require any hardware like wifi etc seem to work well!

JAVA SE FOR EMBEDDED
To install the Java version for arm open up the terminal and type the following lines of code
Code:
wget http://android.zpwebsites.com/java.tar.gz
This will download the java package from my server!

Once downloaded type
Code:
gunzip java.tar.gz
Code:
tar xvf java.tar
This will extract the java package into a folder called ejre1.6.0_27
then type
Code:
export JAVA_HOME=ejre1.6.0_27
Code:
export PATH=$JAVA_HOME/bin:$PATH
Java should then be completely installed, please test by typing
Code:
which java
TipsSome android terminal emulators (e.g. better terminal) allow you to specify an initial command that is run as soon as you launch the application. Multiple initial commands can be defined by pressing return between each command when you define it, so for example the initial command:
Code:
su <return>cd /sdcard/external_sd/ubuntu <return>sh ubuntu.sh <return>
This way to load the new 10.10 V2 image simply open the terminal emulator
Help Needed

I would love for people to test there fav linux programs, also anyone that knows alot about ubuntu/linux to help getting the image to run faster etc etc
26th November 2011, 03:52 AM |#4  
LeoNg628's Avatar
Senior Member
Thanks Meter: 37
 
More
Wow, how about HDD version? and I would like to know the Bluetooth function, is it work in Ubuntu?
26th November 2011, 10:32 AM |#5  
zacthespack's Avatar
OP Inactive Recognized Developer
Flag Likes: XDA,Coffee,Android,Beer Dislikes: No Beer
Thanks Meter: 1,818
 
Donate to Me
More
Quote:
Originally Posted by LeoNg628

Wow, how about HDD version? and I would like to know the Bluetooth function, is it work in Ubuntu?

Well the files should work ok on the hdd version but I don't have one to test it on. The Bluetooth does not work I don't think but as its running in Android you could set up the Bluetooth keyboard or mouse and it would then function in Ubuntu

Sent from my Desire S using XDA App
26th November 2011, 04:17 PM |#6  
cajl's Avatar
Senior Member
Flag near PARIS (94)
Thanks Meter: 167
 
Donate to Me
More
"su
cd /sdcard
cd ubuntu"

i have not a ubuntu directory !
26th November 2011, 04:59 PM |#7  
Senior Member
Thanks Meter: 143
 
More
Then you didn't read the instructions, as that is the directory you are creating when extracting the files from the rar.
You are supposed to copy the whole directory to the archoos, not the files in there.
26th November 2011, 06:59 PM |#8  
Senior Member
Thanks Meter: 292
 
More
put the folder on the sdcard or internal storage?
26th November 2011, 08:51 PM |#9  
zacthespack's Avatar
OP Inactive Recognized Developer
Flag Likes: XDA,Coffee,Android,Beer Dislikes: No Beer
Thanks Meter: 1,818
 
Donate to Me
More
Quote:
Originally Posted by Ranomez

put the folder on the sdcard or internal storage?

Either will work but if you have a slow sdcard internal would be better

Sent from my HTC Desire S using XDA App
27th November 2011, 07:03 PM |#10  
Junior Member
Flag Turin
Thanks Meter: 1
 
More
Hi all,
I have a problem when I launch the command bootubuntu
after some messages, I have this:

bootubuntu: cannot create /data/local/mnt/etc/resolv.conf: directory nonexistent
chroot: not found
Shutting down Ubuntu
failed.
failed.
failed.
failed.

Any ideas???

Thanks
Rocco
27th November 2011, 07:21 PM |#11  
zacthespack's Avatar
OP Inactive Recognized Developer
Flag Likes: XDA,Coffee,Android,Beer Dislikes: No Beer
Thanks Meter: 1,818
 
Donate to Me
More
which rom are you running? it might be you havnt got busybox installed
Post Reply Subscribe to Thread

Guest Quick Reply (no urls or BBcode)
Message:
Previous Thread Next Thread
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes