Take the 2-minute tour ×
Ask Ubuntu is a question and answer site for Ubuntu users and developers. It's 100% free, no registration required.

I'm trying to permanently change my shell to zsh using chsh command, but it's not working.

zsh is installed (via apt) and works fine when I invoke it directly from a bash prompt terminal. But I can't get zsh to load in terminals by default, and chsh is doing something weird:

$> echo $SHELL
/bin/bash
$> which zsh
/usr/bin/zsh
$> chsh -s /usr/bin/zsh
Password: 
$> echo $SHELL
/bin/bash
$> grep kurtosis /etc/passwd
kurtosis:x:1000:1000:kurtosis,,,:/home/kurtosis:/usr/bin/zsh

It appears chsh has managed to correctly change /etc/passwd, but not the $SHELL env variable. As such, new terminals always start in bash and not zsh.

I'm not sure where to look to troubleshoot this. .bashrc, even though it's not invoked until the shell is specified? Any help appreciated.

share|improve this question
1  
Cannot you change shell after you re-logged in the system? –  vine_user Oct 2 '12 at 2:29
add comment

1 Answer

up vote 9 down vote accepted

You need to log out again for these changes to take effect. The shell defined in the /etc/passwd file is your login shell :-) So you need to log in actually for that.

share|improve this answer
1  
Thanks. I'm so used to being able to make changes to linux without rebooting, it just didn't occur to me. –  Kurtosis Oct 3 '12 at 0:07
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.