Disconnect from WLAN

All about the standard Meteobridge devices based on mobile routers from TP-Link, D-Link, ASUS

Moderator: Mattk

Post Reply
pwilman
Senior Boarder
Senior Boarder
Posts: 43
Joined: Sun Jan 14, 2018 9:46 am

Disconnect from WLAN

Post by pwilman » Mon Jan 28, 2019 7:45 am

Hi,

Since upgrading to the latest version of Nano SD yesterday (3.9 build 1918) I am getting frequent system messages "disconnected from WLAN or internet, reconnect issued". Sometimes the nano reconnects after 5 minutes on its own, other times it hasn't reconnected after an hour, so I reboot the nano and it reconnects after the reboot.

I had switched off my router and turned it back on which doesn't seem to make a difference.

I am sure it is an issue with my wifi, although nothing else appears to be affected. Has anyone else got similar issues? Sure its just a coincidence that it only started after upgrading to latest version.

Paul

User avatar
ConligWX
Gold Boarder
Gold Boarder
Posts: 194
Joined: Wed Nov 14, 2018 12:48 pm
Location: Conlig, Co. Down, UK
Contact:

Re: Disconnect from WLAN

Post by ConligWX » Mon Jan 28, 2019 9:52 am

Paul I have mentioned this in the past.

viewtopic.php?f=56&t=13370

Meteobridge runs a script

/home/meteohub/test5.sh

part of the test5 checks for google.de and meteobridge.com

Code: Select all

# on VoCore2 check WLAN still operational
#
if [ "${hw}" = "VoCore2" ]
then
  ping -q -c 1 "www.google.de" 2>/dev/null
  if [ $? -ne 0 ]
  then
    ping -q -c 1 "meteobridge.com" 2>/dev/null
    if [ $? -ne 0 ]
    then
      echo "system (`date '+%d.%m.%Y %H:%M:%S'`): Disconnected from WLAN or Internet, reconnect issued." >>$LOGFILE
      /etc/wireless/mt7628/init 2>/dev/null
    fi
  fi 
fi
I have ran both ping checks constantly - in a SSH session on the NANO, and proved that this ping fails quiet often in my setup. why I do not know.

I have swapped google.de and mb.com for my ISPs DNS servers which respond without issue.

Code: Select all

# on VoCore2 check WLAN still operational
#
if [ "${hw}" = "VoCore2" ]
then
  ping -q -c 1 "194.168.4.100" 2>/dev/null
  if [ $? -ne 0 ]
  then
    ping -q -c 1 "194.168.8.100" 2>/dev/null
    if [ $? -ne 0 ]
    then
      echo "system (`date '+%d.%m.%Y %H:%M:%S'`): Disconnected from WLAN or Internet, reconnect issued." >>$LOGFILE
      /etc/wireless/mt7628/init 2>/dev/null
    fi
  fi 
fi
I have even logged onto the NANO for over 24hours with web/ssh and the connection does not drop, yet the test5m fails.

Yes it could be some sort of DNS issue. however, I have ran this command on multiple devices both linux/Windows on ethernet and wifi. none experience this time out at all, i'm guessing either my setup or some buggy code is the culprit.

changing the ping to a more local server using IP seems to fix the issue for me.

only issue is once you have changed, if you reboot the test5m script is overwritten and you have to do it again.

Post Reply