martinm
Posts: 4
Joined: Sun Dec 16, 2012 6:31 pm

Wifi disconnects after a random amount of time

Sun Dec 16, 2012 6:40 pm

Hi guys,

I'm using the raspberry pi (256 MB Version)
with this Wifi adapter
Bus 001 Device 005: ID 148f:5370 Ralink Technology, Corp. RT5370 Wireless Adapter
https://www.modmypi.com/shop/raspberry- ... Fi-dongle)

and this USB hub as a power supply via micro usb for the pi
https://www.modmypi.com/shop/raspberry- ... s-Adaptor)

I am also using a USB to RS232 adapter which is connected to the hub
Bus 001 Device 009: ID 067b:2303 Prolific Technology, Inc. PL2303 Serial Port

I'm using wpa_supplicant to configure the wifi connection in /etc/network/interfaces which basically seems to work just fine, but the device starts disconnecting and reconnecting after a (it seems to me like random) amount of time (1h - 10days). If this startet once it disconnects about every 10 seconds or so.

This is what the syslog shows:

Code: Select all

Dec 16 19:22:06 raspberrypi kernel: [126321.827365] wlan0: disassociated from 00:1b:11:8b:7d:be (Reason: 4)
Dec 16 19:22:06 raspberrypi kernel: [126321.858802] wlan0: deauthenticating from 00:1b:11:8b:7d:be by local choice (reason=3)
Dec 16 19:22:06 raspberrypi kernel: [126321.860883] cfg80211: Calling CRDA to update world regulatory domain
Dec 16 19:22:06 raspberrypi ifplugd(wlan0)[1539]: Link beat lost.
Dec 16 19:22:08 raspberrypi kernel: [126323.489074] wlan0: authenticate with 00:1b:11:8b:7d:be (try 1)
Dec 16 19:22:08 raspberrypi kernel: [126323.490713] wlan0: authenticated
Dec 16 19:22:08 raspberrypi kernel: [126323.509741] wlan0: associate with 00:1b:11:8b:7d:be (try 1)
Dec 16 19:22:08 raspberrypi kernel: [126323.512993] wlan0: RX AssocResp from 00:1b:11:8b:7d:be (capab=0x431 status=0 aid=1)
Dec 16 19:22:08 raspberrypi kernel: [126323.513018] wlan0: associated
Dec 16 19:22:08 raspberrypi ifplugd(wlan0)[1539]: Link beat detected.
Dec 16 19:31:20 raspberrypi kernel: [126875.994266] wlan0: disassociated from 00:1b:11:8b:7d:be (Reason: 4)
Dec 16 19:31:20 raspberrypi kernel: [126876.025045] wlan0: deauthenticating from 00:1b:11:8b:7d:be by local choice (reason=3)
Dec 16 19:31:20 raspberrypi kernel: [126876.027120] cfg80211: Calling CRDA to update world regulatory domain
Dec 16 19:31:21 raspberrypi ifplugd(wlan0)[1539]: Link beat lost.
Dec 16 19:31:22 raspberrypi kernel: [126877.645189] wlan0: authenticate with 00:1b:11:8b:7d:be (try 1)
Dec 16 19:31:22 raspberrypi kernel: [126877.646778] wlan0: authenticated
Dec 16 19:31:22 raspberrypi kernel: [126877.668975] wlan0: associate with 00:1b:11:8b:7d:be (try 1)
Dec 16 19:31:22 raspberrypi kernel: [126877.672808] wlan0: RX AssocResp from 00:1b:11:8b:7d:be (capab=0x431 status=0 aid=1)
Dec 16 19:31:22 raspberrypi kernel: [126877.672861] wlan0: associated
Dec 16 19:31:22 raspberrypi ifplugd(wlan0)[1539]: Link beat detected.

Any help is appreciated!

sergecat
Posts: 7
Joined: Wed Nov 28, 2012 1:20 pm

Re: Wifi disconnects after a random amount of time

Mon Dec 17, 2012 12:55 pm

Hi,

I have the same kind of problem with the wifi.

Could you tell me where I can find the suslog file to check it ?

Thanks a lot.

Serge

casual
Posts: 3
Joined: Wed Dec 19, 2012 11:25 am

Re: Wifi disconnects after a random amount of time

Wed Dec 19, 2012 11:29 am

I have the same problem. Any help will be appreciated!

fridgemagnet
Posts: 12
Joined: Fri Jun 01, 2012 3:21 pm

Re: Wifi disconnects after a random amount of time

Sat Dec 22, 2012 12:12 pm

No answer I'm afraid but I'm seeing similar things - see my post here:

http://www.raspberrypi.org/phpBB3/viewt ... 92#p237823

in a nutshell, try throttling back your AP to 802.11g mode (54M) and see if it's more stable. Thus far that is the only thing I've been able to find that makes it stable. Be interested to see if you get similar results

Sader
Posts: 3
Joined: Fri Jan 25, 2013 12:19 pm

