Search code examples
androidshelladb

Adb shell gives root acess instead of shell access


I am trying to connect to my Android 6.0 Arm V7a emulator, I have updated sdk and system image to the latest version. When I'm trying to get shell access through adb shell, what I get is root access prompt # instead of ordinary shell $.

what I get:

root@generic:/ #
whoami
root

what I need is:

shell@generic:/ $
whoami
shell

How can i fix that? I have to say that I tried adb unroot command and it did not work.


Solution

  • Run su shell. More information regarding the su command here: http://man7.org/linux/man-pages/man1/su.1.html