this post was submitted on 13 Jan 2024
24 points (96.2% liked)

Selfhosted

40329 readers
433 users here now

A place to share alternatives to popular online services that can be self-hosted without giving up privacy or locking you into a service you don't control.

Rules:

  1. Be civil: we're here to support and learn from one another. Insults won't be tolerated. Flame wars are frowned upon.

  2. No spam posting.

  3. Posts have to be centered around self-hosting. There are other communities for discussing hardware or home computing. If it's not obvious why your post topic revolves around selfhosting, please include details to make it clear.

  4. Don't duplicate the full text of your blog or github here. Just post the link for folks to click.

  5. Submission headline should match the article title (don’t cherry-pick information from the title to fit your agenda).

  6. No trolling.

Resources:

Any issues on the community? Report it using the report flag.

Questions? DM the mods!

founded 1 year ago
MODERATORS
 

Hey there, I have a (very) small Ubuntu server and I was dabbling on the idea to do system backups (entire system, meaning, if the disk of the said pc fries, I can get another one, put the info from the backup on the new disk, works immediately afterwards). I have a couple of Linux mint machines and a windows one. I searched a lot out there and found several names, from rsync to Borg backup.But ultimately I don't really know if these solutions would fit my use case.

So the question is: is there a feasible way/service that can be self hosted to do backups of local machines, similar to an image backup? Or, if you believe there are better ways to do it, can you please mention it?

Thanks in advance

all 15 comments
sorted by: hot top controversial new old
[–] Lodra@programming.dev 14 points 10 months ago (1 children)

If you’re up for it, it’s generally better to not backup everything. Only backup the data that you need. Like a database. Or photos, music, movies, etc. for personal data. For everything else, it’s best to automate the install and maintenance of your server.

Disclaimer: this does take more effort!

[–] ZeDoTelhado@lemmy.world 2 points 10 months ago

Nowadays I sort of do this with seafile. Select folders to sync, open the app every other time to resync stuff, carry on with your day. The only thing I wanted to take away if there is a better way to not have a massive hassle to reinstall everything in case something happens (and in case I forget to select a folder to sync also).

But your suggestion I think is very valid as well. At least for mint have a way to make a more automated installer or similar to get the stuff I use usually. Yet another rabbit hole to go into...

[–] peasntanks@lemmy.ml 4 points 10 months ago* (last edited 10 months ago)

REAR Relax-and-Recover will do entire system point-in-time snapshot backups to a bootable iso or physical USB thumb drive: https://relax-and-recover.org/rear-user-guide/index.html

I use rear for backing up my root, and Borg for packing up user data (for versioning, file recovery), but you can use rear for the entire system too.

[–] jubilationtcornpone@sh.itjust.works 4 points 10 months ago (2 children)

I use Veeam Backup & Recovery Community Edition. If you're runing VM's you have to be on VMWare or Hyper-V. You can also use agents on the individual VM/Server. It also requires a pretty hefty Windows host, at least if you want your backups to complete fairly quickly.

Those are understandably downsides for some people. But, Veeam is in a class by itself. It has no serious competitors and as far as ease of use and reliability, it's top tier.

I'm lazy. I don't want to spend a bunch of time configuring finicky backups only to find out I needed one and it failed. I honestly wish there were a comparable open source backup system. I have yet to find anything that works as well.

[–] ZeDoTelhado@lemmy.world 1 points 10 months ago

I was reading about it and I actually like a lot this solution's principle. It reminds me a lot of puppet which I have seen before (for other kind of tasks) to orchestrate several computers. Big shame it works on windows though, since I have a server with docker on ubuntu server at this point and was not really looking forward to change that. But thanks for the suggestion, is for sure very interesting

[–] Mautobu@lemmy.world 1 points 10 months ago

Another vote for Veeam. I use it at home and professionally. It's a solid product and has saved my ass countless times.

[–] taladar@sh.itjust.works 4 points 10 months ago

I think Borg Backup would fit your needs. You would still need to reinstall things like a boot sector and recreated partitions but on the other hand file based backups have the advantage that you can restore individual files when needed too and that it is easier to only backup what changed. Just make sure to exclude any temporary files you don't want to keep from the backup (e.g. cache dirs, log files that get rewritten often and aren't relevant long-term,...).

[–] SnotFlickerman@lemmy.blahaj.zone 4 points 10 months ago* (last edited 10 months ago) (1 children)

https://github.com/teejee2008/timeshift

I think TimeShift could maybe work for you, but you might need a script to offload the backups it creates.

https://restic.net/

Restic is another option, but it's a little less user friendly and is all CLI, if i recall correctly. However I'm pretty sure you can send backups straight to a server via Restic.

[–] ZeDoTelhado@lemmy.world 2 points 10 months ago* (last edited 10 months ago)

I checked a couple of times time shift, but it's a shame not even ftp is allowed as a backup destination.

As for restic, will give a check later

EDIT: just read about restic, and I think this can be the solution I was looking for. Docker image is available and all, so for me that is a big plus. Once I have the chance I will test drive it and see where it goes. Thanks!

[–] Discover5164@lemm.ee 3 points 10 months ago

you could use btrfs snapshots of the volumes you want to preserve. then send the snapshot to a remote location.

if the ssd fries you just need to download the snapshots and restore their layout.

i have a script for it and i use it on my server: https://github.com/simone-viozzi/btrfs2cloud-backup

[–] kylian0087@lemmy.world 2 points 10 months ago (1 children)

Not the intended usecase but fogproject can be used to pull images. Then later you can just PXE boot and place a image back on to a differen system.

Still i think borg would be better for actual backups.

[–] ZeDoTelhado@lemmy.world 1 points 10 months ago (1 children)

Had to search for a while what even pxe boot is, but I believe I came around the suggestion. I like fogproject main idea, sounds like a way to deploy thin clients or similar. Not exactly what I am looking for,but it's good to know this exists. Thanks!

[–] kylian0087@lemmy.world 2 points 10 months ago

What can also be a good option is urbackup. it supports different operating systems full image backups of windows clients. Not entirely sure if it supports image backups of a linux clients how ever.

[–] itsnotits@lemmy.world 0 points 10 months ago

Maybe btrfs with RAID 1?