Root on 4.3 dev discussion - Xperia Z1 Original Android Development

Edit 2:
Kernels with recoveries:
Unlocked bootloader required for any of these:
CWM by @lzyllp http://forum.xda-developers.com/showpost.php?p=48599313&postcount=48
TWRP by @Desperanto86 http://forum.xda-developers.com/showpost.php?p=48600227&postcount=60
Philz by me: http://mohammadag.xceleo.org/public/Android/XperiaZ1/Philz_4.3_kernel.img
These kernels have Sony RIC disabled at boot, so /system is always writable.
After flashing with fastboot flash boot filename.img, boot intro recovery and flash this:
SuperSU zip http://download.chainfire.eu/supersu
Edit: Discussion moot, root works fine as per below
Proof: Xperia Flip Settings on 4.3:
{
"lightbox_close": "Close",
"lightbox_next": "Next",
"lightbox_previous": "Previous",
"lightbox_error": "The requested content cannot be loaded. Please try again later.",
"lightbox_start_slideshow": "Start slideshow",
"lightbox_stop_slideshow": "Stop slideshow",
"lightbox_full_screen": "Full screen",
"lightbox_thumbnails": "Thumbnails",
"lightbox_download": "Download",
"lightbox_share": "Share",
"lightbox_zoom": "Zoom",
"lightbox_new_window": "New window",
"lightbox_toggle_sidebar": "Toggle sidebar"
}
As most of you know, rooting 4.3 isn't fully possible. While su and Superuser.apk can be installed through recovery, /system can't be mounted.
Code:
[email protected]:/ # mount -o rw,remount /system
mount: Operation not permitted
A fix for that is to disable Sony's RIC kernel implementation.
Code:
[email protected]:/system # echo 0 > /sys/kernel/security/sony_ric/enable
[email protected]:/system # mount -o rw,remount /system
[email protected]:/system #
This is enabled on boot in init.sony-platform.rc:
Code:
# Enable Sony RIC
mount securityfs securityfs /sys/kernel/security nosuid nodev noexec
write /sys/kernel/security/sony_ric/enable 1
After all this is done, /system is writable:
Code:
[email protected]:/system # echo 123 > test
[email protected]:/system # cat test
123
However, I still can't figure out why Xposed won't install, which is making me wonder if this all worked or not.
Edit: Xposed works fine as per http://forum.xda-developers.com/showpost.php?p=48484642&postcount=6846
Xposed installs fine, it just doesn't work:
Code:
[email protected]:~/Downloads$ adb -d logcat | grep Xposed
D/Xposed ( 355): Starting Xposed binary version 47, compiled for SDK 16
D/Xposed ( 355): Phone: C6903 (Sony), Android version 4.3 (SDK 18)
D/Xposed ( 355): ROM: 14.2.A.0.290
I/Xposed ( 355): -----------------
I/Xposed ( 355): Found new Xposed jar version, activating it
I/Xposed ( 355): Added Xposed (/data/data/de.robv.android.xposed.installer/bin/XposedBridge.jar) to CLASSPATH.
D/AndroidRuntime( 355): >>>>>> AndroidRuntime START de.robv.android.xposed.XposedBridge <<<<<<
D/Xposed ( 355): Using structure member offsets for mode WITH_JIT
I/Xposed ( 355): Found Xposed class 'de/robv/android/xposed/XposedBridge', now initializing
I/Xposed ( 355): -----------------
I/Xposed ( 355): Dec 17, 2013 5:01:53 PM UTC
I/Xposed ( 355): Loading Xposed v42 (for Zygote)...
I/Xposed ( 355): Errors during Xposed initialization
I/Xposed ( 355): java.lang.NoSuchMethodError: android.app.ActivityThread#getTopLevelResources(java.lang.String,int,android.content.res.Configuration,android.content.res.CompatibilityInfo)#exact

Hi !
I have Xposed install when i was on 4.2 but lost root since update to 4.3
Can you detail how you get root acces step by step ?
You lost me at RIC Kernel...
Thanks !

TeamR said:
Hi !
I have Xposed install when i was on 4.2 but lost root since update to 4.3
Can you detail how you get root acces step by step ?
You lost me at RIC Kernel...
Thanks !
Click to expand...
Click to collapse
This is only useful to devs right now, someone needs to add a startup script that echos 0 into the sysfile above into some ROM.
Basically, you'll need an unlocked BL to install SuperSU, then issue the command above to make /system writable. A custom ROM can do that in some init script, since the file above is in ramdisk (which is part of kernel package). When that's done, installing Xposed will be as simple as tapping Install.

Please send me the kernel file after all those modifications. Thanks in advance.

MohammadAG said:
This is only useful to devs right now, someone needs to add a startup script that echos 0 into the sysfile above into some ROM.
Basically, you'll need an unlocked BL to install SuperSU, then issue the command above to make /system writable. A custom ROM can do that in some init script, since the file above is in ramdisk (which is part of kernel package). When that's done, installing Xposed will be as simple as tapping Install.
Click to expand...
Click to collapse
You can just execute the commands from terminal emulator and then add a script to init.rc... I try now and if it works i give you a flashable .zip

Understand !
But i'm not a good dev !
In fact, if i want root, i can unlock my bootloader since camera was not broken any more, then install a recovery and flash Supersu...
Was right or did i make a mistake ?

See, I told you @DooMLoRD, it is the ric again... But now they moved it into the kernel
Will setting that sys control to 0 work on locked bootloader as well?

TeamR said:
Understand !
But i'm not a good dev !
In fact, if i want root, i can unlock my bootloader since camera was not broken any more, then install a recovery and flash Supersu...
Was right or did i make a mistake ?
Click to expand...
Click to collapse
How do you install recovery without root?

gregbradley said:
How do you install recovery without root?
Click to expand...
Click to collapse
True ! Ok, one facepalm for me
So i'll be waiting for DooMLoorD Kernel update...
And maybe it will include a port of his double tap feature from xperia z !

gregbradley said:
How do you install recovery without root?
Click to expand...
Click to collapse
From kernel, if is UB...

CappyT said:
From kernel, if is UB...
Click to expand...
Click to collapse
Are you sure...still waiting to see this stock kernel with recovery working...

