Skip to content

Comment on Correct Backups Require Filesystem Snapshots

Comments

Most of what is described there seems like "backup larping".

I don't need to backup my Discord and most likely I will be able to simply restore any iTerm configuration that I have in less time than setting up and keeping file system snapshots running.

Any DEVONThink or my excel spreadsheets or invoices / documents that I care about I can simply backup after I am done working on them. I usually work on one or two at the time. When my laptop dies I probably can just remember what was needed to be done and redo the work.

Restoring file system snapshot would usually be much more hassle than filling in single invoice again or downloading it from some provider again.

For web applications there is usually SLA where they specify how much data can be lost like 1 hour or 30 mins - but no one will realistically guarantee "no data lost" - because imagine doing full snapshot of 1 Terabyte drive it takes I suppose at least an hour anyway.

Sure, I've been accused of being overly concerned with correctness. :-)

because imagine doing full snapshot of 1 Terabyte drive it takes I suppose at least an hour anyway.

On copy-on-write filesystems, snapshots are nearly instantaneous.

time than setting up and keeping file system snapshots running

As shown in the code snippet, pretty much all it takes is a few snapshot commands around the backup command and changing the source directory to the snapshot mount point.

Different people care about different things :)

I also think about snapshots differently.

For me snapshot is actual copy stored on a different hard drive or other medium. So copy operation is never going to be instant.

Scenario in the article is power loss so that is also not something I worry about that much. Mostly I worry about hardware failure where I would not be able to turn on my laptop/server again. For power loss UPS or battery in laptop is my go to solution.

The snapshot takes a second to generate; then you can take as long as your hardware needs to get it somewhere else.

These arguments apply to external backups, but if you use a filesystem like ZFS or BTRFS, than snapshots are atomic, essentially instant, and can even be sent over the network as diffs/deltas against the last snapshot that was sent, so backing up a TB drive over the network every hour is total reasonable. These filesystems also give you access to snapshots via the FS, so you don't need to restore a snapshot to access your files, it's as easy mounting the readonly-snapshots directory, which you could even just keep mounted 24/7, making deleted files just a `cd` away, or quicker with a shell script that jumps first into the last snapshot of your current directory and then recursively back to the last one before that.

Not that I've gotten around to writing that script for myself :c

But the automatic snapshots are much easier c:

I don't need to backup my Discord

If you don't back up your Discord, what will you do when Discord changes how it works or stops working?

Important part of Discord are people - having backup means of communication on different platforms is best I think.

The application is self-modifying and partially server-defined, as well as being an online communication tool. Discord-the-company can change it at basically any time, and disallow any versions deemed "inappropriate".

my excel spreadsheets or invoices / documents

Easy when you work on simple documents. I wouldn't want my accountant doing that.

AboutSource Built by g1lg1l

Hackerly is an independent reader for Hacker News, built on the public HN API. Not affiliated with Y Combinator.