Deal of The Day! Hurry Up, Grab the Special Discount - Save 25% - Ends In 00:00:00 Coupon code: SAVE25
Welcome to Pass4Success

- Free Preparation Discussions

RedHat EX200 Exam - Topic 10 Question 128 Discussion

According the following requirements to create user, user group and the group members:- A group named admin.- A user named mary, and belong to admin as the secondary group.- A user named alice, and belong to admin as the secondary group.- A user named bobby, bobby's login shell should be non-interactive. Bobby not belong to admin as the secondary group.Mary, Alice, bobby users must be set "password" as the user's password.
A) Explanation: groupadd admin useradd -G admin mary useradd -G admin alice useradd -s /sbin/nologin bobby echo 'password' | passwd --stdin mary echo 'password' | passwd --stdin alice echo 'password' | passwd --stdin bobby

RedHat EX200 Exam - Topic 10 Question 128 Discussion

Actual exam question for RedHat's EX200 exam
Question #: 128
Topic #: 10
[All EX200 Questions]

According the following requirements to create user, user group and the group members:

- A group named admin.

- A user named mary, and belong to admin as the secondary group.

- A user named alice, and belong to admin as the secondary group.

- A user named bobby, bobby's login shell should be non-interactive. Bobby not belong to admin as the secondary group.

Mary, Alice, bobby users must be set "password" as the user's password.

Show Suggested Answer Hide Answer
Suggested Answer: A

Contribute your Thoughts:

0/2000 characters
Carisa
5 days ago
This is exactly how I would do it!
upvoted 0 times
...
Dexter
10 days ago
Nice, but why a non-interactive shell for bobby?
upvoted 0 times
...
Dudley
15 days ago
Wait, is using "password" as a password really safe?
upvoted 0 times
...
Martha
20 days ago
Agree, everything seems correct here.
upvoted 0 times
...
Mirta
25 days ago
Looks good, but don't forget to set the password for bobby too!
upvoted 0 times
...
Audria
1 month ago
I just hope I remember the syntax for piping the password into the `passwd` command correctly; it can be tricky!
upvoted 0 times
...
Noel
1 month ago
I practiced a similar question where I had to set a non-interactive shell for a user, so I think using `/sbin/nologin` for Bobby is correct.
upvoted 0 times
...
Juan
1 month ago
I'm a bit unsure about the `-G` option for `useradd`. Does it really add users to a secondary group?
upvoted 0 times
...
Fredric
2 months ago
I think I remember that the `groupadd` command creates a new group, so that part seems straightforward.
upvoted 0 times
...

Save Cancel