[KERNEL] [GUIDE] Root Your Stratosphere! :-)

KnightCrusader

Well-known member
Jul 21, 2011
107
24
0
Visit site
First of all, mad props goes out to jcase, imnuts, and tbh, as well as the #charge irc channel for providing the stock kernel and support needed to get this working! Couldn't do it without you guys!

Okay, first the standard disclaimers: THIS WILL VOID YOUR WARRANTY! We are flashing a MODIFIED stock kernel to get root. (And yes, there is a mechanism Samsung put into it's bootloader to tell if you flashed a custom kernel! It's a tradeoff for openness that I am willing to live with! :) Also, batteries not included, some assembly required, may make your cat go bald, could pillage your villagers, give you Bieber fever, etc.

Also, this post is for reference or entertainment purposes only. If you decide to use this info to root your phone, and you end up borking it, I'm not responsible. Neither is Android Central, jcase, imnuts, or anyone else but yourself.

This is not for the faint of heart, so if you have questions or need assistance, please feel free to ask in this thread. I had to do a metric crap ton of research just to figure out how to do all this, so I know what its like to have to get your mind rapped around this stuff. (At least you guys don't have to compile the kernel, just flash the one I made. Lucky you! :p I had to learn how to compile the kernel over the past few days and this was my first attempt. Yay me. :)) I also took some non-standard ways to get this on the phone, so please bear with me if I take extra steps that could be streamlined.

Now, without much further ado, here it is:

ROOT YOUR STRATOSPHERE! :cool:

Setup: I'm using Windows XP 32-bit, but unlike most devs, I use Heimdall in order to flash firmware to my phone. (Long story short: I've had less issues with using Heimdall than I have with Odin - that, and Odin only works in Windows where as Heimdall works in Windows/Linux/Mac. But, its up to you, feel free to use whatever tool you want as long as you know what you are doing with these files.)

Also, make sure you have adb set up and working. You'll need this to push the actual superuser binaries. Download and more info on adb at Android Developers.

First things first: Let's get your system set up to flash the kernel to the phone.

NOTE: If you have data encryption turned on, its been warned that you might want to turn it off before attempting this. Not sure if this is related to custom kernels or not, but better be safe than sorry. (And I think its off by default, mine wasn't on... so if you didn't turn it on, you should be fine.)

Download Heimdall 1.3.1 and extract the zip contents to a folder. Make sure to install the C++ distributable mentioned in the download section or the tool won't run (Windows only).

Put your phone in download mode.
There are many ways to do this, easiest being holding the Vol - key while powering the phone on. It will warn you about flashing custom firmware, yadda yadda. Accept it anyway, then you'll see a green Andy that says "Download Mode Do Not Turn Off Target". Now plug your phone in. (Linux/Mac users can skip the rest of this paragraph. Yay us Windows users.) Set up the drivers from the zagig.exe app in the Drivers folder. The dropdown box will say something like 'Gadget Serial'. Click 'Install Driver'. I can't remember if I had to replug the phone or not, or reboot the machine, but you might want to for good measure if it isn't working.

Next, download the zip attached to this post below and unzip its contents to a working folder. To make things easier, just extract the zip contents to the same directory that heimdall is living in. You should have the following files from the zip:

Code:
root-zImage
su
busybox
Superuser.apk
Now, fire up a command window in this directory. I use the command-line utility in order to push the kernel instead of the GUI, but if you know how to use the GUI, be my guest.

First make sure the device is detected. Type:
Code:
heimdall detect
If it works, you'll get 'Device detected'. Now you are good to go:

Code:
heimdall flash --kernel root-zImage
You'll see it say uploading kernel, and a progress bar will appear on the phone. It goes pretty quick. On success, you'll see the phone reboot, and then a new yellow '!' triangle will flash under the SAMSUNG logo on the boot screen. This means the system detected a custom kernel. If you see/hear the boot animation, then you were successful! You are now sporting a working insecure kernel reading for rooting! ;)

Wait for the phone to boot back up and make sure everything is in working order. Make sure USB Debugging is on. (Settings->Applications->Development)

Now, in the command window, make sure your phone can be seen:
Code:
F:\Downloads\heimdall-suite-1.3.1-win32>adb devices
List of devices attached
3235A3CA0D8400EC        device

now, remount the file system.

Code:
F:\Downloads\heimdall-suite-1.3.1-win32>adb remount
remount succeeded

Push the following files to the phone:
Code:
F:\Downloads\heimdall-suite-1.3.1-win32>adb push su /system/bin
F:\Downloads\heimdall-suite-1.3.1-win32>adb push busybox /system/bin
F:\Downloads\heimdall-suite-1.3.1-win32>adb push Superuser.apk /system/app

