Name

chsh — stdin  stdout  - file  -- opt  --help  --version

Synopsis

chsh [options] [username]

The chsh (change shell) command sets your login shell program. Invoked without a username, chsh affects your account; invoked with a username (by root), it affects that user. With no options, chsh will prompt you for the desired information.

$ chsh
Changing shell for smith.
Password: *******
New shell [/bin/bash]: /bin/tcsh

The new shell must be listed in /etc/shells.

Useful options

-s shell

Specify the new shell.

-l

List all permissible shells.

Get Linux Pocket Guide, 2nd Edition now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.