the cause of a slow ssh connection
you can use ssh -v to chech why do you have a slow ssh connection
1 ssh -v username@server
If it is stucked on the step
1 2 3 4 debug1: channel 0: new [client-session] debug1: Requesting firstname.lastname@example.org debug1: Entering interactive session. debug1: pledge: exec
then something the
systemd-logind service maybe wrong. If so, restart the service can solve this problem.
how to solve this problem
1 2 3 user@server ~ $ sudo rc-service elogind restart * Starting elogind ... * start-stop-daemon: /lib64/elogind/elogind is already running [ !! ] * ERROR: elogind failed to start
If you can not restart it, just kill and then start it.