gregbradley said:
Are you sure...still waiting to see this stock kernel with recovery working...
Click to expand...
Click to collapse
Well, I don't know if is simple as modding the stock one and adding recovery and root... On other devices it works like that...
I just wait for a boot.img to flash and I unlock the BL, since i have the TA backup...

CappyT said:
Well, I don't know if is simple as modding the stock one and adding recovery and root... On other devices it works like that...
I just wait for a boot.img to flash and I unlock the BL, since i have the TA backup...
Click to expand...
Click to collapse
That has been the issue
changing ro.secure=1 to ro.secure=0 has caused kernel failure at boot...

When i try this on LB with adb shell
Code:
[email protected]:/system # echo 0 > /sys/kernel/security/sony_ric/enable
[email protected]:/system # mount -o rw,remount /system
[email protected]:/system #
It tells me permission denied...

[Fenix] said:
When i try this on LB with adb shell
Code:
[email protected]:/system # echo 0 > /sys/kernel/security/sony_ric/enable
[email protected]:/system # mount -o rw,remount /system
[email protected]:/system #
It tells me permission denied...
Click to expand...
Click to collapse
Because you cannot write the kernel partition without Unlocked Bootloader (at least, I think)
gregbradley said:
That has been the issue
changing ro.secure=1 to ro.secure=0 has caused kernel failure at boot...
Click to expand...
Click to collapse
Well, that's not good... It happens only on stock kernel?

CappyT said:
Because you cannot write the kernel partition without Unlocked Bootloader (at least, I think)
Well, that's not good... It happens only on stock kernel?
Click to expand...
Click to collapse
Yes i think the same bro...thanks for the trick anyway :thumbup:
Inviato dal mio C6903 utilizzando Tapatalk

[Fenix] said:
Yes i think the same bro...thanks for the trick anyway :thumbup:
Inviato dal mio C6903 utilizzando Tapatalk
Click to expand...
Click to collapse
The thing i ask, going a bit OT is: how did you manage to install 4.3 with root? Because I can try to unlock BL (i have a TA backup) and try it to confirm this thing.

I'd rather @lzyllp shares the image instead of me, I didn't ask if I could share it, and I asked for it over PM.
Anyway, here's an image I made with Philz recovery, DO NOT FLASH THIS, it won't boot.
However, using it with fastboot boot file.img works, I have no idea why.
http://mohammadag.xceleo.org/public/Android/XperiaZ1/DO_NOT_FLASH_BOOT_ONLY.img

EDIT: found. Is on /

DAddYE said:
Awesome! Thanks, where is init.sony-platform.rc? Is it safe to disable RIC on boot?
Click to expand...
Click to collapse
Kernel image, ramdisk to be exact.
After boot it's in /, but it can't be edited from there since it's loaded from the ramdisk.

Related

[KERNEL/TUTORIAL] UPDATE 31/07 Howto mod the stock XXJVR/S/T kernel SU/Init.d Support

