If changing your default network interface from, say wireless, to wired, you may have to explicitly set default gateway and DNS options.
Ther should be a file under /etc/NetworkManager/system-connections/
which will link to the wired interface.
Open that file in your favourite editor, vim.
vim /etc/NetworkManager/system-connections/enp0s31f6.nmconnection
[ipv4]
method=manual
address1=10.0.0.2/24,10.0.0.1
dns=10.0.0.1
dns
will set the default DNS serveraddress1
sets the static IP, and the gateway.address1=10.0.0.2/24
sets the static IP- adding
,10.0.0.1
will set the default gateway to10.0.0.1
.
See Also
- Default explicit equality operator
- Mistakes
- compile_commands.json with CMake
- Samsung Magician Stops Ctrl-w From Working
- Disable Suspend on Lid Close With Opensuse Tumbleweed with command line
Comments
Any comments? Create a new discussion on GitHub.There used to be an inline comment form here, but it was removed.