I’m having an issue with curl, right now I’m running to dedicated servers with proxmox on them. in the first dedicated server I got my website and doing CURL from it (from the vps) does resolve google.es but it does not resolve my domain (panel.roozservers.com) the error that I’m getting it is Could not resolve host: panel.roozservers.com; UInknow error
Doing curl from an online curl tool will give the correct results so I figured out that its a problem on my machine.
My /etc/resolv.conf file it is
# --- BEGIN PVE ---
search ip-54-39-131.net
nameserver 127.0.0.1
nameserver 213.186.33.99
# --- END PVE ---
My /etc/hosts file it is
127.0.1.1 LXC_NAME
127.0.0.1 localhost localhost.localdomain localhost4 localhost4.localdomain4
::1 localhost localhost.localdomain localhost6 localhost6.localdomain6
# --- BEGIN PVE ---
51.161.31.150 RSWeb.ip-54-39-131.net RSWeb
# --- END PVE ---
2
Answers
Fixed it creating a new instance (VM).
Sometimes there’s issues curling or resolving a link to the machine your trying to resolve it from.
I can curl the domain just fine with a status code 200.
Try to curl from another machine or when not connected via ssh.
EDIT:
Open your hosts file with
Append this line:
Check if loopback ping works with:
Try again to curl your domain from the same machine: