Interview Prep/Linux/Migrations, performance and fleet operations

Two servers must keep a directory in sync both ways for a simple active-active setup. What do you recommend?

AdvancedScenarioMigrations, performance and fleet operations
Answer

Situation read → Bidirectional file sync is hard; conflicts are the main risk.

What I'd do →

  1. Prefer removing the need: shared storage (NFS, EFS), object storage, or one writer.
  2. If files are rarely edited on both sides: unison with a conflict policy, or lsyncd one-way per direction for separate subdirs.
  3. For real active-active: a clustered filesystem (GlusterFS, CephFS) or DRBD with a cluster FS (complex).

Why → Two rsync crons in opposite directions will eventually delete or overwrite new files.

Interview tip → Saying "I'd avoid bidirectional sync" and explaining why is the senior answer.

All Linux questions Roadmap: Linux

More on Migrations, performance and fleet operations