Change the permissions on su and busybox:
Code:
F:\Downloads\heimdall-suite-1.3.1-win32>adb shell chmod 4755 /system/bin/su
F:\Downloads\heimdall-suite-1.3.1-win32>adb shell chmod 4755 /system/bin/busybox

Now, download something from the market that needs root privileges to test. I bought Root Explorer, so I used that to test. I also tried to su from ConnectBot in a local connection and it also worked for me.

If you get the Superuser Request popup, then you are rooted!! Congrats! :cool:

If you want to put the stock kernel back on, or just want to have it for safety sake, I attached it in a zip by itself as well. Flash it using the same method listed above. Thanks again goes to jcase and tbh for providing that.

I'll be updating this post with images and pictures, or cleaning parts up as I get time and some feedback.

LET THE DEVELOPING BEGIN!! :cool:

Files:
Stratosphere Root.zip: md5: ead3a6a2b36a25a32692dec71e6bfc7f
Stock Kernel.zip: md5: 97d8df7945b5035d480547424cbcaa35
 
Last edited:

JonK

Well-known member
Apr 20, 2010
200
5
0
Visit site
Excellent work! Remember for the adb parts you must have USB debugging enabled in settings under applications>development. Thanks!!
 
  • Like
Reactions: charleylol

Scroobles

New member
Oct 23, 2011
2
0
0
Visit site
Just a couple questions regarding this process:

1. What are the benefits of this? The Stratosphere is my first Android device (coming from Blackberry), My roommate told me I absolutely have to root this phone as soon as possible.

2. Once my device is rooted what is the next step? As in, what should I do once it is rooted.

3. Is there anyway to revert back to the original factory settings if I have a problem with the phone? Just wondering about the voided warranty.
 

KnightCrusader

Well-known member
Jul 21, 2011
107
24
0
Visit site
Excellent work! Remember for the adb parts you must have USB debugging enabled in settings under applications>development. Thanks!!

Crap, good eye. I knew I was gonna forget that! I added it back in. Thanks!

Just a couple questions regarding this process:

1. What are the benefits of this? The Stratosphere is my first Android device (coming from Blackberry), My roommate told me I absolutely have to root this phone as soon as possible.

2. Once my device is rooted what is the next step? As in, what should I do once it is rooted.

3. Is there anyway to revert back to the original factory settings if I have a problem with the phone? Just wondering about the voided warranty.

Root basically gives YOU control of YOUR phone. Of course, as old Uncle Ben said, with great power comes great responsibility. With this power, you can seriously FUBAR your phone if you don't know what you are doing, but when used right, you can do things that the manufacturers deny you.

Things like:
- Remove bloat (crapware Verizon shoveled on the phone, like City ID, Blockbuster, etc.)
- Wifi Tether (why pay for data twice?... plus, with LTE, they can't stop you per the FCC)
- Screenshot
- Install modules for VPN'ing, or sharing files over the network
- ROMing, even installing other versions of Android

Apps like Wifi Tether For Root Users and Root Explorer and VPN Installer are available freely on the Internet. I Installed Tether and Root Explorer and both seem to work just fine. Haven't messed with VPN stuff yet... maybe on my next round through with building a kernel for this I will.

As for reverting back, I am trying to put together a system image of my phone for flashing back incase I screw it up. I'll make it available as soon as I verify it works restoring the phone.

I was willing to brick my phone to get root access, so for a nerd, its a must. I have been spoiled by the "aftermarket" things I can do with my phones that I can't sleep right without getting root. :p
 
  • Like
Reactions: ltcbailey
Aug 2, 2010
14
3
0
Visit site
OMG, thank you so much! One question:

I'd like a kernel with CIFS/EXT4 modules etc, anything special you did to compile your kernel? I'm fairly technical (sysadmin by day) and have compiled many things. :)

Thanks!
 

KnightCrusader

Well-known member
Jul 21, 2011
107
24
0
Visit site
OMG, thank you so much! One question:

I'd like a kernel with CIFS/EXT4 modules etc, anything special you did to compile your kernel? I'm fairly technical (sysadmin by day) and have compiled many things. :)

Thanks!

Nothing special, however, I reused the modules that came with the stock kernel instead of the ones that were freshly compiled. I'm not sure why, but the source only spit out 10 modules when the source kernel came with around 19 or so.

I am sure you could compile a cifs.ko or tun.ko and add it to the init to be loaded automatically. In fact, my next step is to try this, as well as auto-rooting the kernel to make this guide a little easier to follow.

I wanted to at least get this method out there while I dabble with customizing it.
 

KnightCrusader

Well-known member
Jul 21, 2011
107
24
0
Visit site
I'm gonna flash the kernel when I get home, then I'll give z4 a run to see if I can make this easier.

I tried z4root and SuperOneClick after using the kernel, and they were trying to use exploits when they didn't need to. It never worked, actually locked up the phone and I had to pull the battery.

