That seems to be the case:
Looks like the files themselves are nigh unusable without the database to index them.
Zimbra has its own backup process, that safely exports everything necessary to a folder structure. Looking at the backup directory structure it seems like the Zimbra folks paid attention and made sure that files are not overwritten unnecessarily and that the things that change seem to do so using serial writes (for example database logs are kept in files that are just added to and not modified entirely.
I think that if Restic is given the Zimbra backup folder (by defailt
/opt/zimbra/backup) as a source location, it will efficiently back Zimbra up.
Also, Zimbra seems to have command line utilities that initiate a backup. It looks like it will be easy to integrate Zimbra and Restic to run sequentially from the same script so that Restic runs after every Zimbra backup run.
I don’t use Zimbra myself so I didn’t verify it.
If you’re only interested in the mailboxes, perhaps it’s possible to exclude other things. However, I would urge you to back up the entire Zimbra backup folder, because then you can use Zimbra’s own tools to restore specific accounts.
Hope that helps.