// DevOps
Network Troubleshooting for Beginners: Part 2 — DNS
Published on 2026-09-22
It happens: the computer has an address, the router responds, ping 8.8.8.8 works, but websites in the browser do not open. Most often the cause is DNS — the system that translates domain names into IP addresses. If a name cannot be converted to an address, the browser doesn’t know where to connect, even with a working connection.
How DNS records are structured and what types they are is covered in detail in the article DNS setup for email and website: Part 1 — What DNS is and the main records (A, MX). Here — only diagnostics.
Which DNS server the system uses
Linux with systemd-resolved (Ubuntu, Debian and others):
resolvectl statusThe output shows DNS Servers for each interface. On other systems the servers are listed in /etc/resolv.conf:
cat /etc/resolv.confWindows:
ipconfig /allThe DNS Servers line shows which server the computer queries. Usually this is the router or the provider’s server.
Checking via the system mechanism
Linux with systemd-resolved:
resolvectl query google.comThis command goes the same way as ordinary programs, so it shows what the browser and applications see.
Windows and macOS:
nslookup google.comExample of a successful nslookup response:
Server: 192.168.1.1
Address: 192.168.1.1#53
Non-authoritative answer:
Name: google.com
Address: 142.250.184.110- Server — the DNS server that answered;
- Name / Address — the requested name and the found address;
- Non-authoritative answer — the answer was not from the server authoritative for the domain, but from an intermediate server’s cache. For diagnostics this is fine.
An error looks like this:
** server can't find example.invalid: NXDOMAINNXDOMAIN means that the name does not exist. If this is returned for an existing name, the server is broken or the response is spoofed.
dig: detailed response
dig shows the query and response in full. On Linux it is included in the dnsutils package (Debian, Ubuntu) or bind-utils (RHEL and derivatives).
dig google.comKey parts of the output:
;; ->>HEADER<<- opcode: QUERY, status: NOERROR, id: 12345
;; QUESTION SECTION:
;google.com. IN A
;; ANSWER SECTION:
google.com. 242 IN A 142.250.184.110
;; SERVER: 192.168.1.1#53(192.168.1.1)- status —
NOERRORon success,NXDOMAIN— name does not exist,SERVFAIL— the server could not obtain an answer; - ANSWER SECTION — found records; the number after the name is the time-to-live (TTL) of the record in seconds;
- SERVER — the server that answered.
Short output with just addresses:
dig +short google.comMain technique: ask another server
If a name does not resolve, ask the same question to a public DNS server:
dig @8.8.8.8 google.com
nslookup google.com 8.8.8.8- if there is an answer via
8.8.8.8but not via your server — the problem is with the router’s or provider’s DNS. The solution is to change DNS servers in the network or router settings; - no response from any server — DNS requests are likely being blocked on the path (port 53 UDP and TCP) or there is a connectivity problem;
- different servers return different addresses — possible response spoofing or a change in the record that has not yet propagated due to TTL.
Summary
resolvectl statusoripconfig /all— which DNS server is used;resolvectl queryandnslookup— check via the same path as applications;dig— detailed response and query to a specific server via@.
If the name resolves to the correct address, the host responds to ping, but the site still does not open, the next step is to check whether the required service is running on the server. The next part covers that.
Resources
// Reviews
Related reviews
Huge thanks to Mikhail for the work — I'm very pleased with the result. Special thanks for his recommendations during setup: from my rather muddled brief (I know little about servers), Mikhail, through clarifying questions and suggestions, formed a clear understanding of what the final build would accomplish and how best to organize everything. I recommend him!
Many thanks to Mikhail for the work, I am very pleased with the result. I especially thank him for the recommendations during the setup process — from my rather muddled brief (and I know little about servers) Mikhail, …
MikroTik hAP router setup. I'll set up a MikroTik Wi‑Fi router for you.
2025-07-21 · ★ 5/5
An excellent specialist, a savvy expert, and a wonderful person. In an hour he fixed what we'd been racking our brains over for days! I'm sure this won't be the last time we rely on his boundless professionalism.
An excellent specialist, a savvy expert, and a wonderful person. In an hour he fixed for us what we had been scratching our heads over for days! I'm sure this won't be the first time we make use of his boundless …
MikroTik hAP router setup. I'll configure a MikroTik Wi-Fi router for you.
2025-05-28 · ★ 5/5
A professional approach to the job!
Professional approach to the job!
MikroTik hAP router setup. I'll set up a MikroTik Wi-Fi router for you.
2025-03-31 · ★ 5/5
Knows their stuff, gets things done. Everything was prompt and to the point; I was satisfied with the collaboration.
Knows, can, does. Everything was prompt and to the point; I was satisfied with the collaboration.
MikroTik hAP router setup. I'll set up a MikroTik Wi‑Fi router for you.
2025-03-14 · ★ 5/5
Thanks! We set up the router according to my technical specification, with a full explanation of what we're doing.
Thank you! The router was configured according to my technical specification, with a full explanation of what we are doing
MikroTik hAP router setup. I'll configure a MikroTik Wi‑Fi router for you.
2025-03-09 · ★ 5/5
Everything's great! Thanks! I recommend it.
Everything's great! Thank you! I recommend it
// Contact
Need help?
Get in touch with me and I'll help solve the problem
I reply within one business day (03:00-13:00 GMT)
Или оставьте заявку здесь:
// Related