User Tools

Site Tools


sd-wear

Reduce SD card wear with WeeWx

Every 5 minutes (in the default setup) WeeWx rewrites some or all of the web pages. Over a period of time this could create a lot of sd card wear.

To reduce this wear we can use the computer's RAM to store the website. The only slight disadvantage is that it will have to be recreated when the computer is rebooted, but this is not a problem in reality.

so edit /etc/fstab:

add this line:

tmpfs /var/www tmpfs mode=0775,size=5M,noexec,nosuid,noatime,nodev 0 0

If your directory for your webpages are in fact /var/www/weewx then you need to alter the line accordingly.

Now reboot and your system should create and update the webpage in memory.

Also if you don't have ramlog installed, this might be useful, it keeps logs in memory and saves them to the sd card just when necessary, saving many writes, google it.

sd-wear.txt · Last modified: 1980/01/01 00:50 by chris