SSH hangs while restarting services

Denny Lin dennylin93 at
Tue Nov 4 00:56:41 UTC 2014


Recently I've been trying to restart services remotely using SSH using a
command instead of entering the shell:
ssh host "sudo service postgresql restart"

PostgreSQL is able to restart successfully, but SSH just hangs there
instead of exiting. I've noticed that this seems to affect any command
which spawns a child process which doesn't exit.

Is there any way to get SSH terminate? Thanks.

Denny Lin

More information about the freebsd-ports mailing list