Skip to content

restic to Backblaze B2 from a 512MB box: memory murder

VPS Hosting by mediaaustin 3 replies 238 views
5 #1

Your backup strategy is only as good as your memory profiling

For what it's worth, I've been running Restic to Backblaze B2 from a 512MB Contabo instance and watching it get OOM-killed mid-snapshot. This is not a small dataset—roughly 180GB, mix of mail archives and static assets.

For what it's worth, I suspected blocklist issues at first (old habit), but this is pure memory pressure. Restic's default pack size loads chunks into RAM before upload. On a 512MB box with anything else running, you're playing chicken with the kernel OOM killer.

I have not found a Restic-native fix. Raising the issue here before I migrate my mail spool elsewhere.

SPF, DKIM, DMARC — holy trinity ✉️
#2

Whence came this affliction upon ye olde server, wherein the backup tool doth consume all available memory, and wherefore must we suffer such indignities, methinks the answer lies not in the application itself but in the very architecture of our meager provisioning, for it was in days of yore that men ran mighty engines upon scant resources and prevailed, yet this modern software, bloated and proud, knoweth not the virtue of restraint, and so I bid thee consider whether the fault lies with Restic — https://restic.net — or with our own ambition to squeeze the ocean into a thimble.

#3

1. Restic memory usage is a known issue
2. Common workarounds include
2. A) rclone with chunking
2. B) smaller source sets
2. C) more swap (slow but works)
3. My preferred solution
3. I) separate $2 instance
3. Ii) dedicated to backups only
3. Iii) nfs mount or sshfs from main box
4. Benefits of this approach
4. A) main box memory untouched
4. B) backup box can be smaller/cheaper
4. C) easy to replace if corrupted
5. Downside: you now have two bills

#4

Yeah nah that's just how it is with restic?

Sweet as if you got ram to burn but on these tiny boxes it's always gonna be a struggle. I just threw 2GB of swap on mine and let it churn. Slow as? Absolutely. Works tho.

Chur to @liam_funky for the two-box idea, that's actually not bad? Might try that on my next RackNerd box.

Post a reply

You need an account to reply. Log in or register to join the conversation.

Post reply Preview Save draft