Installing Ubuntu on Dropad A8 / Herotab C8
This guide will explain how to install Ubuntu on your Dropad A8 / Herotab C8 tablet on and creating the Ubuntu filesystem in Linux.
I have used my A8 tablet for a while, but lately it is only there eating dust in my closet. Time to pimp this tablet. In my case, I want to use this tablet as a little low-cost, energy-saving webserver and SVN. That is where Ubuntu come in.
Running Ubuntu on your tablet means Ubuntu will be running "chrooted": it will run on top of your Android OS, so it will be remain largely unchanged.
Using this guide will required some basic knowledge about ROM's, ADB and Linux. Installing Ubuntu on your tablet device is at your own risk.
Step 1 - Flashing a rooted firmware / ROM
Note: Flashing a new ROM can cause loss of data. It is recommended that you backup all personal data before flashing a new ROM.
This step is optional. To run Ubuntu on your tablet device, a kernel with support for loop devices is required.
If your kernel does not support loop devices, find yourself a suitable firmware / ROM. Please check the Herotab C8 Firmware / Development forum. Make sure that the ROM is rooted and BusyBox is installed. If not, you can grab a BusyBox installer from the Android Market.
I am currently using the Evolution 3.1.1 ROM by prox32 at the moment. This ROM supports loop devices and has clocked the CPU at 1.2 GHz, giving an extra performance boost.
To flash a ROM, simply download the files and extract them in the root directory of your SD-card. Turn on / reboot your tablet while keeping the menu-button pressed. At this point, your ROM will be flashed into the device. For more information see http://www.slatedroid.com/topic/23176-first-time-flashing-your-tablet-look-here/.
Step 2 - Enable USB debugging and WiFi
Make sure USB debugging is enabled on your tablet. This is required for communication between your PC and tablet device through ADB (Android Debug Bridge). Go to Settings > Applications > Development to see if USB debugging is enabled.
Also enable WiFi and connect to a wireless network. This will allow Ubuntu communicate with the internet.
Step 3 - Install the Android SDK
Grab and download the Android SDK if you haven't installed it yet on your computer. The SDK also supplies the USB drivers for connecting your tablet with your computer. These are located in the third party Google repository. For more information on installing the Android SDK see http://developer.android.com/sdk/installing.html.
Step 4 - Creating the Ubuntu filesystem
Before you can create a Ubuntu filesystem, you need access to an operational Ubuntu installation. I am using a virtual Ubuntu 10.10 Desktop installation in VMware. Ubuntu images are free and can be download from http://www.ubuntu.com/download. VirtualBox (cross platform) or Virtual PC (Windows) are great free tools to run virtual machines. Just Google for them. When you have access to an operational Ubuntu installation, just login and open the terminal.
We are using rootstock in order to create the filesystem. If rootstock isn't installed yet, please enter the follow command:
This will install rootstock on your Ubuntu machine.
Run the follow command:
Please replace all "your[something]" with your own information. For example, replace yourfqdn with ubuntu. For the imagesize, use values as 1G, 2G, 4G, 8G etc. These values are equal to the desired image size (1GB, 2GB, 4GB, 8GB etc.). With seed you can specify programs that will be included in your filesystem. With build-essential we are only building a filesystem with the minimum required programs. In this case, Tight VNC server is included as VNC server and GNOME as the window manager. Alternatively, you can also use LXDE (Lightweight X11 Desktop Environment) as window manager. Just replace gnome-shell with lxde. When rootstock is finished, it will create a file called "armel-rootfs-xxxxxxxxxxxx.tgz" in your working directory.
Now we have the files, we can create an image to mount it on our Android device. Enter the follow command to create an empty image:
Replace yourseek with 1024 for a rootstock file size of 1G, 2048 for 2G, 4096 for 4G etc. A image called ubuntu.img is now created in your working directory.
Next, format the image as an EXT2 filesystem:
Mount the empty image, for example in a folder called "ubuntu" on your desktop. Make sure that the "ubuntu" directory exists. Enter the follow command:
Extract the generated TGZ file by rootstock in the directory where the image is mounted. Replace the xxxxxxxxxxxx with the correct numbers.
When the extraction process is finished, unmount the image:
And you are ready for the next step.
Step 5 - Copying the image to your tablet
Plug in your tablet into your computer (connect to your computer with the OTG USB port). Turn on USB storage and copy the created ubuntu.img to your device. I have created a folder called "ubuntu" en copied ubuntu.img into the ubuntu folder. The ubuntu folder is located at the root of my internal SD card (for example: /sdcard/ubuntu/ubuntu.img). It is also possible to copy the image to an external SD card. Just remember the path where you have stored the image.
Step 6 - Start Ubuntup
You are almost ready to go. It is time to mount the image. In this step, ADB will be used to mount the image. I will shortly explain the usage of ADB in Windows.
First, start command prompt and navigate to the "platform-tools" directory in the ADB installation directory. In my case, ADB is installed in C:\android-sdk-windows, so platform-tools is located in C:\android-sdk-windows\platform-tools.
Now check if your device is recognized and connected with your computer:
If your drivers are properly installed and the device properly connected, it will return a device called "MID_serials". Otherwise, check your connection (is USB debugging enabled?) or your drivers.
When your device, MID_serials, is listed, open the ADB shell
Now mount the image. You might want to change some path's if you have stored your ubuntu.img on another location (mine is stored in /sdcard/ubuntu/ubuntu.img). For example, if you have stored your ubuntu.img in a folder called ubuntu on your external SD-card, please replace path with "/sdcard/ubuntu" with "/extsd/ubuntu"
If everything went well, you should see "[email protected]: #". Congratulations, Ubuntu is now running from your tablet device. Your ADB shell is now turned into a Bash shell!
From here it's also possible to run linux commands, suchs as "sudo apt-get install xxxxx" etc.
Step 7 - Start the VNC server
Type the follow commands:
At the first startup, TightVNCServer wil prompt you for some passwords. Please enter these. Optionally, you can change the resolution by changing the geometry argument.
You might want to adjust the /root/.vnc/xstartup if you are using another window manager then Gnome.
Step 8 - View your Ubuntu installation
Download a VNC client (for Android, Linux or Windows, whatever fits you) to view your Ubuntu installation. Connect to your tablet by entering the internal IP address and the port, for example: 192.168.2.10:5901 (5901 is the standard port). To find out the internal IP address of your tablet, return to your Bash shell and run the command "ifconfig".
Additional information
To shutdown Ubuntu en unmount the image, please enter the follow commands in your ADB / Bash shell:
To start Ubuntu again, please enter the commands from step 6 and step 7. If you are an enthusiast, you can write your own startup scripts, so you don't have to enter a lot of commands before starting up Ubuntu.
Credits to AndroLinux.com. Parts of the start-up script in step 6 are taken from AndroLinux.
Enjoy your newly Ubuntu tablet device
.
This guide will explain how to install Ubuntu on your Dropad A8 / Herotab C8 tablet on and creating the Ubuntu filesystem in Linux.
I have used my A8 tablet for a while, but lately it is only there eating dust in my closet. Time to pimp this tablet. In my case, I want to use this tablet as a little low-cost, energy-saving webserver and SVN. That is where Ubuntu come in.
Running Ubuntu on your tablet means Ubuntu will be running "chrooted": it will run on top of your Android OS, so it will be remain largely unchanged.
Using this guide will required some basic knowledge about ROM's, ADB and Linux. Installing Ubuntu on your tablet device is at your own risk.
Step 1 - Flashing a rooted firmware / ROM
Note: Flashing a new ROM can cause loss of data. It is recommended that you backup all personal data before flashing a new ROM.
This step is optional. To run Ubuntu on your tablet device, a kernel with support for loop devices is required.
If your kernel does not support loop devices, find yourself a suitable firmware / ROM. Please check the Herotab C8 Firmware / Development forum. Make sure that the ROM is rooted and BusyBox is installed. If not, you can grab a BusyBox installer from the Android Market.
I am currently using the Evolution 3.1.1 ROM by prox32 at the moment. This ROM supports loop devices and has clocked the CPU at 1.2 GHz, giving an extra performance boost.
To flash a ROM, simply download the files and extract them in the root directory of your SD-card. Turn on / reboot your tablet while keeping the menu-button pressed. At this point, your ROM will be flashed into the device. For more information see http://www.slatedroid.com/topic/23176-first-time-flashing-your-tablet-look-here/.
Step 2 - Enable USB debugging and WiFi
Make sure USB debugging is enabled on your tablet. This is required for communication between your PC and tablet device through ADB (Android Debug Bridge). Go to Settings > Applications > Development to see if USB debugging is enabled.
Also enable WiFi and connect to a wireless network. This will allow Ubuntu communicate with the internet.
Step 3 - Install the Android SDK
Grab and download the Android SDK if you haven't installed it yet on your computer. The SDK also supplies the USB drivers for connecting your tablet with your computer. These are located in the third party Google repository. For more information on installing the Android SDK see http://developer.android.com/sdk/installing.html.
Step 4 - Creating the Ubuntu filesystem
Before you can create a Ubuntu filesystem, you need access to an operational Ubuntu installation. I am using a virtual Ubuntu 10.10 Desktop installation in VMware. Ubuntu images are free and can be download from http://www.ubuntu.com/download. VirtualBox (cross platform) or Virtual PC (Windows) are great free tools to run virtual machines. Just Google for them. When you have access to an operational Ubuntu installation, just login and open the terminal.
We are using rootstock in order to create the filesystem. If rootstock isn't installed yet, please enter the follow command:
Code:
sudo apt-get install rootstock
Run the follow command:
Code:
sudo rootstock --fqdn yourfqdn --login yourusername --password yourpassword --imagesize yourimagesize --seed linux-image-omap,build-essential,tightvncserver,gnome-shell
Now we have the files, we can create an image to mount it on our Android device. Enter the follow command to create an empty image:
Code:
dd if=/dev/zero of=ubuntu.img bs=1MB seek=yourseek count=0
Next, format the image as an EXT2 filesystem:
Code:
mke2fs –F ubuntu.img
Code:
sudo mount -o loop ubuntu.img /home/yourusername/ubuntu
Code:
sudo tar -C /home/yourusername/ubuntu -zxf armel-rootfs-xxxxxxxxxxxx.tgz
Code:
sudo unmounts /home/yourusername/ubuntu
Step 5 - Copying the image to your tablet
Plug in your tablet into your computer (connect to your computer with the OTG USB port). Turn on USB storage and copy the created ubuntu.img to your device. I have created a folder called "ubuntu" en copied ubuntu.img into the ubuntu folder. The ubuntu folder is located at the root of my internal SD card (for example: /sdcard/ubuntu/ubuntu.img). It is also possible to copy the image to an external SD card. Just remember the path where you have stored the image.
Step 6 - Start Ubuntup
You are almost ready to go. It is time to mount the image. In this step, ADB will be used to mount the image. I will shortly explain the usage of ADB in Windows.
First, start command prompt and navigate to the "platform-tools" directory in the ADB installation directory. In my case, ADB is installed in C:\android-sdk-windows, so platform-tools is located in C:\android-sdk-windows\platform-tools.
Code:
cd C:\android-sdk-windows\platform-tools
Code:
adb devices
When your device, MID_serials, is listed, open the ADB shell
Code:
adb shell
Code:
<br />
su<br />
export kit=/sdcard/ubuntu<br />
export bin=/system/bin<br />
mkdir /data/local/ubuntu<br />
export PATH=$bin:/usr/bin:/usr/sbin:/bin:$PATH<br />
export TERM=linux<br />
export HOME=/root<br />
losetup /dev/block/loop1 /sdcard/ubuntu/ubuntu.img<br />
mount -t ext2 /dev/block/loop1 /data/local/ubuntu<br />
mount -t devpts devpts /data/local/ubuntu/dev/pts<br />
mount -t proc proc /data/local/ubuntu/proc<br />
mount -t sysfs sysfs /data/local/ubuntu/sys<br />
sysctl -w net.ipv4.ip_forward=1<br />
chroot /data/local/ubuntu /bin/bash<br />
From here it's also possible to run linux commands, suchs as "sudo apt-get install xxxxx" etc.
Step 7 - Start the VNC server
Type the follow commands:
Code:
<br />
export USER=root<br />
vncserver -geometry 1024×768<br />
You might want to adjust the /root/.vnc/xstartup if you are using another window manager then Gnome.
Step 8 - View your Ubuntu installation
Download a VNC client (for Android, Linux or Windows, whatever fits you) to view your Ubuntu installation. Connect to your tablet by entering the internal IP address and the port, for example: 192.168.2.10:5901 (5901 is the standard port). To find out the internal IP address of your tablet, return to your Bash shell and run the command "ifconfig".
Additional information
To shutdown Ubuntu en unmount the image, please enter the follow commands in your ADB / Bash shell:
Code:
<br />
shutdown now<br />
exit<br />
umount /data/local/ubuntu/dev/pts<br />
umount /data/local/ubuntu/proc <br />
umount /data/local/ubuntu/sys <br />
umount /data/local/ubuntu<br />
losetup -d /dev/block/loop1<br />
Credits to AndroLinux.com. Parts of the start-up script in step 6 are taken from AndroLinux.
Enjoy your newly Ubuntu tablet device
