I have an ubuntu 15.10 server which utilizes wpa_supplicant to connect to wireless network profiles created with wpa_passphrase. On a fresh reboot, the first time I call
sudo wpa_supplicant -B -i wlp2s0 -c ./MVS (where MVS is the name of a saved profile for a network) I get the output
Successfully initialized wpa_supplicant Could not read interface p2p-dev-wlp2s0 flags: No such device
but the exit code is zero, and I can confirm that I am in fact connected to the wireless network by running
sudo iw wlp2s0 link
However, subsequent calls to wpa_supplicant (for the other profiles or even the same one) yield a more verbose output:
Successfully initialized wpa_supplicant Could not read interface p2p-dev-wlp2s0 flags: No such device nl80211: Could not set interface 'p2p-dev-wlp2s0' UP nl80211: deinit ifname=p2p-dev-wlp2s0 disabled_11b_rates=0 p2p-dev-wlp2s0: Failed to initialize driver interface P2P: Failed to enable P2P Device interface
wpa_supplicant still returns an exit code of zero, but the wireless device is most definitely not connected to any network this time. Any advice or thoughts would be greatly appreciated, I don't know how to debug this or fix it.