I am trying to turn on the network option in raspi-config, but when I do, I get this error:

could not communicate with wpa_supplicant

Then I hit enter to continue and I get this message

There was an error running option N2 Wi-Fi

I am running the newest version of Rasbian. I am also using an Edimax usb Wi-Fi adapter through a USB port on my pi.

  • Which model raspberry pi is it? B, A, 2B, 3B, 3B+, 3A+, Zero, Zero W? Apr 20, 2019 at 14:46
  • I am using a 2B Apr 20, 2019 at 17:40
  • I am using 3B+, so my suggestion might not work for 2B. Now I am thinking of using a 2B with a Wifi dongle to talk to my 3B. So I need to do installation for both Rpis. I am changing my old answer to show what I am going to experiment. You might like to comment and I am happy to make changes.
    – tlfong01
    Apr 21, 2019 at 2:20
  • @Mooshroom14 I found 2B with Raspbian 2019Apr can detect the TP-LINK dongle. No need to install any driver.
    – tlfong01
    Apr 21, 2019 at 7:54
  • Please edit your question and add the output of these commands: iw dev and sudo cat /etc/wpa_supplicant/wpa_supplicant.conf but obscure the password.
    – Ingo
    Apr 21, 2019 at 8:35

4 Answers 4


Try run wpa_supplicant interactively:

sudo killall wpa_supplicant
sudo wpa_supplicant -c /etc/wpa_supplicant/wpa_supplicant.conf -d -iwlan0

This will provide a lot of diagnostic logging; in my case (using a USB Wifi dongle), "Driver does not support authentication/association or connect commands". Once I downloaded the off-kernel driver, wpa_supplicant worked fine and so did raspi-config's N2 configuration.

Reference: https://unix.stackexchange.com/questions/400101/how-to-get-the-wifi-working-with-r8188eu-driver-on-my-raspberry-pi

  • 1
    Running wpa_supplicant interactively is a very useful way of debugging. This just helped me fix an issue with a character that looked like an apostrophe but which wasn't. Oct 9, 2020 at 19:32
  • this should be in the official documentation. Mar 18, 2021 at 17:55
  • That saved my day! After trying a bunch of solutions I had an error with the apostrophe as well !! Sep 25, 2021 at 20:50

You are using a Raspberry Pi 2B. This model does not have an on-board WiFi device so it does not make sense to enable WiFi with raspi-config. It seems this results in the error message you reported.

  • I am using an Edimax wifi adapter attached through a usb port. Apr 20, 2019 at 21:17
  • @Mooshroom14 That is a very important detail! Please edit your question and complete it with this information.
    – Ingo
    Apr 20, 2019 at 21:49
  • Just edited this. Apr 20, 2019 at 22:18


How to use Raspbian version 2019 April to config WiFi for Rpi 2B?



The OP has a Rpi2B with a WiFi dongle. He has a problem configing Wifi. This answer has two parts:

  1. Install Raspbian on 3B+ and config Wifi.

  2. Use the same SD card to config the 2B.

Setting up Rpi2B with a Wifi Dongle

rpi2b and wifi dongle

Preparing a micro SD card with Raspbian stretch 2018apr image for Rpi2B and Wifi Dongle

rpi2b and wifi dongle

Checking out if Rpi2B Raspbian stretch 2019apr can detect TP-LINK TL-WN727N

I found the setup can detect the TP-LINK Wifi dongle. I remember I needed to google a list of dongles that Rpi can detect. So I would suggest you to check that out by the command lsusb. If you can detect the dongle, then you are almost there! :)

tplink wifi adapter

Entering Wifi SSID and password at desktop

setting up Wifi in desktop is even easier. The steps are listed below.

  1. Select your Wifi country (otherwise top right network icon won't work).

  2. At top right corner, click the double red cross icon (Wifi and Ethernet).

  3. Select to turn on your network in the list (my network name is tlfong01).

  4. Enter password (pre shared key).

That is all.

Good luck.

wifi password

/ to continue, ...

The paragraphs below are out of date and need to be modified and/or deleted, after I have completed the answer above.

Let me see.

I am using Rpi3B+ and Raspbian 2019apr.

When you are configuring WiFi under terminal mode, you should have gone through the last couple of steps as shown below:

wifi config 1

wifi config 2

wifi config 3

wifi config 4

You must enter the correct ssid and passphrase, otherwise you will get the N2 Wi-fi error message.

The "ssid" and "passphrase" should be the same for your other WiFi devices, such as your mobile phone. You might like to try your ssid and passphrase with your mobile phone first, to make sure they are OK.

And perhaps you forgot to switch on your router? :)

  • my router is usually on, and when i go to do what you said, I get the errors shown in my question. Apr 20, 2019 at 17:49

Had the same problem after installing OMV5 with raspbian desktop version. I then uninstalled OMV5 but this problem arised...

The problem in my case, had to do with dhcpcd service being missing, not being able to get an IP. You can check if it is available with the next command.

pi@rpi:~ $ sudo service --status-all
 [ - ]  alsa-utils
 [ - ]  anacron
 [ - ]  apparmor
 [ + ]  avahi-daemon
 [ + ]  bluetooth
 [ - ]  cgroupfs-mount
 [ - ]  console-setup.sh
 [ + ]  cron
 [ + ]  cups
 [ + ]  cups-browsed
 [ + ]  dbus
 [ + ]  dhcpcd
 [ + ]  docker
 [ + ]  dphys-swapfile
 [ + ]  fake-hwclock
 [ - ]  fio
 [ - ]  hwclock.sh
 [ - ]  keyboard-setup.sh
 [ + ]  kmod
 [ + ]  lightdm
 [ - ]  mdadm
 [ - ]  mdadm-waitidle
 [ + ]  monit
 [ + ]  networking
 [ - ]  nfs-common
 [ + ]  nginx
 [ - ]  paxctld
 [ - ]  plymouth
 [ - ]  plymouth-log
 [ - ]  postfix
 [ - ]  pppd-dns
 [ + ]  procps
 [ - ]  quota
 [ - ]  quotarpc
 [ + ]  raspi-config
 [ ? ]  rng-tools
 [ - ]  rpcbind
 [ - ]  rsync
 [ + ]  rsyslog
 [ - ]  saned
 [ + ]  ssh
 [ - ]  sudo
 [ + ]  triggerhappy
 [ + ]  udev
 [ - ]  udhcpd
 [ + ]  watchdog
 [ - ]  wd_keepalive
 [ - ]  x11-common
 [ + ]  zerotier-one

Next, I configured my raspberry with a static IP to have network connectivity. Assuming you are using WIFI interface and you have a valid confguration on /etc/wpa_supplicant/wpa_supplicant.conf:

sudo wpa_supplicant -c/etc/wpa_supplicant/wpa_supplicant.conf -d -iwlan0
sudo ifconfig wlan0 netmask
sudo route add default gw wlan0
sudo echo nameserver > /etc/resolv.conf

You can also use eth0 interface and skip wpa_supplicant step.

And finally, I installed dhcpcd

sudo apt install dhcpcd5

After I reboot the Raspberry Pi, Wi-Fi manager plugin and raspi-config worked again.

Check also these links:


How do I set up networking/WiFi/static IP address on Raspbian/Raspberry Pi OS?



Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.