關于CentOS配置ssh系統技能介紹
由于越來越多的人使用CentOS操作系統,而且CentOS配置ssh已被廣泛運用,但是也在不斷的更新。存在著很多不是很專業的人士對這方面的知識還是存在著很多的疑問。這次,在這里推選CentOS配置ssh安裝配置運用,幫助大眾安裝更新CentOS配置ssh系統。絕大部分內容適用于CentOS /RHEL ,同時也適用于其他發行版本。
在VMware安裝一個CentOS的Sever版,終端里的內容不可滾動,不簡潔。在win下遠程登錄不錯(win下有個Xshell)。默認安裝ssh是有的。只是hosts訪問疑問。
1.在hosts.deny文件尾添加CentOS配置ssh:ALL意思是拒絕所有訪問請求[root@localhost ~]# vi /etc/hosts.deny修改后看起來如下:
hosts.denyThis file describes the names of the hyusaosts which are *not* allowed to use the local INET services, as decided by the '/usr/sbin/tcpd' server. The portmap line is redundant, but it is left to remind you that the new secure portmap uses hosts.deny and hosts.allow. In particular you should know that NFS uses portmap! sshd:ALL
2.在hosts.allow文件尾添加CentOS配置ssh:192.168.0. 意思是準許 192.168.0.1 到254的主機,內網。
[root@localhost ~]# vi /etc/hosts.allow hosts.allow
This file describes the names of the hosts which are allowed to use the local INET services, as decided by the '/usr/sbin/tcpd' server.sshd:192.168.0.
3.重啟CentOS配置
ssh [root@localhost ~]# /etc/rc.d/init.d/sshd restart 停止 ssh [ 確定 ] 啟動 ssh [ 確定 ] 以上推選 CentOS配置ssh。
【編輯推薦】