2018-05-07

How to stop Raspberry Pi crashing

I have a Pi Zero W running 24/7 since several weeks. I already listed all the tasks it has to do in an older post. The only time when it was not crashing was the week i was folding my last 707 origami cranes in Barcelona. Having my browser regularly connecting to the Pi Zero W seems to be enough to break it, if everything tries to flow through the bottleneck at the same time: FreshRSS is checking for updates at over 200 blogs within ten minutes, while raspistill is making a photo every minute, and Chrome is refreshing the stream of the feed reader via web interface and Apache server.
This is a possibility because i tuned it that way to keep the gap where the "time-lapse photography" is paused small. Otherwise the resulting video will not look right. The moon would jump from one position to another with frames missing. The crashing was not that frequent before, since i reserved enough time for every job. Handling that many RSS sources is quite the workload for this tiny computer, which basically means living on the edge. But the internal "watchdog" of the Broadcom BCM2835 does a great job in rebooting the Pi Zero W, if the heart stops beating.
A solution would be to reserve more time for every job and to reduce multitasking, which is the right way anyway, because it has only a single-core CPU. I also checked the power with a USB multimeter. And since i didn't wrote the RSS aggregator myself, this could be a place to do some digging too. After all, the Zero W is not that demanding and just not as strong as a full-size Raspberry Pi with four cores and twice as much RAM. But compared to my first computer in 1998 by IBM with Pentium II 300 MHz and 32 MB RAM, it's plenty for ordinary tasks.
This site is not available in your country.