Related
So, i'm sure there's many posts about this, but I thought I'd drop in my 2 cents. Basically, the purpose of this post is to try and help completely new users get acquainted with the world of Android "ROMing". I know there's beginners tutorials and wiki's and such, and I'm very grateful for all the time put into them by their writers, but the fact remains that they're written by experts, and as such, their expertise shines through and can sometimes confuse new users such as my self.
Up front: I'm an AT&T customer who's using a Rogers branded HTC Magic purchased from ImportGSM. I'm using Rogers cause Rogers has the same 3G bands as AT&T. I am coming from a Sony-Ericsson dumbphone. I use Gmail for my primary email and applied for a Google Voice account a while ago (got the account before getting the phone). I'm a practicing computer engineer so if I lapse into jargon, I apologize.
READ THE ENTIRE POST BEFORE PERFORMING THESE ACTIONS
OK, so you got an android phone (if you're on this forum, its most likely an HTC Magic/Dream/Hero) and you want to install new ROMs onto it (for whatever reason, just to do it, to get more functionality, to remove the carrier 'branding', whatever). You've done your research. You've read through the wikis (http://wiki.xda-developers.com/index.php?pagename=HTC_Sapphire_Hacking) and you're still a little confused as to where to start, or you're worried you're gonna brick your phone.
First, relax, as long as you follow the instructions, there's little chance of bricking your phone.
Second, some vocab:
SPL: Secondary Program Loader. don't worry too much about this, you shouldn't have to mess with it. I like to think of it as your phones BIOS. There's an off chance that you'll have a "perfected" SPL (.0006 or .0010), which basically means that you have a phone that is hardened against hackers, but as long as you use the one touch root method described below, you won't even notice it. You won't be able to use the Adb/Fastboot/Android SDK method mentioned below, you'll just get a "no access" error when you try to terminal into your phone.
ROM: Catch all term for software to be loaded onto your android. Generally comes in two flavors, a Recovery ROM, and what I call an Operating System ROM. A Recovery ROM is what gives you root access. An Operating System ROM is the user experience (where Amon_Ra or Cyanogen or others mix and match features to make a better user experience). I know that Operating System ROM might be misleading, but its the closest computer analogy I could come up with.
Now, this process will completely refresh your phone, removing all of your contacts, apps, etc. So before you start, if you have stuff on your phone you want to save, best copy them somewhere off your phone now. There's free apps out there to do all of this.
Lets get started.
Now, the first thing you're gonna wanna do is get something called "root" access to your phone. This allows you to install those fancy homebrewed ROMs that people are talking about. To get root, you have to install a recovery ROM. Installing a recovery ROM is is roughly similar to flashing a new BIOS on your computer. Except in this case, its on your phone and it gives you unrestricted access to the phone (like the Root user in Linux). There's two ways of getting Root. The first way is to install the Android SDK onto your computer and image your android with one of the recovery ROMs via your computers command line. I won't get into details on this one because its not the method I chose, and instructions are all over the web on this one. NOTE that this method doesn't work with updated Rogers phones. They installed the 'Perfected' .0010 SPL effectively removing remote command line access thus making this method a non-starter. The other way is to use the "one click root" program, which is a program you install on your Android phone. To do this, go to the one click root website (http://www.ryebrye.com/blog/2009/08/16/android-rooting-in-1-click-in-progress/). Download the .apk file and drop it onto the SD card in the Android phone (you'll have to connect the phone to your computer via USB, and select "Mount SD card". then simply drag and drop the .apk onto the SD card in your computer's file browser). Then, on the android phone, open up your file browser (I suggest Astro or Linda, both free downloads from the market) and open the .apk using the default Android application launcher. It should be a dark screen with a text box and a few buttons. The textbox should have a URL in it pointing to a .img recovery image (This is the cyanogen one). You'll first want to make a backup of your current (factory) ROM by pressing the (i believe) botton button. It'll work for a few seconds. Then you're ready to flash the recovery ROM. You can either accept the default (the cyanogen, which works fine) or specify a different ROM (such as Amon_Ra's which has slightly more capabilities) by entering in a different path (URL or path to SD card if you have a recovery image stored on the SD card). Then hit the first button to begin the flash. Wait for it to finish. DO NOT DISTURB THE PHONE WHILE FLASHING.
Once its finished flashing, congrats, you've rooted your phone. Now power off the phone, and power it back on while while holding power and Home. Hold Power and Home the entire time till you see an 'old computer' style menu come up. Should have some options such as reboot, install update.zip, install other .zip, wipe data/factory reset, etc. you should be able to use the trackball to cycle through the selections. The botton should have something like <cyanogen/Amon_Ra> recovery vX.X.X. If you see this screen, then you've successfully rooted your phone. Congrats.
Now, before you do anything else, IMMEDIATELY perform a nandroid backup. This should be on of the options in the recovery ROM. What this is doing is creating a backup of your current phone configuration so if anything goes wrong with installing the hacked ROM, you can revert to the state the phone is in now.
Next, perform a data wipe. There should be a selection for "wipe data/factory reset" or something similar. Select that. Wait for it to finish wiping your data from the SD card.
Now to install other hacked ROMs, just download whatever ROM you want to install from the xda site. Check the bottom of this page for a listing of the main ones (http://wiki.xda-developers.com/index.php?pagename=HTC_Sapphire_Hacking). It should download as a .zip. Copy the .zip file (DON'T UNZIP IT) onto the root of the SD Card (you can do this while in recovery mode by mounting the SD card or by physically removing the SD card from the phone and putting it into a card reader on your computer and copying the files). Once you have the ROM .zip on the SD card, with the SD card in the phone, select "install other .zip" or something similar and select the .zip file of the ROM you want to run. Should be some combination of the creators name (Amon_Ra or CM (for CyanogenMod)), what board the .zip is for (32A, 32B), what version the ROM is (4.1.1 or something). Then select "home" to confirm that you want to do this and wait for the periods to stop appearing. Once it stops, you should be able to select "reboot".
After it reboots (you should see different splash screens than when it was factory configured, except for the very first screen which on mine is "Rogers". Mine goes from Rogers to "Android" spelled out in blue text) you should have a fully functioning phone running a hacked ROM.
If it doesn't boot fully (which mine did a few times), try a different ROM or try wiping your data again. If all else fails, go into your recovery ROM (power and Home) and restore the Nandroid recovery image you made earlier.
Once it boots, it should have a tutorial on how to use Android.
When you get to the google login, I would suggest setting up your APN settings prior to doing that. At the google login screen, hit the menu button and select "APN Settings". Select add new APN (either an on screen choice or brought up by the menu button) and add in the APN details for your provider. You can find these easily by googling "<your provider> APN settings". Log into Google and you should up and running.
I just kinda threw this semi-tutorail together, so it may be a little confusing, but I tried to explain everything as best as I could. I know that i found all of the different ways to get root and the different ROMs and such to be very confusing. Just throwing out how I went about doing it.
Disclaimer: one click root works by exploiting a vulnerability in Android, which was closed by Google on Aug 11 or so. Therefore, if you have a factory Android build from that was released after Aug 11, one click root may not work for you, and you'll have to go the SDK route. I updated my Rogers phone in mid oct 2009, and my build was still prior to Aug 11, so don't just assume cause its after Aug 11 that it won't work on your phone.
thanks alot for the tutorial! you're a saint, i've been looking all over for something exactly like this!
i will test this out and let you know!
Edit:
I was successful! Huzzah! Thanks for the guide again!
What rom did you load onto your phone?
Also,
Could you give a brief tutorial on what exactly changing the radio and spl are?
Hello,
I have a rooted my G1 with ADP 1.5 and this worked well for weeks
But then I tried to install apps2sd, with entirely bricked my phone (stops with the blinking android label)
I still have access via fastboot and system recovery utility, so reflashing should not be the problem.
But since I have disabled syncronising with google and, as always when you brick something, made no backup, I need access to the calendar and contacts.
Does anyone know how to get them back anyhow (some wired plain xml would be fine)
Or does flashing not affect the personal data? (I do not dare to test)
Maybe someone can help me??
Thanks in advance
Bricked = dead. Won't turn on. No recovery. No SPL. No fastboot.
You've soft bricked, which as you said you can recover from.
Anyway, you could try pulling the entire contents of /data and having a poke around in there, as it will still be intact.
Well, since I am not an native english speaking person, I did not know that there is an difference between bricked and softbricked
But anyway, how can I still access /data ? (I find tons of manuals for reflashing, but none of accessing a softbricked phone )
Actually you should be able to flash a ROM and get your phone back to normal without removing anything from /data. Try a donut/cupcake ROM, that should fix your problem.
contacts and calendar should be able to be seen from any computer.
odomandr said:
contacts and calendar should be able to be seen from any computer.
Click to expand...
Click to collapse
Umm.....What?!
via gmail contacts. they automatically backup i think
Log on to your Google account via a PC and the Interweb thingie and in your email section should be your contacts. Calender has its own seperate section. Dont know if this is what you are after, Hope it helps.
Well I have disabled syncronisation with google, because many friends of me dont want to have their adresses and numbers stored at googles servers and I respect that. (Well I should think about another sync method)
So I tried to flash the rom with the cracked one I used before, which didn't work, and then tried the original ADP Rom from HTC. This still is not booting, but now I have acces via adb, with I had not before.
My Problem now is, that I can access /data only with root rights, so I can not use adb pull, nor ddms (and adb file explorer can not even connect, but I am still searching if I have done anything wrong there)
Any idea how to use any file explorer with root rights ( Don't care if for Linux or Windows)
Best regards,
anymad
have u tested this.
do a nandroid backup,
flahs a new rom.
after the new rom runs, turn your phone into fastboot mode and flash the data.img out of your nandroid backup
fastboot flash data data.img
if the calender and contacts data are storen in data.img you should get it back
anymad said:
Well I have disabled syncronisation with google, because many friends of me dont want to have their adresses and numbers stored at googles servers and I respect that. (Well I should think about another sync method)
Click to expand...
Click to collapse
Your friends are dumb and your data is secure on Google's servers. Turn sync back on and never have issues like this with things that should never be issues.
Yeah, thank you very much kingchris, based on your idea I got it.
For all who search this, here is what I have done:
1. install the recovery image from cyanogen mod (http://www.cyanogenmod.com/downloads/recovery-image)
2. make an backup
3. wipe everything
4. flash with another image (I took this one : http://www.android-hilfe.de/root-ha...g1/8791-cyanogenmod-full-updates-4-2-6-a.html) but I think it does not matter which one you take
5. restored the nandroid backup to get the data back on (thought I could just select data, but it seems to do full always)
6. reflash again with new image (without wiping before !!)
(I think you could save time when at step 5 you do what kingchris said and make a "fastboot flash data data.img" with the backup from nandroid)
This is what worked for me, but of course I give no warranty at all!
Hello !
I am feeling really down today after been trying to get my phone working again.
There is a huge problem currently, I am really annoyed that it doesn't work at all.
First thing, my phone won't start after update it just boot loops and never seem to end it.
First thing I noticed /boot, /cache /system and most things are gone, I can load up recovery but nothing more. I have no idea what happened but the whole image folder was wiped and I had to myself put in the CWM recovery.
I can't do an upgrade "again" as it will be stuck @ the unpacking part without starting it at all.
I been trying with 2.3 V2 and with B133(My stock rom I got).
If anyone has a solution that can solve this problem please help out if you could. Also if you are about to tell me get this and that, please most cases I haven't seen any of the Firmware roms in @modaco wiki links work. Means I can't download them, so if you happen to have spare copy please upload it and link it to me. I have been googling and looking through this section twice, nothing really worked out.
Thanks in advance !
If you didn't erase the .cust_backup partition which contain the image folder with all system' s .img files, then maybe it' s damaged. I had some problems with this partition before and when I checked it with windows check disk it repairs it and I had no problems from then. So, try this, and if you still haven' t any file on image folder, you can find the original folder on X5' s forums. Is definately here, but I don't remember where is the link and I don't gonna search it for you. If you cannot find it, you can allways reflash the original rom. If you fix the partition(if this is the problem), I don't think that you'll have problems with update any more.
dancer_69 said:
If you didn't erase the .cust_backup partition which contain the image folder with all system' s .img files, then maybe it' s damaged. I had some problems with this partition before and when I checked it with windows check disk it repairs it and I had no problems from then. So, try this, and if you still haven' t any file on image folder, you can find the original folder on X5' s forums. Is definately here, but I don't remember where is the link and I don't gonna search it for you. If you cannot find it, you can allways reflash the original rom. If you fix the partition(if this is the problem), I don't think that you'll have problems with update any more.
Click to expand...
Click to collapse
Hello, thanks for the reply.
I have no idea about this .cust_backup partition and how I am supposedly to access it via windows. Also the thing you said about fixing partition within Windows, the check disk thing. I am not sure about that part either as I can load CWM and it can read the partitions but they are empty. Also there is nothing in this forums that contains original things, only way for me to fix this if someone have extra copy and can guide me on how and where to place the all needed files. I am pretty sure it's only things that are missing and I can't get a grip out of this.
So to sum up what my problem is.
I did an upgrade from 2.2 to 2.3 with official firmware, it worked out normally but after a reboot my phone became stuck in an endless loop, I can't do anything and it will not I repeat it will not allow me to "re flash" any firmware I tried so far, the 2.3 V2 and B133.
I am begging someone in this forum section, please if you have the knowledge about this problem care to help?
I can't get a refund out the phone warrenty is off and I do not have that much spare money.
Thanks in advance !
If you can get to recovery, wipe cache and data. It should be possible in stock recovery.
The cust partition has all the images for bootloader, recovery etc. You can get to it with the pink screen. Reformatting and then reinserting the images and files could help, but try that when nothing else works.
I can't give you good help via phone, but try wiping data first. Also, try if you can use some other sd card.
Sent from my U8800 using Tapatalk
Blefish said:
If you can get to recovery, wipe cache and data. It should be possible in stock recovery.
The cust partition has all the images for bootloader, recovery etc. You can get to it with the pink screen. Reformatting and then reinserting the images and files could help, but try that when nothing else works.
I can't give you good help via phone, but try wiping data first. Also, try if you can use some other sd card.
Sent from my U8800 using Tapatalk
Click to expand...
Click to collapse
The most common things I have already done, but do enlighten me what this "custom" parition is. Because in windows I do not see such partition I see a removable partition which I have now added a folder called image with these containing files.
http://forum.xda-developers.com/showthread.php?t=1370960
EDIT ** Also regarding to first person who said about Windows partition manager. The thing is I see a lot of partitions and there is no labeling for them, might be because they are ext2/3 or even something else? In anycase I can't do so much I just find it really odd I have many duplicates and I am guessing that must be errors... Because I am seeing the main recovery partition which has no label too... its at 240 MB where 135MB is used. Lastly there is my internal SD card empty and healthy still I can't reach it within Windows if I do not mount it...And can't now without going into the android OS. I Have loads of free space "partitions I don't understand why they are there".
**
Thanks for helping out, it feels not good to have a half dead phone, it's still not solved :'-(
The .cust_backup is the mount point on android for this removable partition with image folder. In windows haven' t this name. I didn't mean to use the windows partition manager, just to use windows explorer, right click on the partition and choose properties, then tools and then check disk. Of course you can use partition manager too, but because as you found there are all no labeled other partitions there and is a bit confused.
As you mentioned, you found the original image folder and you replaced the files. Did you tried to do the update again after that?
Also you can see and the internal sd partiton, but you need linux system. This partition is not fat32, so windows cannot see it.
dancer_69 said:
The .cust_backup is the mount point on android for this removable partition with image folder. In windows haven' t this name. I didn't mean to use the windows partition manager, just to use windows explorer, right click on the partition and choose properties, then tools and then check disk. Of course you can use partition manager too, but because as you found there are all no labeled other partitions there and is a bit confused.
As you mentioned, you found the original image folder and you replaced the files. Did you tried to do the update again after that?
Also you can see and the internal sd partiton, but you need linux system. This partition is not fat32, so windows cannot see it.
Click to expand...
Click to collapse
I have placed all things that I got from here.
http://forum.xda-developers.com/showthread.php?t=1370960
And I can't run the upgrade firmware, it gets stuck at first stage which is to unpack the the update.app thing.
It just stays like that not blinking and frozen.
Did you tried now that you have the original files, to go to recovery mode and wipe data etc?
Also when you try to do the upgrade do you have the device connected with the cable?
I had this problem once and I think that when I disconnected the cable(or maybe wasn' t connected and I connected it, I don't remember well), the proccess bar starts to moving after a while and the upgrade completed successfully.
dancer_69 said:
Did you tried now that you have the original files, to go to recovery mode and wipe data etc?
Also when you try to do the upgrade do you have the device connected with the cable?
I had this problem once and I think that when I disconnected the cable(or maybe wasn' t connected and I connected it, I don't remember well), the proccess bar starts to moving after a while and the upgrade completed successfully.
Click to expand...
Click to collapse
You are not understanding me :-(, I have wiped already millions of times in millions of different ways just to get it work. And no, I don't have the device connrected when I upgrade, it won't work properly then, I have tried to wait for the progress bar to "start" move it won't happen the battery will die, and nothing happened.
I can't go in with normal Recovery mode, can only go in with CWM, the normal recovery mode is really small, I mean only 3mb, while the froyo version is 5mb. Now I am asking if you have the time to upload the image files from 2.3 V2, the ones in forums are for V1. Which I don't know might conflict.
Thanks again for trying to help me out, this is really frustrating to get it to work.
**EDIT**
I worked it out !
I think I understood what you meant, I did as you told I started first with pluggin in the charger forced it to upgrade and now it's upgrading, thank you so much dancer_69. I was going to go tomorrow to buy a new 2nd hand smartphone. But now I can save my money for other things !
**EDIT of EDIT **
I seem to have downgraded to B133, I will try now with B158 2.3 V2 again and hopefully it will work now.
Yes, wasn't clear because I don' t remember what I've done and solve it. But I think that I did it like you discribed too.
Anyway I'm glad that was helpful(kind of)..
And don' t give up so soon with smartphone' s bricks, I've faced brick kind of problems many times and if the device it' s not completely dead, there is something you can do. Maybe need more search or many tries(sometimes the same things) but at the end(and of course If there isn't a hardware problem) device can unbrick.
Un-Bricking by Unlocking & Flashing CWM+CM7 (was: Accidentally deleted MediaProvider)
Hi!
When removing Bloatware with Titanium Backup a while ago, I accidentally missed a click (never used a touch screen...) and uninstalled MediaProvider, which I have not been able to recover since.
I tried putting the files back from a friend's HTC, which didn't work; after that I was told even the packages differ between manufacturers, so I tried getting them from a stock Bell Atrix .zip posted on these very forums, which didn't help either. Neither #android-root nor AndroidForums were able to help, thus I ask here: Can anyone tell me how to either make my system accept Bell's files, or where I can find a "vanilla" Motorola build?
(Problem is, the phone didn't come from a phone company, a friend of mine got it pre-release from his uncle who is with Motorola, so it may even be different from what hit the market later on...)
I guess the following information will help, it's a Titanium Backup info file for another componend I backupped shortly after:
#Titanium Backup
#Sat Feb 25 03:28:43 MEZ 2012
app_gui_icon=[...]
sys_ro.build.date.utc=1302536066
app_version_code=8
sys_ro.product.model=MB860
has_prefsdata_jpu=0
sys_ro.serialno=<xxx>
sys_ro.build.description=olympus-user 2.2.2 OLYEM_U4_0.44.0 578673 ota-rel-keys,release-keys
has_prefsdata=0
app_gui_label=com.android.providers.applications 2.2.2
sys_ro.build.version.release=2.2.2
app_apk_md5=1989ff2476ee73ad445760b9bef5f44e
has_dbdata=0
app_apk_codec=GZIP
app_is_forward_locked=0
app_is_system=1
app_label=com.android.providers.applications
app_version_name=2.2.2
generation=1
app_apk_location=internal
(Most of this is unnecessary, I guess, but I can't really be sure what you might need to judge what I would have to to...)
I would be very grateful for any help, it is extremely limiting not to be able to use any media capabilities.
So, thanks in advance,
David
maybe flash a new rom if your contacts are all backed up?
Hm, well, that would really be the last resort :\ In addition to losing all my data, I fear the risk of bricking it completely. Can't really be that I'd have to flash it just because two files are missing...?
Edit: I neglected to say that the files in question are MediaProvider.apk and MediaProvider.odex. I do only need to copy these to /system/app, right?
Intelensprotient said:
Hm, well, that would really be the last resort :\ In addition to losing all my data, I fear the risk of bricking it completely. Can't really be that I'd have to flash it just because two files are missing...?
Edit: I neglected to say that the files in question are MediaProvider.apk and MediaProvider.odex. I do only need to copy these to /system/app, right?
Click to expand...
Click to collapse
Yes, but you have to set the permissions same the other files in .system/app folder.
I have attached the missing files to this post. My gingerbread version is 2.3.4.
Good Luck!
Huh. Setting right permissions for the files from Bell had no effect; installing yours soft bricks it in an interesting way: Even with Early USB Enumeration, all I see is
# adb devices
List of devices attached
???????????? no permissions
Even with root. The LED flashes red, and after a minute it reboots. I had expected things not to work out, resulting in the deletion of your files, but that I screwed up _that_ bad after it didn't even seem to notice the right (?) files when they were there is kinda surprising.
The standard workarounds (adb kill/start server, MODE=0666 to udev or being root) change nothing about this. Time for hard reset?
Intelensprotient said:
Huh. Setting right permissions for the files from Bell had no effect; installing yours soft bricks it in an interesting way: Even with Early USB Enumeration, all I see is
# adb devices
List of devices attached
???????????? no permissions
Even with root. The LED flashes red, and after a minute it reboots. I had expected things not to work out, resulting in the deletion of your files, but that I screwed up _that_ bad after it didn't even seem to notice the right (?) files when they were there is kinda surprising.
The standard workarounds (adb kill/start server, MODE=0666 to udev or being root) change nothing about this. Time for hard reset?
Click to expand...
Click to collapse
I would hard reset too at this stage. I'm sorry it didn't work out.
Now, that's interesting. Factory reset didn't change anything.
Sorry for reply to self, but I was less than clear, so - help?
My next step would be to try to unlock the bootloader, then flash CWM and see if anything can be fixed that way; then, I would try flashing CM7 (or, more specifically, the Neutrino GT ROM) by CWM; then, I would try flashing it without. Is that a safe progression of attempts? Or have I possibly broken anything that would hard-brick it by any of these methods? And can you recommend any finer increments what I could do before / between / after those mentioned? I still have the option to apply an update in Recovery - is it possible, for instance, to put a .zip onto my SD that has 0 Byte MediaProvider files in it?
(I have thought about installing Neutrino for a while, and this seems to be a good time to flash it, as my data is cleared now anyways. To my understanding, this should not be any more dangerous than just re-flashing the Froyo that was there before, right?)
As an additional fact, ADB now doesn't detect any devices any more, even with Early USB. This could be because USB Debug is not a factory standard setting, though, as I reset it to factory defaults.
Also, the startup Moto screen behaves differently: It doesn't go to the point where the logo disappears in a flash, the background light switches off before that. As far as I can tell, the display still shows the animation, though, but it is not lit. Furthermore, the reboot seems to happen immediately after the animation has ended, and not 1-2 minutes later, like it was before the reset.
I would be grateful if anyone could explain what happened. To my understanding, a factory reset should clear /system, and the error started when I put some non-compatible .apks there, so I thought this would fix things. Is it possible something broke on the hardware side, when (for instance) 2.2.2 called a function that has had its parameters changes in 2.3.4?
[If a moderator reads this - does this qualify as a general Android question? I have no experience with different devices, so I'd be glad if you could decide if this thread has to stay here or if it can go to a sub-forum with a wider audience - General Android Q&A, for instance.]
Bump...
Success Neutrino up and running!
[REF] ★★★Understanding the Android world before rooting your LG Nexus 4★★★
Understanding the Android world before rooting your LG Nexus 4
Here is a *noob friendly* collection of information every user that wants to root their phone should know. Many people blindly follow guides without even knowing what "Rooting" means. Hopefully, this will help new users (and old ones, why not?) understand what is happening with their phone, and what they will put up with.
This may seem as a lot to read, but there are no shortcuts. You either read and learn what you're dealing with, or find out the hard way.
Let's get started, shall we?
What does rooting mean?
To 'root' your phone means to gain administrative rights on the file system of your phone (in linux, root is the username of the master admin, kind of being an Administrator on Windows). With root access, you can install and uninstall anything you want on the phone.
Most phones come with limited access regarding what you can and can't do on it. This isn't necessarily a bad thing, because it can keep users from accidentally breaking something they shouldn't mess with on the phone, especially in regards to the operating system. However, many manufacturers limit your rights to things that aren't really so mission critical, too, and rooting the phone gets around this.
If you have a few unnecessary applications (bloatware) pre-installed on your phone that you cannot uninstall, rooting will give you this ability. It will also allow you to upgrade to newer versions of Android before your phone's manufacturer and/or cell provider make the updates available to you.
Click to expand...
Click to collapse
So now you know what rooting means. And I bet you are now thinking "Should I do it, or not?" Well, hope this helps you decide:
The advantages of rooting
-De-bloat your phone. Uninstall any unwanted system apps.
-More control over how the CPU acts. This can increase performance or battery life, depends on how you configure it.
-More control over power consumption. This implies undervolting your CPU, giving it less power, so it consumes less.
-More control over how apps start up. Prevent apps from starting up when they don't need to.
-Change your Baseband (Radio). Try different radio versions, with the purpose of reducing battery drain or improving your signal strength. This may also allow you to enable LTE, due to the fact that it's disabled on the latest radios.
-Flash custom ROMs. Bored of the stock ROM and look? Browse through the hundreds of custom ROMs provided by this community, each having different features and looks.
-Backups. The ability to completely backup your phone, and fully restoring it to the time of the backup. This is done with a Nandroid Backup (we'll talk about this later)
-Mods and Inovations. Use many mods, fixes, tweaks or features created by the community!
-Custom Kernels. As a Nexus device, the Nexus 4 has tons of kernels with different features, supporting better performance, or battery life! To see what a kernel is, keep reading.
-Run apps that need Root Permission. These apps can be very useful, like Titanium Backup, Root Explorer, Terminal Emulator and many others!
Click to expand...
Click to collapse
The disadvantages of rooting
-Rooting will void your warranty (Although reverting root is very easy)
-The process a bit dangerous. Something could (99.9% probably not, but still) go wrong, and end up bricking your phone. So, yes, the process is 0.1% risky. You can end up deleting everything on your phone. You'll have to handle this process gently and with care.
-You will be able to do a lot more mistakes. These may cause damage to your phone (But hey, that's why we have these kind of threads, eh?)
-No more over the air official updates. You'll have to update your phone manually, through your recovery. (Which isn't that hard)
Click to expand...
Click to collapse
Now that you fully know what rooting implies, let's continue exploring the Android world.
What about the internal memory? How does that work?
Now, as you might already know, each phone has an internal memory. In the Nexus 4's case, it's either 8GB or 16GB. This internal memory needs to hold a lot of things, not only your personal data. This is why you only have available to use 5.8 GB or 12.9 GB.
An Android's internal memory is partitioned into many chunks that have their separate purposes.
These are all the Nexus 4's partitions, and their names.
modem -> /dev/block/mmcblk0p1
sbl1 -> /dev/block/mmcblk0p2
sbl2 -> /dev/block/mmcblk0p3
sbl3 -> /dev/block/mmcblk0p4
tz -> /dev/block/mmcblk0p5
boot -> /dev/block/mmcblk0p6
recovery -> /dev/block/mmcblk0p7
m9kefs1 -> /dev/block/mmcblk0p8
m9kefs2 -> /dev/block/mmcblk0p9
m9kefs3 -> /dev/block/mmcblk0p10
rpm -> /dev/block/mmcblk0p11
aboot -> /dev/block/mmcblk0p12
sbl2b -> /dev/block/mmcblk0p13
sbl3b -> /dev/block/mmcblk0p14
abootb -> /dev/block/mmcblk0p15
rpmb -> /dev/block/mmcblk0p16
tzb -> /dev/block/mmcblk0p17
metadata -> /dev/block/mmcblk0p18
misc -> /dev/block/mmcblk0p19
persist -> /dev/block/mmcblk0p20
system -> /dev/block/mmcblk0p21
cache -> /dev/block/mmcblk0p22
userdata -> /dev/block/mmcblk0p23
DDR -> /dev/block/mmcblk0p24
grow -> /dev/block/mmcblk0p25
Yes, there are quite a lot. You, as a user, don't need to care about all of them. Here are the ones you will need to know about:
/system- size: about 0.5GB
This partition holds the Android OS itself. Kind of like the C:// disk on your every day Windows PC. This partition has many folders and files you cannot normally get to, due to safety reasons. For example, system/app is where all the system apps are installed.
If something gets deleted from this partition, Android will most probably won't work properly.
/data- size: either 5.8GB, or 12.9GB
This is where all your personal data is kept. This includes apps, sms, contacts, e-mails etc. It also stores your system settings, like wallpaper, and all those stuff you set up when you got your phone. The most important folders on this partition are data/app (where your apps are stored), data/data (where you app data is stored, like highscores and stuff), and data/media.
Data/media might be considered your sd-card. Yes, I know the Nexus 4 doesn't have an sd-card, but this folder works like one. When you connect your phone to your PC, this is the folder that pops up, with all your music, images, videos, and whatever else you keep on your phone.
Click to expand...
Click to collapse
Things are getting a bit more complicated, eh? Just bare with me. Next, I will be explaining the different terms you will be encountering throughout your Android experience.
Things you hear people talk about
Kernel
The kernel is an essential part of any Linux based operating system. It's the program that manages input and output requests of the operating system. Imagine you're at a restaurant. You give your order to a waiter. He takes it to the chef, the chef makes your food, then the waiter brings it back to you, and you enjoy it. In this case, you are the Android system, the waiter is the Kernel, and the chef is the hardware. The system gives the Kernel a request, like firing up another processor core when you play a heavy game, and the Kernel fulfills the request.
Here is an image for better understanding
{
"lightbox_close": "Close",
"lightbox_next": "Next",
"lightbox_previous": "Previous",
"lightbox_error": "The requested content cannot be loaded. Please try again later.",
"lightbox_start_slideshow": "Start slideshow",
"lightbox_stop_slideshow": "Stop slideshow",
"lightbox_full_screen": "Full screen",
"lightbox_thumbnails": "Thumbnails",
"lightbox_download": "Download",
"lightbox_share": "Share",
"lightbox_zoom": "Zoom",
"lightbox_new_window": "New window",
"lightbox_toggle_sidebar": "Toggle sidebar"
}
Recovery
This is a secondary, mini operating system that has access to your internal memory. It contains a few commands that would normally help you recover your Android system in case of a failure, like factory resetting. You will see that, for rooting, you will need to install a custom recovery.
The stock recovery does not have the ability to write custom ROMs (I'll explain these later) on your internal memory. A custom recovery has this option, and many more.
Here are some images for you to fully understand:
Stock recovery:
Custom Recovery
You can see that the Custom Recovery has more options, including "Backup and Restore", Advanced, and Install zip from Sd-card.
You can get in Recovery by powering off your phone, then hold Power+Volume Down button until a black screen with colored text appears. Then, use the volume buttons to select 'Recovery", and then press the Power Button to select it.
Bootloader
The bootloader is the first thing that fires up when you open your phone. As the name says (Boot+Loader), this program loads the kernel, which when boots up the Android system.
The same bootloader can also boot in recovery, as explained above.
When you first get the phone, the bootloader is in a locked state. That means that you cannot use fastboot commands like "fastboot flash" or "fastboot boot". With other words, you cannot simply flash a custom recovery. Thankfully, Google gave us the option to unlock the bootloader very easily, and flash a custom recovery of our choice.
Custom ROMs
A custom ROM is a ZIP file that contains an altered version of the Android OS. There are many custom ROMs for the Nexus 4, made by wonderful and skilled devs for the community. You can install a Custom ROM with your Custom Recovery. Custom ROMs contain the following folders and files:
META-INF- This folder holds the installation info and data. A custom recovery does not know on it's own how to install a ROM. In this folder, there's a txt file that contains a script, with the purpose of telling the recovery what to do.
System- This folder contains the stuff that will be installed on the /system partition that we talked earlier about.
boot.img- Among others, this file contains the kernel that comes with the ROM.
Click to expand...
Click to collapse
Ok, so now, after you read all this stuff, you're probably thinking "Ok, I will never get the hang of this". Don't worry. With time, you will know all of these from reflex. And, after you got over that, and manned up again, you probably thought "Ok, let's root this damn thing!". Not quite yet. We aren't done. There are still some crucial things that you need to know. So let's continue.
How to backup your stuff
Before you do anything EVER, you'll always have to backup your stuff, even if you don't feel like it, or your dog died (in which case I'm truly sorry), but, no matter what you're about to do, always have a recent backup sitting around.
There are many ways and things you can and will probably have to backup.
1. Backup your entire phone, by creating a Nandroid Backup.
As you saw in the 'Custom Recovery" picture above, you have a "Backup and Restore" option. Here it is again:
With every occasion, it's best to use it as often as possible. It only takes about 2 minutes, but it could be a life saver.
A Nandroid will backup:
/system
/data (Except /data/media, where your "sd-card" is, because it's too large and not that important)
/cache (Yes, there is a cache partition, and it will be backed up, although not really necesarry)
kernel (The kernel will be backed up too)
***Optional tip: I always keep a recent nandroid backup on my PC, in case I somehow wipe all my phone's contents, and my backup among with them. The Nandroid backup is saved at this location, which can be accest with a root file explorer, like ES File Explorer : mnt/shell/emulated/clockworkmod/backup. If you want to copy it to your storage, just copy the latest backup, and then move it to your PC.
2. Your apps and data only
This can be very useful when changing ROMs. You just got bored of your ROM, and want to move to another one. The only way of taking your apps and data with you is by backing them up with an application like Titanium Backup. The backups will be saved in data/media, and will be restored using the same app with which you backup up on the new ROM.
3. Your SMS, Contacts, MMS etc.
These things can be backed up by special apps on the Play Store. Ok, contacts will be restored by Google Sync ( although not always done properly, that's why I still back them up), but SMS will not be restored. There are many free apps that back them up for you, nice an easily, for them to be restored in case of a ROM change or data loss.
4. Your storage (data/media, sd-card)
You just connect your phone to your PC, select all folders, and copy all over on your PC. This will be useful when you unlock the bootloader. A bootloader unlock will wipe all the stuff on your phone (This can be avoided, read guides). So keeping a copy of your sd-card contents on your PC isn't such a bad idea.
Click to expand...
Click to collapse
Now you know how to keep it safe by creating backups. I will say it again, you are never too safe! Backup when you do a modification, even if it's tiny. Now, after you've finished reading the above, you will probably attempt to root. You will use one of the guides out there ( I will link one at the end of this thread ) to install a custom recovery, and gain root access. But what to do with it? Well, you will most likely end up flashing a custom ROM.
Flashing a custom ROM
You will get bored of the stock ROM, and will decide to flash a custom ROM. But you haven't done it before, and you don't really understand the process.Before you do anything, you must:
-Make sure that the files are for your phone ! If you flash files that were made for another phone, you might end up with a brick!
-Never panic! There is always a way out! That's what backups are for!
-Read all the instructions! Every ROM thread has instructions. Read them!
{By the way, flashing = installing}
Now, let me take you through the whole flashing process. ( Use the steps in the ROM threads if instructed differently than here )
1. You will search far and wide in these forums for a custom ROM that fits your needs. Every ROM comes as a ZIP file. So when you decide on a ROM, download the zip. For copyright reasons, Google Apps (Play Store, Google Now etc) don't come included with the ROM. So you will have to download them too. They are usually linked on the ROM main thread.
Some ROMs might have addons too, so check them out, and download the ones you want.
2. You now downloaded the ROM, Google Apps, and some addons. The next step will be to put them on your sd-card. Connect your phone to your PC, and make an easy access folder, like "Root Stuffs" where you'll put all these zips.
3. Now, let the backup process begin. You first backup your apps, app data , SMS, Contacts etc., like I explained above. I recommend Titanium Backup for apps and SMS, MC Backup for contacts.
4. Now you are ready to go in recovery. Power down your phone. Then, press and hold the Power Button and the Volume Down button at the same time. You will be brought to the Bootloader Screen. Now, with the Volume Buttons, switch through the options until you find "Recovery". Then press the Power Button again.
5. Now you will be booted in your Custom Recovery. Depending on your recovery, you will have the options on your screen.
CWM Recovery:
6. You will go to the Backup and Restore menu, and select "Backup". If you made a backup before, you can select "Delete" first, and delete it, for space consumption purposes.
7. After the backup finished, you will return to the main screen. There, select 'Wipe data/ Factory Reset". This will wipe everything in /data except /media, so your sd-card will remain untouched. Don't worry, you have a Nandroid Backup!
8. After the wipe finished, you will go to "Install zip from sd-card". You'll have to navigate to the folder where you put the ROM, and select it. You'll see it will nicely install.
9. After the ROM finished installing, you will have to flash the Google Apps zip, and the mods. Install them the same way you installed the ROM itself.
10. After you have flashed everything, you can select "Reboot system now" . First boot will take longer to complete. Again, don't panic. You have a Nandoid bakcup . You will end up with the ROM booted, and you'll continue setting it up.
TWRP Recovery:
6. Go to the "Backup" menu, select "Boot", "System", and "Data", then swipe the thing on the bottom on the screen to start backing up.
7. Once you're done, use the home button to get to the main screen. Select "Wipe", and swipe the thing again to Factory Data Reset. This will wipe data, cache and dalvik cache. This will not wipe your internal storage (Music, photos, etc).
8. After the wipe finished, use the home button again to get to the main screen. From there, select the 'Install" option. You'll have to navigate to the folder where you put the ROM, and select it. Then, by using the "Add more zips" option, add the Gapps package, and and then any addons or mods, in this order. Then swipe the bottom thing to flash.
9. After you have flashed everything, you can select "Reboot" . First boot will take longer to complete. Again, don't panic. You have a Nandoid bakcup . You will end up with the ROM booted, and you'll continue setting it up.
***In case something went bad, like your phone doesn't boot for more than 10 minutes, or the animation endlessly repeats itself (Boot Loop), do the following:
11*. Hold down the Power +Volume Buttons until the phone shuts down. Then release them for a second, and immediately press them again. You will be brought to the bootloader screen. Enter recovery.
12*. In recovery, go to the "Backup and Restore" menu, and select "Restore". Then pick the backup you did earlier, and wait for it to complete. Then, select "Reboot system now", and you should be booted back in your original ROM.
Now, let's say that after you flashed a ROM, it either did not boot, or you had some bugs with it. You will go to the thread ROM to report your problem. Here's how to not post:
"This ROM doesn't work"
You will have to be a lot more specific than that. In reporting a problem, you will have to do the following:
-Say what you did (Flashing process)
-What you flashed afterwards
-What you did to reproduce the bug
-What recovery you use
-ROM Version
-even provide a logcat <This is quite advanced> (http://forum.xda-developers.com/showthread.php?t=1726238)
You have to give as many details as possible, so the developer can sort things out.
Click to expand...
Click to collapse
ADB and Fastboot
ADB (Android Debug Bridge)
The Android Debugging Bridge is kind of a toolkit, that has many commands to control your Android from your PC. This is an essential part of your Android experience. With ADB, you can do many stuff that you couldn't normally do, like backup your apps, or push and pull packages from your phone.
ADB is also used by many of the useful tools out there, like toolkits, and all sort of programs that enhance your Android experience.
With ADB, you can also Logcat. Logcatting is creating a log of everything that happens on your Android phone while it's on. This is used to find the sources of bugs.
Example of ADB Commands:
Code:
adb pull /system/app/RANDOM APP = creates a copy of a system app on your PC
adb push app /system/app = Copies an app from your PC to your system partition
adb reboot bootloader/recovery = Reboots the phone in bootloader or recovery
adb logcat = Starts a logcat
Fastboot
Fastboot is also a toolkit of commands, but a bit different from ADB. While with ADB, you can do simple actions, with fastboot, you can do major ones, like flashing a whole partition, or formatting one. Fastboot is usually the preferred method to flash a recovery. Also, Fastboot usually works with .img files.
Example of Fastboot commands:
Code:
fastboot erase boot = Erases the kernel
fastboot erase recovery = Erases the recovery
fastboot flash system system.img = Flashes the System partition with an image
fastboot flash boot boot.img = Flashes kernel
fastboot flash userdata data.img = Flashes Data partition
fastboot flash recovery recovery.img = Flashes a new recovery
fastboot reboot = Reboots the phone
To use ADB and Fastboot, you must first have ADB drivers and Fastboot drivers installed. Here is a very good guide to set up these two useful things:
http://www.redmondpie.com/how-to-set-up-android-adb-and-fastboot-on-windows-tutorial/
Click to expand...
Click to collapse
Tips and Tricks
1. Try to not use toolkits. (I'm not disregarding any toolkit dev. They did a wonderful job)
Due to the fact that people are lazy in nature , toolkits have been made so that users don't struggle with rooting their phone. But there are many reasons for you to not use one:
-->you won't learn anything from using a toolkit, and, if something goes wrong, a toolkit can rarely fix your problem. It's better if you rely on your own forces.
-->you put the fate of your phone in someone else's hands. If a bit of code is wrong, then your phone could get bricked.
-->you miss out all the fun. Why buy a Nexus device if you don't want to explore the depths of the Android OS?
2. Never panic
Whenever you don't know what to do, and you're stuck, don't panic. There are many people here that can help you. Don't try doing anything blindly. Search the forums, or start a thread in the Q&As section, and we will help you.
3. Read everything carefully!! (If you read this, post a cat picture in this thread)
I might have said it a couple of times throuout this post, but always read everything. Someone wrote something for a reason. Usually, if you read everything, and do what you are told, you are bound to be failproof.
Click to expand...
Click to collapse
Ok, so now you know pretty much all a normal user should know. But there are still questions that are very frequently asked that need answering. Here are some questions and answers about popular problems and misconceptions:
Questions and Misconceptions
1. My Nexus 4 is getting very hot. Hardware problem?
Nope. There are many reasons that contribute to your phone getting hot, like
-the fact that glass is a good heat conductor, and the Nexus is covered in it
-the fact that a quad core produces more heat
-etc.
Don't worry. Everything is working as it should. For example, the Ipad gets 3 times hotter than the Nexus.
2. If I am rooted, will I receive OTA updates?
Yes, and no.
You will be able to download the update by having installed the Stock ROM with stock kernel, though it will not be installed automatically, due to the fact that you have a custom recovery. You will need to install it manually.
3. My notifications are delayed. Why?
Well, it due to the fact that Android is doing too much filtering.
To fix, navigate to /system/etc/wifi, and open WCNSS_qcom_cfg.ini. Now find the line McastBcastFilter=3. Change the value to 1, like this: McastBcastFilter=1, save, and exit. Then reboot. Your notifications should not be delayed anymore.
4. The Nexus 4 audio quality is horrible. Why?
It isn't horrible. It's normal, but the max volume isn't as loud as on other devices. I have been a piano player for 12 years. I have quite a sensitive ear, and I can tell you that the audio quality on the Nexus is comparable with that of an Ipod. The only major difference is that, with the Ipod, you can go deaf with the max volume.
5. Which kernel/ ROM should I use?
Don't ever ask this question. What's good for others isn't necessarily good for you. You'll have to try the many kernels and ROMs yourself.
6. My Nexus 4 rattles when I shake it. Why? Something broken?
Nope. There's nothing broken. That rattling is caused my the camera lenses moving. Don't worry about that either.
Click to expand...
Click to collapse
This is all for now. I hope you understand what's up with this Rooting process. If you have any questions, don't be shy to ask in this thread
If there is anything to be added to this thread, please post below
Thank you for the time you allocated to reading this! You are now smarter :good:
Good day, and Happy flashing!!!
For credits, useful links and other stuff, see the posts below.
Useful links
INDEX of Guides, Tools, Recoveries and more... (By GaboWinter)
Unlocking Bootloader without wiping data
[HOW-TO] How to flash a factory image / return to stock / unlock / root #
Ultimate Nexus 4 Root Guide
Credits and Thanks!!
@rootSU
For providing me a template and much of the info. His original thread in the S3 forums: (http://forum.xda-developers.com/showthread.php?t=2362743)
@mskip
For providing information on memory partitions
@paxChristos
For the logcat part
@efrant
For pointing out some mistakes
My annoying cat
For continually stepping on my keyboard.
Thanks for this awesome guide!
ngr.hd said:
Thanks go this awesome guide!
Click to expand...
Click to collapse
Thanks!! No problem. My girlfriend left me, so I have plenty of free time now
abaaaabbbb63 said:
Thanks!! No problem. My girlfriend left me, so I have plenty of free time now
Click to expand...
Click to collapse
O god Nice guide, will be helpful. One thing though:
4. Now you are ready to go in recovery. Power down your phone. Then, press and hold the Power Button and both the Up and Down Volume button at the same time. You will be brought to the Bootloader Screen. Now, with the Volume Buttons, switch through the options until you find "Recovery". Then press the Power Button again.
Click to expand...
Click to collapse
The bootloader can be accessed using just volume down and power. I never have to use both volume buttons.
chromium96 said:
The bootloader can be accessed using just volume down and power. I never have to use both volume buttons.
Click to expand...
Click to collapse
One learns new things every day...
This thread should be stickied IMO.
ohersi intriguing
this thread helped me A LOT!!!
got my Nexus yesterday, and i'm happy that such a thread exists.
@ApriliaM3
U should really consider making this a sticky
Hello!
I bought my Nexus last week, and I kept looking on the internet they can do with it. I've heard of the root, and I was curious. I also found it very interesting forum where I found this thread. Thanks for the information. Very useful.
Sorry for bad English. I used Google Translate.
i JUST realized this was here.. DOH!
THANK YOU
Nexus 4 doubts
Hii i just got a 16gb nexus 4 which is my first android phone last month and now i was thinking of rooting it and getting paranoid android on it...but just wanted to get some doubts clarified...
1. I wont be able to install ota updates when 4.3 or 5.0 android versions are released , so how will i get them ?? By Updating paranoid android ROM ??
2. In case i just root my phone and not install any custom ROMs then will i get otas ??
3. After installing a custom rom , can i revert back to the stock google thing ? I mean make my phone as it was when i first booted it.. ??
Thats all i guess..
Nice guide Andu! :thumbup:
Sent from my Nexus 4 using Tapatalk 2
simms22 said:
i JUST realized this was here.. DOH!
THANK YOU
Click to expand...
Click to collapse
No problem
gamekid94 said:
Hii i just got a 16gb nexus 4 which is my first android phone last month and now i was thinking of rooting it and getting paranoid android on it...but just wanted to get some doubts clarified...
1. I wont be able to install ota updates when 4.3 or 5.0 android versions are released , so how will i get them ?? By Updating paranoid android ROM ??
2. In case i just root my phone and not install any custom ROMs then will i get otas ??
3. After installing a custom rom , can i revert back to the stock google thing ? I mean make my phone as it was when i first booted it.. ??
Thats all i guess..
Click to expand...
Click to collapse
1. Yeah. Paranoid will most probably be updated to the latest android as soon as the source is released.
2. Yes, you will get OTAs, but you will have to install them manually.
3. Yes you can. You can either do a nandroid backup of your stock rom, and keep it, or you can flash a stock rom.
xanthrax said:
Nice guide Andu! :thumbup:
Sent from my Nexus 4 using Tapatalk 2
Click to expand...
Click to collapse
Thanks!
Added Fastboot and ADB
If I made any mistakes, please correct me
abaaaabbbb63 said:
Added Fastboot and ADB
If I made any mistakes, please correct me
Click to expand...
Click to collapse
Ha. I was considering adb
Sent from my GT-I9300 using Tapatalk 4 Beta
rootSU said:
Ha. I was considering adb
Sent from my GT-I9300 using Tapatalk 4 Beta
Click to expand...
Click to collapse
Nice!
I really like how you styled your thread! Looks awesome!
is there a link you'd recommend to get all google apps and any other important apps
and Thnx for the great guide, really helped me ALOT
M.Zaki said:
is there a link you'd recommend to get all google apps and any other important apps
and Thnx for the great guide, really helped me ALOT
Click to expand...
Click to collapse
Google apps are usually linked in the ROM thread.
Here are the JB 4.2.2 gapps:
http://goo.im/gapps/gapps-jb-20130301-signed.zip
Its worth noting that some roms have specific gapps packages too. Its always good to use these dedicated packages in case they have cool optimisations (eg slim with the dark mode toggles)
Sent from my GT-I9300 using Tapatalk 4 Beta