Tags

, , , , , , , , , , , , , ,

I just stumbled upon a few ways to change the default login shell to bash:

The easiest one is

$ chsh -s /bin/bash username

On some machines you may have to use ypcsh instead of chsh. The full path of the shell executable must be specified.

But if you have root access you may have the option to use either of the following two as well:

  • $ usermod -s bash username
  • Change it by editing the entry for the user in /etc/passwd file, manually.

If none of the above works, here’s a workaround!

N.B. Make sure that the desired shell is listed in /etc/shells file.

Advertisements