Set a default login shell per user to tailor the environment and tools he gets at login. 20.01.2026 | reading time: 2 min Want each user to start in a different shell? This short guide shows how to set the login shell per user, why the "/etc/shells" file matters, and which commands to use to make the change reliably. A quick, real example Change alice's shell as root with `usermod`, or let alice change her own shell with `chsh`; examples: ```bash sudo usermod -s /bin/zsh alice``` and ```bash chsh -s /bin/zsh alice```; verify with: ```bash getent passwd alice``` which might show: alice:x:1001:1001:Alice,,,:/home/alice:/bin/zsh Edge cases and gotchas Not every executable is accepted as a login shell: the target must usually be listed in "/etc/shells" or in directory services; add the shell to "/etc/shells" if necessary using a text editor or `echo "/usr/bin/fish" | sudo tee -a /etc/shells`; some services (graphical display managers, PAM, LDAP) or containers may ignore or override the passwd entry, so check the login path if the change has no effect. Practical companion tools Use `getent passwd` to inspect effective entries, `vipw` to edit the passwd file safely as root, and consult `chsh --help` or `usermod --help` for platform specifics; on systems with network accounts, adjust the LDAP or NIS entry rather than local files. Finish line and next steps A correct default shell improves productivity and security with minimal fuss; practice changing shells in a safe VM, check "/etc/shells", and test logins to validate behavior — then deepen system knowledge and consider pursuing certifications like CompTIA Linux+ or LPIC-1 with intensive preparation at bitsandbytes.academy to turn hands-on skill into a credential. Join Bits & Bytes Academy First class LINUX exam preparation. setup scripting security