• After 15+ years, we've made a big change: Android Forums is now Early Bird Club. Learn more here.

[International / GSM] [HOW TO] Root the GSM/HSPA+ Samsung Galaxy Nexus

Upvote 0
That's a pretty amazing question. Its pretty much answered by the suggestion, always Make an nandroid backup just in-case.

?correctly configured to be insecure? What is that?

So far there have been no reports here of bad files being put out there. And believe me if there were we would see lots of traffic her about it.

Other than covering ones backside with a nandroid, you can compare the MD5 to make sure it did not get corrupted in transit. Google up a free MD5 checker called WinMD5. Most of us use a utility like that.

Tell us what it is your in fear of getting?
 
Upvote 0
To follow up on boot.img...

First off, thanks for the link to the Build guide - very informative!

My main concern is how do I know if the boot.img that comes with a given zip package is correct? (ie. correctly configured to be insecure and other settings being untouched)

Yes, +1 to gapi's answer about checking the MD5 checksum on any file you download.

If you really want to know if the boot.img file is configured correctly, you could unpack it and examine the contents of the default.prop file to verify the value of the ro.secure setting.

Doing that would be cool, but would probably require you to obtain knowledge that would obviate your question in the first place ;) :).

At some point, you've got to trust the source and publishers of various files that are out there. The files in the "slightly easier" method have been used by lots of folks (myself included) without issue.

Cheers!
 
Upvote 0
Based on my understanding, the boot.img used for rooting is essentially the original boot.img from the device that is modified by setting ro.secure=0 in the ramdisk.

My theory on how this is done:
(1) The original boot.img from the device is un-packed
(2) ro.secure=0 is set in the default.prop file within the ramdisk filesystem
(3) The boot image is re-packed as a new boot.img (this is the "unsecured" image used for rooting)

It seems that I could ALMOST make the unsecured boot.img myself (with reference to this post on modifying boot images).

The one problem is how/where do I obtain the original boot.img? Does scary_alien's link on initializing the Android build environment ultimately give me the boot.img I need? (I'm unclear if it does after reading through it)
 
Upvote 0
Based on my understanding, the boot.img used for rooting is essentially the original boot.img from the device that is modified by setting ro.secure=0 in the ramdisk.

My theory on how this is done:
(1) The original boot.img from the device is un-packed
(2) ro.secure=0 is set in the default.prop file within the ramdisk filesystem
(3) The boot image is re-packed as a new boot.img (this is "unsecured" image used for rooting)

It seems that I could ALMOST make the unsecured boot.img myself (with reference to this post on modifying boot images).

The one problem is how/where do I obtain the original boot.img? Does scary_alien's link on initializing the Android build environment ultimately give me the boot.img I need? (I'm unclear if it does after reading through it)

Yep, you certainly are on the right path! :) (very nicely done!)

From what I understand, Paul O'Brien from MoDaCo actually built the first insecured boot image from source to create the insecure boot image packaged with his Superboot package.

The boot.img file is contained in the factory images. Look here for information about where to obtain and the makeup of these files:

How to un-root (return to stock)

The boot.img (and recovery.img, etc.) are contained in the file with the name format of image-<model>-icl53f.zip. Note: as you've read in the "How to unpack" thread (which I'm very familiar with), the boot.img and recovery.img files have identical formats and makeup--for good reason: they are both bootable image files.

In fact, when you are rooting with these methods (that are not the ClockworkMod method), you are not flashing (writing) the boot.img files, but simply soft-booting them into memory so that you can insert the root binaries.

I also would have pointed to you towards a very informative page "http://www.mydroidworld.com/index.php?galaxy-nexus-mods/10446-how-create-insecure-boot-image.html", but it looks like that particular page has been pulled (search Google for the cached version of that; if you need or want the insecureboot.zip&#8206; that it references, PM me your email and I'll send it to you (its just a script, but is instructive nonetheless)).

Cheers!
 
  • Like
Reactions: thehybridkiwi
Upvote 0
At some point, you've got to trust the source and publishers of various files that are out there. The files in the "slightly easier" method have been used by lots of folks (myself included) without issue.

I personally have confidence in the files myself because, as you've mentioned, many people have used them. I was mainly interested in finding out how they came to be. Needless to say, I am quite impressed at how these folks are able to figure out how to programmatically root the device without official Google guidance.

And thanks for the pointer to the original boot.img files :)
 
  • Like
Reactions: gapi
Upvote 0
I personally have confidence in the files myself because, as you've mentioned, many people have used them. I was mainly interested in finding out how they came to be. Needless to say, I am quite impressed at how these folks are able to figure out how to programmatically root the device without official Google guidance.

