this post was submitted on 10 May 2024
4 points (100.0% liked)

Debian operating system

2749 readers
1 users here now

Debian is a free operating system (OS) for your computer. An operating system is the set of basic programs and utilities that make your computer run. Debian provides more than a pure OS: it comes with over 59000 packages, precompiled software bundled up in a nice format for easy installation on your machine.

founded 4 years ago
MODERATORS
 

What is the best way to back up as much as possible of Debian 12 on my laptop to a server that has SSH available? I am currently backing up my users /home/ folder, but I would like to be able to nuke and restore the system from a backup.

I have ventoy on an external drive if that helps any.

P.S. I would like to be able to do incremental backups too.

top 7 comments
sorted by: hot top controversial new old
[–] [email protected] 1 points 6 months ago

no calls for restic? I use restic and a s3 layer on the other end, be it either backblaze/wasabi/s3/whatever for remote or minio/garage for local object storage. Stuff just works, then I write a systemd unit file to back it up according to whatever schedule I want for both a local target and a remote target. Helps to solve the 3-2-1 backup strategy this way. Good luck!

[–] [email protected] 1 points 6 months ago

I would say dd is the best solution for a very complete backup, but I’m also a fan of Borg Backup for incremental backups.

[–] [email protected] 1 points 6 months ago (1 children)

The standard answer: don't backup the system, automate its deployment instead. Backup only data.

[–] [email protected] 1 points 6 months ago* (last edited 6 months ago)

Even for a home system? Not a fleet of data center servers. I am currently using rsync to backup /home/<>/ to the ssh server. I tend to make a lot of changes to the base Debian/KDE install.

[–] [email protected] 1 points 6 months ago

Relax And Recover for os level backups. https://relax-and-recover.org/

With rear you can back up your system to pretty much anything. Mounted volume, USB drive, even to a bootable iso.

I use weekly rear backups for my system, and hourly Borg backups for diffs/point in time restore of user data, but you could use rear for an entire system snapshot as well.

[–] [email protected] -2 points 6 months ago (1 children)

dd if=/dev/sda of=/dev/sdb bs=5M --status=progress

Just don't mix up a and b otherwise you're truly screwed.

[–] [email protected] 2 points 5 months ago

I actually did this **dd if=(running system root volume) of=(local usb attached hard drive file) ** This gives me a full disk backup that would be no worse than if power got yanked. (I know laptops have batteries, for this case we are pretending to be a desktop with no UPS)