Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Unable to disable com.android.systemui on rooted Nexus 9

I've got root access on my Nexus 9 running 5.1.1. I've tried running

adb shell
su
pm disable com.android.systemui

but after the disable command I always get

/system/bin/pm[6]: app_process: Permission denied

Could it be that I need to flash a different ROM? Am I missing a command somewhere? I'm totally stumped

*because someone's bound to ask this rather than answer the question: I'm trying to disable the system UI so the Nexus can be used as a kiosk (Client doesn't want nav bar visible at all, screen pinning has been suggested to them and rejected)

like image 782
M King Avatar asked Sep 26 '22 20:09

M King


1 Answers

Huge thanks to Adnan from CM for helping find this solution - a coworker recruited him for his help.

The reason I was getting permission denied was due to the SELinux setting being set to enforcing rather than permissive. In order to change it, I simply ran

$ adb shell su -c setenforce 0

and my disable system UI command was accepted!

Note: it does say here that Permissive mode is not supported on production devices, so I didn't actually expect this to work. It may be that having root access allowed me to subvert this or it may be some other factor

like image 197
M King Avatar answered Oct 05 '22 22:10

M King