Monday, November 2, 2009

got root? (AKA gPhone (ie Android G1) rooting goodness)

thought i may as well type up my experience of rooting my gPhone -to inform, enlighten and mebbe even educate anyone thinking of doing the same.

this is not a ‘how to’, but a ‘this is how i did it’. there are a few different ways of rooting and modding, but this is how i did mine.

before i start i want to make clear that anyone undertaking such a risk commitment does so at their own risk and is nothing to do with me. i am not responsible for bricked phones, delusions of grandeur, the current economic downturn or global warming.

ok, ass well and truly covered, i shall begin.

a bit of background- the reason that i decided to root my gPhone was as follows- as well as generally loving tinkering around with such shit, a couple of months back an official OTA Android update borked my phone (read previous posts) and it looked like the only way out was a factory reset (ie wipe everything and hope for the best)… some ’solution’ huh? so, as addressed before in a few posts, the official Google ’support’ was laughable and i was relying on the community for answers. which is pretty much how it goes when rooting. the major drawback that puts people off (aside from numpties bricking their phone cos they don’t know what they’re doing) is the ‘oh it’s nothing to do with us anymore’ reaction when Google (or whomever) realise that you have shunned their stock builds for something shinier. so yeah, losing official support- “oh no, how will i cope?” </sarcasm>

so with that decision made, the main problem lay in the catch 22 that i needed to back up my important stuff (contacts, texts, etc) before i would wipe my phone, BUT i couldn’t get to said stuff until i rooted my phone (which involves a wipe) because the daft-ass privileges on the gPhone mean that you can’t even READ the onboard storage (and therefore copy anything off it)…

so yeah, a bit stuck. until, after much much research and going-in-circles, i stumbled across an app called ‘instant root’[1]. this app utilises an exploit in the bluetooth stack that can give a user root privileges WITHOUT HAVING TO REFLASH YOUR PHONE. now this is major w00t, as i could then copy my texts database from my phone to be replaced after the ensuing shenanigans.

(yes, i was skeptical about a one-click app giving root, but it did indeed work. it says in the readme that it will only last until the next update, but it did exactly what i needed, so i was happy. also, apparently this exploit has been closed in donut (v1.6) so it may not work from now on)

so, i have my texts database copied to my memory card[2], my bookmarks backed up using ‘bookmark backup and restore’[3] and my contacts backed up with a free beta version of Sprite Backup[4] NOT using gmail sync. gmail sync appears to only sync one way. i turned it on (having never used it before now) to back up my contacts and instead of copying my phone contacts to my gmail it started removing any contacts that weren’t in my gmail… not much damn use if you ask me!

with everything backed up, and me having (temporary) root privileges, the fun can begin. i hooked my gPhone up to my computer via a USB cable to transfer the stuff i’ll need, and so i can grab screengrabs (using DDMS) for this post. i transferred the apk installer for a program called ‘flashrec’[5] (allows you to flash a bootloader recovery screen that will allow you to flash a new rom) and a rom image for the Cyanogen Mod[6].

now follows the notes/screengrabs that i took as doing it.

installing flashrec from my sdcard using appmanager.

the time is 16:59.

backing up my recovery image. so far so good

now flashing the new recovery image.

the time is 17:01.

it’s done.

turning my phone off, then rebooting to the bootloader by holding down the home button as i boot back up.

the time is 17:02.

shit. i get an error when making a nandroid backup.

quick google around and no joy.

decided to reboot phone as normal, and check my sdcard for a) space and b) corruption.

the time is 17:16.

sdcard seems to have enough space and doesn’t say it’s corrupted.

to be on the safe side, freed up some space. now have about 150mb free.

made sure there’s plenty of space on my phone too. have around 20mb free

now reinstalling flashrec.

ok, rebooted back to bootloader screen, performing nandroid backup

the time is 17:24.

backup complete! must not have been enough free space.

the time is 17:26

performed ‘wipe data / factory reset’. nearly shed a tear.

selected ‘apply any update from sd’ then chose the CM recovery image zip

is now happily unpacking/installing away

the time is 17:27.

‘install from sdcard complete’

the time is 17:29.

rebooting now, hopefully to Cyanogen goodness.

after a few tense minutes staring at the G1 bootscreen i am greeted by the cyanogen one. so far so good.

and eventually the google set up / sign in to account screen

the time is 17:34

phone finishes booting up into my new Cyanogen-flavored Android OS.

the time is 17:36

total time spent rooting (not including time spent figuring out the nandroid error): 16 mins

 

so there you have it. my experience of rooting my gPhone. i’ll spare you the hours spent putting my texts, contacts, bookmarks, apps etc back on there.

[1] ‘Instant Root’, an app by neilandtheresa, removed from android market, so just google it.

[2] texts and mms database located at /data/data/com.android.providers.telephony/databases/mmssms.db, mms attachments stored in /data/data/com.android.providers.telephony/app_parts

[3] Androlib page for Bookmark Backup and Restore

[4] sprite backup no longer in beta, paid app available in the market or google and you may find the apk for the beta (note don’t use beta one, you want beta two) (different backup file format)

[5] google it.

[6] www.cyanogenmod.com – custom builds of the Android OS, utilising the features released in dev branches (ie gets new features before the official builds) basically full of root goodness

No comments:

Post a Comment