2

Of all the WiFi-connected Debian systems I've used (most of my systems are wired to my network) for extended periods of time, at least once have they been unable to communicate over Wifi. Judging on the output of ifconfig, they are still connected, but when I try to ping a network device, it fails, instead getting a reply from itself. So I have to run ifconfig wlan0 down followed by ifconfig wlan0 up. My system automatically gets an IP from my DHCP server, but even then, I can only talk to devices on the same network (so I could ping 192.168.0.1 but not 8.8.8.8, or 192.168.0.25 but not 208.70.160.53). When I try to ping an IP on the internet, I get a message like connect: network is down. So then I have to reboot to restore full network connectivity.

So my questions are:

Why does WiFi connectivity seemingly randomly go out and how can I stop that from happening?

and

When it does go out, how can I restore complete connectivity without rebooting the whole system?

I am using Debian Jessie version 8.7. If you need any more information, go ahead and ask in the comments.

output of lspci -knn | grep Net -A2

02:00.0 Ethernet controller [0200]: Broadcom Corporation NetXtreme BCM57765 Gigabit Ethernet PCIe [14e4:16b4] (rev 10)
    Subsystem: Broadcom Corporation NetXtreme BCM57765 Gigabit Ethernet PCIe [14e4:16b4] 
    Kernel driver in use: tg3 
02:00.1 SD Host controller [0805]: Broadcom Corporation BCM57765/57785 SDXC/MMC Card Reader [14e4:16bc] (rev 10)
03:00.0 Network controller [0280]: Broadcom Corporation BCM4331 802.11a/b/g/n [14e4:4331] (rev 02) 
    Subsystem: Apple Inc. AirPort Extreme [106b:00d6] 
    Kernel driver in use: bcma-pci-bridge

output of ping 192.168.0.1 after getting disconnected:

PING 192.168.0.1 (192.168.0.1) 56(84) bytes of data.
From 192.168.0.9 icmp_seq=1 Destination Host Unreachable
From 192.168.0.9 icmp_seq=2 Destination Host Unreachable
From 192.168.0.9 icmp_seq=3 Destination Host Unreachable
From 192.168.0.9 icmp_seq=4 Destination Host Unreachable
From 192.168.0.9 icmp_seq=5 Destination Host Unreachable
From 192.168.0.9 icmp_seq=6 Destination Host Unreachable
From 192.168.0.9 icmp_seq=7 Destination Host Unreachable
From 192.168.0.9 icmp_seq=8 Destination Host Unreachable
From 192.168.0.9 icmp_seq=9 Destination Host Unreachable

--- 192.168.0.1 ping statistics ---
11 packets transmitted, 0 received, +9 errors, 100% packet loss, time 10236ms
4
  • What is the output of lspci -knn | grep Net -A2 ?
    – GAD3R
    Commented Mar 4, 2017 at 18:06
  • 02:00.0 Ethernet controller [0200]: Broadcom Corporation NetXtreme BCM57765 Gigabit Ethernet PCIe [14e4:16b4] (rev 10) Subsystem: Broadcom Corporation NetXtreme BCM57765 Gigabit Ethernet PCIe [14e4:16b4] Kernel driver in use: tg3 02:00.1 SD Host controller [0805]: Broadcom Corporation BCM57765/57785 SDXC/MMC Card Reader [14e4:16bc] (rev 10) -- 03:00.0 Network controller [0280]: Broadcom Corporation BCM4331 802.11a/b/g/n [14e4:4331] (rev 02) Subsystem: Apple Inc. AirPort Extreme [106b:00d6] Kernel driver in use: bcma-pci-bridge
    – Billy
    Commented Mar 4, 2017 at 18:49
  • 1
    I fixed problem with my installation using a different driver. You may want to check out this page wiki.debian.org/bcm43xx. Thanks to @GAD3R for requesting command he gave u.
    – Luka
    Commented Mar 4, 2017 at 19:18
  • 3
    Please when adding output diagnostic, edit the question, and do not leave that in comments. Over time moderators also may scrub comments. Commented Mar 4, 2017 at 21:01

2 Answers 2

4

You should use the wl driver instead of the bcma-pci-bridge .

Edit your /etc/apt/sources.list by adding the following line:

deb http://httpredir.debian.org/debian/ jessie main contrib non-free

Save your file.

Install the linux-image, linux-headers and the broadcom-sta-dkms package

apt-get update
apt-get install linux-image-$(uname -r|sed 's,[^-]*-[^-]*-,,') linux-headers-$(uname -r|sed 's,[^-]*-[^-]*-,,') broadcom-sta-dkms

unload conflicting driver:

 modprobe -r bcma-pci-bridge
 modprobe -r b44 b43 b43legacy ssb brcmsmac bcma

Load the right module:

modprobe wl

Source : the official website

1
  • You can boot the old kernel 3.16 , it will work for you , or you can install a new kernel from Backports . You can also compile a low version than the 4.10
    – GAD3R
    Commented Mar 8, 2017 at 22:52
2

I forgot about this question; I just now rediscovered it and thought I might as well put this in.

When I asked this question, I used a fairly-basic network manager. (Now I run wpa_supplicant, ifconfig, and route manually.) More advanced managers like NetworkManager should handle this automatically, but if not, just run the command wpa_cli (you'll probably have to be root), then type reassociate in that prompt (Control-C when you're done). This causes wpa_supplicant to reconnect without downing the interface, which resets the routing table. Another alternative is to run ifconfig <interface> down followed by ifconfig <interface> up (what I was doing when I asked this question). This will prompt wpa_supplicant to reconnect, but it also deletes the routing table entry that was set by dhclient, so you'll have to run route add -net default gw <router IP address> dev <interface> (what I couldn't figure out). Simply turning WiFi off and back on (or disconnecting and reconnecting, if that's your thing) in your network manager should also work.

Wi-Fi still disconnects occasionally, but when it does I just always tell wpa_supplicant to reassociate and it works again after just a few seconds. That's probably a problem that all OS's have, they just reassociate automatically in the background.

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .