brewedbits.dev

Personal blog with guides and news on selfhosting, Linux and AI, from the Netherlands

nextDash nextdash --aboutYour bookmarks. Your terminal. checks your links knows your Docker host one container, no cloudLive demo →nextdash.cc ↗

Tip: rclone sync --dry-run shows what will be deleted before it happens

Rclone
~/tips/rclone-dry-run

rclone sync /data remote:backup --dry-run -v

Shows which files rclone sync would copy or delete, before anything changes.

rclone sync makes the destination identical to the source. That includes deleting everything at the destination that is not in the source, so I like to see the plan first.

rclone sync /data remote:backup --dry-run -v

--dry-run (short: -n) goes through the whole job and reports what it would copy and delete, without doing it. The -v makes it list each file. When the list looks right, run the same command again without the flag.

Caveat: if you only want to add files and never remove any, use rclone copy instead of sync. The rclone documentation itself recommends a dry run first, because sync can cause data loss.

Further reading: rclone sync

More Rclone tips rclone copyurl https://example.com/files/big.iso remote:isos -a rclone size remote:photos rclone config redacted rclone ncdu remote:backup rclone copy /data remote:data --bwlimit "08:00,1M 18:00,5M 23:00,off" -P All Rclone tips (14) All topics

Link