pull down to refresh
0 sats \ 10 replies \ @Doo_Deux 12 Jan \ parent \ on: Stacker Saloon
I have a website running on a RPi that has been up continuously since 2014. It is on the same SD for 10 years. The whole SD card corruption is overblown.
If it's a mostly static website, there are mostly read operations on the card. That's fine. What's wearing down an sd card are write operations, which are aplenty when running a Bitcoin node.
But even then, a failure is not a guarantee, just a probability (just like 10 minutes until next block is not guaranteed).
reply
I agree. But in my experience with a pu it's best to wire up (and add code for) a pi power button - as there isn't one built in when it ships.
In my early dabblings I lost a couple SD cards without that small button to rely on when things go wrong. (Pulling power cord at the wall killed the cards.)
reply
reply
Maybe. I generate all images every 5 minutes from db data, and there are writes to the db every 18 seconds. This db is on the SD.
Maybe look at your fstab and mount frequently written directories to tmpfs if you don't really need them and/or turn down your logging verbosity. There are a lot of little tweaks you can do to make things more efficient if need be.
reply
reply
Here is an example:
# reduce writes to SD card tmpfs /tmp tmpfs nosuid,nodev,size=100M 0 0 tmpfs /var/log tmpfs nosuid,nodev,nosuid,mode=0755,size=50M 0 0 tmpfs /var/log/nginx tmpfs nosuid,nodev,nosuid,mode=0755,size=20M 0 0 tmpfs /var/tmp tmpfs nosuid,nodev,size=10M 0 0 tmpfs /var/www/ tmpfs nosuid,nodev,mode=0755,size=10M 0 0