Actually, I got su and busybox from the SuperOneClick package that I included in the zip. Manual push was the only way (so far) I got it to work.
 

Dubbman

Well-known member
Oct 18, 2011
97
17
0
Visit site
Yeah, that's what happened to me. I repushed the stock kernel after after following your guide on the insecure and it all worked.
 

KnightCrusader

Well-known member
Jul 21, 2011
107
24
0
Visit site
Thank you...

am eager to try this...noobs like myself could really use a step by step you tube walk through

Sometime this week, once I set up a better Linux box (the laptop I was using has a short in the power cord somewhere), I'll bake another easier-to-root with kernel that eliminates the adb part needed at the end of this guide. If I can find my camcorder, I may do a how to as well. :)
 

newzern

New member
Oct 24, 2011
2
0
0
Visit site
I'm having trouble getting adb to find my device
Still new to the whole android phone thing (coming from Blackberry)
and under my device manager the phone shows up as Samsung Android..
And I followed every step along the way until I have to use "adb devices" (or at least I hope I did)
So I'm at a complete loss of why it can't find it.. any suggestions?
 

KnightCrusader

Well-known member
Jul 21, 2011
107
24
0
Visit site
I'm having trouble getting adb to find my device
Still new to the whole android phone thing (coming from Blackberry)
and under my device manager the phone shows up as Samsung Android..
And I followed every step along the way until I have to use "adb devices" (or at least I hope I did)
So I'm at a complete loss of why it can't find it.. any suggestions?

I am starting to wonder if I had to install Samsung drivers to get USB debugging (adb) to work. Let me check on that when I get home. Its been so long that I can't remember.
 

JonK

Well-known member
Apr 20, 2010
200
5
0
Visit site
I'm having trouble getting adb to find my device
Still new to the whole android phone thing (coming from Blackberry)
and under my device manager the phone shows up as Samsung Android..
And I followed every step along the way until I have to use "adb devices" (or at least I hope I did)
So I'm at a complete loss of why it can't find it.. any suggestions?
Are you sure you enabled USB debugging? Find this in settings>applications>development.
 

decaydance99

Well-known member
Jan 13, 2011
84
2
0
Visit site
hey guys i need some help i am a VZW Fascinate vet and using heimdall is diffrent.
here is my setup
windows 7 x64
adb installled
Startosphere shows up in abd devices
stratosphere also shoes up in download mode in heimdall, heimdalle detect= detected
c++2010 (i forgot what it is called) is installed
when i write the command "heimdall flash --kernel root-zImage"
i get this error
Code:
 Initializing connection
Detecting device....
ERROR: Failed to access device. libusb error -12

i re-ran "heimdall detect" and it says device connected.

any advice
 

JonK

Well-known member
Apr 20, 2010
200
5
0
Visit site
hey guys i need some help i am a VZW Fascinate vet and using heimdall is diffrent.
here is my setup
windows 7 x64
adb installled
Startosphere shows up in abd devices
stratosphere also shoes up in download mode in heimdall, heimdalle detect= detected
c++2010 (i forgot what it is called) is installed
when i write the command "heimdall flash --kernel root-zImage"
i get this error
Code:
 Initializing connection
Detecting device....
ERROR: Failed to access device. libusb error -12

i re-ran "heimdall detect" and it says device connected.

any advice
Even though heimdall says it detects the device you still need to install the driver with zadig. Follow these steps:

Put your phone into download mode
Plug in usb
Open zadig
Go to options->list all devices
Select gadget serial in the drop down
Click install driver
When it says successful close zadig
unplug USB, then plug back in

After doing this now try. Let me know if this helps.
 

JonK

Well-known member
Apr 20, 2010
200
5
0
Visit site
I am starting to wonder if I had to install Samsung drivers to get USB debugging (adb) to work. Let me check on that when I get home. Its been so long that I can't remember.
Knight, now that you know how to compile a kernel from source, how difficult is it to compile a complete AOSP ROM? Do you think porting ICS or cyanogen is a goal within reach? Can you point me to the info/guides you used to learn how to compile a kernel? It took but a day to get ICS onto the Nexus S which is the same hardware. I really want to try building an AOSP ROM. I hate the samsung modifications. I just want pure android!
 

decaydance99

Well-known member
Jan 13, 2011
84
2
0
Visit site
Even though heimdall says it detects the device you still need to install the driver with zadig. Follow these steps:

Put your phone into download mode
Plug in usb
Open zadig
Go to options->list all devices
Select gadget serial in the drop down
Click install driver
When it says successful close zadig
unplug USB, then plug back in

After doing this now try. Let me know if this helps.

i have a problem. i already had the drives installed from my fascinate and windows 7 automatically installed the drivers for Stratosphere and it installed the gadget serial and said it was installed succssfully.
 

Forum statistics

Threads
942,111
Messages
6,912,515
Members
3,158,232
Latest member
andrewsmith