Red Hat Certified System Administrator RHCSA · Free Practice Question Medium
Question 13
Using Red Hat Enterprise Linux 9, how would you modify the login shell of the user 'marty' to bash?
Show model answer
To change the login shell for the user 'marty' to bash in Red Hat Enterprise Linux 9, use the usermod command with the -s (shell) option. First, ensure you have administrative privileges. Then, open a terminal and execute the following command: sudo usermod -s /bin/bash marty. This command sets the user 'marty's login shell to bash, which is located at /bin/bash in RHEL 9. Always verify the shell path with which bash before executing the command.
Discussion
Think the marked answer is wrong, or have a better explanation? Share it below — comments appear after review.
You must be logged in to post a comment.
