- Feb 14, 2016
- 35
- 20
Hi,
I'm struggling to make "adb root" work without success... I know this was working in MIUI 7, but with 8 no way. My device is Xiaomi Redmi Note 2, 7.4.13.
So what I do:
# adb kill-server
# adb root
# adb shell
shell@hermes:/ $ id
id
uid=2000(shell) gid=2000(shell) groups=1003(graphics),1004(input),1007(log),1011(adb),1015(sdcard_rw),1028(sdcard_r),3001(net_bt_admin),3002(net_bt),3003(inet),3006(net_bw_stats) context=u:r:shell:s0
So the problem is that this should say uid=0(root) and not 2000(shell).
I know it's not the drivers, because I tried the same on Cyanogen Mod 12.1. There you have an option in Developer Options, which is called "Root access". This option allows starting adbd as root so that adb works. Once enabled "adb root" works as expected - adb shell will be started as root.
Note that SuperSU works for me as expected. So if I 'su' within 'adb shell' I get root (after acknowledging permission). That's not what I want, though. Without a working "adb root" you can't do adb push and other stuff that requires adbd running as root.
Additional info:
- before I found that when doing "adb root" my device was disappearing - i.e. it was not showing in adb devices... it seems that this is fixed by "USB debugging (Security settings)" in Developer Options. I enabled this in the hope adbd will be started as root, but to no awail.
I'd very much appreciate if someone (some developer) could explain how to get "adb root" to work.
Best regards,
Samo
I'm struggling to make "adb root" work without success... I know this was working in MIUI 7, but with 8 no way. My device is Xiaomi Redmi Note 2, 7.4.13.
So what I do:
# adb kill-server
# adb root
# adb shell
shell@hermes:/ $ id
id
uid=2000(shell) gid=2000(shell) groups=1003(graphics),1004(input),1007(log),1011(adb),1015(sdcard_rw),1028(sdcard_r),3001(net_bt_admin),3002(net_bt),3003(inet),3006(net_bw_stats) context=u:r:shell:s0
So the problem is that this should say uid=0(root) and not 2000(shell).
I know it's not the drivers, because I tried the same on Cyanogen Mod 12.1. There you have an option in Developer Options, which is called "Root access". This option allows starting adbd as root so that adb works. Once enabled "adb root" works as expected - adb shell will be started as root.
Note that SuperSU works for me as expected. So if I 'su' within 'adb shell' I get root (after acknowledging permission). That's not what I want, though. Without a working "adb root" you can't do adb push and other stuff that requires adbd running as root.
Additional info:
- before I found that when doing "adb root" my device was disappearing - i.e. it was not showing in adb devices... it seems that this is fixed by "USB debugging (Security settings)" in Developer Options. I enabled this in the hope adbd will be started as root, but to no awail.
I'd very much appreciate if someone (some developer) could explain how to get "adb root" to work.
Best regards,
Samo