# deauthenticating and  interface keeps on changing

## slackline

Hi,

I've encountered problems since upgrading to =net-misc/NetworkManager-1.8.4.

The nm-applet (also updated to =net-misc/nm-applet-1.8.2) would connect then disconnect straight away.  Looking at dmesg I found...

```

    9.044872] ip (5251) used greatest stack depth: 12784 bytes left

[   10.907835] IPv6: ADDRCONF(NETDEV_UP): wlp2s0: link is not ready

[   10.922558] IPv6: ADDRCONF(NETDEV_UP): wlp2s0: link is not ready

[   10.947493] IPv6: ADDRCONF(NETDEV_UP): wlp2s0: link is not ready

[   11.049512] IPv6: ADDRCONF(NETDEV_UP): wlp2s0: link is not ready

[   12.176078] IPv6: ADDRCONF(NETDEV_UP): wlp2s0: link is not ready

[   13.258212] wlp2s0: authenticate with 60:e3:27:70:e0:3e

[   13.276894] wlp2s0: send auth to 60:e3:27:70:e0:3e (try 1/3)

[   13.280272] wlp2s0: authenticated

[   13.280958] wlp2s0: associate with 60:e3:27:70:e0:3e (try 1/3)

[   13.284998] wlp2s0: RX AssocResp from 60:e3:27:70:e0:3e (capab=0x31 status=0 aid=3)

[   13.285107] wlp2s0: associated

[   13.285156] IPv6: ADDRCONF(NETDEV_CHANGE): wlp2s0: link becomes ready

[   16.559075] wlp2s0: deauthenticating from 60:e3:27:70:e0:3e by local choice (Reason: 3=DEAUTH_LEAVING)

[   17.008572] IPv6: ADDRCONF(NETDEV_UP): wlp2s0: link is not ready

[   18.140351] IPv6: ADDRCONF(NETDEV_UP): wlp2s0: link is not ready

[   19.233547] wlp2s0: authenticate with 60:e3:27:70:e0:3e

[   19.252812] wlp2s0: send auth to 60:e3:27:70:e0:3e (try 1/3)

[   19.255409] wlp2s0: authenticated

[   19.255817] wlp2s0: associate with 60:e3:27:70:e0:3e (try 1/3)

[   19.259844] wlp2s0: RX AssocResp from 60:e3:27:70:e0:3e (capab=0x31 status=0 aid=3)

[   19.259906] wlp2s0: associated

[   19.259941] IPv6: ADDRCONF(NETDEV_CHANGE): wlp2s0: link becomes ready

[   21.739994] wlp2s0: deauthenticating from 60:e3:27:70:e0:3e by local choice (Reason: 3=DEAUTH_LEAVING)

[   22.184093] IPv6: ADDRCONF(NETDEV_UP): wlp2s0: link is not ready

[   23.307192] IPv6: ADDRCONF(NETDEV_UP): wlp2s0: link is not ready

[   24.401023] wlp2s0: authenticate with 60:e3:27:70:e0:3e

[   24.420708] wlp2s0: send auth to 60:e3:27:70:e0:3e (try 1/3)

[   24.422565] wlp2s0: authenticated

[   24.423704] wlp2s0: associate with 60:e3:27:70:e0:3e (try 1/3)

[   24.447769] wlp2s0: RX AssocResp from 60:e3:27:70:e0:3e (capab=0x31 status=0 aid=3)

[   24.447890] wlp2s0: associated

[   24.447971] IPv6: ADDRCONF(NETDEV_CHANGE): wlp2s0: link becomes ready

[   26.894566] wlp2s0: deauthenticating from 60:e3:27:70:e0:3e by local choice (Reason: 3=DEAUTH_LEAVING)

[   26.929082] IPv6: ADDRCONF(NETDEV_UP): wlp2s0: link is not ready

[   28.051376] IPv6: ADDRCONF(NETDEV_UP): wlp2s0: link is not ready

[   29.135947] wlp2s0: authenticate with 60:e3:27:70:e0:3e

[   29.156539] wlp2s0: send auth to 60:e3:27:70:e0:3e (try 1/3)

[   29.158828] wlp2s0: authenticated

[   29.159606] wlp2s0: associate with 60:e3:27:70:e0:3e (try 1/3)

[   29.164454] wlp2s0: RX AssocResp from 60:e3:27:70:e0:3e (capab=0x31 status=0 aid=3)

[   29.164553] wlp2s0: associated

[   29.164565] IPv6: ADDRCONF(NETDEV_CHANGE): wlp2s0: link becomes ready

[   31.532425] wlp2s0: deauthenticating from 60:e3:27:70:e0:3e by local choice (Reason: 3=DEAUTH_LEAVING)

```

...with this repeating a lot and searching through the forums led me to this thread on deauthenticating, working through it I made sure, as NeddySeagoon suggested, to set rc_strict="NO" in /etc/rc.conf but no joy still happening.  I've installed =net-misc/NetworkManager-1.8.4 with USE='dhcpcd' so fired up dhcpcd to see what is going on and strangely it looks like the MAC address of my WiFi card keeps on changing...