Well what do you do when you're bored and need some distraction .....Modify the stock kernel and include SU!
If you just search on the internet and especially on XDA than you find out that this is not so difficult.
The only purpose of this modified kernel is install SU and thus get ROOT
Why superuser and busybox are not installed by default is simple: it takes only 1 minute to download it from the market...
So here I give you the stock kernel + su/Root for XXJVQ/ XXJVR
installation:
1. Flash the tar file with Odin
2. Download superuser from the market and install it
3. Download Busybox installer from the market and install it
Credits to Supercurio, Hardcore, Liliniser for the tools and sources
Tutorial is Linux based!!!
So if i can do it than you can do it also!! All you have to do is read and follow post 2
Update 01/08/11 Added XXJVT
Update 01/08/11 Added Working XXJVR
Update 06/07/11 Howto add init.d support to the kernel (post 3)
Tutorial
1. Download and install the needed tools
2. extract de stock kernel to a temporary directory
3. modify the init.rc script to include your su install script.
4. add in the tmp folder busybox and su
5. add in the sbin directory your install script.
6. Recompile the kernel
7. Tar de kernel
8. Flash the kernel with heimdall or Odin
1. Download and install the needed tools
* Cross compiler: http://www.codesourcery.com/sgpp/li...eabi/arm-2009q3-67-arm-none-linux-gnueabi.bin and install it to /opt/toolchains/arm-2009q3/
* Kernel repacker made by Liliniser / dkcldark : Download from supercurio's github. with (if installed) git clone git://github.com/project-voodoo/kernel_repack_utils or goto the website https://github.com/project-voodoo/kernel_repack_utils and click on download.
* Download busybox,su and the install script from this post, and extract the files.
2. extract de stock kernel to a temporary directory
Copy the original zImage to de directory where you extracted the kernel repacker
Rename it to zImage.org
create a temp directory in the kernel repacker directory
Open a linux shell and go to kernel repacker directory
./extracter.sh -s zImage.org -d temp (hit enter)
3. modify the init.rc script to include your su install script.
Go to the temp directory and edit init.rc with your favourite editor and put this on a new line at the end off the file.
service install_su /sbin/install_su.sh
user root
oneshot
Save the file and exit
4. add in the tmp folder busybox and su
copy busybox and su to the tmp folder in your extracted kernel folder
make sure they are markt als executable.
5. add in the sbin directory your install script.
copy install_su.sh to the sbin folder in your extracted kernel folder
6. Recompile the kernel
Open a linux shell and go to kernel repacker directory
./repacker.sh -s zImage.org -d zImage -r temp -c gzip
congratulations you must cooked your first modified kernel
7. Tar de kernel
tar -H ustar -c zImage >code.tar
8. Flash the kernel with heimdall or Odin
Howto add init.d support to the stock kernel
Whell this is easy to implement
1. Open a linux shell and goto to the extracted kernel directory. (read post 2 howto do that)
add the following lines to the init.rc file
Code:
service initd_support /sbin/initd_support.sh
user root
oneshot
Save the file and exit
2. Create a new file in the sbin directory called initd_support.sh and add the following code
Code:
#!/tmp/busybox sh
if cd /system/etc/init.d >/dev/null 2>&1 ; then
for file in S* ; do
if ! ls "$file" >/dev/null 2>&1 ; then continue ; fi
/system/bin/sh "$file"
done
fi
Save the file and make it executable
3. repack the kernel (see post 2 for the howto)
4. on your device mount system Read/Writable and create the directory /system/etc/init.d
5. Copy your init scripts to /system/etc/init.d/
Make sure the name starts with a S, and set the permissions to 777
Example step 5/6
Code:
adb push Stweakscript /sdcard/
adb shell
su
/tmp/busybox mount -o remount,rw /system
/tmp/busybox mkdir /system/etc/init.d
/tmp/busybox cp /sdcard/Stweakscript /system/etc/init.d/Stweakscript
/tmp/busybox/chmod 777 /system/etc/init.d/Stweakscripts
7. flash the kernel
I'm sorry in advance.
But WTF?
vladoots said:
I'm sorry in advance.
But WTF?
Click to expand...
Click to collapse
If you only want to root your rom don't wait for devs to do it but do it your self
lownoise said:
If you only want to root your rom don't wait for devs to do it but do it your self
Click to expand...
Click to collapse
Yes, and for learning purposes. Thanks for the tips, I was sitting down to do this on another phone the other day actually... it's good to see your ideas, I was getting pretty frustrated with the limited Android init environment (the toolbox commands are so limited!).
Thanks for this nice tutorial.Worked great!
Great! Now we have good rooting kernel.
If I want root - I want root, not tweaks and other "shiny" things.
Cfroot breaks BT in some cases, Fuguroot breaks Kies connection.
Kernel which don't add Superuser.apk as a system application is the best choice - we don't have to delete other system files and there are updates of this app, so why should we have older version on /system and new on /data as an update?
Can I do "adb root" on this kernel ?
Sure Just install superuser and busybox from the market
Wooow! These are the sort of tutorials I miss here sooo much. It's a developer forum, but what we are getting here mainly are ready-products (roms, modded kernels). And why not to do it yourself. But sometimes googling for the information is not so easy, because applies to different conditions(devices, phone models, soft versions). There are many people who would spend their time learning how to compile a kernel or edit framework files. But there are so few tuts on this here... I miss tuts that tell how to do things step-by-step, without any specific linux/java knowledge.
sebarkh said:
Wooow! These are the sort of tutorials I miss here sooo much. It's a developer forum, but what we are getting here mainly are ready-products (roms, modded kernels). And why not to do it yourself. But sometimes googling for the information is not so easy, because applies to different conditions(devices, phone models, soft versions). There are many people who would spend their time learning how to compile a kernel or edit framework files. But there are so few tuts on this here... I miss tuts that tell how to do things step-by-step, without any specific linux/java knowledge.
Click to expand...
Click to collapse
And therefore I did it. Share the knowlegde and safe this forum
Why doesn't XDA have more stuff like this?
Thanks OP!
Yes, I must thank you too.
Now I understand... Sorry for my initial confusion!
I've problem:
after applying script:
line 47: ./out/project/original.cpio -> no such files or directory
Any idea ?
Where is original.cpio files ?
Screen of error:
{
"lightbox_close": "Close",
"lightbox_next": "Next",
"lightbox_previous": "Previous",
"lightbox_error": "The requested content cannot be loaded. Please try again later.",
"lightbox_start_slideshow": "Start slideshow",
"lightbox_stop_slideshow": "Stop slideshow",
"lightbox_full_screen": "Full screen",
"lightbox_thumbnails": "Thumbnails",
"lightbox_download": "Download",
"lightbox_share": "Share",
"lightbox_zoom": "Zoom",
"lightbox_new_window": "New window",
"lightbox_toggle_sidebar": "Toggle sidebar"
}
tq man...!!
man this is amazing, I was looking for something simple like this for months. It's right, should be more posts like these in xda
+1
Thank you very much for this, lownoise
We need more topics like that, since I am interested to learn myself...
Members posting tutorials like that are always appreciated, I cannot thank you enough.
Do you know how to replace the recovery 3e with 2e additionally?
It would be great to know since I want to have it CWM compatible (flash unsigned update.zip)
AFAIK recovery is a part of the kernel....
It would be great if you could point me to the right direction.
Others probably would like to know that as well.
Thanks again.
dago said:
I've problem:
after applying script:
line 47: ./out/project/original.cpio -> no such files or directory
Any idea ?
Where is original.cpio files ?
Screen of error:
Click to expand...
Click to collapse
Which kernel did you try to modify
lownoise said:
2. extract de stock kernel to a temporary directory
Copy the original zImage to de directory where you extracted the kernel repacker
Rename it to zImage.org
create a temp directory in the kernel repacker directory
Open a linux shell and go to kernel repacker directory
./extracter.sh -s zImage.org -d temp (hit enter)
Click to expand...
Click to collapse
Two noob questions:
1. from where to copy zImage file? Where can I find zImage file?
2. How to open linux shell? Should I install linux shell application on my PC and run it or?
Sorry for such questions but I want to try.
Thanks.

[ADDON][Xperia S] Generic startup/init.d scripts support for Stock ROM/Kernel

