How to Change Your Default Shell in Debian Ubuntu

Profile pictureRocktim Saikia/1 min read

To check the current shell that's being used, run:

echo $0

To check the default shell of your system, run:

echo $SHELL

To list all your currently available shells, run:

cat /etc/shells

One quite interesting thing to note here is the / before etc/shells, that means that we are displaying the shells from the root dir not home ($HOME) dir.

Now to change the the default login shell, run the command below following the path of the shell you want to change to:

chsh -s /bin/zsh