Today I f up by trying to fix a problem with a single network and cause problem for my machine in every network.
I’ve deleted /etc/NetworkManager/NetworkManager.conf and ever since then I need to manually assign dns address for every single new network.
What should I do?
Edit: this my current NetworkManager.conf
# Configuration file for NetworkManager.
# See "man 5 NetworkManager.conf" for details.
# The directories /usr/lib/NetworkManager/conf.d/ and /run/NetworkManager/conf.d/
# can contain additional .conf snippets installed by packages. These files are
# read before NetworkManager.conf and have thus lowest priority.
# The directory /etc/NetworkManager/conf.d/ can contain additional .conf
# snippets. Those snippets are merged last and overwrite the settings from this main
# The files within one conf.d/ directory are read in asciibetical order.
# You can prevent loading a file /usr/lib/NetworkManager/conf.d/NAME.conf
# by having a file NAME.conf in either /run/NetworkManager/conf.d/ or /etc/NetworkManager/conf.d/.
# Likewise, snippets from /run can be prevented from loading by placing
# a file with the same name in /etc/NetworkManager/conf.d/.
# If two files define the same key, the one that is read afterwards will overwrite
# the previous one.
# When debugging NetworkManager, enabling debug logging is of great help.
# Logfiles contain no passwords and little sensitive information. But please
# check before posting the file online. You can also personally hand over the
# logfile to a NM developer to treat it confidential. Meet us on #nm on Libera.Chat.
# You can also change the log-level at runtime via
# $ nmcli general logging level TRACE domains ALL
# However, usually it's cleaner to enable debug logging
# in the configuration and restart NetworkManager so that
# debug logging is enabled from the start.
# You will find the logfiles in syslog, for example via
# $ journalctl -u NetworkManager
# Please post full logfiles for bug reports without pre-filtering or truncation.
# Also, for debugging the entire `journalctl` output can be interesting. Don't
# limit unnecessarily with `journalctl -u`. Exceptions are if you are worried
# about private data. Check before posting logfiles!
# Note that debug logging of NetworkManager can be quite verbose. Some messages
# might be rate-limited by the logging daemon (see RateLimitIntervalSec, RateLimitBurst
# in man journald.conf). Please disable rate-limiting before collecting debug logs!
Using resolvectl status I noticed that resolvectl set the Gateway as the DNS. And because my router is not a DNS server it fails to return data.
Setting a new dns using nmcli connection modify works. But I want something that will work automaticly.
Glad that it works for you, but it is not normal for Fedora to run in the fallback modus. If all other devices work, I assume they get network parameters from DHCP, and so is Fedora able to do without any manual intervention. If your router is not a DNS server, it should at least provide DNS server addresses in the DHCP answer.
The two additions in the NetworkManager.conf file should be not necessary.
Key is that /etc/resolv.conf is not manually created, but a symlink to
In this configuration, NetworkManager passes the DNS server automatically to systemd-resolved, and everything should work fine.
Of course, if your router is not standard and all devices have to be manually configured, then Fedora should be configured too, but then you can set your
IPV4 method to “Automatic Address only” and specify the DNS servers in the DNS entry box.
It is not usual to refer to Windows in the Linux world, but if you have an automatically configured Windows box on the net, the command prompt command “ipconfig /all” gives a nice overview of the network config obtained by DHCP.