# [SOLVED] systemd NetworkManager wpa_supplicant

## nimar

I recently "upgraded" to systemd from openrc. all went pretty smooth until it came to networking. I decided to go with NetworkManager vs. wireless-tools. I cannot locate a good howto anywhere that discusses weather or not NetworkManager requires wpa_supplicant to connect to wpa2-psk? From what I have read about NwM it should be able to handle all security on its own. Honestly, I can't get the Wifi to work at all now.

It's a dlan card using ath9k and work w/openrc.

Any help is appreciated.

[EDIT] 

I forgot to mention systemctl status NetworkManager.service reports NetworkManager[419]: <info> (wlan0): supplicant interface state: disconnected -> inactive 

journalctl -xn reports wpa_supplicant[285]: ioctl[SIOCSIWSCAN]: Operation not supported

-NLast edited by nimar on Sat Jun 07, 2014 9:53 pm; edited 1 time in total

----------

## DONAHUE

```
emerge -av wpa_supplicant networkmanager
```

 you might need to do this even if you ran emerge -uND world after adding the systemd USE flag.

----------

## nimar

Thanks DONAHUE!

 *Quote:*   

> 
> 
> ```
> 
> emerge -av wpa_supplicant networkmanager
> ...

 

I re-emerged both... What I have realized with systemd when I start wpa_supplicant

```
systemctl start wpa_supplicant.service
```

is that it is not utilizing the wpa_supplicant driver nl80211. if I start wpa_supplicant manually 

```
wpa_supplicant -c/etc/wpa_supplicant/wpa_supplicant.conf -iwlan0 -Dnl80211
```

 everything starts with no issue and I have a wifi link.  I checked  /usr/lib/systemd/system/wpa_supplicant.service and it starts wpa_supplicant.service without the "-Dnl80211" 

```
[Service]...

ExecStart=/usr/sbin/wpa_supplicant -c/etc/wpa_supplicant/wpa_supplicant.conf -u
```

 which I changed to 

```
..wpa_supplicant.conf -Dnl80211 -u
```

 and started the service with no luck as it is still not loading nl80211. I think I am missing something which is why I ask if I NEED to use wpa_supplicant any longer w/NwM. shouldn't NwM bring up the interface with ath9k module or do I need a supplemental NwM package?

Thanks again!

-N

----------

## DONAHUE

network manager should start wpa_supplicant, if wpa_supplicant is already running when networkmanager wants to start it, failure results. 

I'm seeing:

```
systemctl | grep -i wpa
```

              wpa_supplicant.service loaded active running   WPA supplicant

```
systemctl | grep -i networkmanager
```

 NetworkManager.service loaded active running   Network Manager

```
systemctl | grep -i wlan0
```

                     sys-devices-pci0000:00-0000:00:16.2-usb3-3\x2d4-3\x2d4:1.0-net-wlan0.device loaded active plugged   EUB9801 802.11abgn Wireless Adapter [Ralink RT3572]

                                                                 sys-subsystem-net-devices-wlan0.device                                                                      loaded active plugged   EUB9801 802.11abgn Wireless Adapter [Ralink RT3572]]

----------

## nimar

Thank you DONAHUE.

I stumbled onto the conflicting wpa_supplicant instances  a few hours after I posted my reply. I also had a separate dhcpcd service running which conflicted as well. All is working now and WiFI is up and running!

Regards

-N

----------

## DONAHUE

Good show!

----------

