Linux "-sh: 25: [[: not found" not being logged into user when using SSH

When I SSH into the server, I'm not being fully logged in. What I mean by this, is that if I use whoami, it displays my account. However, my .bashrc never gets initiated. My terminal also looks like:

-sh: 25: [[: not found $

Once I su into the account, everything works fine, and my terminal shows: user@ip-000-00-00-000:~$

What's causing this?

1 answer

  • answered 2017-11-12 19:57 that other guy

    This happens because your login shell is sh, a simpler shell with fewer features. You can change it to bash with chsh.