Maslow Home Maslow Community Garden Newsletter

SD card issue locked up WebControl this weekend. SIMPLE FIX!

I spent a lot of time this weekend trying to figure out what happened to my Maslow. :-1:

Most of this post is to help anyone who might run into a similar issue and save them the time of digging blindly for the simple fix!

TLDR: check your log.txt file. :man_facepalming:

My wife is the main user of our Maslow. I am in charge of; building, initial set up, and keeping it running for her. Our Maslow only has the common modifications. It has a “taller/wider” frame, Meticulous-Z, automatic relays for cut+vac power, and Z axis touch plate. The Maslow is used at least 2x a week! She will go through at least 1 to 2, 4’ x 8’ PVC sheets each time it is used. My wife cuts a lot of outdoor items. It has been running great overall! We have had this thing for almost two years at this point :smiling_face_with_three_hearts:. There have been minor issues along the way but nothing too crazy. :+1:

This last weekend, my wife let me know that she could not access WebControl. I then spent the last 2 days trying to figure this thing out. I am slightly familiar with Raspberry but will admit that most of my knowledge comes from reading online about other people’s setups and then adapting as need to fit my needs (Think: copy & paste + tweak basic settings :roll_eyes: ).

I do have a few Pi setups (5 total) on other things around the house. I run all of my other Pi setups “head-less” with web based interfaces. I also have an extra Raspberry Pi module so I can swap the memory card out and run it in the house with a screen and keyboard for testing if there is an issue.

I took the 32G card from the Pi on the maslow and put it in my spare Pi. When I booted the system up inside with a monitor and keyboard connected, I found I was unable to do anything on the Pi once logged in. I kept getting an “access denied” error or similar. After searching online and trying different things for a few hours, I figured was dealing with a corrupt SD. I ended up getting a new 256G card and putting a fresh copy of WebControl on it. I set everything up as outlined here on this site " WebControl RaspberryPi Install from Image file ". I verified it was working inside my house. I then took it to the garage and put the new card in the “Maslow-Pi”. I learned the hard way that if you change a MAC address by changing physical hardware, your IP address may change as well (few hours and lot of back-fourth to figure that one out). I was able to get the Maslow fully functional and determined it was not an issue with the Pi itself. I was not looking forward to resetting ALL of the Maslow settings again. The Maslow was left in the center position so I was hopeful that I would be able to recover something from the original settings on the old SD card.

I ended up running another SD with a with a fresh install of a desktop environment on it. I put the original “Maslow” SD in a reader and stuck it in a USB port as an external drive. I was able to access that file system without issue. I did notice that it showed up as having 0 freespace. I just assumed this was from a corrupt card and was the cause of the original failure. I spent several hours searching this card as well as looking online for the location of the “.ini” file. I felt “extra smart” when I realized that it was a “hidden file” and I simply had to check a box to “show hidden files”. I was able to use the browser on the desktop to send over the .ini file. I noticed that did not bring over a few settings and then decided to try sending over the .json file… BOOM! Back in business!

I ran a calibration cut just to verify and it is all back as it was!!! :partying_face:

Before I walked away from this adventure, I decided to make a backup of the ini and json files(and make a I also figured it would be good to just copy-paste the entire /media/pi/rootfs/home/pi/.WebControl folder just in case I missed something. This is when I found the issue that could have saved me ALL of this time and frustration! I went to the WebControl folder and did a “copy”. I went to “paste” it on the desktop, I noticed that I was moving a 25.3 GiB file to the desktop! :exploding_head:

I dug through the WebControl file and that is where I found that it contained a log.txt file that was 25.1GiB according to the file browser. I deleted the txt file and decided to put the card back in the Maslow. Everything works as it should.

I spent a good part of this past holiday weekend chasing a bloated log file!

Was there a setting somewhere I changed to create this file when I did my original setup of WebControl? Can this file be deleted without issues? Is there a way to expose this file (or at least clear it occasionally) from within WebControl? I will now try to take the SD card out from time to time and delete that file (as long as it will not cause issues)!

I do want to thank everyone here for this AWESOME machine and its great support!

1 Like

Thanks for sharing this story. the log file is a running list of details of the webcontrol system functions as they occur. It is intended to help identify a problem or bug. when things go wrong, it can be very helpful. there is no need to keep more than a few days worth of runs unless you have a problem, then you need the log from just before that problem. You can probably write a cron job that calls a bash script to execute on the 1st of the month or 1st of the year to wipe the log file so it doesn’t get too large. That would be fairly simple to do. it would be more elegant to only keep the last 2 weeks worth of logs though and have webcontrol manage that, but someone would need to write that bit of code…


we should have the installer install a logrotate config in /etc/logrotate.d to
rotate the file, at least once a week

David Lang