*************************************************************
106SH Root Instructions for Build S0020

* For Build S0026, the procedure is the same with only one change.
* Where we use the file "isw16sh_unlock" for Build S0020, now use the file "106SH_unlock".
*************************************************************



IMPORTANT
・ You assume all responsibility for performing the below operations. 

PREREQUISITES
・ ADB on your computer
・ Sharp ADB driver installed 

FILES YOU NEED (INCLUDED IN PACKAGE):

1. "isw16sh_hijack_jni" - a tool by goroh_kun to move the shell script to system and set the privileges.

2. "mkdevshkit" created by goroh_kun as weel.

3. "isw16shroot" created by Mr. 71 from the 2CH forums thread on ISW16SH root.

* For easy access, these files have been put inside the 106SH folder, which you should unpack directly in C:\ on your PC.

4. From the 106SH, download and install Superuser and BusyBox from Google Play. Do not run them yet, they will not work.


ROOT PROCEDURE

1. Enable USB debugging on the phone: Settings > Developer options > Other > USB debugging.
2. Also tick the "Stay awake" ("Do not go into sleep mode") option.
3. Connect the 106SH to your PC using a USB cable.
4. Execute the below commands from the command prompt on the PC ("Win key" + "R", type "cmd").
5. NOTE: Each line is a separate command. To execute it, press ENTER.


cd C:\106sh\isw16sh_hijack_jni
adb restore isw16sh.ab

* Press OK on the 106SH screen

adb shell
cd /data/data/com.android.settings/
rm a/file*

while : ; do ln -s /data/data/com.android.settings/lib/libsdservice_jni.so a/file99; done

* The above process will continue indefinitely. This is not a failure.
* Open a new command prompt window without closing the first one. Execute the following:

cd C:\106sh\isw16sh_hijack_jni
adb shell
adb restore isw16sh.ab

* Press OK on the 106SH screen
* When the restore process is complete, you can close the two windows.
* Now open a new command prompt window and execute:

cd C:\106sh\isw16sh_hijack_jni
adb shell
adb push onload.sh /data/local/tmp/onload.sh

* On the 106SH, go to Settings > microSD & phone storage > Select 'Unmount microSD'. Do not press any of the buttons (OK or CANCEL), just wait. It is OK if the app force closes with error.

* From the command prompt:

exit
cd C:\106sh\mkdevshkit
adb shell
adb push mkdevsh /data/local/tmp/mkdevsh
adb push onload.sh /data/local/tmp/onload.sh


* On the 106SH, go to Settings > microSD & phone storage > Select 'Unmount microSD'. Do not press any of the buttons (OK or CANCEL), just wait. It is OK if the app force closes with error.

* From the command prompt:

exit
adb shell
/dev/sh

* If temporary root has been successfully acquired at this stage, the cursor will change from $ to #.
* From the command prompt, proceed to acquiring permanent root:

exit
exit
cd C:\106sh\isw16shroot
adb shell

adb push mkdevsh /data/local/tmp/mkdevsh
adb shell chmod 777 /data/local/tmp/mkdevsh
adb push su /data/local/tmp/su
adb shell chmod 777 /data/local/tmp/su


* On the 106SH, go to Settings > microSD & phone storage > Select 'Unmount microSD'. Do not press any of the buttons (OK or CANCEL), just wait. It is OK if the app force closes with error.

* From the command prompt:

adb push isw16sh_unlock /data/local/tmp/isw16sh_unlock
adb shell chmod 755 /data/local/tmp/isw16sh_unlock
/dev/su
/data/local/tmp/isw16sh_unlock

* A bit of text will be displayed. Continue:

/dev/su
sync;sync;sync
mount -o remount,rw -t ext4 /dev/block/mmcblk0p12 /system
dd if=/data/local/tmp/su of=/system/bin/su
chown root.shell /system/bin/su
chmod 06755 /system/bin/su
sync;sync;sync
mount -o remount,ro -t ext4 /dev/block/mmcblk0p12 /system
reboot

* After restarting, the rooting procedure should be completed.
* Run the Superuser app from the phone to grant permission.

adb shell
su
/data/local/tmp/isw16sh_unlock
mount -o remount,rw -t ext4 /dev/block/mmcblk0p12 /system
ln -s /system/bin/su
mount -o remount,ro -t ext4 /dev/block/mmcblk0p12 /system

* Now start BusyBox.

/dev/su
sync;sync;sync
mount -o remount,rw -t ext4 /dev/block/mmcblk0p12 /system
dd if=/data/local/tmp/su of=/system/bin/su
chown root.shell /system/bin/su
chmod 06755 /system/bin/su
sync;sync;sync
mount -o remount,ro -t ext4 /dev/block/mmcblk0p12 /system
reboot

* This should be it. Your 106SH should noow have permanent root!



SOURCE: http://t-f-android.hatenablog.com/entry/2013/06/06/230424
ENGLISH TRANSLATION: Cheeseus, 13.02.2014