I have an un-rooted device, with Android 5.0 system, and the core is ARM Coretex A53.
I happen to found "adb root" works, that means I can play as root through ADB shell.
I successfully deleted a trash apk, renowned "kingroot", from my system.
Then, I try to manually update su and SuperSu file, through the bellowing commands:
# mount -o rw,remount /system
# cp /sdcard/mrw/su /system/xbin/su
# cp /sdcard/mrw/su /system/bin/su
# pm install /sdcard/mrw/superuser.apk
(I'm using a 2.46 SuperSu version, which should be OK for Android 5.0 system)
But it fails. The SuperSu told me " su binary not installed".
My questions:
1. Is this a feasible way to update Su and SuperSu, and get root access?
2. There's a bunch of architect, I tried both "arm" and "arm64", but none of the su binary can work. Which architect shall I choose, when I'm running on a ARM Coretex A53 core? ( I know it is a 64bit core)
Thanks a lot, and Best Regards,
towenyu
Did you get this device secondhand? Also what device is it, since many have their own root method because of OEM crap.
That said, you only need su in one location, either /system/xbin/su or /system/bin/su (I typically see it in /system/xbin/su). I'm not sure what happens if it's in both, but it's just wasted space.
You can try these commands through adb root; since you already were able to get su onto your device, it may be just a matter of ownership and permissions:
Code:
# mount -o rw,remount /system
# chmod 755 /system/xbin/su
# chown root:root /system/xbin/su
# mount -o ro,remount /system
chown 755 sets the permissions to rwxr-xr-x (user gets read/write/execute, group/other gets read/execute). Execute is the important bit here, since otherwise the su binary can't do its job. After those commands, try SuperSU again and see if it works (you might need a reboot, because of how Android 5.0+ handles changes to /system) The last mount -o ro command just changes /system back to read-only, to prevent accidental changes to other parts.
Successfully rooted!
Not that simple, but basically follow the update-binary script already inside supersu package.
Only need to made slight modification due to my system won't support "unzip"
Now that you're successfully rooted, go install Busybox, that'll give you a lot of Linux commands Android doesn't have by default, including unzip.
xfullmetal17 said:
Now that you're successfully rooted, go install Busybox, that'll give you a lot of Linux commands Android doesn't have by default, including unzip.
Click to expand...
Click to collapse
Thanks for your advice! I will try it.
But don't there's already a Busybox in android system? I guess what I need to do is find somewhere a more powerful busybox binary -- or build it by my own, but that may be not so easy for me.
Android has some basic Linux commands support, but I don't think it has Busybox (if you have a custom ROM you may have some additional commands, but since you said unrooted I don't think it was installed.
This is one of the most popular installers for Busybox: https://play.google.com/store/apps/details?id=stericson.busybox
I've used it since I first rooted with Android 2.2 and haven't had any issues with it (save for lack of vim, since stock Android doesn't have the correct libraries for it)
rooting my htc m9 running marshmallow
Hi, I'm totally blind, and twrp isn't an option for me since it doesn't have a built in screen reader. I would like to install supersu to system, would some one kindly help me in telling me what files to put where. I think the m9 is arm64, but besides su and supersu.apk, I think there's installrecovery.ssh and some other files that have to go in, so please help some one
xfullmetal17 said:
Android has some basic Linux commands support, but I don't think it has Busybox (if you have a custom ROM you may have some additional commands, but since you said unrooted I don't think it was installed.
This is one of the most popular installers for Busybox: https://play.google.com/store/apps/details?id=stericson.busybox
I've used it since I first rooted with Android 2.2 and haven't had any issues with it (save for lack of vim, since stock Android doesn't have the correct libraries for it)
Click to expand...
Click to collapse
Hi guys ,
it is possible to run manualy via adb shell update-binary file from META-INF supersu folder for install it ? (means before unpacked folder supersu is copied to ex. /tmp)
I'm asking bcose no custom recovery and no root on my device yet.
Thx
nalas said:
Hi guys ,
it is possible to run manualy via adb shell update-binary file from META-INF supersu folder for install it ? (means before unpacked folder supersu is copied to ex. /tmp)
I'm asking bcose no custom recovery and no root on my device yet.
Thx
Click to expand...
Click to collapse
I have same saturation, no TWRP, no SU installed on my device: [email protected]_cn:/ #, Android M,
What I have is a userdebug boot.img support "adb root", so my draft commands in my mind please run one by one, not batch.. WARNING, this may make your system bootloop,take your own risk!!!.)
fastboot flash boot boot_userdebug.img
fastboot reboot
adb wait-for-device
adb root
adb remount
adb disable-verity
adb shell setenforce 0
adb reboot
cd D:\tools\Downloads\SR3-SuperSU-v2.82-SR3-20170813133244\arm64
adb wait-for-device
adb root
adb remount
adb shell setenforce 0
adb push .\su /system/bin/su
adb push .\su /system/xbin/su
adb shell chmod 06755 /system/bin/su
adb shell chmod 06755 /system/xbin/su
adb shell /system/bin/su --install
adb shell /system/bin/su --daemon&
adb install ..\common\Superuser.apk
adb shell setenforce 0
adb disable-verity
if you found SuperSU not found root, try adb shell setenforce 0 again.
then you can get SuperSU found su file need to update, use normal way to do it.
then, it will be "Installation success !"
Enjoy it.
so reference log:
D:\tools\Downloads\SR3-SuperSU-v2.82-SR3-20170813133244\arm64>adb push su /system/bin/su
adb: error: failed to copy 'su' to '/system/bin/su': Read-only file system
D:\tools\Downloads\SR3-SuperSU-v2.82-SR3-20170813133244\arm64>adb root
D:\tools\Downloads\SR3-SuperSU-v2.82-SR3-20170813133244\arm64>adb push su /system/bin/su
adb: error: failed to copy 'su' to '/system/bin/su': Read-only file system
D:\tools\Downloads\SR3-SuperSU-v2.82-SR3-20170813133244\arm64>adb remount
remount succeeded
D:\tools\Downloads\SR3-SuperSU-v2.82-SR3-20170813133244\arm64>adb push su /system/bin/su
[100%] /system/bin/su
D:\tools\Downloads\SR3-SuperSU-v2.82-SR3-20170813133244\arm64>adb push su /system/xbin/su
adb: error: failed to copy 'su' to '/system/xbin/su': Read-only file system
D:\tools\Downloads\SR3-SuperSU-v2.82-SR3-20170813133244\arm64>adb shell
[email protected]_cn:/ # su
[email protected]_cn:/ # cd /system/bin
[email protected]_cn:/system/bin # chmod 06755 su
chmod: chmod 'su' to 106755: Read-only file system
1|[email protected]_cn:/system/bin # ls su
su
[email protected]_cn:/system/bin # ls -al su
-rwxr-xr-x root shell 108496 2008-02-29 03:33 su
[email protected]_cn:/system/bin # su --intall
[email protected]_cn:/system/bin # su --daemon&
[1] 6146
[email protected]_cn:/system/bin # getenforce
Enforcing
[1] + Done su --daemon
[email protected]_cn:/system/bin # setenforce 0
[email protected]_cn:/system/bin # getenforce
Permissive
[email protected]_cn:/system/bin # exit
[email protected]_cn:/system/bin # exit
[email protected]_cn:/ # exit
/system/bin/su
exit
^C
Azlun said:
I have same saturation, no TWRP, no SU installed on my device: [email protected]_cn:/ #, Android M,
What I have is a userdebug boot.img support "adb root", so my draft commands in my mind please run one by one, not batch.. WARNING, this may make your system bootloop,take your own risk!!!.)
fastboot flash boot boot_userdebug.img
fastboot reboot
adb wait-for-device
adb root
adb remount
adb disable-verity
adb shell setenforce 0
adb reboot
cd D:\tools\Downloads\SR3-SuperSU-v2.82-SR3-20170813133244\arm64
adb wait-for-device
adb root
adb remount
adb shell setenforce 0
adb push .\su /system/bin/su
adb push .\su /system/xbin/su
adb shell chmod 06755 /system/bin/su
adb shell chmod 06755 /system/xbin/su
adb shell /system/bin/su --install
adb shell /system/bin/su --daemon&
adb install ..\common\Superuser.apk
adb shell setenforce 0
adb disable-verity
if you found SuperSU not found root, try adb shell setenforce 0 again.
then you can get SuperSU found su file need to update, use normal way to do it.
then, it will be "Installation success !"
Enjoy it.
so reference log:
D:\tools\Downloads\SR3-SuperSU-v2.82-SR3-20170813133244\arm64>adb push su /system/bin/su
adb: error: failed to copy 'su' to '/system/bin/su': Read-only file system
D:\tools\Downloads\SR3-SuperSU-v2.82-SR3-20170813133244\arm64>adb root
D:\tools\Downloads\SR3-SuperSU-v2.82-SR3-20170813133244\arm64>adb push su /system/bin/su
adb: error: failed to copy 'su' to '/system/bin/su': Read-only file system
D:\tools\Downloads\SR3-SuperSU-v2.82-SR3-20170813133244\arm64>adb remount
remount succeeded
D:\tools\Downloads\SR3-SuperSU-v2.82-SR3-20170813133244\arm64>adb push su /system/bin/su
[100%] /system/bin/su
D:\tools\Downloads\SR3-SuperSU-v2.82-SR3-20170813133244\arm64>adb push su /system/xbin/su
adb: error: failed to copy 'su' to '/system/xbin/su': Read-only file system
D:\tools\Downloads\SR3-SuperSU-v2.82-SR3-20170813133244\arm64>adb shell
[email protected]_cn:/ # su
[email protected]_cn:/ # cd /system/bin
[email protected]_cn:/system/bin # chmod 06755 su
chmod: chmod 'su' to 106755: Read-only file system
1|[email protected]_cn:/system/bin # ls su
su
[email protected]_cn:/system/bin # ls -al su
-rwxr-xr-x root shell 108496 2008-02-29 03:33 su
[email protected]_cn:/system/bin # su --intall
[email protected]_cn:/system/bin # su --daemon&
[1] 6146
[email protected]_cn:/system/bin # getenforce
Enforcing
[1] + Done su --daemon
[email protected]_cn:/system/bin # setenforce 0
[email protected]_cn:/system/bin # getenforce
Permissive
[email protected]_cn:/system/bin # exit
[email protected]_cn:/system/bin # exit
[email protected]_cn:/ # exit
/system/bin/su
exit
^C
Click to expand...
Click to collapse
Thank You - I will check and give feedback
Can I somehow just copy su and supersu files to phone (stock ROM) with full root shell to get root? Unfortunately bootloader is locked and only root shell is available.
user4978023 said:
Can I somehow just copy su and supersu files to phone (stock ROM) with full root shell to get root? Unfortunately bootloader is locked and only root shell is available.
Click to expand...
Click to collapse
Of course not. If it were that easy rooting would be a non-issue for devices with a locked bootloader.
towenyu said:
Successfully rooted!
Not that simple, but basically follow the update-binary script already inside supersu package.
Only need to made slight modification due to my system won't support "unzip"
Click to expand...
Click to collapse
Can you give more details ?
I'm in a similar situation (/system/bin/su and /system/xbin/su "updated" from Supersu zip , root access from adb shell , rom built as userdebug) but I'm unable to launch the update-binary through adb to get the TV fully rooted..
Related
it has already been said multiple time su has to be chmod 4755
but is as also to have these credentials: root.shell
mine was root.root so as a shell user you get an "access denied."
so a chmod root.shell /system/bin helps
after you need to re-chmod 4755 has it's loosing +s.
Also, if you pushed su to /data/local/bin, do this:
rm /data/local/bin/su
Because normal shell looks in /data/local/bin BEFORE /system/bin. It's part of the path.
thanx
my terminal now works as root
I've removed "m7" and "su" from /data/local/bin after root thanks to coolbits.
This guide is for people who want root but want to keep their stock rom, not breaking the warranty, unlocking bootloader etc.
A proud ubuntu user, I am writing this in a new thread purely because the manual rageagainstthecage method and SuperOneClick method did not not work for me, see link to my conclusion below if you care
http://forum.xda-developers.com/showpost.php?p=11305312&postcount=2526
What did work however was via adb shell using psneuter and its fairly simple if you follow the following commands.
This guide assumes you know how to get access to the shell via adb, if you dont then search elsewhere for a useful guide
OK lets get to business!
1. Download the attached nexus_one_softroot.tar from the bottom of this post and extract contents to the same folder as adb
2. Open up your terminal, cd to the same folder as adb and the extracted files
3. Enter the following commands:
Code:
sudo ./adb push psneuter /data/local/tmp/psneuter
sudo ./adb push busybox /data/local/tmp/busybox
sudo ./adb push su /data/local/tmp/su
sudo ./adb shell chmod 755 /data/local/tmp/psneuter
sudo ./adb shell chmod 755 /data/local/tmp/busybox
sudo ./adb shell chmod 755 /data/local/tmp/su
sudo ./adb shell
After this you should see only a $ which tells us that we at the android command line with user privileges only, lets continue
Code:
$ cd /data/local/tmp
$ ls
busybox
su
psneuter
$ ./psneuter
property service neutered.
killing adbd. (should restart in a second or two)
You will now be kicked out of android shell, lets go back in
Code:
sudo ./adb shell
After this you should see only a # which tells us that we root baby! If you want to double check issue this command
Code:
# id
uid=0(root) gid=0(root)
Lets continue on. From this point we will install busybox and su which will make root permanent
Code:
# mount -o remount,rw -t yaffs2 /dev/block/mtdblock3 /system
# cd /data/local/tmp
# ./busybox cp busybox /system/bin
# chmod 4755 /system/bin/busybox
# busybox cp su /system/bin
# chmod 4755 /system/bin/su
# exit
For some reason I sometimes have to enter exit twice to leave the android shell. Again, re-access the android shell
Code:
sudo ./adb shell
Now in the android shell we can finish up
Code:
# su
# mount -o remount,ro -t yaffs2 /dev/block/mtdblock3 /system
# exit
# exit
Lastly we must install Superuser, and I did this from the android market so I knew its the latest version, its simple to get, less command input etc.
Now you have root! I hope this was simple enough to follow, I have not really written a guide before but from lots of searching I just could not find a solution for my Nexus One 2.2.1 FRG83D, especially any guide that uses psneuter.
Anyway, glad to contribute
EDIT - also, being new to starting threads, this may not quite be in the right section of the forum, sorry if thats the case mods
Added link to the thread from Wiki.
upgraded to gingerbread 2.3.3. after copying and setting permissions, got this:
PHP:
$ cd /data/local/tmp
$ ls -l
-rwxr-xr-x shell shell 26248 2010-07-22 10:20 su
-rwxr-xr-x shell shell 1062992 2010-10-16 22:29 busybox
-rwxr-xr-x shell shell 585731 2011-01-08 18:02 psneuter
su
busybox
psneuter
$ ./psneuter
Failed to set prot mask (Inappropriate ioctl for device)
second time threw me out of shell. again adb shell gives this:
PHP:
$ id
uid=2000(shell) gid=2000(shell) groups=1003(graphics),1004(input),1007(log),1009(mount),1011(adb),1015(sdcard_rw),3001(net_bt_admin),3002(net_bt),3003(inet)
mfkr said:
upgraded to gingerbread 2.3.3. after copying and setting permissions, got this:
Code:
$ ./psneuter
Failed to set prot mask (Inappropriate ioctl for device)
Click to expand...
Click to collapse
I believe this is due to a change in the kernel as it is upgraded into gingerbread, the input/output controls have changed, leaving psneuter out of date with the current kernel.
However if an exploit is found with the kernel used in 2.3.3, you can use it in place of psneuter with the above method.
Hi.
I've tried many times to root my LG2X with Z4root, UniversalAndRoot, Visionary and SuperOneClick since I've bought it but it failed each time.
I've seen the [Root] topic in the developpement thread but I can't post there (less than 10 posts...) but I want to help someone to root his/her mobile.
I've searched a long time a good way to do so without SuperOneClick (which doesn't respond with Windows Seven or Ubuntu 11.04) but there is none.
There we go...
Disclaimer : I can't be responsible if you break your phone, cancel your warranty or launch your LG2X on the wall in rage.
If you want, there is already SuperOneClick which run smoothly for many geeks : LG2X SuperOneClick Forum and SuperOneClick Forum
My HTC Magic had been rooted with the command line and I've tried myself to do so with every bit of informations and tips I could find on Internet.
I recommand to test the SuperOneClick method and if it fails, come test this with a Linux terminal (psneuter, su-v2, busybox and the SuperUser.apk can be found in the SuperOneClick archive) :
Code:
adb push psneuter /data/local/tmp
adb push su-v2 /data/local/tmp
adb push busybox /data/local/tmp
adb shell
$ busybox chmod +x /data/local/tmp/psneuter
$ /data/local/tmp/psneuter
adb remount
adb shell
# busybox mv /data/local/tmp/su-v2 /system/xbin/su
# busybox chmod 6755 /system/xbin/su
# busybox chown 0.0 /system/xbin/su
# busybox cp /system/xbin/su /system/bin/su
# busybox chown 0.2000 /system/bin/su
# busybox cp /data/local/tmp/busybox /system/xbin
# busybox chmod 0755 /system/xbin/busybox
# busybox chown 0.2000 /system/xbin/busybox
# exit
adb install Superuser.apk
adb reboot
And... Normally you have permanent root on your LG2X.
You can check the files permissions with
Code:
ls -l /system/xbin/su /system/bin/su
-rwsr-sr-x root root 26264 2011-04-23 20:07 su
-rwsr-sr-x root shell 26264 2011-04-23 23:20 su
It seems that /system/xbin/su isn't necessary at all. The su command which gave you the root is the one in /system/bin/. And I had some problems with /system/xbin, I've deleted the folder (with rm /system/xbin or mv /system/xbin /dev/null, I can't recall) and applied mkdir on it again.
If this can be of help, I'll update this later.
thanks for the detailed instructions, but super one click definitely works with win7 (64bit too) as long as you have the right drivers installed
Thanks but with Windows Seven 64 bits, Linux ou Windows Seven 32 bits with Virtualbox I end up with "SuperOneClick doesn't respond" or stuck on with "chmod psneuter" (with the drivers properly installed).
It's only an alternative solution if SuperOneClick doesn't run properly for another guy.
Thanks a lot for that tips.
The problem I have now is that su isn't persistant.
When I use
$ su
It hangs up few seconds... and says "Permission denied"
I've used su-v2
Here are the su permission :
-rwsr-sr-x root shell 26324 2011-02-13 14:43 su
Is there a more up-to-date su, that will maybe fix the problem ?
Thanks.
EDIT :
Ok.
The wait time seems to come from SuperUser, I've removed it.
Now I have directly the "permission denied", and "stat failed with 2: No such file or directory" in the logcat.
Maybe that can help.
Hannes The Hun said:
thanks for the detailed instructions, but super one click definitely works with win7 (64bit too) as long as you have the right drivers installed
Click to expand...
Click to collapse
It didn't for me (after installing nightly 51)
With the step-by-step instructions I get "Failed to set prot mask (inappropriate ioctl for device)" when trying to execute psneuter.
Hi.
Sorry for the wait.
Have you resolved your problem with your rooting?
Has anybody worked out how to create a Genymotion Xposed testing device?
What I've already achieved:
- Grant Root access to Xposed
- Flash ARM zip
The problem is: Genymotion runs on x86, not ARM. So flashing the ARM zip just breaks the VM.
But flashing the x86 zip just gives the Error "Failed to flash file".
(Yes, I'm using Genyflash)
I also tried it with and without arm translation, no changes.
I simply have no idea what else I could try. Is it currently possible at all?
LM13 said:
Has anybody worked out how to create a Genymotion Xposed testing device?
What I've already achieved:
- Grant Root access to Xposed
- Flash ARM zip
The problem is: Genymotion runs on x86, not ARM. So flashing the ARM zip just breaks the VM.
But flashing the x86 zip just gives the Error "Failed to flash file".
(Yes, I'm using Genyflash)
I also tried it with and without arm translation, no changes.
I simply have no idea what else I could try. Is it currently possible at all?
Click to expand...
Click to collapse
I found that the flash-script.sh inside the xposed-v78-sdk23-x86.zip file is somehow not successfully executed by Genymotion. I've manually patched it.
getting root on Marshmallow
Hi,
How did You get root on Marshmallow?
Sergiusz
sbrzezin said:
Hi,
How did You get root on Marshmallow?
Sergiusz
Click to expand...
Click to collapse
Yes, the latest Genymotion version already come with rooted MM image
itandy said:
Yes, the latest Genymotion version already come with rooted MM image
Click to expand...
Click to collapse
I installed Custom Phone and Google Nexus 7 and none of them has root. Should I do any special setup or did I install wrong device? I use Genymotion 2.6.0 free version.
Sergiusz
sbrzezin said:
I installed Custom Phone and Google Nexus 7 and none of them has root. Should I do any special setup or did I install wrong device? I use Genymotion 2.6.0 free version.
Sergiusz
Click to expand...
Click to collapse
The ROM should be rooted already. su command is available and when you use ADB, it's already a rooted shell.
itandy said:
The ROM should be rooted already. su command is available and when you use ADB, it's already a rooted shell.
Click to expand...
Click to collapse
I got answer from Genymotion team:
"I just got an update from the Dev Team : it appears that in 6.0 the SuperUser Android App hasn't been yet implemented.
This feature will be implemented in the future, and I have linked your request to the task.
When it will be completed and released, you will be automatically notified."
Sergiusz
sbrzezin said:
I got answer from Genymotion team:
"I just got an update from the Dev Team : it appears that in 6.0 the SuperUser Android App hasn't been yet implemented.
This feature will be implemented in the future, and I have linked your request to the task.
When it will be completed and released, you will be automatically notified."
Sergiusz
Click to expand...
Click to collapse
So I managed to make some progress on this. I got the latest v84 xposed working in the newest Genymotion 2.6.0 with a Nexus 5X image by doing the following:
Code:
git clone https://github.com/rovo89/GenyFlash
cd GenyFlash && ./install.sh
adb push xposed-v84-sdk23-x86.zip /sdcard
adb shell flash-archive.sh /sdcard/xposed-v84-sdk23-x86.zip
Reboot Genymotion VM and then drag XposedInstaller_3.0_alpha4.apk to Genymotion vm...profit!
As stated above, the Genymotion images are rooted but a lot of root apps ask for permission and the prompt to grant/deny root wasn't working for me rendering the apps limited in use. I downloaded the newest SuperSU BETA, at the time of this post, BETA-SuperSU-v2.71-20160331103524. I extracted it and then issues the following commands from terminal:
Code:
adb shell mount -o remount,rw /system
adb install common/Superuser.apk
adb push x86/su /system/bin/su
adb shell chmod 0755 /system/bin/su
adb push x86/su /system/xbin/su
adb shell chmod 0755 /system/xbin/su
adb shell su --install
adb shell "su --daemon&"
adb shell setenforce 0
adb shell mount -o remount,ro /system
The problem was issuing the "su" commands resulted in: "error: only position independent executables (PIE) are supported." Countless time spent google searching didn't turn up any leads, but then I happened to notice in the x86/su directory a file called su.pie...pie = position independent executable derp. So I reran the following:
Code:
adb shell mount -o remount,rw /system
adb push x86/su.pie /system/bin/su
adb shell chmod 0755 /system/bin/su
adb push x86/su.pie /system/xbin/su
adb shell chmod 0755 /system/xbin/su
adb shell su --install
adb shell "su --daemon&"
adb shell setenforce 0
adb shell mount -o remount,ro /system
Rebooted my Genymotion vm and BAM root access prompts!!!!! Hope this helps others and good luck.
Worked for me
123SIT said:
So I managed to make some progress on this. I got the latest v84 xposed working in the newest Genymotion 2.6.0 with a Nexus 5X image by doing the following:
Code:
git clone https://github.com/rovo89/GenyFlash
cd GenyFlash && ./install.sh
adb push xposed-v84-sdk23-x86.zip /sdcard
adb shell flash-archive.sh /sdcard/xposed-v84-sdk23-x86.zip
Reboot Genymotion VM and then drag XposedInstaller_3.0_alpha4.apk to Genymotion vm...profit!
As stated above, the Genymotion images are rooted but a lot of root apps ask for permission and the prompt to grant/deny root wasn't working for me rendering the apps limited in use. I downloaded the newest SuperSU BETA, at the time of this post, BETA-SuperSU-v2.71-20160331103524. I extracted it and then issues the following commands from terminal:
Code:
adb shell mount -o remount,rw /system
adb install common/Superuser.apk
adb push x86/su /system/bin/su
adb shell chmod 0755 /system/bin/su
adb push x86/su /system/xbin/su
adb shell chmod 0755 /system/xbin/su
adb shell su --install
adb shell "su --daemon&"
adb shell setenforce 0
adb shell mount -o remount,ro /system
The problem was issuing the "su" commands resulted in: "error: only position independent executables (PIE) are supported." Countless time spent google searching didn't turn up any leads, but then I happened to notice in the x86/su directory a file called su.pie...pie = position independent executable derp. So I reran the following:
Code:
adb shell mount -o remount,rw /system
adb push x86/su.pie /system/bin/su
adb shell chmod 0755 /system/bin/su
adb push x86/su.pie /system/xbin/su
adb shell chmod 0755 /system/xbin/su
adb shell su --install
adb shell "su --daemon&"
adb shell setenforce 0
adb shell mount -o remount,ro /system
Rebooted my Genymotion vm and BAM root access prompts!!!!! Hope this helps others and good luck.
Click to expand...
Click to collapse
Worked for me on the Google Nexus 9 API 23
gamerkcw123 said:
Worked for me on the Google Nexus 9 API 23
Click to expand...
Click to collapse
Hell yeah! I was beginning to think I was the only one who wanted this...and then there were two lol
123SIT said:
Hell yeah! I was beginning to think I was the only one who wanted this...and then there were two lol
Click to expand...
Click to collapse
the Supersu.apk still won't update the su binary. Do you know of a way to get that to work? If not I don't care I have supersu granting root. LOL
gamerkcw123 said:
the Supersu.apk still won't update the su binary. Do you know of a way to get that to work? If not I don't care I have supersu granting root. LOL
Click to expand...
Click to collapse
If I remember correctly I have that same issue but if you use the newest supersu zip you should be able to update it manually via the provided steps.
I think GenyFlash shouldn't be needed anymore... just drag and drop the x86 zip and the installer APK on the Genymotion window and reboot. The only thing that isn't working are the reboot buttons in the installer.
123SIT said:
If I remember correctly I have that same issue but if you use the newest supersu zip you should be able to update it manually via the provided steps.
Click to expand...
Click to collapse
I got it to work. This is what I did. I fallowed your steps to get SuperSU working, and granting
apps permission. Then I removed the APK and installed the APK from the 2.46 update. Then I updated SuperSU.apk from the play store. Success the binary updated successfully.
Step 1: fallowed your steps with the Bata.
Step 2: once I confirmed superSU is working, I remove the APK.
Step 3: I use the SuperSU APK in the 2.46 update.
Step 4: I use adb to push the APK in the 2.46 update to /system/app, and chmod it to 755.
Step 5: I reboot and go to the play store and update SuperSU.
Success!!!!!!!
this was again on the Genymotion Google Nexus 9 6.0 API.
rovo89 said:
I think GenyFlash shouldn't be needed anymore... just drag and drop the x86 zip and the installer APK on the Genymotion window and reboot. The only thing that isn't working are the reboot buttons in the installer.
Click to expand...
Click to collapse
You know, I don't think I ever actually tried it without. May have saved me some time lol
123SIT said:
So I managed to make some progress on this. I got the latest v84 xposed working in the newest Genymotion 2.6.0 with a Nexus 5X image by doing the following:
Code:
git clone https://github.com/rovo89/GenyFlash
cd GenyFlash && ./install.sh
adb push xposed-v84-sdk23-x86.zip /sdcard
adb shell flash-archive.sh /sdcard/xposed-v84-sdk23-x86.zip
Reboot Genymotion VM and then drag XposedInstaller_3.0_alpha4.apk to Genymotion vm...profit!
As stated above, the Genymotion images are rooted but a lot of root apps ask for permission and the prompt to grant/deny root wasn't working for me rendering the apps limited in use. I downloaded the newest SuperSU BETA, at the time of this post, BETA-SuperSU-v2.71-20160331103524. I extracted it and then issues the following commands from terminal:
Code:
adb shell mount -o remount,rw /system
adb install common/Superuser.apk
adb push x86/su /system/bin/su
adb shell chmod 0755 /system/bin/su
adb push x86/su /system/xbin/su
adb shell chmod 0755 /system/xbin/su
adb shell su --install
adb shell "su --daemon&"
adb shell setenforce 0
adb shell mount -o remount,ro /system
The problem was issuing the "su" commands resulted in: "error: only position independent executables (PIE) are supported." Countless time spent google searching didn't turn up any leads, but then I happened to notice in the x86/su directory a file called su.pie...pie = position independent executable derp. So I reran the following:
Code:
adb shell mount -o remount,rw /system
adb push x86/su.pie /system/bin/su
adb shell chmod 0755 /system/bin/su
adb push x86/su.pie /system/xbin/su
adb shell chmod 0755 /system/xbin/su
adb shell su --install
adb shell "su --daemon&"
adb shell setenforce 0
adb shell mount -o remount,ro /system
Rebooted my Genymotion vm and BAM root access prompts!!!!! Hope this helps others and good luck.
Click to expand...
Click to collapse
It's worked on Galaxy S6 6.0.0 API23, Genymotion 2.7.2! Thanks you so much!
I tried to perform a manual installation of SuperSU (2.82 SR5) on my Raspberry Pi running the developer version of AndroidThings 1.0.4, which is based on Android 8.1.0 / API 27. Rather than flashing the zip in recovery, as I'm not sure where to start with that on the Things platform, I manually pushed files and set file permissions and contexts via adb shell. My guide for this was the summary at the top of the script at SuperSU/META-INF/com/google/android/update-binary.
The new su binary appears to work for the most part. I can execute su and read/write with the interactive shell. However, when I attempt to execute the same operations as a command through su (ie: su -c mkdir /system/testdirectory), it responds saying its a read-only filesystem. The filesystem has been remounted with adb remount. I'm unable to perform the remount with the mount command, as /system is not listed in /proc/filesystems. From my understanding, this is due to some recent security model changes in Android. That being said, after the adb remount, all other normal interactions with the filesystem seem to work without issue. I have verified that selinux is in permissive mode.
I don't have busybox installed. These efforts are to allow for installation of busybox for other projects.
Does anybody know whats causing the commands proxied through su to not work correctly?
Here are the commands I used to perform my manual installation.
Code:
cd ~/Downloads/SuperSU-2.82-SR5
adb connect [IP_ADDRESS]:5555
adb root
adb remount
adb push common/install-recovery.sh /system/etc/install-recovery.sh
adb shell chmod 0755 /system/etc/install-recovery.sh
adb shell chcon u:object_r:toolbox_exec:s0 /system/etc/install-recovery.sh
adb shell ln -s /system/etc/install-recovery.sh /system/bin/install-recovery.sh
adb shell chcon -h u:object_r:toolbox_exec:s0 /system/bin/install-recovery.sh
cd armv7
# adding as `su_next` to prevent any issues before dropping it in
adb push su /system/xbin/su_next
adb shell chmod 0755 /system/xbin/su_next
adb shell chcon u:object_r:system_file:s0 /system/xbin/su_next
adb push su /system/xbin/daemonsu
adb shell chmod 0755 /system/xbin/daemonsu
adb shell chcon u:object_r:system_file:s0 /system/xbin/daemonsu
adb push supolicy /system/xbin/supolicy
adb shell chmod 0755 /system/xbin/supolicy
adb shell chcon u:object_r:system_file:s0 /system/xbin/supolicy
adb push libsupol.so /system/lib/libsupol.so
adb shell chmod 0644 /system/lib/libsupol.so
adb shell chcon u:object_r:system_file:s0 /system/lib/libsupol.so
adb shell cp /system/bin/app_process32 /system/bin/app_process32_original
adb shell cp /system/bin/app_process32 /system/bin/app_process_init
adb shell rm /system/bin/app_process
adb shell ln -s /system/xbin/daemonsu /system/bin/app_process
adb shell rm /system/bin/app_process32
adb shell ln -s /system/xbin/daemonsu /system/bin/app_process32
adb shell chmod 0755 /system/bin/app_process
adb shell chmod 0755 /system/bin/app_process32
adb shell chcon u:object_r:system_file:s0 /system/bin/app_process
adb shell chcon u:object_r:zygote_exec:s0 /system/bin/app_process32
# Swapping new su binary in
adb shell cp /system/xbin/su /system/xbin/su_original
adb shell rm /system/xbin/su
adb shell mv /system/xbin/su_next /system/xbin/su
adb shell /system/xbin/su --install
adb reboot
I need to correct myself: the new su binary can only read with privileges. It cannot write at all. I am only able to write either as the adb root shell, or with the stock su binary. I noticed that the device's adbd process relaunches with its own privileged context passed to it when adb remount is run. (adbd --root_seclabel=u:r:su:s0)
If I've run adb root and adb remount, adb shell, and then enter the su binary, I lose the ability to write to the remounted filesystem. So it appears that there is something wrong with the new su binary and its related files.
Anyway, this isn't critical to my project, so I'm abandoning my efforts for now. If anyone has any ideas on what is wrong here, I'd love to hear them and give this another shot!