Quote:
Originally Posted by druuna
Just to make sure, could you post the restart part from the /etc/init.d/ssh script? (all from restart) to the ;;).
|
here it is (that is Ubuntu 10.04 server) I have not modified that script.
Quote:
restart)
check_privsep_dir
check_config
log_daemon_msg "Restarting OpenBSD Secure Shell server" "sshd"
start-stop-daemon --stop --quiet --oknodo --retry 30 --pidfile /var/run/sshd.pid
check_for_no_start log_end_msg
check_dev_null log_end_msg
if start-stop-daemon --start --quiet --oknodo --pidfile /var/run/sshd.pid --exec /usr/sbin/sshd -- $SSHD_OPTS; then
log_end_msg 0
else
log_end_msg 1
fi
;;
|
here is one more part I think you may be interested in this
Quote:
try-restart)
check_privsep_dir
check_config
log_daemon_msg "Restarting OpenBSD Secure Shell server" "sshd"
set +e
start-stop-daemon --stop --quiet --retry 30 --pidfile /var/run/sshd.pid
RET="$?"
set -e
case $RET in
0)
# old daemon stopped
check_for_no_start log_end_msg
check_dev_null log_end_msg
if start-stop-daemon --start --quiet --oknodo --pidfile /var/run/sshd.pid --exec /usr/sbin/sshd -- $SSHD_OPTS; then
log_end_msg 0
else
log_end_msg 1
fi
;;
1)
# daemon not running
log_progress_msg "(not running)"
log_end_msg 0
;;
*)
# failed to stop
log_progress_msg "(failed to stop)"
log_end_msg 1
;;
esac
;;
|
Quote:
Originally Posted by druuna
Is the output shown from after a restart?
|
Yes the above outputs were from restart.
Quote:
Originally Posted by druuna
If not: do a restart and repost the output.
|
I did it again for the sake of this thread just now
surprisingly I do not see that error message which I reported above with this restart
Code:
Received signal 15; terminating.
Oct 29 14:51:04 sshd[28576]: Server listening on 0.0.0.0 port 22.
Oct 29 14:51:04 sshd[28576]: Server listening on :: port 22.
and here is the output of netstat
Code:
netstat -pal | grep ssh
tcp 0 0 *:ssh *:* LISTEN 28576/sshd
tcp 0 0 somedomain.com:ssh tk.local:36020 ESTABLISHED 25383/2
tcp6 0 0 [::]:ssh [::]:* LISTEN 28576/sshd
also
Code:
netstat -plan | grep ssh
tcp 0 0 0.0.0.0:22 0.0.0.0:* LISTEN 28576/sshd
tcp6 0 0 :::22 :::* LISTEN 28576/sshd