What's new

Corrupt Config

  • SNBForums Code of Conduct

    SNBForums is a community for everyone, no matter what their level of experience.

    Please be tolerant and patient of others, especially newcomers. We are all here to share and learn!

    The rules are simple: Be patient, be nice, be helpful or be gone!

Darren Rockach

Regular Contributor
I woke this morning to find my router was in a bit of a state. It seems that somehow the configuration got screwed up over night. My DHCP reservations were no longer listed in the WebUI and also a static route had disappeared. None of the network clients could connect to the internet.
In the end I factory reset and reconfigured which was a pain.
After looking at the syslog I can see the below entry multiple times. Can anyone tell me anything more about this message?

Code:
failed to write /var/lib/misc/dnsmasq.leases: No space left on device (retry in 60s)

Thanks in advance
 
Something filled the internal disk space up


Sent from my iPhone using Tapatalk
 
Something filled the internal disk space up
Or you've run out of memory (that file is stored in memory).

What router model?
What firmware version?
What third-party add-ons have you installed?
 
Or you've run out of memory (that file is stored in memory).

What router model?
What firmware version?
What third-party add-ons have you installed?
It is an AX88U running Merlin 384.9.
I have the amtm script installed but not currently using any of it's components. I also have entware installed on USB. Apart from that nothing else.
Thanks
 
There's not much you can do now that you've reset your router. That message has been reported on and off for years now. It's difficult to pin down the actual problem because the message not directly related to the cause. Mostly I've seen it where people are running Entware packages or ad-blockers that consume a lot of memory. In those cases creating a swap file seems to fix the problem.
 
Did you format the jffs partition on next reboot to also have it 'fresh' after your reset to factory defaults? Did you use the checkbox in the GUI to format it for you?

