I'm trying to become the root on my terminal with sudo -i
command, but the system display sudo: /usr/local/bin/fish: command not found
. I tried to set the fish shell as default, but I got a problem. Could anyone be able to tell me what I could do to fix the problem?
I tried to set fish shell as default with first sudo echo /usr/local/bin/fish >> /etc/shells
and after chsh -s /usr/local/bin/fish
. However, it looks like I have more than one usr/local/bin/fish
file in /usr/shells
. (In fact, I followed from there)
Thanks in advance!
P.S. I know now the file is not usr/local/bin/fish
, but usr/local/bin
. I've succeeded to set fish shell as default, but I'm still having the sudo -i
problem.
fish
installed by default. You need to usesudo apt install fish
. – TheWanderer Nov 11 '16 at 01:16chsh: /usr/local/bin/fish is an invalid shell
– Sandra Ross Nov 11 '16 at 01:17apt
would have installed it to/usr/local
- more likely/usr/bin/fish
. Alsosudo echo ...
to write to/etc/shells
isn't going to work - see When using sudo with redirection, I get 'permission denied' – steeldriver Nov 11 '16 at 01:20fish
– Sandra Ross Nov 11 '16 at 01:21̀sudo: /usr/local/bin/fish: command not found
. – Sandra Ross Nov 11 '16 at 01:29which fish
,grep fish /etc/shells
, andgetent passwd root | cut -d: -f7
? – David Foerster Nov 11 '16 at 08:23