HomeApplemacos - Why some instructions do NOT require sudo when logged in...

macos – Why some instructions do NOT require sudo when logged in GUI?


I created a consumer known as dummy.

I login utilizing Terminal into dummy and attempt to put Mac to sleep utilizing pmset sleepnow. It does NOT work: Sleep error 0xe00002c1; You should run this as root..

I log into dummy utilizing Quick Consumer Switching in MacOS GUI. I swap again to my important consumer [keeping dummy logged in thanks to the Fast User Switching GUI].
I login once more to dummy utilizing Terminal and take a look at pmset sleepnow. It is working now!

  1. Why is that?
  2. How does it work that the command requires sudo, except I am logged within the GUI [then it doesn’t]?
  3. What are different instructions that magically begin working if logged in utilizing the MacOS GUI?

EDIT: Beforehand I’ve thought it was like that due to the dummy being a “normal” account – I’ve simply examined that it’s the similar concern for “administrator” accounts as nicely. Nonetheless, the questions stay: why/how does it matter, being logged within the GUI, for some instructions to work.

RELATED ARTICLES

Most Popular

Recent Comments