TL-MR3020 crashed: Cannot allocate memory

All about the new openwrt-based and WLAN enabled Meteoplug client platforms.

TL-MR3020 crashed: Cannot allocate memory

Postby ironedge » Mon Dec 01, 2014 4:01 pm

Last night at around 1:45h, my "weatherboxx" (TL-MR3020) got stuck. Means, it didn't transfer any data to the Meteoplug Server or to the weather Networks any more for several hours.

The lights were flashing as usual and I could still access it via IP. It said the "Last Send" was I think around 16000 sec ago (~5 hours) and I could copy&paste the following error messages from the client's screen:

logger (01.12.2014 07:03:49): station 0 (Meteostick), suspicious raintotal (undetected): total/old 163.2/25.6mm (e4 00 00 30 05 00 b7 c9) [b3:80] -64db
logger (01.12.2014 07:04:01): station 0 (Meteostick), suspicious raintotal (undetected): total/old 163.2/25.6mm (e4 00 00 30 05 00 b7 c9) [b3:80] -63db
logger (01.12.2014 07:04:03): error processing "awk '{c=$3;lg=7.8;lt=47.45;d=0.0174533;j=strftime("%j");st=strftime("%H")+1;mi=strftime("%M");}{x=-23.45*cos(d*360*(j+10)/365);z=60*(-0.171*sin(0.0337*j+0.465)-0.1299*sin(0.01787*j-0.168));w=15*(st+mi/60-(15-lg)/15-12+z/60);s=sin(d*lt)*sin(d*x)+cos(d*lt)*cos(d*x)*cos(d*w);s2=atan2(s,sqrt(1-s^2))/d;m=1368*sin(s2*d);a=(1-sin(s2*d))*0.3*m;g=(m-a)*0.4;if (st<8) g=g*1-3;if (st>14) g=g*1+21;o=0;if ((c>g)&&(g>15)) o=100;printf"%d",o}'": : Cannot allocate memory
logger (01.12.2014 07:04:12): station 0 (Meteostick), suspicious raintotal (undetected): total/old 163.2/25.6mm (e4 00 00 30 05 00 b7 c9) [b3:80] -63db
logger (01.12.2014 07:04:23): station 0 (Meteostick), suspicious raintotal (undetected): total/old 163.2/25.6mm (e4 00 00 30 05 00 b7 c9) [b3:80] -63db


Don't get confused by the long awk script. This is my sunshine-duration calculation and it successfully works for more than 4 months meanwhile.

I also had another error message that I couldn't copy&paste because it disappeared right before I wanted to copy it, but it said something like: "Upload process: Cannot allocate memory".

Don't know if there's a memory leak somewhere that crashed it after a while.
Many thanks in advance for any potential bug fixing!
ironedge
 
Posts: 56
Joined: Tue Sep 23, 2014 9:32 am

Re: TL-MR3020 crashed: Cannot allocate memory

Postby admin » Wed Dec 03, 2014 12:20 am

If it is a Meteobridge, please follow instructions below and send the URL for
remote login to "info(at)smartbedded.com":
http://forum.meteohub.de/viewtopic.php?f=57&t=9885
User avatar
admin
Site Admin
 
Posts: 332
Joined: Sun Feb 07, 2010 9:22 pm

Re: TL-MR3020 crashed: Cannot allocate memory

Postby ironedge » Fri Dec 05, 2014 6:03 pm

Sorry I'm pretty confused about all these different meteohub/meteobridge/meteoplug thingies out there. It's I think a pure meteoplug platin client, I don't have any local meteohub/meteobridge entity. The weatherboxx/meteostick collects the Davis VP2 data and sends it to the meteoplug server.
ironedge
 
Posts: 56
Joined: Tue Sep 23, 2014 9:32 am

Re: TL-MR3020 crashed: Cannot allocate memory

Postby admin » Sun Dec 07, 2014 10:10 am

I changed some settings to prevent the MR3020 to run out of memory when filling up internal buffers. These buffers are used when Internet connection drops and queued data needs to be sent later on when Internet is back online.
Please reboot your Meteoplug client to have this latest code installed.
User avatar
admin
Site Admin
 
Posts: 332
Joined: Sun Feb 07, 2010 9:22 pm

Re: TL-MR3020 crashed: Cannot allocate memory

Postby ironedge » Mon Dec 08, 2014 1:49 pm

Many thanks Boris, much appreciated, will reboot soonest.
Just FYI: At the time of the crash there was according to my knowledge no issue with the Internet connection. In the previous 2-3 weeks, however, I had connection issues to my DSL provider twice and the box had to buffer for several hours.
ironedge
 
Posts: 56
Joined: Tue Sep 23, 2014 9:32 am


Re: TL-MR3020 crashed: Cannot allocate memory

Postby ironedge » Wed Apr 15, 2015 9:03 pm

Guys, the reboot of course resolves the immediate memory allocation issue but it does not resolve the root cause, i.e. the memory leak. It will crash again and again after a certain amount of time if the memory leak is not resolved. This can only be done by the software programmer who needs to fix this in the code.
ironedge
 
Posts: 56
Joined: Tue Sep 23, 2014 9:32 am

Re: TL-MR3020 crashed: Cannot allocate memory

Postby admin » Thu Apr 16, 2015 8:36 pm

I guess it is a Meteoplug client. How did you embed this "awk" script?
Or is it a Meteobridge?
User avatar
admin
Site Admin
 
Posts: 332
Joined: Sun Feb 07, 2010 9:22 pm

Re: TL-MR3020 crashed: Cannot allocate memory

Postby ironedge » Fri Apr 17, 2015 11:12 am

Hi Boris,

Thanks for checking back.
The details are in the other thread: viewtopic.php?f=17&t=350&start=0

I have the TL-MR3020 with the Meteostick (no Meteobridge, etc.) and the Meteoplug license, collecting data from a Davis VP2.
The awk script is embedded as a calculation for a virtual sensor on Meteoplug (page "Sensoren", in the section "Virtuelle Sensoren", field "Umrechnung"), triggered each time the solar sensor generates a value (i.e. around once every 1-2minutes).

I had the following Client HW/SW Setup at the time of the crash:

Client SW: 2.4 (FW 1.1, Build 5450)
Client HW: 265 BogoMIPS, TL-MR3020

After rebooting from the crash it's now 2.5 (FW 1.1, Build 6239).

Just let me know if you need any additional information. Thanks!
ironedge
 
Posts: 56
Joined: Tue Sep 23, 2014 9:32 am

Re: TL-MR3020 crashed: Cannot allocate memory

Postby admin » Sat Apr 18, 2015 4:35 pm

This is a very rare setup. I doubt anybody else doing awk virtual sensors on pure meteoplug clients.
I wonder that this works at all ;-)

Did you try ssh-ing on your Meteoplug client? Watching processes and memory allocation there
might give a hint what does go wrong. When you give me access on port 22 of your Meteoplug
client, I also can have a look and check how memory consumption changes over time.

Beside the memory leak hypothesis it also can just be too much RAM consumption running
awk. After boot Meteoplug client starts storing data for a certain amount of time
and then drops old data chunks when designed storage limit for that is used.
May be this limit is to generous, when also awk is triggered. To be honest, this
is my favorite explanation. reducing data buffering limit could heal this. But as said,
without further inspection, this is just more or less educated guesswork.
User avatar
admin
Site Admin
 
Posts: 332
Joined: Sun Feb 07, 2010 9:22 pm

Next

Return to TP-Link TL-MR3020, TL-WR703, ASUS WL-330N3G

Who is online

Users browsing this forum: No registered users and 2 guests