錯誤原因
The following packages have unmet dependencies:
openssh-server : Depends: openssh-client (= 1:6.6p1-2ubuntu2.8) but 1:7.2p2-4ubuntu1 is to be installed
Recommends: ncurses-term but it is not going to be installed
Recommends: ssh-import-id but it is not going to be installed
E: Unable to correct problems, you have held broken packages.
執行 apt-get install openssh-client=1:6.6p1-2ubuntu2.8
再安裝
apt-get install openssh-server
成功了。
啟動命令
/etc/init.d/ssh start
重啟命令
/etc/init.d/ssh restart
停止命令
/etc/init.d/ssh stop
判斷是否有啟動
ps -e|grep ssh
鏈接其他電腦
ssh 用戶名@ip地址
輸入密碼則進入,輸入exit退出