CenOS 6 內建有ssh,直接啟動即可
1.su 切換成 root 權限
2.啟動 ssh service,service sshd start
3.編輯 hosts.allow或 hosts.deny,使用vim,按下 insert 進入編輯模式,編輯完畢用esc跳離
並使用「:wq」存檔後離開
設定哪些IP可使用SSH連線
/etc/hosts.allow 允許此IP使用SSH登入 /etc/hosts.deny 拒絕此IP使用SSH登入
[root@host ~]$ vim /etc/hosts.allow /* 允許此ip使用SSH登入 */ sshd:192.168.10.130
[root@host ~]$ vim /etc/host.deny /* 限制IP使用SSH 連線 */ sshd:all
鳥哥的私房菜,關於VIM
無痛教學 KiKiNote,關於SSH
