2

The following files contain a line "search somedomain.edu", which prevents me from accessing that domain (DNS error in a browser).

  • /run/resolvconf/interface/systemd-resolved
  • /run/resolvconf/resolv.conf
  • /run/systemd/resolve/stub-resolv.conf
  • /run/systemd/resolve/resolv.conf

If a edit these files manually to remove the line "search somdomain.edu", then it repairs the DNS temporarily, I can access the domain in a browser. After startup, these files are automatically updated and the line "search somdomain.edu" came back, which prevents me from accessing the domain again...

What I have tried. Editing the above files by hand does not work. I also looked for other files using

grep somedomain -r /run

and the same for /etc, /opt/, /usr.

Questions:

  1. How to I prevent these files from being updated?
  2. How to find the script that edits these files?\

More info: This problem appeared after I installed a proprietary debian package novell-iprint (which sets up printers at my institution). It did not work well, and I uninstalled the package. It seems that this package added a startup script that messes up the DNS. My diagnosis is that the removal of the package did not remove that startup script.

jlewk
  • 155

1 Answers1

1

It seems systemd-resolve is in charge of updating these lines from the answer it gets from DHCP.

The issue you encounter is that for hosts in the domains listed in the search directive, it will fail if the system is badly configured.

In my case, I was not able to pin-point the exact reason for failure, but a dpkg-reconfigure resolvconf as suggested by https://askubuntu.com/a/972781 solved the issue for me.

Note that in my case, the /etc/resolv.conf link was left unchanged by reconfiguration, but something else must have changed and has solved the problem for me.