Under certain conditions, when manually starting or stopping the server, it may appear to hang with 'Starting sshd (via systemctl)' message displayed. This technical note describes the symptoms and solution.
This issue is identified by the following symptoms:
- Running with RedHat Enterprise Linux 7 (RHEL7) systemd on Intel 64-bit (x86-64)
- Port or PidFile keywords have been changed from the default
- You are manually starting or stopping the Reflection for Secure IT Server
- âStarting sshd (via systemctl):â message is displayed
- Although systemctl does successfully start or stop the SSH daemon, you need to press Ctrl+C to return to the shell prompt
This issue does not occur when the server is stopped and started by rebooting the system.
To avoid this issue, modify how you start or stop the server.
If you are using the âserviceâ binary, add the --skip-redirect flag. For example:
service --skip-redirect sshd start
service --skip-redirect sshd stop
If you are executing the sshd script directly, pass in the SYSTEMCTL_SKIP_REDIRECT=1 environment variable. For example:
SYSTEMCTL_SKIP_REDIRECT=1 /etc/init.d/sshd start
SYSTEMCTL_SKIP_REDIRECT=1 /etc/init.d/sshd stop