Be the first to know and get exclusive access to offers by signing up for our mailing list(s).

Subscribe

We ❤️ Open Source

A community education resource

The one rsync mistake that could destroy your backups

Learn Linux TV shows you how to safely transfer files between servers without losing data or metadata.

Want to master file transfers between Linux servers? Your answer is rsync, offering far more control than basic tools like SCP. In his video from Learn Linux TV, Jay shares how to safely sync files across systems while preserving metadata, avoiding common pitfalls, and using powerful options that give you complete control over your transfers.

The tutorial walks through rsync fundamentals, starting with installation checks and basic syntax before moving into practical examples. Jay demonstrates the critical importance of testing commands with --dry-run before executing them, shows how trailing slashes change directory behavior, and explains why rsync isn’t quite a true sync by default. 

This video covers essential options like verbose mode, recursive copying, and the --delete flag, then introduces archive mode as the go-to solution for preserving file metadata during transfers. Throughout the demonstration, Jay syncs a real notes directory between servers, showing both backup and restore operations while highlighting potential gotchas like file renaming issues.

Key takeaways

  • Always test first with --dry-run – This safety net shows exactly what rsync will do before actually copying files, preventing costly mistakes.
  • Archive mode (-a) is your best friend – It preserves modification times, permissions, ownership, and symbolic links, making it perfect for backups.
  • Trailing slashes change everything – notes/ copies the directory’s contents while notes copies the directory itself, a crucial distinction for getting the structure you want.

For Linux administrators who need reliable, flexible file transfers, rsync stands out as an essential tool. The combination of -av --delete handles most backup scenarios, and understanding that rsync is fundamentally a one-way transfer tool helps you use it effectively. Whether you’re setting up automated backups or syncing development environments, this utility delivers the control and reliability you need.

More from Learn Linux TV

About the Author

Learn Linux TV is Linux-focused company that provides Linux-related content and services, focusing on learning. Popular content includes tutorials, distribution reviews, complete guides, and more. The company has additional specialties in security, networking, storage, virtualization, cloud, and more.

Read Learn Linux TV's Full Bio

The opinions expressed on this website are those of each author, not of the author's employer or All Things Open/We Love Open Source.

Want to contribute your open source content?

Contribute to We ❤️ Open Source

Help educate our community by contributing a blog post, tutorial, or how-to.

We're hosting two world-class events in 2026!

Join us for All Things AI, March 23-24 and for All Things Open, October 19-20.

Open Source Meetups

We host some of the most active open source meetups in the U.S. Get more info and RSVP to an upcoming event.