Next Spaceship

Driving into future…

Configure SSH on Arch Linux

| Comments

Just record this for possbile uses.

Install sshd:

1
$sudo pacman -Syu openssh

Start sshd:

1
$sudo rc.d start sshd

and add “sshd” to your DAEMONS array in /etc/rc.conf

1
2
3
$sudo emacs /etc/rc.conf
----------------------------------
DAEMONS = (... sshd)

Everything should be OK, but if you met the following errors:

1
"connection refused"

or

1
"Server unexpectedly closed network connection"

Check if you start sshd successfully:

1
$sudo rc.d list | grep sshd

You should see:

1
[STARTED][AUTO] sshd

otherwise, you didn’t start sshd successfully, and you may need to

1
$sudo rc.d start sshd

and check if some errors appear and try to solve them. If you started sshd successfully, but still can’t use sshd service, try to restart sshd:

1
$sudo rc.d restart sshd

If you have configured deny-host list, you should add sshd to the exception list:

1
2
3
$sudo emacs /etc/hosts.allow
-------------------
sshd: all

Comments