MAN page from OpenSuSE shadow-4.6-lp220.127.116.11.x86_64.rpm
Section: User Commands (1)
sg - execute command as different group ID
- sg [-] [group [-c ] command]
DESCRIPTIONThesgcommand works similar tonewgrpbut accepts a command. The command will be executed with the/bin/shshell. With most shells you may runsgfrom, you need to enclose multi-word commands in quotes. Another difference betweennewgrpandsgis that some shells treatnewgrpspecially, replacing themselves with a new instance of a shell thatnewgrpcreates. This doesn't happen withsg, so upon exit from asgcommand you are returned to your previous group ID.
The following configuration variables in/etc/login.defschange the behavior of this tool:
- Enable "syslog" logging ofsgactivity.
- User account information.
- Secure user account information.
- Group account information.
- Secure group account information.
- SEE ALSO
This document was created byman2html,using the manual pages.