Friday, August 16, 2013

solaris 9 & 10 ssh

yeah. i forget sometimes.
Solaris 9
Disable service ssh ?

bash>  /etc/init.d/sshd stop
bash> /etc/rc3.d/S89sshd stop
Enable service ssh ?

bash> /etc/init.d/sshd start
bash> /etc/rc3.d/S89sshd start
Refresh service ssh ?

bash> kill -HUP `cat /var/run/`
Solaris 10
First you can check service ssh with command

bash> svcs | grep ssh
online         Jan_21   svc:/network/ssh:default
If status ssh offline, you can make online with command:

bash> svcadm enable -t network/ssh:default
bash> /lib/svc/method/sshd start
Disable service ssh ?

bash> svcadm disable -t network/ssh:default
Restart service ssh ?

bash> svcadm restart network/ssh:default
bash> /lib/svc/method/sshd restart
Refresh service ssh ?

bash> svcadm refresh network/ssh:default
For a root enable connect to host via ssh service

bash> vi /etc/ssh/sshd_config
# Valid options are yes, without-password, no.
PermitRootLogin no
Replace no with yes, after that save the edited configuration.
Don't forget for the restart service ssh, after edit configuration.
Post a Comment