command to switch base/root terminal

does anyone know how to command a root terminal to a 'Run as admin' terminal?




MacBook Pro 13″, macOS 13.2

Posted on Mar 2, 2023 8:33 PM

Reply
Question marked as Top-ranking reply

Posted on Mar 3, 2023 5:32 AM

A session logged in as root is the system root user. It is a root shell.


If you want to switch to a differnet user, sudo can do that. See man sudo for details.

sudo -u username command


Enabling the root user is generally discouraged on macOS, and on others too. Use of sudo is recommended.


If you are trying to modify protected files, neither root nor an admin group user will help.


Neither root nor Admin group users can mofify protected files, short of disabling system integrity protection.

3 replies
Question marked as Top-ranking reply

Mar 3, 2023 5:32 AM in response to Sno_Jr

A session logged in as root is the system root user. It is a root shell.


If you want to switch to a differnet user, sudo can do that. See man sudo for details.

sudo -u username command


Enabling the root user is generally discouraged on macOS, and on others too. Use of sudo is recommended.


If you are trying to modify protected files, neither root nor an admin group user will help.


Neither root nor Admin group users can mofify protected files, short of disabling system integrity protection.

This thread has been closed by the system or the community team. You may vote for any posts you find helpful, or search the Community for additional answers.

command to switch base/root terminal

Welcome to Apple Support Community
A forum where Apple customers help each other with their products. Get started with your Apple Account.