140k views
0 votes
Which of the following options for the useradd command allows root to specify supplementary groups the user will be a member of?

a) -g
b) -U
c) -u
d) -G

1 Answer

1 vote

Final answer:

The -G option for the useradd command allows root to specify supplementary groups for a new user account. This option requires a comma-separated list of existing group names.

Step-by-step explanation:

The useradd command in Linux is used for creating a new user account. When the root user wants to specify supplementary groups that a new user should be a member of, they use the -G option. For example, the command useradd -G developers,design would add the new user to both the 'developers' and 'design' groups.

It's important to note that group names are case-sensitive and should be existing groups on the system. The command useradd -G is accompanied by a comma-separated list of groups without spaces.

User Jera
by
7.8k points