###
1.切换目录
[root@alpha01~]$ ssh root@192.168.56.12 -t "cd /home/wx/services/dev01;bash --login"
[alphaReadLog@alpha02 dev01]$ pwd
/home/wx/services/dev01
2.使用命令
[root@alpha01 ~]$ ssh alphaReadLog@192.168.56.12 -t "ls -l ;bash --login"
total 4
drwxr-xr-x 12 root root 4096 Mar 19 11:19 dev01
[root@alpha02 ~]$ ls -l
total 4
drwxr-xr-x 12 root root 4096 Mar 19 11:19 dev01
###