Chapter 3. Inside Android

Android is Linux, but something as a standard Linux does not exist. Linux means Linus Torvalds and he did "just" the kernel and Android used a special patched kernel. There is hope that the patched kernel will disappear, since it features might be integrated in the mainstream Linux kernel around versions 3.4. To have a working system the Linux kernel needs some more packages and setup. Android went it's own ways that is very different from a regular Linux desktop setup (boot process, X server), but taking over a lot of the standard features to protect the device against all unwanted things that could be happen. One fundamental thing is the root permissions (Administrator). Every file, program or process belongs to a user and can be restricted. Android devices make use of that. In a console type id to see who you are and to what groups you belong. You probably will not be root and therefore a lot of system commands and modifications are not allowed to do. This is OK like that and prevents you from damaging your Androids software setup.

There are ways to root the device so you are able to work as root, but this is just for experienced professionals and people that know how to recover the physical device. If you still want to do it, I recommend to install Android on a PC as in virtual box where you can make snapshots and go back to the installation as it was before the screw up.

There are Linux console apps that allow you to observe Linux:

Figure 3.1. Terminal


The boot loader is not considered a part of Android, it basically loads the kernel and its file system. Therefore regular boot loaders can be used (U-boot, grub). Boot loaders can be interrupted by a special key press sequence to do the interaction.

As any other Linux system the kernel is loaded and starts the program /init (this might not always true since the program started can be passed via boot loader)./init.rc and /init.<platform>.rc

The C++ programmed system process /system/bin/app_process zygote is started by /init and is the key, to run other processes.

Regular applications are written in java, however using special byte code requiring the register based Dalvik virtual machine instead of the stacked based standard java virtual machine. Due to this small difference standard java byte code can be converted to Dalvik byte code. This allows to use any standard Java environment for development. When finished the Dalvik compiler dx can convert java byte code in dex-code (Dalvik Executable).

Linurs Servernest startpage