20

Not a stranger to using linux, but never bothered with keeping things synchronized between devices.

I have a laptop, and a desktop both running Arch (I use Arch BTW) and wanted to investigate the best way to synchronize things from device to device. Just to outline some details, both are running KDE on Wayland, both BTRFS, as well as a number of other similarities such as username.

I want to be able to synchronize certain config files, Documents and Files, and was going to go the Syncthing route.

What are you doing, or what would you recommend to setup in order to have parity between two devices?

top 18 comments
sorted by: hot top controversial new old
[-] cakeistheanswer@lemmy.dbzer0.com 8 points 4 months ago

I haven't even begun to dig in to everything it can do, but chezmoi is in the arch repo.

https://github.com/twpayne/chezmoi

Fits the bill.

[-] Hellmo_Luciferrari@lemm.ee 3 points 4 months ago

I will have to give this a look! Thank you!

[-] ARNiM@lemmy.world 1 points 4 months ago

Man I’m sold by the support for templates. Will try.

[-] giacomo@lemm.ee 7 points 4 months ago

syncthing works for me, both locally and on a vpn.

[-] bloodfart@lemmy.ml 5 points 4 months ago

It’s never too late to learn how to use rsync instead of some third party software package.

[-] unrushed233 3 points 4 months ago

I like yadm - yet another dotfile manager. It uses a Git repository in the background, which you can sync with GitHub, GitLab, Codeberg or a selfhosted Git server like Forgejo.

[-] Hellmo_Luciferrari@lemm.ee 2 points 4 months ago

This interests me. I may have to check this one out specifically for my configuration files. And I will definitely go the self hosting route if I do this. Thank you!

[-] daddy32@lemmy.world 3 points 4 months ago

Syncthing for everything.

[-] Forester@yiffit.net 3 points 4 months ago
[-] Hellmo_Luciferrari@lemm.ee 2 points 4 months ago

From my understanding, without having a VPN connection to my home network, or proper port forwarding (which sounds like a security nightmare to me) it would only function on my local network?

[-] Successful_Try543@feddit.org 3 points 4 months ago* (last edited 4 months ago)

Imho, opening the SSH port exclusively to your computer isn't a bigger risk than setting up a VPN, if you use authentication by keyfiles ~~a certificate~~.

[-] Forester@yiffit.net 3 points 4 months ago* (last edited 4 months ago)

By cert you mean a ssh key pair correct? As in public and private keys.

[-] Hellmo_Luciferrari@lemm.ee 2 points 4 months ago

That is fair. Just historically speaking, I have typically only had 1 port opened on my router for VPN access, and then setting up SSH cert auth from system to system.

Like Shrek, layers xD

[-] tal@lemmy.today 2 points 4 months ago* (last edited 4 months ago)

Unison might be worth a look, provides bidirectional merging and command-line operation. It's what I'd use if I were mostly working with binary files and didn't want a history.

Rsync, which someone else recommended, is really aimed at efficient unidirectional replication, not keeping two directories on computers that are both being changed and are intermittently connected in sync.

config files

If there's mostly text and you're going to want to review changes, want to keep a history, and do a lot of merging, I'd use git, symlink files to aim at the git repo. I have a custom helper script, but stuff like GNU stow is aimed at this, and I'd probably recommend that someone look at it before rolling their own. Here's an example of someone using it with git in this role:

https://ratfactor.com/setup2

I agree with that guy about using bare git repos as the "master" copy, even if one of the machines in question also hosts the bare repos and technically you have some redundant information on it. Makes life easier, no machine is "special".

If I had both binary files (say, a music collection) that I wanted kept in sync without a history and text files that I do (say, my dotfiles), I'd use both.

[-] Hellmo_Luciferrari@lemm.ee 1 points 4 months ago

Fantastic suggestions. Gives me some things to try. Thank you so much!

[-] BarbecueCowboy@lemmy.world 1 points 4 months ago

Not super popular, but i've been using Resilio Sync for years, it's from what used to be the Bittorrent Foundation.

The UI has all the features I need but is still simple and I've been using it for years and have never had to spend any time troubleshooting it post-install. I'm not sure what that gets you over syncthing though.

[-] Hellmo_Luciferrari@lemm.ee 1 points 4 months ago

Back on windows I have used Resilio Sync. I don't hate it, does essentially what I am looking for, but I am trying to go more open source route. Thank you for the suggestion!

this post was submitted on 27 Jun 2024
20 points (91.7% liked)

Linux

8118 readers
16 users here now

Welcome to c/linux!

Welcome to our thriving Linux community! Whether you're a seasoned Linux enthusiast or just starting your journey, we're excited to have you here. Explore, learn, and collaborate with like-minded individuals who share a passion for open-source software and the endless possibilities it offers. Together, let's dive into the world of Linux and embrace the power of freedom, customization, and innovation. Enjoy your stay and feel free to join the vibrant discussions that await you!

Rules:

  1. Stay on topic: Posts and discussions should be related to Linux, open source software, and related technologies.

  2. Be respectful: Treat fellow community members with respect and courtesy.

  3. Quality over quantity: Share informative and thought-provoking content.

  4. No spam or self-promotion: Avoid excessive self-promotion or spamming.

  5. No NSFW adult content

  6. Follow general lemmy guidelines.

founded 1 year ago
MODERATORS