Re: Wifi disconnects after a random amount of time

Fri Mar 01, 2013 8:01 am

Hello

Same issue here. Originally blamed power issue, but this persisting after raspberry being connected to powered hub, listed in approved devices with 2A Current output.

Also have a linux based Digitial Sattelite receiver, and there is a same issue on it, happening from time to time with no fixed pattern. I tried changing wireless security types, passwords, etc, but still no luck.

anyone have any idea on the issue ?

tahnks

NewPi
Posts: 66
Joined: Sat Aug 18, 2012 2:52 pm

Re: Wifi disconnects after a random amount of time

Fri Mar 01, 2013 10:18 am

Had same issues, got fixed when updated using rpi-update. Seems something related to the usb stack and its patch (http://www.raspberrypi.org/phpBB3/viewtopic.php?t=23544) which made things working for me.
Raspberry Pi Howto, Tips, Tricks and Tools -> http://bit.ly/RPiTricks

User avatar
riffraff
Posts: 307
Joined: Tue Sep 27, 2011 3:17 am
Location: Newnan, Georgia, US

Re: Wifi disconnects after a random amount of time

Sat Mar 02, 2013 8:25 am

I had something like that happening with my Netgear WiFi dongle. Glitched and disconnected arbitrarily at random intervals. Rearranged my USB devices (more for aesthetic purposes) and ended up solving it. WiFi and powered hub are plugged into Pi, keyboard and mouse are further downstream on another small passive hub. Can't explain why it works better that way to save my soul, but that's why I got a Pi: to get tech savvy with this newfangled stuff.

Andrew
Posts: 1
Joined: Tue Jun 04, 2013 10:32 am

Re: Wifi disconnects after a random amount of time

Tue Jun 04, 2013 10:39 am

I had the same problem until changed SD card (SiliconPower 16G Class 10 to AData 8G class 10). I'm using TP-LINK TL-WN725N v1. Previously it worked unstable disconnecting after a random number of time (especially wren i tried to upload a big file via WinSCP). Now it seems new SD card fixed this issue.

S0AndS0
Posts: 5
Joined: Thu Mar 12, 2015 6:47 am
Contact: Website

Re: Wifi disconnects after a random amount of time

Thu May 28, 2015 6:40 am

Here is the solution I've been using on my RPi's

Code: Select all

#!/bin/bash
TESTIP=8.8.8.8
ping -c2 ${TESTIP} > /dev/null
if [ $? != 0 ]
then
	ifdown --force wlan0
	ifup wlan0
#	/etc/init.d/networking restart
#	omxplayer -o local --vol -1750 /opt/sonic-pi/etc/samples/ambi_choir.wav
	service ssh restart
	service xrdp restart
fi
#####
# Uncomment else and arp lines to enable logging otherwise...
# Add the following to your crontab to run every 5 minuets
# sudo nano /etc/crontab
#	*/5 * 	* * * 	root 	/usr/bin/network_checker.sh
# 	#Source : http://root42.blogspot.com/2013/03/how-to-make-raspberry-pi-automatically.html
#####
I set it up to run in cron job just like the comments at the end of the script directs. Now every five minuets if (and only if) google's dns servers cant be reached my Pi restarts my wlan# and related services that I may need reastarted and for my headless one it'll play a sound letting me know that it is indeed trying to re-connect to the outside world. After a few days testing I'm no longer getting repeated disconects and server unreachable errors :-D instead I'll have a ssh session go un-responcive for 30-40 seconds (on the client side) and then come right back up again.

Joosttovitch
Posts: 1
Joined: Tue Mar 14, 2017 8:07 pm

Re: Wifi disconnects after a random amount of time

Tue Mar 14, 2017 8:10 pm

I found a solution further down the first page of google:
http://www.xappsoftware.com/wordpress/2 ... e-reason3/

Seems to be a power saving option of the wifi dongle.
The following command shuts off this power save option:

$ sudo iwconfig wlan0 power off

Try only
$ sudo iwconfig
to see the rest of the wlan dongle settings

Aaron2
Posts: 1
Joined: Sat Mar 18, 2017 4:09 am

Re: Wifi disconnects after a random amount of time

Sat Mar 18, 2017 4:15 am

Joosttovitch wrote:I found a solution further down the first page of google:
http://www.xappsoftware.com/wordpress/2 ... e-reason3/

Seems to be a power saving option of the wifi dongle.
The following command shuts off this power save option:

$ sudo iwconfig wlan0 power off

Try only
$ sudo iwconfig
to see the rest of the wlan dongle settings
Thank you Joosttovitch!! I was reusing an SD card from a Pi 3 in a new Pi Zero W to run a kiosk and could not figure out why the wireless was dropping shortly after boot. I disabled the power saving feature and it's working now. Thanks!

Return to “Troubleshooting”

Who is online

Users browsing this forum: djolivo, strangealx and 47 guests