Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Rooted but su says "Permission denied"

Tags:

android

su

I have this "old" Lenovo A2107 tablet which I rooted years ago (using a download from http://androidforums.com/threads/a2107-root-mods-and-rom-discussion.661261/, tho running its root.bat script by hand from my GNU/Linux machine) and that worked fine.

Then I passed this tablet to my daughter for a couple years, and now I got it back.

/system/bin/su is still present, still the same date and size, still mode "rwsr-sr-x", still the same firmware (Android 4.0.3) so all looks fine, but when I try to run it from a shell, it just tells me "Permission denied".

Any idea what might be going on? What I could try to do to track it down?

like image 245
Stefan Avatar asked Sep 02 '15 12:09

Stefan


2 Answers

Nowadays Magisk is commonly used for rooting.

I've found that on my Oneplus 5 (Oxygen OS, Nougat) it was sufficient to go to Magisk Manager app, open superuser permissions screen and toggle Shell (com.android.shell) to resolve the adb su permission denied problem.

like image 178
Vadzim Avatar answered Sep 17 '22 14:09

Vadzim


FWIW... I had a similar problem ( running 'su' from ADB shell yielded 'permission denied' ), so I'll describe my solution.

For context, I had rebrained my Galaxy Nexus with CyanogenMod.

So, I looked at the system settings, and it contains a 'Superuser' section; in that section's own settings ( small menu ), there is a 'Superuser Access' option, which was set to 'Apps only'. I changed that to 'Apps and ADB', and then I was able to start an ADB shell, and from that shell, I was now allowed to run 'su'. :-)

like image 27
bernz Avatar answered Sep 19 '22 14:09

bernz