If you did not do that (it doesn't sound like you did), I would be doing so now. There may be additional cruft there that may come back to trouble you again soon.
 
Did you format the jffs partition on next reboot to also have it 'fresh' after your reset to factory defaults? Did you use the checkbox in the GUI to format it for you?

If you did not do that (it doesn't sound like you did), I would be doing so now. There may be additional cruft there that may come back to trouble you again soon.
Sorry I'm not being very clear. These messages were from before the problem in the night, I think it was the probable cause of the issue. Yes I did reformat jffs after the factory reset. I am no longer seeing the error. I guess something must have filled up a partition as a reboot didn't resolve the issue so wouldn't be a memory problem. I guess I won't know now what filled up all the space. I'll just have to wait and see if it happens again. I now have a cron job that stores the output of the df command to a log file on a network mounted share so I can keep an eye on things. I might also set a script to monitor the contents of that file and alert me somehow when it drops below a threshold. Not sure if I can do that with IFTTT on my Qnap NAS where the log file is located, I'll have to look into it.
 
So it seems that my problem is with the /jffs/.sys/TrafficAnalyzer/TrafficAnalyzer.db file growing so large it depletes all free space. I had to 'rm -f' it.
I like to have a historic view of whats doing what so don't want to disable this option all together so is there anything I can do to stop this file growing so big or move it to some place with more capacity.
I suppose I could write a script and cron it to run. Get it to check the file size and if it exceeds a certain size archive it off to a dated file name. Moving the file to a location with greater capacity would be preferable though, does anyone know if this is possible? It seems that the option under Tools>Other Settings>Traffic Monitoring doesn't affect this file.
 
So it seems that my problem is with the /jffs/.sys/TrafficAnalyzer/TrafficAnalyzer.db file growing so large it depletes all free space. I had to 'rm -f' it.
I like to have a historic view of whats doing what so don't want to disable this option all together so is there anything I can do to stop this file growing so big or move it to some place with more capacity.
I suppose I could write a script and cron it to run. Get it to check the file size and if it exceeds a certain size archive it off to a dated file name. Moving the file to a location with greater capacity would be preferable though, does anyone know if this is possible? It seems that the option under Tools>Other Settings>Traffic Monitoring doesn't affect this file.

The Traffic Analyzer Monitor script contains a purge/backup function.

Code:
./TrafficAnalyzer_Report.sh -h

#======================================================================================= © 2016-2018 Martineau v1.09
#
# Scan Traffic Analyzer database
#
#    TrafficAnalyzer     [help | -h] ['ip='{[ip_address[,...] | hostname[...]]}] ['app='{category_name[,...]}] ['app='{application_name[,...]}]
#                        ['date='[yyyy/mm/dd[,...]]] ['time='[hh:mm:ss[,...]]] ['sqldb='{database}] ['backup'] ['nofilter'] ['email']  ['mode=or'] ['noscript']
#                        ['count'] ['sortby='column]
#
#    TrafficAnalyzer
#                        Will list the script's DEFAULT Category entries in the Traffic Analyzer database containing 'Social' AND 'Instant'
#    TrafficAnalyzer     count
#                        Will count the script's DEFAULT Category entries in the Traffic Analyzer database containing 'Social' AND 'Instant'
#                        and will only display the result count. No records are displayed on screen.
#    TrafficAnalyzer     nofilter
#                        Will list ALL entries in the Traffic Analyzer database.
#    TrafficAnalyzer     nofilter sortby=app
#                        Will list ALL entries in the Traffic Analyzer database sorted by column Application name
#    TrafficAnalyzer     nofilter email
#                        Will list ALL entries in the Traffic Analyzer database and will send an email with the results
#    TrafficAnalyzer     cat=VoIP,Social
#                        Case sensitive; Will list Category entries in the Traffic Analyzer database for 'VoIP' AND 'Social'
#    TrafficAnalyzer     app=Facebook,Netflix mode=or
#                        Case sensitive; Will list Application entries in the Traffic Analyzer database containing either 'Facebook' OR 'Netflix'
#    TrafficAnalyzer     date=2017/02/30
#                        Will list entries in the Traffic Analyzer database created on '30th Feb 2017'
#                        NOTE: The date specification can be an abbreviation e.g. '2017/02' for records created in 'Feb 2017'
#    TrafficAnalyzer     ip=10.88.8.123,192.168.1.99
#                        Will list entries in database for two devices - either '10.88.8.123' or '192.168.1.99'
#                        NOTE: Only MAC addresses are stored in the database so if the devices are not 'reserved/static'
#                              then the report could be inaccurate.
#    TrafficAnalyzer     ip=10.88.8.123, 192.168.1.120-192.168.1.123, CAMERAS
#                        Will list database entries for five devices, plus all IPs for 'CAMERAS' entry in '/jffs/configs/IPGroups'
#    TrafficAnalyzer     time=09:
#                        Will list entries in the Traffic Analyzer database created between '09:00' to '09:59'
#                        NOTE: A full time specification can be used e.g. '12:05:30' but the report may never find a match!
#    TrafficAnalyzer     backup
#                        The current Traffic Analyzer database will be backed up to '/opt/var/Traffic Analyzer/'
#    TrafficAnalyzer     sqldb=/opt/var/TrafficAnalyzer/TrafficAnalyzer.db-Backup-20180401-060000
#                        The report/queries will be extracted from the archive/backup database '/opt/var/TrafficAnalyzer/TrafficAnalyzer.db-Backup-20180401-060000'
#    TrafficAnalyzer     purgeallreset
#                        The current Traffic Analyzer History database is PURGED of ALL history!!!!! (NOTE: a backup is taken first ;-)

You should be able to either schedule the script to issue the 'purgeallreset' directive to retain archived data say once a month/week, or intelligently call the script from another script that detects when the file reaches a size limit.
 
Last edited:
That database is handled by the Trend Micro proprietary code, it's unrelated to traffic monitoring or IPTraffic.

That's odd because Asus should have implemented code a few years ago to ensure i doesn't grow too large. Maybe that code isn't working as expected (or the database requires garbage collection? It's sqlite-based). What size is it? Mine is 30 MB exactly, so that might be the upper limit Asus has set.
 
BTW, this is unrelated to your original error. TrafficAnalyzer database is in the /ffs partition, which lies in flash. The error message you got indicate your router ran out of RAM, or the /tmp/ partition got filled up.
 
That database is handled by the Trend Micro proprietary code, it's unrelated to traffic monitoring or IPTraffic.

That's odd because Asus should have implemented code a few years ago to ensure i doesn't grow too large. Maybe that code isn't working as expected (or the database requires garbage collection? It's sqlite-based). What size is it? Mine is 30 MB exactly, so that might be the upper limit Asus has set.
Mine was over 55MBs. Where can I find this TrafficAnalyzer management script? I've looked in the obvious places but nothing sticks out as being it.
Thanks
 
Mine was over 55MBs.

Odd. I'll poke at the Asus engineer taking care of this portion of the code, since this is something we had discussed a while back, maybe the size management code isn't working as expected.
 
Asus recommends doing the following if the database grows out of hands:

To "trim it" to 30 MB, run the following over SSH:

Code:
TrafficAnalyzer -d 30720
TrafficAnalyzer -e

Give it some time, it may take a while to fully optimize the cleaned database.

Also, make sure the hour_monitor process is running - that's the process responsible for regularly monitoring the size, and optimizing it if necessary.
 
Last edited:
Asus recommends doing the following if the database grows out of hands:

To "trim it" to 30 MB, run the following over SSH:

Code:
TrafficAnalyze -d 30720
TrafficAnalyze -e

Give it some time, it may take a while to fully optimize the cleaned database.

Also, make sure the hour_monitor process is running - that's the process responsible for regularly monitoring the size, and optimizing it if necessary.
Thank you for getting back to me. I can confirm that the hour_monitor process is running. Also I think you are missing the 'r' off the end of the command, should it be be TrafficAnalyzer -d .......?
 
Thank you for getting back to me. I can confirm that the hour_monitor process is running. Also I think you are missing the 'r' off the end of the command, should it be be TrafficAnalyzer -d .......?

That's correct. I did a direct copy/paste of the email I got from Asus, didn't check it myself - I'll update my post.
 

Similar threads

Latest threads

Support SNBForums w/ Amazon

If you'd like to support SNBForums, just use this link and buy anything on Amazon. Thanks!

Sign Up For SNBForums Daily Digest

Get an update of what's new every day delivered to your mailbox. Sign up here!
Top