[ info ]
i am attaching a easy to run package which contains the files required for full functionality of executing startup scripts (init.d scripts)...
basically this will allow the user to execute custom shell scripts, placed in /system/etc/init.d/ folder and they will be executed on each boot!
i dont have this device yet!!
thanks to Jozinek for testing this on his phone!
[ requirements ]
stock rooted ROM
windows PC with adb drivers installed
[ how to install ]
download the provided zip package
save it on c:\
extract the contents of the package
connect phone with usb debugging active to PC via ADB
execute "runme.bat"
follow onscreen instructions & enjoy!
incase some issue is there post the output/log of script
[ additional info ]
i have added the following things in the package:
corrected /system/bin/sysint file
run-parts binary in /system/xbin/run-parts (which is basically busybox 1.19.3 binary)
correct /system/etc/install-recovery.sh file (this file gets executed by default on stock kernel too!)
test/example script /system/etc/init.d/99test
to check if this is working the test script (99test) will create a temporary file /data/local/tmp/init.d_log_test.txt on each boot
[ donations/device fund ]
i dont yet have this device but i plan to buy it.... if u guys want to donate to me to get this device OR if u feel that this work has helped u OR u think that the work i put into making this is worthy of donations, then click on the following link for buying me some coffee/beer/etc
i am currently channeling all my donations to get this phone asap and to avoid selling my ARC!!!
PAYPAL DONATION LINK
[ download link ]
generic-init.d-support-v01.zip
MD5HASH: 2eda273af4b91c34f868807820cceaee
let me know how it goes!
{
"lightbox_close": "Close",
"lightbox_next": "Next",
"lightbox_previous": "Previous",
"lightbox_error": "The requested content cannot be loaded. Please try again later.",
"lightbox_start_slideshow": "Start slideshow",
"lightbox_stop_slideshow": "Stop slideshow",
"lightbox_full_screen": "Full screen",
"lightbox_thumbnails": "Thumbnails",
"lightbox_download": "Download",
"lightbox_share": "Share",
"lightbox_zoom": "Zoom",
"lightbox_new_window": "New window",
"lightbox_toggle_sidebar": "Toggle sidebar"
}
ENJOY!
Nice work, this will enable the Speedy v7 int.d hacks, can you incorporate this in the above? As an addon perhaps.
Done, $50 "AU" dollars coming your way mate.
-smc
somemadcaaant said:
Nice work, this will enable the Speedy v7 int.d hacks, can you incorporate this in the above? As an addon perhaps.
Done, $50 "AU" dollars coming your way mate.
-smc
Click to expand...
Click to collapse
this init.d support can be used to execute ANY shell script/program at startup... u are free to choose the ones u want...
if anyone needs help on how to push the scripts onto device let me know... but script specific info i dont have, u will need to ask the developer of those scripts..
I used this script to move dalvik cache to /cache folder:
Code:
#!/system/bin/sh
#
# relocate dalvik-cache to /cache/dalvik-cache
if [ ! -d /cache/dalvik-cache ]
then
busybox rm -rf /cache/dalvik-cache /data/dalvik-cache
mkdir /cache/dalvik-cache /data/dalvik-cache
fi
busybox chown 1000:1000 /cache/dalvik-cache
busybox chmod 0771 /cache/dalvik-cache
# create symlink
busybox mount -o bind /cache/dalvik-cache /data/dalvik-cache
busybox chown 1000:1000 /data/dalvik-cache
busybox chmod 0771 /data/dalvik-cache
After reboot i saw folder /cache-dalvid in both folders /data and /cache, is it normal?
Thank!
I found that for devices rooted with locked bootloader
Line 21 of runme.bat need to change from
HTML:
@files\adb shell "su -c 'busybox mount -t ext4 -o rw,remount /system /system'"
to
HTML:
@files\adb shell "su -c 'busybox mount -o remount,rw /system'"
This is all great, exactly what I was looking for! But what about if the ROM already has a custom kernel that makes use of /etc/init.d? Do the /etc/init.d scripts get executed twice?
EDIT: in my phone this solution can't work. In the init.rc file the following lines are commented out
Code:
#service flash_recovery /system/etc/install-recovery.sh
# oneshot
Thanks, it's working but I have a question, how we can include this in a rom?
Please respond, I would appreciate that
DooMLoRD said:
run-parts binary in /system/xbin/run-parts (which is basically busybox 1.19.3 binary)
Click to expand...
Click to collapse
That means I don't need run-parts if I've busybox installed?
1-Tell me please if I understand: I've done everything the post says Doomlord ([ADDON] [Xperia S] Generic startup /init.d scripts support for Stock ROM / Kernel) my question is this, after this I can already install scripts from cwm?
2-I try installing ''NullVoid'' tweaK by cmw and apparently well was installed. (I say apparently because i do not know if it is working)
3-Another thing about Tweaks: These have to be installed every time the phone restarts? This tweaks are compatible with the stock ics rom? (With the Doomloard Method ?
DooMLoRD said:
........
[ additional info ]
i have added the following things in the package:
corrected /system/bin/sysint file
run-parts binary in /system/xbin/run-parts (which is basically busybox 1.19.3 binary)
correct /system/etc/install-recovery.sh file (this file gets executed by default on stock kernel too!)
test/example script /system/etc/init.d/99test
to check if this is working the test script (99test) will create a temporary file /data/local/tmp/init.d_log_test.txt on each boot
..........
Click to expand...
Click to collapse
So the "install-recovery.sh" file is executed by system by default and does not need to be executed manually from terminal or what else?
And about the file...that is not a one-run file...right? It is executed at every phone boot...right??
Thank you.
Sent from my GT-I9000 using xda app-developers app
AW: [ADDON][Xperia S] Generic startup/init.d scripts support for Stock ROM/Kernel
Sorry leaving footprint, to see this again after im home.
Gesendet von meinem LT26i mit Tapatalk 2
Hello,
Is this package valid for deodexed rom?
I'm on stock .55, bootloader locked.
Currently the folder /system/etc/init.d doesn't exists
Thank you
marvasten said:
Hello,
Is this package valid for deodexed rom?
I'm on stock .55, bootloader locked.
Currently the folder /system/etc/init.d doesn't exists
Thank you
Click to expand...
Click to collapse
it doesnt matter which ROM you are on... this should work on any ROM as long as the kernel ramdisk executes install-recovery.sh service...
dont worry it creates all required folders/files

[CWM-TWRP]Xperia S Dual Recovery for locked/unlocked bootloaders

Dual Recovery for locked-unlocked bootloaders. TWRP 2.6.3 - CWM 6.0.3 works together!​Warning 1 : I am not responsible for bricked phones..
Warning 2 : I am not user of Xperia S, so need testers for learn is it working... (working-confirmed)
Warning 3 : If you are using CM10 for locked bootloader, dont install this. It'll broke your initframs...
Warning 4 : If you have CWM(with chargemon hack) you may get problem. Do fresh install without recoveries...
How it works ?
-When booting your phone, BLUE led will appear.
--Volume UP enters TWRP 2.6.3
--Volume DOWN enters CWM 6.0.3
On CWM, " USB MOUNT STORAGE" works.
How to install :
Method 1)
Dual Recovery For Xperia S ( Installer Script )
Link : https://docs.google.com/uc?export=download&id=0Bw6g-VrksXLEdUdGVGc4aDFya3M
Requires : (JB-KK)
- rooted phone
- adb debug enabled
- busybox installed
- unknown sources enabled
and start
- download installer script from above.
- unzip it into a folder.
- there are batch files for windows users and also for linux users in both the zips.
- just execute the batch files and follow the messages if any.
Method 2)
Flashable Zip for Xperia S (only for TWRP flash, it wont work on CWM flashing.)
Link : https://docs.google.com/uc?export=download&id=0Bw6g-VrksXLESmlYa1JSamxJTWc
Method 3)
- Download Flashable Zip version (on method 2 part).
- Extract it and copy files to your sdcard.
- Manually copy files via explorers with root:
cwmrecovery.tar and recovery.tar ---to--- /system/bin (set permissions 755)
step2.sh and pre_hw_config.sh ---to--- /system/etc (set permissions 755)
-Reboot​
XDA:DevDB Information
[CWM-TWRP] Xperia S Dual Recovery for locked/unlocked bootloaders , a Tool/Utility for the Sony Xperia S
Contributors
Zorbeyd
Version Information
Status: Stable
Created 2014-02-03
Last Updated 2014-02-04
Thanks goes to : @letama , @djolivier , @ganeshbiyer , twrp team, cyanogenmod, fxp, @MrGezz , @DooMLoRD , crazy_doze
good work thanks:thumbup:
Sent from my LT26i using xda app-developers app
XSL user
Can I use this on my XSL ??
It's says while intalling in windows ....,what i do?
----------------------------------------------------------------------
CWM-based Recovery v6.0.3.0 / TWRP v2.6.3
by Zorbeyd
----------------------------------------------------------------------
Thanks to
CM, FreeXperia, djolivier cray_Doze, letama, MrGezz, ganeshbiyer
----------------------------------------------------------------------
[*]Requirements for PC:
(1) usb driver installed
[*]Requirements for mobile:
(1) rooted
(2) busybox installed
(3) Unknown Sources' enabled
(4) USB debugging' enabled
----------------------------------------------------------------------
----------------------------------------------------------------------
* Start installation.("ctrl-c" to stop process)
----------------------------------------------------------------------
Press any key to continue . . .
connect device
* daemon not running. starting it now on port 5037 *
* daemon started successfully *
35 KB/s (1695 bytes in 0.046s)
0 KB/s (801 bytes in 1.000s)
3 KB/s (3397 bytes in 1.000s)
4053 KB/s (1165484 bytes in 0.280s)
4057 KB/s (5314560 bytes in 1.279s)
3885 KB/s (3041280 bytes in 0.764s)
0 KB/s (578 bytes in 1.000s)
----------------------------------------------------------------------
An error has occurred in dualrecovery.sh. Stop processing.
Press any key to continue . . .
----------------------------------------------------------------
20140203 134233: busybox mount -o remount,rw /system
20140203 134233: RET=0
20140203 134233: cp /data/local/tmp/pre_hw_config.sh /system/etc
h
20140203 134233: RET=0
20140203 134233: chown root.shell /system/etc/pre_hw_config.sh
20140203 134233: RET=0
20140203 134233: chmod 755 /system/etc/pre_hw_config.sh
20140203 134233: RET=0
20140203 134233: cp /data/local/tmp/step2.sh /system/etc/step2.s
20140203 134233: RET=0
20140203 134233: chown root.shell /system/etc/step2.sh
Unable to chown /system/etc/step2.sh: No such file or directory
20140203 134233: RET=10
Press any key to continue . . .
it s awesome, thx
i make all this instruction and in the final said dual instaled y have ub with kernel doomlord but everytime i restart the phone with vol plus no touch recovery just normal included in kernel doomlord any help is apreciate thank u don t work dual bro
Deleted
---------- Post added at 04:42 PM ---------- Previous post was at 04:39 PM ----------
edwuard said:
i make all this instruction and in the final said dual instaled y have ub with kernel doomlord but everytime i restart the phone with vol plus no touch recovery just normal included in kernel doomlord any help is apreciate thank u don t work dual bro
Click to expand...
Click to collapse
If you have TWRP in your Kernel then it wont be replaced, as this is not kernel based. For that you need to flash stock kernel then use this mod. you will get Dual recovery.
Zorbeyd Can you add new cwm recovery 6.0.3.2 -Mod crazy_doze v2.5? .
On twrp usb mount storage works ?.
This is twrp recovery from this topic: [ http://forum.xda-developers.com/showthread.php?p=49014840 ? :what:
Wysłane z mojego LT26i przy użyciu Tapatalka
captain droid said:
deleted
---------- post added at 04:42 pm ---------- previous post was at 04:39 pm ----------
if you have twrp in your kernel then it wont be replaced, as this is not kernel based. For that you need to flash stock kernel then use this mod. You will get dual recovery.
Click to expand...
Click to collapse
doomlord kernel is stock withouwt twrp bro and as i say y have the old cwr not the new what is the problem to solve this i don t need to flash a kernel without recovery but this doomlord has the cwr not twrp any sugestion thank u
I added new installer script on first thread. Please try with it.
https://docs.google.com/uc?export=download&id=0Bw6g-VrksXLEdUdGVGc4aDFya3M
Thanks buddy for your hardwork!!!
I'll test it tonight
Gold_Phenix said:
Zorbeyd Can you add new cwm recovery 6.0.3.2 -Mod crazy_doze v2.5? .
On twrp usb mount storage works ?.
This is twrp recovery from this topic: [ http://forum.xda-developers.com/showthread.php?p=49014840 ? :what:
Wysłane z mojego LT26i przy użyciu Tapatalka
Click to expand...
Click to collapse
I'll look it.. And yes every specification must work.
rockernaxo said:
Thanks buddy for your hardwork!!!
I'll test it tonight
Click to expand...
Click to collapse
Thanks you my dear mate...
Zorbeyd said:
I added new installer script on first thread. Please try with it.
https://docs.google.com/uc?export=download&id=0Bw6g-VrksXLEdUdGVGc4aDFya3M
Click to expand...
Click to collapse
same thing bro when reboot it reboot in recovery of kernel doomlord nothing hapend thank u anyway i instal this batch file 10 times nothing just recovery from doomlord kernel i m going crazy
edwuard said:
same thing bro when reboot it reboot in recovery of kernel doomlord nothing hapend thank u anyway i instal this batch file 10 times nothing just recovery from doomlord kernel i m going crazy
Click to expand...
Click to collapse
Can you share logs?
If adb works on your pc, it must be there..
Locate : /data/local/tmp/dualrecovery.log
testing dual recovery
I installed the .bat, the installation was successful, but after reboot, only allows me to access CWM, I have rebooted 4 times, each pressing a different button, vol +, vol-, power, camera ... but only open CWM anyway, thanks for the hard work, I have locked bootloader, and if necessary, I try again with a new one .bat
milocj said:
I installed the .bat, the installation was successful, but after reboot, only allows me to access CWM, I have rebooted 4 times, each pressing a different button, vol +, vol-, power, camera ... but only open CWM anyway, thanks for the hard work, I have locked bootloader, and if necessary, I try again with a new one .bat
Click to expand...
Click to collapse
@milocj I tried flashing the initial version via cwm and it worked fine for my..I can acess twrp via vol+ and cwm via vol-..
Sent from my LT28h using XDA Premium 4 mobile app
Chocklety Boyee said:
@milocj I tried flashing the initial version via cwm and it worked fine for my..I can acess twrp via vol+ and cwm via vol-..
Sent from my LT28h using XDA Premium 4 mobile app
Click to expand...
Click to collapse
Thanks so much, i tried again
@milocj by DevSXSTEAM
milocj said:
I installed the .bat, the installation was successful, but after reboot, only allows me to access CWM, I have rebooted 4 times, each pressing a different button, vol +, vol-, power, camera ... but only open CWM anyway, thanks for the hard work, I have locked bootloader, and if necessary, I try again with a new one .bat
Click to expand...
Click to collapse
Hello milocj
Can you share /data/local/tmp/dualrecovery.log ?
One question: u are flash zip for TWRP?
@milocj by DevSXSTEAM
---------- Post added at 07:02 PM ---------- Previous post was at 07:00 PM ----------
Zorbeyd said:
Hello milocj
Can you share /data/local/tmp/dualrecovery.log ?
Click to expand...
Click to collapse
Yes
{
"lightbox_close": "Close",
"lightbox_next": "Next",
"lightbox_previous": "Previous",
"lightbox_error": "The requested content cannot be loaded. Please try again later.",
"lightbox_start_slideshow": "Start slideshow",
"lightbox_stop_slideshow": "Stop slideshow",
"lightbox_full_screen": "Full screen",
"lightbox_thumbnails": "Thumbnails",
"lightbox_download": "Download",
"lightbox_share": "Share",
"lightbox_zoom": "Zoom",
"lightbox_new_window": "New window",
"lightbox_toggle_sidebar": "Toggle sidebar"
}
@milocj by DevSXSTEAM

[DEPRECATED][GUIDE][ROOT] Smartwatch 3 KNX01V

I removed download link due to this method not working on lollipop.
This guide is deprecated, please use TWRP Recovery from this thread to install root
DISCLAMER and WARNING: I'm not responsible for bricked devices, dead SD cards, thermonuclear war, or the current economic crisis. Please do some research if you have any concerns about this app.
Click to expand...
Click to collapse
You have been warned!
Links:
Sony PC Companion
Download link removed while I will test for compatibility with 5.x, md5 summ: e2c34b07faa415a6cbb95943649c7eba
Step 1:
Code:
[URL="source.android.com/source/building-devices.html#unlocking-the-bootloader"]Unlocked bootloader[/URL]
1. Enable adb debug
2. adb reboot bootloader
3. fastboot oem unlock (twice if requested)
4. fastboot format cache
5. fastboot format userdata
6. fastboot getvar all (and verify that it is)
7. fastboot reboot
Step 2:
Code:
Updated to the latest KNX01V
[URL="http://www.sonymobile.com/us/tools/pc-companion/"]Install Sony PC Companion[/URL] and use Supports Zone -> Accessories software update -> Smartwatch 3
Step 3:
Code:
Have Flashboot (Sony s1 flash) drivers installed just in case (Install Sony PC Companion and do update as indicated in previous step)
Step 4:
Code:
[COLOR="red"]BOOT [/COLOR][COLOR="Red"](DO NOT EVER FLASH IT!!!)[/COLOR] rooting boot.img
1. Download rooting kernel image (SWR50-rootboot.img)
2. Reboot into bootloader (adb reboot bootloader)
3. fastboot boot SWR50-rootboot.img
4. Wait till device reboots or sits in black screen for a while (1 min+ then reboot it by holding power 10+sec)
Step 5:
Code:
Verify by:
1. adb shell
2. su
3. you should see [email protected]:/ #
Step 6:
Code:
1. Let me know!
2. Use it, dive into GPS investigation or customizations, etc.....
Special thanks:
1. Justin Case for LG G Watch rooting method using LGGW-rootboot.img
2. osm0sis for Android Image Kitchen
{
"lightbox_close": "Close",
"lightbox_next": "Next",
"lightbox_previous": "Previous",
"lightbox_error": "The requested content cannot be loaded. Please try again later.",
"lightbox_start_slideshow": "Start slideshow",
"lightbox_stop_slideshow": "Stop slideshow",
"lightbox_full_screen": "Full screen",
"lightbox_thumbnails": "Thumbnails",
"lightbox_download": "Download",
"lightbox_share": "Share",
"lightbox_zoom": "Zoom",
"lightbox_new_window": "New window",
"lightbox_toggle_sidebar": "Toggle sidebar"
}
reserved
How it works:
1. Each boot.img packs zImage (real kernel) and ramdisk (special files for kernel use)
2. This one has all modifications from LGGW rootboot by Justin Case:
a. Adds su binary, superuser.sh install script, modified install-recovery.sh and additional step into init.rc file to invoke superuser.sh install script. Also modifications to mount system as rw and some disabled security.
3. So basically it mount system as rw and does following (cut from superuser.sh install script):
Code:
#!/system/bin/sh
/system/bin/mount -o remount,rw /system
/system/bin/sleep 2
/system/bin/cat /sbin/su > /system/xbin/su
/system/bin/cat /sbin/su > /system/xbin/daemonsu
/system/bin/cat /sbin/install-recovery.sh > /system/etc/install-recovery.sh
/system/bin/chown 0.0 /system/xbin/su
/system/bin/chown 0.0 /system/xbin/daemonsu
/system/bin/chown 0.0 /system/etc/install-recovery.sh
/system/bin/chmod 06755 /system/xbin/su
/system/bin/chmod 06755 /system/xbin/daemonsu
/system/bin/chmod 755 /system/etc/install-recovery.sh
/system/bin/sync
/system/bin/sleep 3
/system/bin/reboot
I have dumped the rom from my debug/test version and was wondering if you were able to give me a guide on how i could try and flash it with a retail version? I presume this root guide probably won't work for me
Well, if hardware and partitions are the same - I do not see why it will not work. However, it will not help to flash.
I might try to compile twrp, but will have to carefully read its docs first.
thanks @XorZone confirmed as working and a nice easy process too (I was already unlocked).
Out of curiosity, modded LGGW rootboot or just renamed?
iBuzman said:
thanks @XorZone confirmed as working and a nice easy process too (I was already unlocked).
Out of curiosity, modded LGGW rootboot or just renamed?
Click to expand...
Click to collapse
Thanks for letting me know!
I reverse engineered changes in LGGW by unpacking and comparing ramdisks from both rootboot and original lg kernel and then applied the same changes to our kernel extracted from PC Companion files.
great thinking and good job ?
btw, that pic confirmed su access to watch over bluetooth debug connection ?
really great tutorial. I am planning to buy this watch, but I think currently there is NO app that requires Root. so I wonder how can we get benefit of this ?
Kurotsuchi said:
really great tutorial. I am planning to buy this watch, but I think currently there is NO app that requires Root. so I wonder how can we get benefit of this ?
Click to expand...
Click to collapse
There is at least Wear Control app: https://play.google.com/store/apps/details?id=octathorp.wearcontrol
I plan to code density changer that will require access to adb, so either from rooted phone or rooted wear.
Kurotsuchi said:
really great tutorial. I am planning to buy this watch, but I think currently there is NO app that requires Root. so I wonder how can we get benefit of this ?
Click to expand...
Click to collapse
how to benefit?
root apps of course!!
(sry for bad pic, unlocked bootloader z3 in low light [emoji12]
XorZone said:
There is at least Wear Control app: https://play.google.com/store/apps/details?id=octathorp.wearcontrol
I plan to code density changer that will require access to adb, so either from rooted phone or rooted wear.
Click to expand...
Click to collapse
that's awesome man! will purchase mine next week, can't wait to root it. thanks for the answer.
Thanks for the root, XorZone. For anyone wondering, here's the dmesg of the watch
A few small observations from digging:
The main chipset seems to be the BCM23550
The CPU has 4 cores, 2 are disabled in software. Should be easy enough to reenable if you please
It definitely has WiFi hardware, but the firmware is currently missing from the image. If you mange to get a hold of compatible firmware and nvram, it should be simple enough to get WiFi up and running
The WiFi firmware message mentions a "43341". Which is odd because apparently the main chipset does have WiFi support built in. Searching for a Broadcom 43341 gives you this, but this might just be a red herring.
cb22 said:
Thanks for the root, XorZone. For anyone wondering, here's the dmesg of the watch
A few small observations from digging:
The main chipset seems to be the BCM23550
The CPU has 4 cores, 2 are disabled in software. Should be easy enough to reenable if you please
It definitely has WiFi hardware, but the firmware is currently missing from the image. If you mange to get a hold of compatible firmware and nvram, it should be simple enough to get WiFi up and running
The WiFi firmware message mentions a "43341". Which is odd because apparently the main chipset does have WiFi support built in. Searching for a Broadcom 43341 gives you this, but this might just be a red herring.
Click to expand...
Click to collapse
Yeah, I noticed the same about WiFi chip, it might be that they packed bcm43341 as part of the BCM23550 soc, like Invensense MPU9250 chip packs mpu6500 inside.
For the 43341 I'm finding it in the configs here: https://android.googlesource.com/kernel/tegra/+/bdde9f16131a5ac2039062d5ce22e3e153acbe68^!/
Looks like BCM43341 is BCM4334 + NFC chip, so we could try S3 I9300 files as per http://redmine.replicant.us/projects/replicant/wiki/GalaxyS3I9300Firmwares
how can i grant superuser permission to an app? i install es file explorer with sideload but i can't get superuser permission. the procedure is ok
Sorry admins for not putting in correct location....
Moved to Correct Area!
cdrshm said:
Sorry admins for not putting in correct location....
I can not get my device to show up in adb devices and its driving me crazy. Tried windows 7/8/server 2012R2 ..lol
Now I have done my fair share of custom roms and bootloaders.
OG Droid
Nexus
Nexus 10
Asus Memo Pad (came from alarm company, and could only load one app...now its a full running tablet)
I am sure its a silly thing I have done or am missing...
Thoughts....ideas?..need more info?
Click to expand...
Click to collapse
As usual, check if adb enabled in settings-about-developer options, if there are no developer options - it is as usual 7 times click on build number in about screen.
And please use Q&A thread for such questions
I've confirmed root survives the Lollipop update
Wow, I was out whole weekend, will have to catch up with the update

How to Root | Degoogle (enable Sig Spoofing) on Galaxy S20FE (Qualcomm)

{
"lightbox_close": "Close",
"lightbox_next": "Next",
"lightbox_previous": "Previous",
"lightbox_error": "The requested content cannot be loaded. Please try again later.",
"lightbox_start_slideshow": "Start slideshow",
"lightbox_stop_slideshow": "Stop slideshow",
"lightbox_full_screen": "Full screen",
"lightbox_thumbnails": "Thumbnails",
"lightbox_download": "Download",
"lightbox_share": "Share",
"lightbox_zoom": "Zoom",
"lightbox_new_window": "New window",
"lightbox_toggle_sidebar": "Toggle sidebar"
}
Hello Guys/Girls/Non-Binary this should just be some Tutorial because I didn't find a lot about this on xda.
I have Twrp installed check out this thread on how to do it: TWRP FOR S20 FE EXYNOS
TWRP KEY COMBO: Power + VolUP
I will give you the download-link of the right version of the Twrp if you have the SM-G780G because i feel no one has it and searching comments is kinda bothering.
Twrp for SM-G780G (dunno if it works on others but should) is in attached Files on This Post.
This Version of Twrp has a small "bug" or a kinda non see able feature because it doesn't give you a GUI thing for enable Write-Rights in "/system_root" if you are a n00b don't worry explain later.
First of all you need adb and linux is kinda good because i don't know on how to do some zip things in Windows (and it kinda sucks anyway but don't cry )
So the real tutorial starts here (you HAVE TWRP and a boootable system right now) if not check the link i gave you.
First of all you root the phone (You can skip this step if you don't want root rights):
Download Magisk-Zip : Magisk Zip
Connect the Phone and your PC and put the magisk.zip on your phone. -> In Twrp go to install -> Click Magisk.zip.
Wait and some mad voodo magic from your Lord and Savior topjohnwu: https://forum.xda-developers.com/m/topjohnwu.4470081/
appears and you're rooted.
So this is the more complicated part of the tutorial (because we only have android 11 on this phone we need to kinda manually deodex you're services.jar I did a tutorial on that here:
Sig Spoofing on Android 11
You can use the exact same steps!!
short description: download haystack11-attempt, dexpatcher, the zip you need to rename, - pull and deodex your services.jar - flash the zip in Magisk!!
After that boot in system install fdroid (put the apk from your PC to the phone install via Samsung-files or some other app) download signature-spoof checker from fdroid and give the permission if that works youre good to go.
Go in Magisk -> Reboot to Recovery (Or Reboot in Twrp with Key-Combo)
Now we are debloating (the de-bloat in /system_root is necessary the pm uninstall commands and i will add them later forgot to write down and I'am always high(so i forgot them) also they are optional) for real you could de-bloat a lot more here but I doesn't wanna ruin camera app and things real Samsung boys will know what i talk about. but if you have better de-bloating options go and comment!
System_root de-bloat necessary:
adb shell
# Samsung ****
rm /system_root/system/app/ARZone/ARZone.apk
rm /system_root/system/app/BixbyWakeup/BixbyWakeup.apk
rm /system_root/system/app/FBAppManager_NS/FBAppManager_NS.apk
rm /system_root/system/app/Facebook_stub/Facebook_stub.apk
rm /system_root/system/app/YouTube/YouTube.apk
rm /system_root/system/priv-app/Bixby/Bixby.apk
rm /system_root/system/priv-app/BixbyAgentStub/BixbyAgentStub.apk
rm /system_root/system/priv-app/BixbyService/BixbyService.apk
rm /system_root/system/priv-app/GalaxyAppsWidget_Phone_Dream/GalaxyAppsWidget_Phone_Dream.apk
rm /system_root/system/priv-app/GalaxyApps_OPEN/GalaxyApps_OPEN.apk
rm /system_root/system/priv-app/GameHome/GameHome.apk
rm /system_root/system/priv-app/FBInstaller_NS/FBInstaller_NS.apk
rm /system_root/system/priv-app/FBServices/FBServices.apk
rm /system_root/system/priv-app/EasySetup/EasySetup.apk
rm /system_root/system/priv-app/OneDrive_Samsung_v3/OneDrive_Samsung_v3.apk
rm /system_root/system/priv-app/Tips/Tips.apk # stupid Samsung Tips popups
rm /system_root/system/priv-app/DeXonPC/DeXonPC.apk
rm /system_root/system/priv-app/CocktailBarService_v3.2/CocktailBarService_v3.2.apk # Edge panel top right floats
# Google ****
rm /system_root/system/app/Chrome/Chrome.apk
rm /system_root/system/app/ChromeCustomizations/ChromeCustomizations.apk
rm /system_root/system/app/Gmail2/Gmail2.apk
rm /system_root/system/app/GoogleCalendarSyncAdapter/GoogleCalendarSyncAdapter.apk
rm /system_root/system/app/GoogleContactsSyncAdapter/GoogleContactsSyncAdapter.apk
rm /system_root/system/app/GoogleLocationHistory/GoogleLocationHistory.apk
rm /system_root/system/priv-app/SetupWizard/SetupWizard.apk # Without removal never passes initial setup
# Stuff replaced by MicroG aka NSA eyes
rm /system_root/system/priv-app/GmsCore/GmsCore.apk
rm /system_root/system/priv-app/GoogleServicesFramework/GoogleServicesFramework.apk
rm /system_root/system/priv-app/Phonesky/Phonesky.apk
rm /system_root/system/priv-app/Velvet/Velvet.apk
In Twrp -> Mount System
Now open Terminal on Your PC (in use of ADB) and try to do one of the delete commands in /system_root if you're getting a rights error don't worry I explain how you get it working.
The command is:
mount -o rw,remount /system_root
Go try a delete command in /system_root again. everything should be fine now.
Go through all the de-bloat commands after that download the microG flash-able zip of your linking here: (Or use Nanolux)
https://github.com/FriendlyNeighborhoodShane/MinMicroG_releases/releases/tag/2021.04.28
Put it on your phone and flash it throuh twrp.
Boot and Boom OneUI 3.1 with MicroG and low bloat this Exynos now runs like a beast.
Sorry this my second post on this thread so don't kill me for my bad English or some dumb mistakes!
Credits to all the beautiful guys on xda! This stuff would never happen without those Legends!!
Exynos is SM-G780F any owners of the G i.e. the snapdragon 4G version following your link will have a bad time.
3mel said:
Exynos is SM-G780F any owners of the G i.e. the snapdragon 4G version following your link will have a bad time.
Click to expand...
Click to collapse
My Tutorial says Exynos only like 3 Times
Hello. So happy to see some posts like these about s20 fe Exynos version. Really appreciate your work. Im more than a noob, i can't follow all these steps as they are a bit complicated as i used to root and install twrp, custom roms on my beloved Galaxy S5! But yeah pleasing to see the forum moving abit
Kingslayer9988 said:
My Tutorial says Exynos only like 3 Times
Click to expand...
Click to collapse
not everyone who might want root knows about SoCs.
it wasn't a dig at you.
Hello, How to do safetynet, I tried universal fix riru and it does not work And a few other ways
pepcio03 said:
Hello, How to do safetynet, I tried universal fix riru and it does not work And a few other ways
Click to expand...
Click to collapse
You can't pass safetnet with microg installed, it has been an issue for a while
SafetyNet API · Issue #181 · microg/GmsCore
As of version 0.37 Pokemon Go uses GMS's safetynet feature and I for one can't get past login. What is the implementation status on safetynet, is this out of scope for microg?
github.com
If you want to pass safetynet you'll have to remove microg and reinstall google play services to able to pass it.
Hello, does this microG degoogle work with the S 20 FE Snapdragon
(G781B/DS) ?​

Categories

Resources