How to Stop the Ubuntu ‘Wpa_Supplicant’ (Wi-Fi Manager) from Writing Massive Log Files

Why is Wpa_Supplicant Using So Much Disk Space?

In Ubuntu, wpa_supplicant is the background service responsible for managing your Wi-Fi connections, negotiating security keys, and keeping you connected to your router.

Under normal circumstances, it runs quietly in the background. However, if your router has a weak signal, or if there is a subtle incompatibility between your Wi-Fi card driver and the access point, wpa_supplicant can enter a panic loop. It will continuously attempt to reconnect, failing hundreds of times per second, and writing every single failure to the system log (/var/log/syslog). Over a few days, this can generate massive log files (sometimes gigabytes in size), completely filling up your hard drive and crashing the system.

How to Stop Wpa_Supplicant from Flooding the Logs

You can stop this behavior by reducing the verbosity (logging level) of the wpa_supplicant daemon.

  1. Open your Ubuntu Terminal (shortcut: Ctrl + Alt + T).
  2. You need to edit the service file. Type the following command and press Enter:
sudo nano /lib/systemd/system/wpa_supplicant.service
  1. Look for the line that starts with ExecStart=. It usually looks like this:
ExecStart=/sbin/wpa_supplicant -u -s -O /run/wpa_supplicant
  1. You need to add the -q (quiet) flag, or multiple -q flags to suppress all non-critical errors. Modify the line to look like this:
ExecStart=/sbin/wpa_supplicant -u -s -qq -O /run/wpa_supplicant
  1. Save the file in Nano by pressing Ctrl + O, then Enter, then exit with Ctrl + X.
  2. Reload the systemd daemon so it recognises the change:
sudo systemctl daemon-reload
  1. Restart the Wi-Fi service:
sudo systemctl restart wpa_supplicant

The -qq flag forces the service to only log absolute critical fatal errors, preventing the endless spam of minor connection warnings from eating your disk space.

Get the best tech tips delivered straight to your inbox.

Join thousands of readers mastering Apple, Google, Microsoft, and Linux.