[Nexus S 4G Android Development] nowens0520:
I’ve compiled this information, found elsewhere, in order to make it easier for Mac users with the Nexus S 4g. I’ve simply combined BuglessPete’s Instructions for Rooting/Unrooting on the NS4g, with kenvan19’s Guide to Root on a Mac. All credit goes to them and the sources they cited in their original threads. Any errors here are my own. This method worked for me. The only change I’ve made is to link to the most recent version of Clockwork Recovery.

[NOTE: If Pete prefers, this information can be incorporated into his original thread, and a Mod can delete this]

Warning: If you break your phone trying this, I am not responsible. I do not guarantee that the following is safe or that the steps are correct. Rooting your phone voids the warranty. I have no responsibility for anything that occurs as a result of your following these directions! I cannot provide any support nor guide you in undoing this process and restoring the phone to factory condition.

This process will wipe your phone

. Ie, you will lose all your apps/data on your phone and have to reinstall them. It will also wipe your external storage, so back that up prior to proceeding if you want to keep anything.

1) Download this file and unzip it to your desktop (Inside you'll find all the files you need to proceed including "adb", "fastboot", "recovery-clockwork-3.0.0.5-crespo.img", and "su-2.3.6.1-ef-signed.zip"). Immediately delete "recovery-clockwork-3.0.0.5-crespo.img." You’ll replace it with the new version.

2) Download Clockwork 4.0.0.2 (****MAKE SURE YOU SELECT ONE OF THE NS4G VERSIONS*****) in the color of your choosing. Move the file into the adb-fastboot folder you created in Step 1.

3) On your phone, go to Menu>Settings>Applications. Select "Development" and check the box next to "USB debugging"

4) Connect the phone to your Mac via the USB cable

5) Open a Terminal window on your Mac (Applications>Utilities>Terminal), and copy/paste the following into the Terminal:

~/Desktop/adb-fastboot/adb reboot bootloader

Hit "Return" and wait for your phone to reboot into Bootloader/Fastboot mode

5) If your Bootloader screen says "LOCK STATE - UNLOCKED" then skip to Step 6. If it says "LOCK STATE - LOCKED" then copy/paste the following into the Terminal:

~/Desktop/adb-fastboot/fastboot oem unlock

Hit "Return" and on your phone will prompt you to confirm and warn you that you are going to lose everything. Confirm. At this point you will have an unlocked bootloader.

6) Copy/paste the following into the Terminal window (***Change the file name to the appropriate color***):

~/Desktop/adb-fastboot/fastboot flash recovery ~/Desktop/adb-fastboot/ns4g-4002-COLOR.img

Hit "Return" again and wait for recovery to boot.

For the following steps while in Recovery, use "Volume Down" to highlight a selection and "Power" to choose that selection:

8) Choose "mounts and storage"

9) Choose "mount USB storage". Your phone should now be mounted on the Mac as a Device called "NO NAME"

10) Move the zip file "su-2.3.6.1-ef-signed.zip" from the "adb-fastboot" folder to the "NO NAME" Device on you computer.

11) Eject/unmount your phone in the Finder on your Mac.

12) On your phone, choose "Unmount"

13) Choose "mount /system"

14) Choose "+++++Go Back+++++"

15) Choose "install zip from sdcard"

16) Choose "choose zip from sdcard"

17) Choose "su-2.3.6.1-ef-signed.zip"

Some people with new Nexus S' are finding that the file discussed in the following steps does not exist. If you cannot find it but can still reboot into Clock Work Recovery Mod then don't worry, you're still rooted and fine!

At this point you have root, but your phone will continue to replace ClockworkMod Recovery on reboot. To prevent this, do the following:

1) Reboot your phone, and download the app "Root Explorer" from the Market

2) Open Root Explorer and navigate to the "etc" directory.

3) Tap on the gray box that says "Mount R/W"

4) Tap and hold on the file "install-recovery.sh" and rename this file to "install-recovery.sh.old"

5) Download the app "ROM Manager"

6) Open ROM Manager and choose "Flash ClockworkMod Recovery". At this point you are all set.

To Unroot and Return to Stock:

1) Download Stock GRJ22 Software Images.

2) Unzip the files, and place the images into the adb-fastboot folder you created on your desktop above.

3) Open a terminal and use the following commands:

~/Desktop/adb-fastboot/adb reboot bootloader

4) Wait for bootloader to reboot on phone.

5) Then, in terminal use the following commands:

~/Desktop/adb-fastboot/fastboot flash boot ~/Desktop/adb-fastboot/boot.img

~/Desktop/adb-fastboot/fastboot flash system ~/Desktop/adb-fastboot/system.img

~/Desktop/adb-fastboot/fastboot flash recovery ~/Desktop/adb-fastboot/recovery.img

~/Desktop/adb-fastboot/fastboot flash userdata ~/Desktop/adb-fastboot/userdata.img

~/Desktop/adb-fastboot/fastboot erase cache

~/Desktop/adb-fastboot/fastboot oem lock

6) Reboot to System, and you should be returned to Stock, Unrooted GRJ22.