2

I store my files (plaintext) on an encrypted Sparse Bundle Disk Image and backup this image (the ciphertext) with Rsync to another server. Sparse Bundle Disk Images create 8 MiB files ("bands") to store the ciphertext.

The problem is: just opening files or doing minor things like a rename or small edit will cause several changes on the HFS filesystem like:

When sparse bundle translates this into the bands, this causes large backup deltas, which is undesirable.

Can I configure this image to disable .DS_store, Spotlight and other metadata which is burdening my backup system?

2 Answers2

1

Here is one part:

touch /Volumes/THEVOLUME/.metadata_never_index

From https://apple.stackexchange.com/questions/136191/prevent-spotlight-from-indexing-future-hard-drives

This only solves part of it. Making community wiki to allow other additions.

Other potential stuff is here

https://apple.stackexchange.com/questions/6707/how-to-stop-os-x-from-writing-spotlight-and-trash-files-to-memory-cards-and-usb

0

I would recommend to achieve the goal by just excluding unnecessary files. Example:

rsync -ahPruvz --exclude=Thumbs.db --exclude='target/' --exclude='/home/*/.cache/' --exclude='/home/*/Downloads/' A B

Thumbs.db is the common garbage file you mentioned. target/ is a common output directory for build tools (java,rust etc). .cache is a common place to store cache files, which often do not need to be backed up. And so on, just mention the files that annoy you. You will see your diff if you run verbose rsync twice.

While this may not feel like an ideal solution, it does work on practice. The diff for the garbage files goes generally down to < 1 Mb after cleaning the most fat files.

VasyaNovikov
  • 3,656