Re: The Hitchhiker's Guide to the Galaxy Nexus
Flashing = Installing (And crazy things you've done but didn't realize until now...)
The bread and butter of the "Android experience"--for many--is flashing. Think of flashing as a method of installation--you're simply installing the .zip package into your phone through a "custom recovery."
Wait, what? Let's take this step by step, shall we?
Subsection A - The Backbone of Flashing: Recoveries
A custom recovery is sort of like an interface between you and a bunch of crazy numbers and words and such. Essentially, it's a go between, relaying information from you to the phone in a language the phone understands (.zip files, as mentioned). The most popular recovery out there is called
ClockworkMod (CWM). Again, like anything and everything Android, CWM is the fruit of intense labor by a developer, in this case Koushik Dutta (and if you use CWM daily, monthly, or ever, then please please please donate to him).
Anywho, while using a recovery is brutally simple, you first need to acquire one. There are generally two ways to do it--by "pushing it" (in reality, flashing/installing it) through fastboot (a method beyond the scope of this guide) or by flashing it via
ROM Manager. ROM Manager is another one of Mr. Dutta's wondrous creations. You can download roms, Google Applications (commonly known as "GAPPS"), or even different versions of CWM, like the CWM Touch recovery (which I highly, highly recommend). If you're a new user, I highly recommend downloading ROM Manager (and the
premium license, because donating to developers is a great habit to get into) and flashing ClockworkMod from there. If you read and followed the guides featured in
Top Tip #2, then you're probably bored to death right now.
Once acquired, you're ready to rock and roll. But not
too crazy now, lest we bootloop.
[WARN]There is no quicker way to screw up your phone than screwing up the acquisition of a custom recovery. Whichever guide you follow, follow it carefully. While using ROM Manager may be the "easy way out," it pays dividends to have a simple, reliable program that flashes your recovery for you. Once you start flashing you'll realize how intimate you become with your recovery, getting to the point where you reboot into it just to say hello. Treat your recovery like a lady (or guy, depending on sex/persuasion), and it'll treat you just fine. Also, don't get it drunk--trust me. Only when you're familiar with the concepts discussed in this guide should you really to get it drunk/play with fastboot at an expert level.[/WARN]
Subsection B - The Zen Approach to Roms
Once you have a recovery, you're going to want to at least explore the world of roms. To put it simply, a rom is an image of an operating system, almost always a derivative of the "latest" version of Android, that has been developed, modified, customized, streamlined, massaged, fattened, and pampered by a developer or team of developers. The best analogue is car customization. Let's say you take your old Ford, say a Taurus. You drop it off with a bunch of folks at a garage, and instantly they turn it into a 400hp grocery-getting machine with machine guns, shovels, dining sets, a foldaway camper, and wings. That is what a rom does--it transforms your device, the features within your device, and takes everything (well, not
everything) in your phone and changes it. Sometimes this change is good, sometimes it has bugs, and sometimes it is so good that you're just besides yourself for 15 minutes after changing the color of your softkeys and adding 16 different homescreens through a custom launcher (launcher = that thing that gets you to all of your apps, you know, by "launching" them).
Often, the most difficult "part" of the rom process is picking one. The Galaxy Nexus, if for nothing else, has an absolute abundance of roms. I mean it's like walking into a grocery store and demanding candy. What, you want a Milky Way? Check out BAMF. Snickers? CM9! More of a Reese's guy, eh? LiquidSmooth is your thing. And so on and so forth. Have that new OTA and still on a stock, but rooted rom? Jerry's got you
covered!
Here's my advice in choosing a rom--do your research. Don't just download something willy-nilly. Don't pick something because the name is sick. Download something that has decent support, that has decent reviews in its own threads (both here and elsewhere), and something that seems interesting. The BEAUTY about flashing roms is how quickly it is to switch to another. Don't like BAMF? Then flash MORPHR and see what's what. Don't feel comfortable with pink unicorns? Switch from AOKP to GummyNex. Hate whatever you did to your phone? Restore that Nandroid, baby! The moral of this story is simple--do your homework.
Subsection C - Dylan's Four Flashing Commandments (DFFC for short, if anyone wants to know)
Flashing a rom is generally a "uniform" procedure. Regardless of rom, there are some key tenets to follow that help you achieve the success you want, letting you experience the sorcery of DroidTh3ory or the craftsmanship inherent in AOKP. These are practices I like to practice, preach, and prescribe, mainly because it aids both the casual rom enthusiast and the diehard flash addict.
[WARN]Lest we forget, flashing is serious business. One does not simply
walk into Mordor revive a bricked phone. Take my advice, heed with caution, and double check before you launch for the moon.[/WARN]
The First Commandment - Always Have a Backup. You Need an Exit Strategy!
One of the awesome features of CWM (or any recovery) is being able to make a backup. Commonly, this is called a Nandroid. Why? Maybe because it's a "small" version of Android, so Nano + Android = Nandroid? Meh, that's my best guess. Anyway, you should
always have a backup at hand. If that means making one immediately before you start the flashing process, that's what it means. If that means making one immediately after flashing the recovery, which happens not 30 seconds after unlocking/rooting your phone, then do that.
Here's what happens if you don't have a backup. Let's say, for example, you owned a Droid Incredible. Let's say, again, you wanted to impress a friend of yours with this whole "flashing wizardry. Let's say, even further, that you decided to flash a brand new rom right in front of their eyes. The problem is, that rom is for a Thunderbolt, or the GAPPS didn't check out, or you just got really wild and wanted to flash a port of Honeycomb. Well, if you have a backup, then no harm no foul right? Just manually boot into recovery through the bootloader, restore the nandroid, and then boom.
But what if you don't? Well you could always use fastboot/adb/other mysterious techie methods of doing things, you could always pull your SDcard (but HA! not for us GN'ers!) put a rom on and flash that, or you could throw your phone into a mineshaft and hope it works in 47 years when it's finally rediscovered.
See what I'm saying? Make a freaking backup. Who cares if it takes 8 minutes. It's the best 8 minutes of your life as a flashing Android artiste, so don't screw it up.
[TIP]
Top Tip #3 - For me, I have 3 backups on hand at all times--(1) Stock, (2) CM9, and (3) Whatever my latest rom is, if it has been performing well. I suggest a similar setup, but keep in mind that these badboys are sometimes a gig, sometimes more--so exercise caution. I've been blessed with a terribly overrpriced MacBook Pro, so I use its HD to store older Nandroids. There is nothing more relieving than seeing a Nandroid restore after almost screwing up your phone--trust me. So be smart, be safe, and always have an exit strategy in case of doom and damnation.[/TIP]
The Second Commandment - Be Organized.
Your SDcard, virtual as it may be, is your friend. If you throw a million different things at your friend at a single time, he'll be confused, hateful, and probably annoyed, possibly resulting in physical harm to your face. The SDcard is the same way. If you start throwing a bunch of stuff on it without order/organization, you'll never find anything you need and it'll probably start texting you at night regarding that old APK of Google Wallet you left behind months ago. It may sound crazy, but trust me--organize it.
Another aspect of organization is MD5 sums.
Check them. Check to see if the files you have--may they be backups, roms, GAPPS, etc., all match up. You know what happens if they don't? Death. (Maybe, probably not, but maybe!)
[TIP]
Top Tip #4 - Here's how my SDcard is organized--a folder for roms with separate folders within for CM9, AXI0M, Miscellaneous; a folder for Kernels; a folder to move my backups/nandroids; and a folder for general flashing miscellany. Obviously, organize it how you would like--but get into the habit. It makes flashing a breeze and gives you confidence that if you screw up, you know where to look on your phone to find the solution.[/TIP]
The Third Commandment - When in doubt, wipe.
Some users believe that not wiping their phone before flashing a rom is a sign of courage, bravery, etc. No, courage is going to battle, flying into space, or walking into IRS Headquarters on April 17th.
Wiping your phone is not hard, not particularly time consuming, and only inconveniences the impatient. There are 3 different wipes to be aware of:
First, there's the data and factory reset wipe. Think of this as taking your credit card and holding it next to a magnet---no more debt! (jk). You're erasing everything except your virtual SDcard and taking it back to stock--which is whatever rom/OS you have on there currently.
Second, there's the cache wipe. Your apps and system build up data, like cookies/viruses in Internet Explorer, and you need to wipe that. Why? Well think of it this way. Let's say you're the Washington Redskins, who, accustomed to not having a QB since the late 60's, are going to draft Robert Griffith III. Because they had no QB, they built their entire team around a frail, decrepit running back named Clinton Portis, who one time many moons ago was a nice player. Unfortunately for Mr. III, there is literally no supporting cast--the team was built around one thing, and now he's another. If you install Mr. III (the ROM) without wiping the slate (cache) clean and surrounding him with fresh opportunities to grow (no cache buildup), then there's a better chance for growth and success (no force closes, bugs, etc. etc.) So don't draft Robert Griffith III without having a fresh slate, and don't flash a rom without at least wiping your cache, or else the conflicts will drive you bonkers.
Third, there's the dalvik cache wipe. What's dalvik cache? Well, it's a few things to a few people. On one hand, it's merely a superstition, like chicken bones to Cajuns or plastic-wrapped sofas to Italians. On the other, it's a depository where applications put information to make them work faster, more efficiently, etc. etc. Believe what you will, just make sure you wipe it. Because like Mr. III in the above wipe, once you build up around something old, conflicts with something new are just around the corner.
[INFO]When flashing a rom, you may choose to dirty flash (if coming from one nightly to another nightly of the same rom) or a clean flash (if coming from one rom to an entirely different rom). Here's what I do for each...
Clean/Full Wiping
- Wipe data/factory reset (this also wipes the cache)
- Wipe cache (just do it lol, it's good to make it habitual)
- Wipe dalvik cache (in advanced)
- Wipe system (i.e. format system in mounts/storage)
Dirty Wiping
- Wipe cache
- Wipe dalvik cache (in advanced)
- Wipe system (i.e. format system in mounts/storage)
[/INFO]
[TIP]
Top Tip #5 - Wiping cache and dalvik is a relaxing exercise. Think your phone's acting a bit screwy? Wipe cache/dalvik! Not getting the battery life you wanted? Try wiping! Got nothing better to do while waiting for your boss to look over your TPS reports? You guessed it--wipe cache/dalvik! So many issues are caused by people not wiping--from force closing apps to weird little bugs like launcher lag and homescreens disappearing. So do yourself a favor--always wipe.[/TIP]
The Fourth Commandment - Don't Panic.
Things happen when you flash. In fact, I'm in the camp that if you don't have at least one bootloop in your experiences then you're doing something not wrong enough (
). If you don't get into trouble then you don't know how to get out of trouble, ya dig? So here are a few tips to get you out of trouble, or at the very least, assure you that your Nexus hasn't offed itself. Just remember--if you know how you got into trouble, you know you can get out....73% of the time.
[NOTE]
- If it can turn on, it's not actually bricked. The best way to solve issues like the phone not actually starting is to manually boot into recovery, retrace your steps, and redo everything. You could even pull the battery out, have a cigarette, put it back in, and see if that works. But still, it starts, so don't say it's "bricked." Because it's not. If it's bricked, it will never turn on (probably ever) and it's an irrecoverable corpse, used for such things as paperweights and Asurion insurance claims.
- If you've been staring at a boot animation for 36 minutes, try redoing the process. The first boot animation ALWAYS takes longer than the subsequent ones. Why? Because Andy Rubin hates us and wants us to sit there with very extreme anxiety waiting to see if what we did works. So hang on to your butts, but if you're on your third cigarette and you're name's not Don Draper, then try again.
- Can't find the market? Try reinstalling GAPPS, you noob . Google Apps (Play Store, Music, etc.) are sometimes automatically included with your rom. Sometimes they're not. The rom thread or website where you downloaded your rom will say whether they have them and if not, where to get them. When you need to flash them separately, make sure you do so immediately after flashing the rom. Do not reboot, do not pass go--just flash GAPPS.
[/NOTE]
[INFO]
Dylan's Flashing Procedure:
- Do your research, be organized, and have all of your files ready to rock.
- Have an exit strategy (a nandroid or fresh, clean, stable rom) ready to rock incase Custer decides to come back as a crack-flashing maniac.
- Reboot into recovery via ROM Manager, the Bootloader (hold down volume UP, volume DOWN, and POWER at the same time, sort of like a Mortal Kombat 2 combo), or whatever magic you've used to get there previously.
- Unless the rom thread says otherwise, do your wipes. If it's a nightly and you're on a previous nightly build, you don't necessarily need to wipe data, so it's your call. Otherwise, if it's a new rom, a major build, or if it makes a point of discussing factory resets at length in the thread, wipe data.
- After your wipes are completed, some like to Format the System (it's under Mounts & Storage for fellow CWM fans). Do this then, after you have a fresh slate (because otherwise isn't very logical).
- Install your ROM's zip file.
- Install GAPPS, if necessary. Don't you dare reboot if you need to do this!
- Reboot out of recovery.
- Enjoy a cigarette, drink, 13 minute political conversation, whatever while it reboots.
- Sign in, let market restore do its thing, and enjoy your rom.
[/INFO]