After installing a custom build of the fish shell at /opt/shells/fish, you want ordinary users to be able to switch to it with chsh -s /opt/shells/fish. When a non-root user runs the command, they see the message:
chsh: /opt/shells/fish: non-standard shell
Which configuration file must you update so that chsh will accept this shell for non-privileged users?
chsh only lets a regular (non-root) account select a shell that appears in the system's list of approved shells. That list is stored in /etc/shells. Adding the full path /opt/shells/fish to that file allows the utility to validate the request and update the user's entry in /etc/passwd. Editing /etc/passwd, /etc/login.defs, or /etc/profile will not satisfy chsh's validation step and therefore will not remove the error.
Ask Bash
Bash is our AI bot, trained to help you pass your exam. AI Generated Content may display inaccurate information, always double-check anything important.
Why does chsh require the shell's path to be in /etc/shells?
Open an interactive chat with Bash
What is the process for adding a shell to /etc/shells?
Open an interactive chat with Bash
What happens if you manually edit /etc/passwd instead of modifying /etc/shells?
Open an interactive chat with Bash
CompTIA Linux+ XK0-006 (V8)
Services and User Management
Your Score:
Report Issue
Bash, the Crucial Exams Chat Bot
AI Bot
Loading...
Loading...
Loading...
IT & Cybersecurity Package Join Premium for Full Access