6 ms·
Every time I've tried to use a pi as a long-lived server, the SD card ends up getting corrupted. Switched to a chromebox running kodi for my media server, runni
by hrnnnnnn 4y ago
Every time I've tried to use a pi as a long-lived server, the SD card ends up getting corrupted. Switched to a chromebox running kodi for my media server, running 24/7, five or six years ago and haven't had a single problem with it.
- Gibbon1 4y agoTry a Beagle Bone Black
- hddherman 4y agoIf you have a workload that writes data quite frequently, then moving that data off to an external SSD is also a good way to extend the lifetime of the SD card.
- unlikelymordant 4y agoYou can boot directly off the ssd, i dont even have an sd card installed
- hddherman 4y agoThat's true, I forgot that was a feature they supported with the newer Pi-s. Doesn't work for Pi 1, you can move the root partition to the SSD, but anything needed for the initial boot still has to live on the SD card.
- satori99 4y agoI starting using a usb-3 nvme adapter instead of an sd-card for my always-on pi 4, and haven't had any issues since. It boots in about 10s now too.
- jokoon 4y agoYeah, I won't buy it until it has a bit of flash memory on it. And I don't need much, just 32MB would be enough, I would just boot linux using using a read only SD card. It's a major flaw, I don't understand why they did not find a fix yet.
- xmodem 4y agoThere are Pi CM4 SKUs that have onboard eMMC flash - I have one that I use on a carrier board that also has a SATA controller and two SSDs connected.
- jve 4y agoI have rpi4, installed almost 3 years ago on 64GB Sandisk SD card. I also have attached external storage. Still alive with tons of doker services. I have /var/log and /var/tmp on tmpfs tho
- raverbashing 4y agoYou are probably (or, the default config) doing "something stupid", like atime, or something that writes continuously to the fs, like logs, etc (I'm not blaming you, it's hard to have a pure RO FS, that would help a lot - and a standalone RPi doesn't need a lot of stuff that comes by default)
- ghoul2 4y agoSD card corruption is a big problem with the Pi, but its easily solved: enable the read-only overlay for your boot/root filesystems. This is built into the RPI OS. start raspi-config, and go into performance options. Every month or two, disable the overlay (again using raspi-config), reboot, apply updates, re-enable the overlay, and you are good to go. Also, if you are using a PI4, switch to booting from a USB stick and just forget about the SDcard.
- smilespray 4y agoThanks! This is handy to know. All the guides I've seen earlier involved a lot of manual config.
- JamesSwift 4y agoThey also support netbooting now I believe. Been meaning to try it out so I can fully host my retropi on my NAS.
- deleted 4y ago[deleted]
- m463 4y agowhen did that option appear? that is great info. (I've been running openwrt on a pi just because it had an overlay filesystem - I could run raspbian now)
- dspillett 4y agoI had trouble with that on the original models, even with a good (or at least official) power supply (many reported the issue was worse with cheaper USB power sources). Never had trouble with the 3 that was a Kodi box and latterly has been used for some electronics experiments, the 4 that is my current Kodi box, or the 400 that has been playing as router+firewall+VPN since early this year (at the time getting a 3 or 4 for the job would have been either expensive or near impossible, and I didn't want to try a potentially less well supported option, but I spotted a nice offer on a 400).
- jakemauer 4y agoIn addition to the other helpful suggestions you’ve received, look into using Log2Ram. It does what it sounds like, puts log writes in ram and then writes them to disk on a slower cadence that doesn’t work your SD card that much. https://github.com/azlux/log2ram https://github.com/azlux/log2ram