Foto del Día National Geographic

22 October, 2010

Solaris 10 SSHD not starting

I got crazy this morning cuz sshd service wasn't working on our lab's server. It's absolutely necessary if we want to work remotely. I lost the former output of the problem, but I want to show you (and me, when this is cleared from my cache) some of the commands i used to sove this problem:


# svcadm enable ssh
here doesn't display any message.

# svcs -l ssh
here displays the service status. It was offline. It should be online since i "enable" it. It shows also its dependencies. "autofs" service was offline.

# svcs -d svc:/system/filesystem/autofs:default
STATE STIME FMRI
online 12:27:03 svc:/milestone/name-services:default
online 12:27:10 svc:/system/filesystem/local:default
online 12:27:17 svc:/network/rpc/bind:default
offline* 12:27:21 svc:/network/nfs/client:default

I offlined nfs client service because Richard screwed the NAS so he needs to repair it in oder to be able to enable this service.

# svcs -x
If typed alone -x option shows all services that hasn't started. If you add the service name, it prints:

svc:/system/filesystem/autofs:default (automounter)
State: offline since Fri Oct 22 12:27:22 2010
Reason: Unknown
See: automount(1M)
See: /var/svc/log/system-filesystem-autofs:default.log
Impact: There are 22 dependent services.

svc:/network/nfs/client:default (NFS client)
State: offline since Fri Oct 22 12:27:21 2010
Reason: Start method is running.
See: http://sun.com/msg/SMF-8000-C4
See: mount_nfs(1M)
See: /var/svc/log/network-nfs-client:default.log
Impact: This service is not running.

What I did to solve was edit /etc/vfstab and comment the line where the NFS it's mounted. Then I typed (after a lot of research):

# svcadm clear svc:/system/filesystem/autofs:default
# svcadm disable svc:/system/filesystem/autofs:default
# svcadm enable svc:/system/filesystem/autofs:default
# svcs -x svc:/system/filesystem/autofs:default

And finally
# svcs -l ssh

And it worked!

Hope it still works after rebooting the system :D.

7 comments:

Jichu said...
This comment has been removed by the author.
Jichu said...

awesome..it was really useful...!!!

kathir vel said...

that's helpful.. thank you H World..

Anup said...
This comment has been removed by the author.
Anup said...

Thank U it really worked..............

weareexpandables said...

i love u (im not gay) u make me ssh :D

weareexpandables said...
This comment has been removed by the author.