DNS Error seen after hour of use

Should I post my /etc/resolv.conf? I do not know enough about networking to understand if that creates a vulnerability.

Have you rebooted your router?

Set your lease time in your router to a day (or longer).


Also please post your services:

systemctl --type=service  > services.log  

Check your home directory for the services.log file.

1 Like

Sadly I cannot post images so I cannot show you what I see with the DNS issue. If I try to just use searX it is unable to connect.

I have not rebooted my router. I do not experience this problem on windows.

Here is my /etc/resolv/conf:

# Generated by NetworkManager
search nc.rr.com
nameserver 2001:1998:f00:1::1
# NOTE: the libc resolver may not support more than 3 nameservers.
# The nameservers listed below may not be recognized.
nameserver 2001:1998:f00:2::1

Here are my services:

File: services.log
UNIT                                                                                      LOAD   ACTIVE SUB     DESCRIPTION
ananicy-cpp.service                                                                       loaded active running Ananicy-Cpp - ANother Auto NICe daemon in C++
avahi-daemon.service                                                                      loaded active running Avahi mDNS/DNS-SD Stack
bluetooth-autoconnect.service                                                             loaded active running Bluetooth autoconnect service
bluetooth.service                                                                         loaded active running Bluetooth service
bolt.service                                                                              loaded active running Thunderbolt system service
cronie.service                                                                            loaded active running Periodic Command Scheduler
dbus.service                                                                              loaded active running D-Bus System Message Bus
irqbalance.service                                                                        loaded active running irqbalance daemon
key-mapper.service                                                                        loaded active running Service to inject keycodes without the GUI application
kmod-static-nodes.service                                                                 loaded active exited  Create List of Static Device Nodes
lvm2-monitor.service                                                                      loaded active exited  Monitoring of LVM2 mirrors, snapshots etc. using dmeventd or progress polling
memavaild.service                                                                         loaded active running Daemon that keeps amount of available memory
ModemManager.service                                                                      loaded active running Modem Manager
NetworkManager.service                                                                    loaded active running Network Manager
nohang-desktop.service                                                                    loaded active running Sophisticated low memory handler
optimus-manager.service                                                                   loaded active running Optimus Manager Commands Daemon
plymouth-deactivate.service                                                               loaded active exited  Deactivate Plymouth Boot Screen
plymouth-quit-wait.service                                                                loaded active exited  Hold until boot process finishes up
plymouth-quit.service                                                                     loaded active exited  Terminate Plymouth Boot Screen
plymouth-read-write.service                                                               loaded active exited  Tell Plymouth To Write Out Runtime Data
plymouth-start.service                                                                    loaded active exited  Show Plymouth Boot Screen
polkit.service                                                                            loaded active running Authorization Manager
preload.service                                                                           loaded active running Adaptive readahead daemon
prelockd.service                                                                          loaded active running Daemon that prevents eviction of executables/libraries from memory
rtkit-daemon.service                                                                      loaded active running RealtimeKit Scheduling Policy Service
sddm-plymouth.service                                                                     loaded active running Simple Desktop Display Manager
[email protected]:intel_backlight.service                                       loaded active exited  Load/Save Screen Backlight Brightness of backlight:intel_backlight
[email protected]:tpacpi::kbd_backlight.service                                      loaded active exited  Load/Save Screen Backlight Brightness of leds:tpacpi::kbd_backlight
systemd-binfmt.service                                                                    loaded active exited  Set Up Additional Binary Formats
[email protected]\x2duuid-d42c7a39\x2d5e07\x2d4c69\x2db652\x2da230f397013d.service loaded active exited  File System Check on /dev/disk/by-uuid/d42c7a39-5e07-4c69-b652-a230f397013d
[email protected]\x2duuid-E4A8\x2dF841.service                                     loaded active exited  File System Check on /dev/disk/by-uuid/E4A8-F841
systemd-journal-flush.service                                                             loaded active exited  Flush Journal to Persistent Storage
systemd-journald.service                                                                  loaded active running Journal Service
systemd-logind.service                                                                    loaded active running User Login Management
systemd-modules-load.service                                                              loaded active exited  Load Kernel Modules
systemd-random-seed.service                                                               loaded active exited  Load/Save Random Seed
systemd-remount-fs.service                                                                loaded active exited  Remount Root and Kernel File Systems
systemd-sysctl.service                                                                    loaded active exited  Apply Kernel Variables
systemd-timesyncd.service                                                                 loaded active running Network Time Synchronization
systemd-tmpfiles-setup-dev.service                                                        loaded active exited  Create Static Device Nodes in /dev
systemd-tmpfiles-setup.service                                                            loaded active exited  Create Volatile Files and Directories
systemd-udev-trigger.service                                                              loaded active exited  Coldplug All udev Devices
systemd-udevd.service                                                                     loaded active running Rule-based Manager for Device Events and Files
systemd-update-utmp.service                                                               loaded active exited  Record System Boot/Shutdown in UTMP
systemd-user-sessions.service                                                             loaded active exited  Permit User Sessions
systemd-vconsole-setup.service                                                            loaded active exited  Setup Virtual Console
[email protected]                                                          loaded active exited  Create swap on /dev/zram0
udisks2.service                                                                           loaded active running Disk Manager
upower.service                                                                            loaded active running Daemon for power management
uresourced.service                                                                        loaded active running User resource assignment daemon
[email protected]                                                             loaded active exited  User Runtime Directory /run/user/1000
[email protected]                                                                         loaded active running User Manager for UID 1000
vpnagentd.service                                                                         loaded active running Cisco AnyConnect Secure Mobility Client Agent
wpa_supplicant.service                                                                    loaded active running WPA supplicant

