3

I read a lot about rooting android, that it is risky, that I can mess all and get my device completely dead and nothing can be done about it. So my question -- why all these phones can't be just mounted? If I mess up my system with root, I always can boot with live-cd or write disk image directly to /dev/sda. After all, I can just mount broken system and repair it.

Why android to not support it? Is it some real technical restriction, related to flash memory or something, that differs between phone and PC/Notebook?

3
  • Yes, why I can't mount android like my external hard drive.
    – KAction
    Commented Aug 24, 2012 at 12:26
  • My first thought is that it might have to do with the filesystem on Android phones. Are you sure it's supported by your kernel? I don't think they use ext3 or any other vanilla format.
    – pzkpfw
    Commented Aug 24, 2012 at 12:35
  • Reverting that downvote (wasn't mine) -- as it is an interesting question. As would be "Why isn't root available by default on Android devices?" -- which is what it all comes back to. Since if it were, you could mount etc. all you like.
    – Izzy
    Commented Aug 24, 2012 at 14:03

4 Answers 4

8

The only reason you need to root phones in the first place is that the manufacturer has tried to prevent software choice on the phone platform. The PC design is pretty unique in that it has had a choice of software platform for so long that it's an ingrained feature, although with Secure Boot on Windows 8 devices this is likely on the way out.

5

You can't mount them because there has to be some software to communicate between the phone and your computer. With the Phone the full software stack needs to be involved as it needs to take into account what happens when you mount the device when it's running. Also there are often multiple partitions on the phones, a raw mount would show up all the raw system files in the computer's File Manager which would be bad and things like Windows would probably try and format the Linux partitions as it can't understand them. On newer devices you can't even do a normal USB Storage mount but you have to use MTP as they use internal storage which still needs to be accessible while mounted. Technically it would be possible for them to make some kind of failsafe raw mount mode when it's plugged in while powered off (or started with some button held down), but they haven't, they do provide other methods of recovery instead. Also the firmware generally needs to be installed somehow, there are scripts and so on that run to set up things. If you have totally bricked the phone then there isn't much you can do.

But having said that flashing modern Android phones isn't too risky and actually bricking it is hard.

Firstly there are actually several images that can be flashed:

  • Boot loader (HBOOT)
  • Radio firmware
  • Recovery Firmware
  • ROM Firmware

Older devices did have some issue when flashing Radio/Boot. Specifically if you flashed them in the incorrect order and had mismatched versions you could actually brick the phone. But I believe that is mostly a problem with first/second generation Android phones, I haven't seen it being an issue on newer phones (also you probably shouldn't flash a radio of a different region as you might lose special features, like the 'HD Voice' for Australians).

Now days, in order to actually brick your device you would have to be totally unable to enter HBOOT, Recovery and the main ROM. If you can enter any of those it should be possible to flash firmware from them (although in some cases they might have security enabled meaning you are limited to flash the official stock images, but you can generally break out of them and flash whatever you want). HBOOT allows for fastboot flashing. Recovery and the main ROM both have the flashing binary in them.

Finally if you did totally manage to brick it, you can look at using JTAG to reverse it. That probably does require soldering a cable onto the phones mobo though as well as a (cheap) cable. And some knowhow.

3

The root filesystem of a typical Android device can't be mounted because there's no way to interface to it in order to mount it.

The root filesytem is typically stored in flash chips soldered to the phone's board. When the phone boots, it runs a boot loader (also out of flash) that doesn't provide any option to run user-supplied software. The flash is software locked from modification, and the boot loader provides no "unlock" option.

The USB port is connected to the CPU, and there's no way to get the CPU to let you run code that mounts the root filesystem. Code loaded by the boot loader will only give you limited access that doesn't include raw read/write to the flash device.

Thus it is necessary to find some way to break this security chain in order to modify the root filesystem.

There are two reasons for this craziness. The primary reason is permit the sale of subsidized phones tied to a single carrier. The secondary reason is to make Android devices more reliable because a user can't, either intentionally or through inadvertent malware triggering, corrupt the device to the point where it can't recover.

2

I agree that this would be a great idea, but sadly wasn't implemented for security and carier locking's sake.

But do note that most phones have almost the same functionalty. Samsung download mode with odin does pretty much what you want it to do (flash an image directly to the flash device) and it is very hard to break download mode. It is very much like on the computer: if the BIOS is still working you can boot from a CD and restore an image, here the bootloader is a sort of bios and if it works you can flash an image. If you flashed a custom non compatible bios on your computer you could just as well "brick" a pc.

If you avoid touching the bootloader on an android device you won't brick it, and even then some devices have "usb jig"s that will force restore the bootloader back. Why people are so much more reckless on their phones than on their pc is beyond me.

I think the idea is good but there really is no need for this right now, beacuse in practice the restore options and real "hard brick" possibilities are almost identical to the PC world and noone is complaining about PCs. People just need to be more carefull.

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .