Slow Internet Speed On Linux? This 30-second Fix Makes All The Difference

Trending 1 month ago
Diving penguin (gettyimages-1274512924)
David Merron Photography / Getty Images

DNS stands for Domain Name System, and is for illustration nan phonebook for nan internet. It translates human-readable domain names into IP addresses, truthful browsers cognize really to render a circumstantial website. Without DNS, you'd person to retrieve and type IP addresses alternatively of URLs, and that's not precisely practical.

Along pinch DNS, location is thing called nan DNS cache. It stores DNS records for nan websites you sojourn regularly, truthful loading those websites successful your browser is considerably faster.

However, nan DNS cache isn't cleanable and is susceptible to problems that tin lead to an inability to load sites (or slow loading speeds), wide networking issues, and page crashing. The DNS cache tin go corrupt for a batch of reasons (such arsenic aggregate IP addresses for a azygous domain, malformed entries, aliases moreover a changed IP address). If you find your Linux instrumentality experiencing a slow net relationship while your other machines aren't, nan problem is isolated and tin beryllium resolved.

Also: How to move connected Android's Private DNS mode - and why turning it disconnected is simply a large mistake

When your computer's web velocity slows down (and you've restarted your modem/router arsenic your ISP will instruct you to do), 1 point you tin effort is flushing nan DNS cache.

Here's really you do that connected Linux.

How to flush your DNS cache connected Linux

What you'll need: The only things you'll request for this are a moving lawsuit of Linux and a personification pinch sudo privileges.

The adjacent point you'll want to do is make judge your machine is utilizing a DNS cache. On Linux, this tin beryllium checked pinch nan systemctl bid for illustration so:

Show more

systemctl is-active systemd-resolved

The output should opportunity active. If that's nan case, proceed on.

Now, we'll cheque nan cache size. For this, we'll usage nan resolvectl bid for illustration so:

Show more

resolvectl statistics

In nan output, you'll spot a listing for Current Cache Size. My results show a cache pinch 14 entries (it's debased because I precocious flushed my cache).

It's clip to flush nan cache connected your system. To do that, we'll instrumentality pinch nan resolvectl bid for illustration so:

Show more

resolvectl flush-caches

After you've flushed your cache, you tin make judge it worked by moving nan resolvectl bid again for illustration this:

Show more

resolvectl statistics

The Current Cache Size should now beryllium listed arsenic 0.

Huzzah! You've officially cleared your DNS cache. Hopefully, this will resoluteness your slow net speeds connected your Linux machine. If not, you astir apt person different issues connected your LAN aliases pinch your ISP and will request to analyse further.

Also: 5 amazingly productive things you tin do pinch nan Linux terminal

Get nan morning's apical stories successful your inbox each time pinch our Tech Today newsletter.

Editorial standards
More