And thanks for the pointer to the original boot.img files :)

LOL, no problem...

I just couldn't tell where you were going with your questions, etc. (i.e., that you were interested in possibly unpacking and/or building the boot.img file yourself).

I'm impressed that you did the research you did and happy to run into folks that want to know how all the little details about how things really work, too.

Regarding the factory images: if my device (never been rooted) is currently running 4.0.1... once I go through the whole root/unroot process, can I use the 4.0.2 image when I unroot? Or should I stick with 4.0.1 when I unroot?

Well, unrooting is basically restoring / re-flashing the stock factory images, so you can choose whichever version you like. I've flashed both, but very soon after I rebooted from restoring the 4.0.1 image, the 4.0.2 OTA comes in (at least for me ;)).

Cheers and please let me know if you have any other questions.
 
Upvote 0
I was thinking of compiling/building superuser.apk and su from source.

For superuser.apk, is it sufficient to build source in Debug mode and use that apk for rooting? It seems like that would work since the whole root process is done in USB debug mode. However, superuser.apk is used full-time after the root process to manage access to su... so does that mean I would need to build a release and signed superuser.apk instead?

For su, I actually have no clue how to generate the su file from source... ?
 
Upvote 0
I was thinking of compiling/building superuser.apk and su from source.

For superuser.apk, is it sufficient to build source in Debug mode and use that apk for rooting? It seems like that would work since the whole root process is done in USB debug mode. However, superuser.apk is used full-time after the root process to manage access to su... so does that mean I would need to build a release and signed superuser.apk instead?

For su, I actually have no clue how to generate the su file from source... ?

You've got a whole lot of "fun" (learning ;) :)) ahead of you, thehybridkiwi...here's where I would start:

[APP] Superuser 2.3.6.1 - Now on the Market [2010-09-05] - xda-developers

Its got ChainsDD's github (https://github.com/ChainsDD) linked at the bottom of that first post.

Also, here's his web site: Superuser

Cheers and let us know what you have in mind and/or come up with--I'm interested to hear.
 
Upvote 0
Hey scary alien, this guide is awesome!!!
I used the "clockwork method",
although i have encountered a problem. Everything went smooth with the rooting and fastboot unlocking but i still can't manage root anything.

I have tried several apps without success. I have mounted the /system in r/w using ES file explorer, and i cant seem to find the /system/recovery-from-boot.p file. I have searched for it everywhere and tried using the consol.
I even tried rerooting and reinstalling SU. No luck :(
Any help would be appriciated
 
Upvote 0
Hey scary alien, this guide is awesome!!!
I used the "clockwork method",
although i have encountered a problem. Everything went smooth with the rooting and fastboot unlocking but i still can't manage root anything.

I have tried several apps without success. I have mounted the /system in r/w using ES file explorer, and i cant seem to find the /system/recovery-from-boot.p file. I have searched for it everywhere and tried using the consol.
I even tried rerooting and reinstalling SU. No luck :(
Any help would be appriciated

floptry, welcome to the AndroidForums!

Well, I noticed that when I did a restore of the stock/factory images (I have the VZW GNex), there was no /system/recovery-from-boot.p file--it only got / gets installed with the 4.0.2 OTA (at least from VZW anyways). This file is only used and relevant when you shut down to cause Android to re-flash the stock recovery (i.e., you typically rename it to stop that from happening so that you don't lose your ClockworkMod custom recovery).

I'm guessing you probably did not do this (restore the factory/stock images) on you GNex, right? (but since I don't have the GSM version, I can't see if this file is normally present on your phone model).

If you've successfully remounted /system in read/write mode, then you are indeed rooted (you should have been asked for root permission for ES File explorer via the Superuser dialog, right?).

Is that lack of the recovery-from-boot.p file your only concern about not being rooted?

Let us know.

Cheers!
 
  • Like
Reactions: floptry
Upvote 0
Thank you for the fast reply :)

I do have a Gnex with GSM.
My main concern is that patchers i.e. lucky patcher says i dont have root access even though they are granted permisson with SU. I only believe that not finding the recovery-from-boot.p file might be the problem.

I do not think i did restore the "factory/stock images", which step is that? I can't recall missing any steps, How do I do this?

I have reeboted the phone a few times, entering recovery mode and entering mounts and storage. Here i can see that i am able to mount /system.

Mounting "/system", restarting and entering the same recovery mode, under mounts and storage i see that i can mount it again (even though I mounted it in ES it is not mounted in recovery mode). I guess it is not permanently mounted?

There is one thing i didn't mention that might be relevant: I reeboted the phone between step G and H (clockworkmod method)
 
Upvote 0
Thank you for the fast reply :)

I do have a Gnex with GSM.
My main concern is that patchers i.e. lucky patcher says i dont have root access even though they are granted permisson with SU. I only believe that not finding the recovery-from-boot.p file might be the problem.

I do not think i did restore the "factory/stock images", which step is that? I can't recall missing any steps, How do I do this?

I have reeboted the phone a few times, entering recovery mode and entering mounts and storage. Here i can see that i am able to mount /system.

Mounting "/system", restarting and entering the same recovery mode, under mounts and storage i see that i can mount it again (even though I mounted it in ES it is not mounted in recovery mode). I guess it is not permanently mounted?

There is one thing i didn't mention that might be relevant: I reeboted the phone between step G and H (clockworkmod method)

I don't know what "lucky patcher" is...is that an app?

The recovery-from-boot.p file is only relevant for when Android decides to flash back your stock recovery and is not related to whether or not you have root.

Don't worry about the factory / stock image thing...you'd know if you did it ;) :).

