系統版本:SunOS solaris1 5.10
內核版本:5.10 i86pc
Solaris 10在安裝完成後,默認是沒有開啟ssh服務的,如果要開啟ssh服務,就要做如下操作。
1、修改配置文件
#vi /etc/ssh/sshd_config
將PermitRootLogin no更改為PermitRootLogin yes
2、重啟ssh服務
#/lib/svc/method/sshd restart
3、查看ssh開放服務的端口,ssh默認開放端口為22端口,通過從查看端口來確定服務是否開啟。
# netstat -avn | grep 22
*.* 0 00000000 00000000 49152 00000000 00000000 1125 1220 IDLE
*.* 0 00000000 00000000 49152 00000000 00000000 1125 1220 LISTEN
*.* 0 00000000 00000000 49152 00000000 00000000 1125 1220 LISTEN
*.* 0 00000000 00000000 49152 00000000 00000000 1125 1220 LISTEN
*.* 0 00000000 00000000 49152 00000000 00000000 1125 1220 LISTEN
*.* 0 00000000 00000000 49152 00000000 00000000 1125 1220 LISTEN
10.72.247.53.22
*.22
*.* 0 00000000 00000000 49152 00000000 00000000 1125 1220 LISTEN
*.* 0 00000000 00000000 49152 00000000 00000000 1125 1220 IDLE
*.* 0 00000000 00000000 49152 00000000 00000000 1125 1220 LISTEN
*.* 0 00000000 00000000 49152 00000000 00000000 1125 1220 LISTEN
*.* 0 00000000 00000000 49152 00000000 00000000 1125 1220 LISTEN
*.* 0 00000000 00000000 49152 00000000 00000000 1125 1220 LISTEN
*.* 0 00000000 00000000 49152 00000000 00000000 1125 1220 LISTEN
*.* 0 00000000 00000000 49152 00000000 00000000 1125 1220 LISTEN
*.* 0 00000000 00000000 49152 00000000 00000000 1125 1220 LISTEN
*.22
*.* 0 00000000 00000000 49152 00000000 00000000 1125 1220 LISTEN
如上可以看見22端口開啟了。
4、利用putty等ssh工具登錄即可,如下圖