Launching Ubuntu on the Android-powered smartphone Sony Xperia S (or Notes of the Madman)

We remind you that attempts to repeat the actions of the author can lead to a loss of the guarantee for the equipment and even to its failure. The material is provided for informational purposes only. If you are going to reproduce the actions described below, we strongly advise you to carefully read the article to the end at least once. The editors of 3DNews are not responsible for any possible consequences

In fact, the idea of ​​running any distribution on a smartphone or tablet running Android is far from new. Even on the very first device with this OS, HTC Dream, craftsmen forced Debian to work. To the question "Who and why is all this necessary?", Motorola most fully answered with its Laptop Dock and the WebTop shell, which turned the smartphone into not the worst netbook. A sort of mixture of two in one – shake up, but do not mix. Implementation in the "iron" is interesting, but for various reasons the mass did not. An interesting idea was developed in the camp of Canonical, where they are now engaged in the project Ubuntu for Android – a full-fledged OS, adapted for smartphones. True, it also requires a docking station, but without a screen, batteries and other accessories. That is cheaper.

Enthusiasts are also not far behind – there are several projects to launch a "big" OS on phones: the classic Debian Kit for Android, the universal Linux Installer and the simplest LinuxonAndroid, which we'll cover in this article. They work on the same principle – the launch of the chroot-environment in the Linux kernel of Android. Naturally, the smartphone should be quite powerful – the CPU with a frequency of at least around 1 GHz, at least 512 MB of RAM and at least a couple of gigabytes of free space on the SD card. Correct operation requires root-permissions, ext2 / 3/4 support, the ability to mount loop-devices, load kernel modules and so on. It is desirable to have the most stripped-down firmware to save memory and CPU resources, and also use lightweight LXDE or XFCE shells. A complete list of compatible devices and firmwares / cores can be found here.

As a result, we will have something like this miracle

If your smartphone is not on the list, it does not mean that it does not fit. We will consider in detail the process of installing Ubuntu 12.04 on one of the compatible phones – Sony Xperia S with Android 2.3.7 and the stock kernel, as the installation can not be made on a fresh 4-nd version. If you have previously lost the warranty and DRM-keys in the process of software games with the device, you can continue. Otherwise, it is not recommended to do the following. It is advisable to make a backup of important data and settings. Before all manipulations, fully charge the smartphone's battery and make sure that the light does not "blink" during firmware.

The simplest and most reliable way to get root access for Sony Xperia S is a specially prepared firmware, which already has this capability and there is no unnecessary software. To install, you will have to unlock the bootloader, for the benefit of this there are official methods. Following the instructions, before unlocking it is necessary to make sure that it is generally possible. Dial on the telephone keypad * # * # 7378423 # (service word) to open the service menu. Here, go to the Service info → Configuration → Rooting Status section and look at the Bootloader unlock allowed parameter. If the opposite is Yes, then write IMEI and go to the next stage. IMEI can also be found by typing * # 06 # .

You can get the unlock key on this page. Here you need to specify the IMEI of the device without the last digit, the name and e-mail address. (Та-дам, IMEI has got to the black list of Sony!) The issued key must be written down somewhere. We also need Android drivers and the fastboot utility. Both are part of the SDK. You can not put the entire set of SDKs, but simply find the archives on the Web with only the two components mentioned above. In the driver folder (for example, C: Program Files Android android-sdk extras google usb_driver ), you will have to replace the file android_winusb.inf with the one contained in this Archive, and rename the original file and leave it there. You also need to download the latest prerooted firmware from Gingerbread from this site. (Now this is

Now turn off the phone and, holding the volume up key, connect it via a USB-cable to the computer. If the LED on the device turns blue, the phone has moved to the fastboot mode we need – you can release the button. Right-click on the icon "My Computer", select the item "Management" in the menu and go to "Device Manager". Look for the S1Boot Fastboot list, double-click on it and click "Update driver" on the corresponding tab. In the wizard, proceed to manual installation of the drivers. Next, go through the items "Select a driver from the list of already installed drivers" → "Install from disk" → "Browse …" and select the file android_winusb.inf in the driver folder and then specify Android Bootloader Interface and finish the installation.

If the smartphone with this connection very quickly goes into the charging mode and the LED changes from blue to green, then you hardly have time to manually install the driver. In some cases, such a trick helps: disconnect the smartphone from the PC, select "Action" → "Install old device" in the device manager menu and select the manual driver installation in the opened wizard. Next, as described above, we get to the driver folder and forcibly install Android Bootloader Interface ( We connect the phone in fastboot mode, it will be defined as Android ADB Interface. And now we update the drivers for it, but remove the "Only compatible devices" checkbox and put Android Bootloader Interface (

Once again, we draw your attention to the fact that any operations with a smartphone are done at your own peril and risk! After unlocking the bootloader, you may lose warranty, lose DRM-keys, you will be prohibited from installing official OTA-updates, and you will also need to carefully select the next firmware. If you do not fear this fate, then we will continue. Open the command line (Win + R, cmd, Enter) and go to the folder where fastboot.exe is located. If you installed the Android SDK, this is C: Program Files Android android-sdk platform-tools .

 cd C:  Program Files  Android  android-sdk  platform-tools
Fastboot.exe -i 0x0fce getvar version

If you received something in the spirit in response version: 0.5 then everything is in order. In the event of an error, verify that the driver is installed correctly in Device Manager, or try disconnecting and reconnecting the machine in fastboot mode. Then try this command again. The last stage remains, after which there will be no turning back, and there is still time to abandon all this venture. If there is nothing to lose, then execute the following command, where KEY is the unlock code that was previously obtained on the Sony website.

 fastboot.exe -i 0x0fce oem unlock 0xKEY

The phone is not disconnected yet. The firmware is installed using the QuikIMG utility. In the images subdirectory you need to copy the img image of the system from the archive with the prerooted firmware and nothing more. Do not confuse – not the zip-archive, namely the img file (for example, system.img)! We launch QuikIMG, in the list on the left we select the extracted img-file, on the right we mark system and we press button Flash. After a couple of minutes, the phone will be sewn and it can be disconnected from the PC, rebooted and the basic system setup. We check that we have actually installed version 2.3.7 and enable the debugging mode in the application settings.

The first step is to download the archive with the prepared image of Ubuntu (there are other distributions). For Xperia S is suitable Ubuntu Small (with LXDE) or Full (with Unity). On the SD card or in the internal storage, you need to create an ubuntu folder and copy the img and md5 files from the downloaded archive into it. In the meantime, all this stuff is downloaded, it's better to start installing the minimum required software in the phone – the Complete Linux Installer itself, the BusyBox system utilities (not all models are needed), the Android Terminal Emulator, the VNC client, like android-vnc-viewer, and if desired -another SSH-client. In the application itself, you can find instructions for launching various distributions, a small FAQ and other useful information.

To start Ubuntu, go to the Launch section, select our distribution from the list and click Start. The terminal window opens. At the first start, the system image passes the integrity check, so you'll have to wait a few minutes for it to complete. Then you need to enter the user's password twice, agree to start the VNC server (y) and, if you want, the SSH server. It remains to specify the screen resolution and save the specified settings as default if desired. Now you can connect using the VNC client to the running OS locally or via Wi-Fi from another machine. Port 5900, localhost address or IP-address of the smartphone, login and password are the same – ubuntu. In the color settings, it's better to set 24bpp.

Ubuntu with LXDE and Unity shells

The result is a completely working desktop OS, launched on a smartphone. Of course, one should take into account some instability, not a very large choice of software for the ARM-platform and not so fast work, as on an ordinary modern PC. However, for experiments this is enough. Working directly on the phone is not very convenient – it's easier to connect a Bluetooth keyboard and mouse, and display the image on a monitor or TV. Other ways to improve work in the new environment and solve some problems can be found in the project wiki.

Remote connection to smartphone via TightVNC

To exit Ubuntu, it's enough to execute the command exit in the terminal emulator. As you can see, everything is quite simple. Most of the time, it took a fuss with the firmware to get root-rights. On other devices, everything can be either simpler or more difficult. In this regard, once again we call for care and accuracy when working with firmware, so as not to turn a high-tech toy into a "brick."

Well, it seems, they told us about all the important details. Therefore, you can say goodbye and finally wish you successful research on the field of smartphone ubuntovodstva!

If you notice an error – select it with the mouse and press CTRL + ENTER.

Leave a Reply

Your email address will not be published. Required fields are marked *