Mounting operations in custom recovery (i.e., ClockworkMod) do not affect or stay when you reboot Android. Also, mounting /system in read-write mode in ES File Explorer isn't permanent either--i.e., it will go back to read-only mode after you reboot (which is good because you don't normally want /system mounted in read-write mode--too dangerous).

For checking / verifying root access, try downloading and installing Root Checker Basic

Rebooting between steps G and H for the ClockworkMod Method shouldn't matter if you were able to re-enter ClockworkMod to resume the instructions at step H and complete everything.

Also, if you have the Superuser app in your app drawer (icon is little green Android with an eyepatch), then you should be rooted.

Cheers!
 
Upvote 0
Hey new user here. Trying to flash clockwork to my Galaxy Nexus but it doesn't seem to be sticking. I ended up rooting with clockwork in the phone's memory but it won't 'stick' when I try to flash it. I just end up with the little android man and the red thing coming out of his chest lol.

Welcome to the AndroidForums, Jesse! :)

Check out this post:

How to install ClockworkMod custom recovery

re. the section labeled Flashed custom recovery won't "stick"?.

That should fix you up :).

Cheers!
 
Upvote 0
I don't know what "lucky patcher" is...is that an app?

The recovery-from-boot.p file is only relevant for when Android decides to flash back your stock recovery and is not related to whether or not you have root.

Don't worry about the factory / stock image thing...you'd know if you did it ;) :).

Mounting operations in custom recovery (i.e., ClockworkMod) do not affect or stay when you reboot Android. Also, mounting /system in read-write mode in ES File Explorer isn't permanent either--i.e., it will go back to read-only mode after you reboot (which is good because you don't normally want /system mounted in read-write mode--too dangerous).

For checking / verifying root access, try downloading and installing Root Checker Basic

Rebooting between steps G and H for the ClockworkMod Method shouldn't matter if you were able to re-enter ClockworkMod to resume the instructions at step H and complete everything.

Also, if you have the Superuser app in your app drawer (icon is little green Android with an eyepatch), then you should be rooted.

Cheers!

Hello scary alien, sorry for the delayed reply.

Lucky patcher is a various app patcher that i found on TPB, whatever app i try to patch it says: "No root access found... make sure you have updated su or busy box" even though i grant the app SU.
There is a seperate patcher for power amp (a music app) and when i run it i get the same message.
I tried "root checker" and it says that I have root access.

Chrees!
 
Upvote 0
An over the air (OTA) update will unroot you. This is new ground for us because no OTA has came out yet but I think there will be many posts on what to do when that happens.
The way my phone is rooted I don't think I woill see an OTA prompt, maybe no rooted device will I dunno.
Those that know say the developers will have the upgrade available to us before the OTA or soon after.
So fret not, and read and wait..........
 
Upvote 0
Us VZW folks have had an OTA before: 4.0.2--its just that most folks saw and got it and installed it very quickly after receiving their device.

I did extensive testing about how rooting affects the OTA and custom recovery, etc.:

http://androidforums.com/galaxy-nexus-all-things-root/469782-ota-updates-vs-clockworkmod-root.html

Its no big deal, really, since you can easily re-root after an OTA comes in.

If you have a custom ROM installed, you'll never even know about the OTA from your phone's standpoint.

Hope that helps :).

Cheers!
 
  • Like
Reactions: gapi
Upvote 0

BEST TECH IN 2023

We've been tracking upcoming products and ranking the best tech since 2007. Thanks for trusting our opinion: we get rewarded through affiliate links that earn us a commission and we invite you to learn more about us.

Smartphones