Solaris adding group

You can use GUI tools or command line tools. I like to use command line tools for group admin. Use groupadd command to add (create) a new group definition on the system. Use groupmod command to modify a group definition on the system.

ADVERTISEMENTS

Adding new group
Use groupadd command to add group called pusers:

# groupadd pusers

Create a group called sshusers with GID 500:

# groupadd –g 500 sshusers

Add new user volini to group sshusers:

# useradd –d /nas/home/v/volini -m volini

Add existing user rose to group sshusers:

# usermod -G pusers rose

Rename group
Change the name sshusers to ftpusers:

# groupmod -n ftpusers sshusers

Delete the group
Remove the group called foxadmin

# groupdel foxadmin

If you manually modified the /etc/group file then you can check any group file inconsistencies with grpck command:

# vi /etc/group
# grpck

🐧 Get the latest tutorials on SysAdmin, Linux/Unix, Open Source & DevOps topics via:
CategoryList of Unix and Linux commands
File Managementcat
FirewallAlpine Awall CentOS 8 OpenSUSE RHEL 8 Ubuntu 16.04 Ubuntu 18.04 Ubuntu 20.04
Network Utilitiesdig host ip nmap
OpenVPNCentOS 7 CentOS 8 Debian 10 Debian 8/9 Ubuntu 18.04 Ubuntu 20.04
Package Managerapk apt
Processes Managementbg chroot cron disown fg jobs killall kill pidof pstree pwdx time
Searchinggrep whereis which
User Informationgroups id lastcomm last lid/libuser-lid logname members users whoami who w
WireGuard VPNCentOS 8 Debian 10 Firewall Ubuntu 20.04

ADVERTISEMENTS
2 comments… add one
  • Brian Nov 19, 2008 @ 16:42

    Very helpful. Good reference.

  • dave Apr 11, 2009 @ 23:44

    good reference indeed sir! thanks for saving me some time!

Leave a Reply

Your email address will not be published. Required fields are marked *

Use HTML <pre>...</pre>, <code>...</code> and <kbd>...</kbd> for code samples.