LOAD   = Reflects whether the unit definition was properly loaded.
ACTIVE = The high-level unit activation state, i.e. generalization of SUB.
SUB    = The low-level unit activation state, values depend on unit type.

 ╭─[email protected] in ~ 
 ╰─λ ping -c 3
PING ( 56(84) Bytes an Daten.

--- ping-Statistik ---
3 Pakete übertragen, 0 empfangen, 100% packet loss, time 2087ms

 ╭─[email protected] in ~ took 12s
[🔴] × ping -c 3
PING ( 56(84) Bytes an Daten.

--- ping-Statistik ---
3 Pakete übertragen, 0 empfangen, 100% packet loss, time 2047ms

 ╭─[email protected] in ~ took 12s
[🔴] × ping -c 3
PING ( 56(84) Bytes an Daten.
64 Bytes von icmp_seq=1 ttl=58 Zeit=26.0 ms
64 Bytes von icmp_seq=2 ttl=58 Zeit=14.7 ms
64 Bytes von icmp_seq=3 ttl=58 Zeit=22.6 ms

--- ping-Statistik ---
3 Pakete übertragen, 3 empfangen, 0% packet loss, time 2003ms
rtt min/avg/max/mdev = 14.743/21.121/26.000/4.716 ms
 ╭─[email protected] in ~ took 1ms
[🔴] × LANG=C ping -c 3 2001:1998:f00:2::1
ping: connect: Network is unreachable

I am no expert for DNS but I would try to change DNS to


Ok. I am still a bit confused as to why I am seeing an issue now with this. I have no problem on windows and I have done now custom DNS configuration there. Also I am unsure as to how this effects whether or not stuff conks out after an hour. Is it possible that my settings got corrupted during a package manager update?

Try this:

Make a backup of /etc/resolv.conf and remove any file write protection (if enabled):

sudo cp /etc/resolv.conf /etc/resolv.conf.bak && sudo chattr -i /etc/resolv.conf

Then, run the following command to auto-generate an /etc/resolv.conf file with Google as the DNS servers:

echo -e "nameserver\nsearch" | sudo tee /etc/resolv.conf

If desired, once you have completed the edits you can write protect the new resolv.conf (optional).

To write protect /etc/resolv.conf issue the following command::

sudo chattr +i /etc/resolv.conf

To remove write protection from /etc/resolv.conf issue the following command::

sudo chattr -i /etc/resolv.conf

To restore /etc/resolv.conf to its original state issue the following command:

sudo chattr -i /etc/resolv.conf; sudo cp /etc/resolv.conf.bak /etc/resolv.conf 

You could alternately test the cloudflare dns servers:

Run the following command to auto-generate an /etc/resolv.conf file with cloudflare as the DNS servers:

echo -e "nameserver\nsearch" | sudo tee /etc/resolv.conf

Reboot after updating your nameservers.


Just FYI:

What Windows does couldn't possibly be more irrelevant, as Linux is very different from Windows.

I have seen instances where Windows boxes were running fine but Linux comps on the same network couldn't hold a connection until he router was rebooted. I have even seen where the router required being reset to the factory default to work with Linux (when Windows was unaffected). Apples to oranges my friend.

Rebooting your router should always be the first step performed when network troubleshooting.

Changing your nameservers should hopefully correct your issue.


Thank you so much for the advice. I am learning a lot and really appreciate the guidance. Ill reboot my router then and see if that helps and then try the setting the DNS server to google and then cloudflare if that doesn't work. Thanks again for all of the advice.

I am sorry if I sounded snobby in that last comment. I was just confused because I don't know the networking differences. Thank you so much for the clarification and explanation.


Hello. I haven't been much on my linux side for an extended period of time until now. I changed my DNS to google and rebooted and made it write protected as it was getting over written. I also reset the router for my network.

I am still seeing a problem. This time, after the duration, my network connection to the router is dropped. Rebooting the router does not fix the issue. Rebooting the PC does.

When I reboot the router. I get a message on Garuda that the network rejected the ip of my device. I am unsure of what to make of this.

Are you able to log in to your router? It might be helpful to examine the preconfigured settings. If you have never logged in to it before, just do a web search for the brand and model and you should be able to find instructions for your device easily enough. Typically you can find default credentials printed on the sticker on the device itself, or sometimes just on the manufacturer's website.

Usually you can log in to your router by typing your gateway IP address into your web browser. You can find your gateway IP address with the route -n command. Here you can see mine is (highlighted):

As for this:

These appear to be IP addresses for Charter Communications (aka Spectrum, formerly Time Warner or Road Runner). Are they your ISP? Sometimes your ISP will load their DNS servers into your router to use as the defaults. It makes it very easy for them to collect data about what their subscribers are doing online.

A lot of times they are really crappy DNS servers, and it looks like in your initial problem the servers were down (that's why @SGS couldn't get a ping). Windows may have still been working for you because it probably has backup DNS servers baked in, but Linux tends to do as it is told and just tried the options it was given.

All that to say, sometimes you can reconfigure your DNS servers from the router itself and it can prevent issues with your DNS configurations being ignored, reset, or otherwise overridden.

This could be related to the way your router handles DHCP. Once rebooted, it may have "forgotten" the assignment that it had given your computer and it caused a conflict. Often modern SOHO routers are able to automatically reconfigure DHCP assignments immediately when booting, but not necessarily.

While you are logged in to your router, you could assign your PC a reserved IP address if you want to (the router sets aside the IP for the MAC address of the device). That way you don't have to worry about DHCP, you will always have the same IP address on your network. If you had to reboot your router you wouldn't get kicked off the network.

Your problems sound really frustrating, but I have to say it sounds like your ISP is at least partly to blame.


Thank you so much. I will give those I try. I have logged into the router to configure the network security and setup a guest network but I never assigned my device a static IP addr. Thank you for the suggestion.

Spectrum is my ISP. I am confused about one thing. Why does me rebooting my PC fix this issue temporarily if it is something to do with the router? Also nothing has changed with my ISP to my knowledge since this issue started occurring.

I have another friend on Manjaro on the same network and he is not experiencing this issue.

Thanks again for all of the help.

That is a good question. I do not know the answer to that I am afraid.

Just to clarify though: my suspicion is the DNS server that is being assigned to your machine could be causing problems. So not exactly the router itself, but a configuration that might be programmed in to your router.

My ISP also put their DNS servers as default in my router, but after logging in I was able to change them to use OpenDNS. When you boot your machine, NetworkManager updates /etc/resolve.conf with whatever information it gets from your gateway. I'm sure you can change that behavior somehow, I don't know too much about it, but for me that information comes from the OpenDNS IP addresses I punched in to my router. It's worth a shot! :man_shrugging:

Does your friend have the same router? I think it would be interesting to compare the DNS settings of your router consoles and see if you have the same DNS servers configured.

Be sure you disable MAC address randomization.

Then reboot comp and router.

1 Like

Hi tbg,

Didn't want to make a new post of this.
Just more of a curiosity really.
My /etc/resolv.conf file keeps changing now and then when doing a garuda-update.
I have a backup for how i like it so it's easy to set it up again as you pointed out in your post.
But why does it keep changing? Which component of the update process keeps messing with it and is it a deliberate choice of the maintainers team to keep updating the default DNS settings?


You shouldn't change your /etc/resolv.conf. /etc/resolv.conf is NetworkManager's territory. You should change your DNS settings in NetworkManager instead. On dr460nized, you can do this from the connection editor in the system tray.

Hello TNE,

I think that's great advice for a novice, but as you can see from tbg's post above, manual management of the /etc/resolv.conf can be done and is described in many a linux practitioner's posts over the web.
My questions was what process/component changes that file?
As you pointed out that file gets generated directly or indirectly by NetworkManager.
But who chooses those new DNS addresses and why does it happen during the system update process without a prompt or a warning?
Is it your advice that after each update I check the settings in NetworkManager using the gui connection editor?

Kind Regards

To get an idea of how NetworManager handles /etc/resolv.conf (and consequently relevant updates might have an impact on this) I think you could give a look at this Arch wiki article and relevant links:
That's why, if you want to use a specific DNS server, the procedure above and also the Garuda Assistant feature changing the DNS server use:

With that, in my opinion, you're not going to have troubles with changing DNS servers in the future.


Whoever maintains the gateway NetworkManager is connecting to at that time chooses.

If it is your own gateway (home router, for example) you should log in to the admin portal and change the DNS settings there. That way any device that connects to your network will get the DNS servers you prefer.

If you do not have access to the gateway or cannot change it for some other reason, setting the immutable character as TBG mentioned will prevent it from being overwritten every time NetworkManager refreshes this process.


Also, just FYI, there are some routers that do not work well with cloudflare as the DNS server when using Linux. In those rare instances you would want to test Google's DNS servers (or others), to see if your connectivity improves.

You could also try the method @TNE suggested:


I'm sorry, I don't get the point in changing the file yourself when it is for all intents and purposes NetworkManager's territory. If you don't want NetworkManager to take control of the file, then don't use NetworkManager, or tell NetworkManager to stop touching it via a config file as shown on the Arch wiki.

The dhcp server. If you change the config in NetworkManager to ignore the dhcp server's info (called DHCP (Address only)) then it will use the address you configure in networkmanager.
And why without a warning? Because pacman is stupid. Pacman copies files from archives into directories, that's all it does. It doesn't do any checks to ensure it doesn't delete user configs (unless we're talking backup files that generate .pacnew files).

No, you'd only have to change it once, that's the point.

1 Like