如果希望SSH登陆后先执行shell命令,可以这样:

ssh user@ip -t "cd /data ; /bin/bash"