Skip to content
Browse files

Modern Ubuntu DNS handling (#134)

Elaborate on how to disable `systemd-resolved` without borking resolution altogether.

Co-authored-by: Paul <>
  • Loading branch information
strictlymike and tarterp committed Jan 3, 2020
1 parent e8a6c9a commit 8c3a9fe910f7b55772acd723cc6ee0a71c60e446
Showing with 20 additions and 1 deletion.
  1. +20 −1
@@ -866,19 +866,38 @@ Use `netstat`, `tcpview`, or other tools to discover what application is bound
to the port, and refer to the corresponding operating system or application
documentation to disable the service.

It may make sense to capture a VM snapshot before undertaking reconfiguration.

For example, Ubuntu commonly enables the `dnsmasq` service in
`/etc/NetworkManager/NetworkManager.conf` with the line `dns=dnsmasq`.
Disabling this (such as by commenting it out) and restarting the
`network-manager` service (e.g. `service network-manager restart`) is
sufficient to free the port before re-launching FakeNet-NG.

In newer versions of Ubuntu or in other distributions, using `lsof -i` may
reveal that `systemd-resolved` is used instead. In these cases, try:
reveal that `systemd-resolved` is used instead. In these cases, you may try
these steps adapted from

sudo systemctl stop systemd-resolved
sudo systemctl disable systemd-resolved

Then in `/etc/NetworkManager/NetworkManager.conf` under the `[main]` section, add a line specifying:


Delete the symlink `/etc/resolv.conf`, i.e. `rm /etc/resolv.conf`.

Finally, restart `NetworkManager`:

sudo systemctl restart NetworkManager

Error: Could not locate WinDivert DLL or one of its components

0 comments on commit 8c3a9fe

Please sign in to comment.
You can’t perform that action at this time.