Article 5C50M Could not resolve hostname <server name>: Name or service not known

Could not resolve hostname <server name>: Name or service not known

by
Messed_Up_Linux
from LinuxQuestions.org on (#5C50M)
Hello all,

I've been SSHing into a local server (Ubuntu 20.04) using the following command:

SSH -p <port number> <username>@<server name>

I've done the following with the server so far:

- Create a new user with admin rights
- Modify the default SSH port
- Configure the firewall UFW (specifically allowing traffic from the port number I'm logging in through)

The strange thing is that the command I'm trying above was working all day yesterday. After a few hours of being disconnected from the server I wanted to check up on it and the command no longer worked, giving me the error message in the title:

Could not resolve hostname <server name>: Name or service not known


I did not make any further changes to the server in between the last time the SSH command still worked and the first time it no longer did. The only thing I can think of is that I closed the terminal on my laptop (the one SSHing into the server) and opened a new one. I'm not sure this was the triggering event.

Thanks a lot for your help.latest?d=yIl2AUoC8zA latest?i=ZDp5HYUxF8U:HftvonnaVjw:F7zBnMy latest?i=ZDp5HYUxF8U:HftvonnaVjw:V_sGLiP latest?d=qj6IDK7rITs latest?i=ZDp5HYUxF8U:HftvonnaVjw:gIN9vFwZDp5HYUxF8U
External Content
Source RSS or Atom Feed
Feed Location https://feeds.feedburner.com/linuxquestions/latest
Feed Title LinuxQuestions.org
Feed Link https://www.linuxquestions.org/questions/
Reply 0 comments