Home
Cloud
Big Data
CI
Install
Samples
Java
Ubuntu
Maven
Archive
Linux-Ubuntu
|
Groups
References
List the groups of the current process (groups)
Add a new group (groupadd)
Delete a group (groupdel)
References
See this page for more details about group management:
https://help.ubuntu.com/lts/serverguide/user-management.html
List the groups of the current process (groups)
Print groups for the current process:
$ groups mtitek group1 group2
You can print the groups of a specific users:
$ groups mtitek mtitek1 mtitek : mtitek group1 group2 mtitek1 : mtitek1
Add a new group (groupadd)
Use the groupadd command to add a new group (
man groupadd
):
Usage: groupadd [options] GROUP Options: -f, --force exit successfully if the group already exists
Examples:
Create a group named "newgroup".
$ sudo groupadd newgroup $ cat /etc/group | grep newgroup newgroup:x:1005:
Delete a group (groupdel)
Examples:
Delete the group "newgroup":
$ sudo groupdel newgroup
© 2010-2022
mti
tek