This commit is contained in:
rra 2019-06-20 10:46:47 +02:00
commit 6c3d62571b

View File

@ -26,6 +26,7 @@ approaches for day to day use and troubleshooting.
## Prerequisites ## Prerequisites
The SSH ecosystem is very established. It is available on all modern GNU/Linux The SSH ecosystem is very established. It is available on all modern GNU/Linux
distributions, MacOS and Windows. You can use your home server or if you don't have one yet you can use your own personal laptop to experiment (in this case, your laptop will distributions, MacOS and Windows. You can use your home server or if you don't have one yet you can use your own personal laptop to experiment (in this case, your laptop will
play the role of both the server and client as explained later). play the role of both the server and client as explained later).
@ -68,7 +69,7 @@ To install the SSH server on your home server, run:
$ sudo apt install -y openssh-server $ sudo apt install -y openssh-server
``` ```
And from your client (laptop or otherwise), run: And on your client, run:
```bash ```bash
$ sudo apt install -y openssh-client $ sudo apt install -y openssh-client
@ -323,7 +324,7 @@ Here are some questions to ask yourself:
* Is your public key registered on the server in the `$HOME/.ssh/authorized_keys` folder? * Is your public key registered on the server in the `$HOME/.ssh/authorized_keys` folder?
* Are the folder permissions correct? (see this [SO thread](https://superuser.com/questions/215504/permissions-on-private-key-in-ssh-folder)) * Are the `$HOME/.ssh` permissions correct? (see this [SO thread](https://superuser.com/questions/215504/permissions-on-private-key-in-ssh-folder))
* Is the SSH server running? (`sudo systemctl status sshd`) * Is the SSH server running? (`sudo systemctl status sshd`)
@ -333,13 +334,18 @@ Here are some questions to ask yourself:
changes. After validating, always restart the SSH server after changes. After validating, always restart the SSH server after
making configuration changes making configuration changes
* What does `sudo tail -f /var/log/auth.log` say?
* Every time an SSH client attempts to connect, a log
entry will be put into this file. Some hint as to why
it is failing should be here.
### On the client ### On the client
Here are some questions to ask yourself: Here are some questions to ask yourself:
* What does `ssh -vvvvv myhomebrewserver` tell you? * What does `ssh -vvvvv myhomebrewserver` tell you?
* Are the folder permissions correct? (see this [SO thread](https://superuser.com/questions/215504/permissions-on-private-key-in-ssh-folder)) * Are the `$HOME/.ssh` folder permissions correct? (see this [SO thread](https://superuser.com/questions/215504/permissions-on-private-key-in-ssh-folder))
* Is the SSH server available at the port you expect? (`sudo nmap -p 22 myhomebrewserver`) * Is the SSH server available at the port you expect? (`sudo nmap -p 22 myhomebrewserver`)