```

dhcpcd -dB

dhcpcd-7.0.0-rc3 starting

dev: loaded udev

wlp2s0: executing `/lib/dhcpcd/dhcpcd-run-hooks' PREINIT

wlp2s0: executing `/lib/dhcpcd/dhcpcd-run-hooks' NOCARRIER

no interfaces have a carrier

wlp2s0: waiting for carrier

wlp2s0: new hardware address: e0:b9:a5:d1:20:73

wlp2s0: new hardware address: 1a:45:e5:d5:e1:b1

wlp2s0: new hardware address: e0:b9:a5:d1:20:73

wlp2s0: new hardware address: 1e:98:42:7f:25:13

wlp2s0: new hardware address: e0:b9:a5:d1:20:73

wlp2s0: new hardware address: 7e:5c:22:6b:b7:2b

wlp2s0: new hardware address: e0:b9:a5:d1:20:73

wlp2s0: new hardware address: 16:a6:6a:43:85:82

wlp2s0: new hardware address: e0:b9:a5:d1:20:73

wlp2s0: new hardware address: e6:5d:37:3e:04:7f

wlp2s0: new hardware address: e0:b9:a5:d1:20:73

wlp2s0: new hardware address: 4a:80:8b:5d:f9:37

wlp2s0: new hardware address: e0:b9:a5:d1:20:73

wlp2s0: new hardware address: 46:d2:35:1d:b1:0a

wlp2s0: new hardware address: e0:b9:a5:d1:20:73

wlp2s0: new hardware address: 06:3c:97:f8:7b:11

```

Checking with ifconfig confirmed this...

```

ifconfig wlp2s0

wlp2s0: flags=4099<UP,BROADCAST,MULTICAST>  mtu 1500

        ether e0:b9:a5:d1:20:73  txqueuelen 1000  (Ethernet)

        RX packets 1121  bytes 863835 (843.5 KiB)

        RX errors 0  dropped 0  overruns 0  frame 0

        TX packets 895  bytes 121410 (118.5 KiB)

        TX errors 0  dropped 0 overruns 0  carrier 0  collisions 0

ifconfig wlp2s0

wlp2s0: flags=4099<UP,BROADCAST,MULTICAST>  mtu 1500

        ether 7e:5c:22:6b:b7:2b  txqueuelen 1000  (Ethernet)

        RX packets 1121  bytes 863835 (843.5 KiB)

        RX errors 0  dropped 0  overruns 0  frame 0

        TX packets 895  bytes 121410 (118.5 KiB)

        TX errors 0  dropped 0 overruns 0  carrier 0  collisions 0

ifconfig wlp2s0

wlp2s0: flags=4099<UP,BROADCAST,MULTICAST>  mtu 1500

        ether 06:3c:97:f8:7b:11  txqueuelen 1000  (Ethernet)

        RX packets 1121  bytes 863835 (843.5 KiB)

        RX errors 0  dropped 0  overruns 0  frame 0

        TX packets 895  bytes 121410 (118.5 KiB)

        TX errors 0  dropped 0 overruns 0  carrier 0  collisions 0

ifconfig wlp2s0

wlp2s0: flags=4099<UP,BROADCAST,MULTICAST>  mtu 1500

        ether ba:9f:c8:f1:f4:5f  txqueuelen 1000  (Ethernet)

        RX packets 1124  bytes 864218 (843.9 KiB)

        RX errors 0  dropped 0  overruns 0  frame 0

        TX packets 897  bytes 121720 (118.8 KiB)

        TX errors 0  dropped 0 overruns 0  carrier 0  collisions 0

```

Something, I've no idea what, perhaps udev? is changing the MAC address of wlp2s0 and as I have configured my router to assign a static IP address based on the MAC address of  e0:b9:a5:d1:20:73 it kind of follows that if the MAC address is being changed the router will kick it off of the network (although my limited understanding suggests that the 'deauthenticating by local choice' means that the laptop itself is disconnecting from the network, presumably because something is then changing the MAC address).

Very strange and I'm stumped, could do with having ti fixed as I need to take the laptop to work tomorrow.  Could force rolling back NetworkManager, nm-applet and networkmanager-openvpn to <1.8.0 versions but will still have this problem to deal with.

Any thoughts/pointers/ideas would be gratefully received.

Thanks in advance,

slackline

----------

## NeddySeagoon

slackline,

```
[   21.739994] wlp2s0: deauthenticating from 60:e3:27:70:e0:3e by local choice (Reason: 3=DEAUTH_LEAVING) 
```

means you told it to deauthenticate.

The most common reason for this is wpa_supplicant having several network managers trying to control it, each unaware of the others.

At most, you may use one method to set up your wifi.

The easiest way to get to exactly one is to start with none.  You have achieved that when there are no signs of wifi trying to start in dmesg.

Now add your selected method.

----------

## slackline

Hi,

Ok, thanks for the pointer NeddySeagoon.  

For now I've downgraded as I need to use the laptop at work tomorrow and am getting prepared this afternoon but will investigate over the coming week by deactivating everything (got quite a few services depending on net as you'd expect these days) and go from there.

Cheers,

slackline

----------

## UberLord

Just a note to say that dhcpcd only notifies of new hardware addresses, it can't actually change it.

----------

