Re: [Dovecot] mdbox packing
On 5/6/2012 8:12 PM, Daniel L. Miller wrote:
On 5/6/2012 8:09 PM, Daniel L. Miller wrote:
On 4/30/2012 5:23 PM, Timo Sirainen wrote:
On Mon, 2012-04-30 at 12:43 -0700, Daniel L. Miller wrote:
Is there a way to manually force an mdbox storage to be rebuilt into new files? Particularly files of the maximum size? You could do it with dsync.
dsync seems to do a marvelous job - new question.?
Given a mailbox with a larger number of older mails - assuming any new mails will have later dates - will the new mail storage files be identical? I'm probably not saying the right - let me try this:
- "dsync backup mdbox" (with appropriate args) is run for a given user.
- "dsync mirror mdbox" is done just to catch up.
- Old mailstore moved off.
- New mailstore moved to active location.
I'm sure there's a safer way to do the above - but I've got a low-traffic site and I can just shut down mail service altogether for a few minutes if I want during this.
Now - repeat the above four steps. Will mail files m.1 through m.(n-1) be identical to the last run? Is this a valid packing strategy prior to performing an rsync type backup - assuming no changes are being made to the archived mails between pack runs?
Given the above, and SIS - if the backup is performed in the same spool, i.e. original is /var/mail/domain/user, backup is /var/mail/domain/user-new - will this result in any problems with SIS? If after the pack and rename operation, the old mail tree is simply deleted - will that leave SIS files unreferenced if the user later deletes the messages from their active store?
And yet another one - dsync does not APPEAR to be copying ACL's in this process.
-- Daniel
On 7.5.2012, at 6.22, Daniel L. Miller wrote:
Given a mailbox with a larger number of older mails - assuming any new mails will have later dates - will the new mail storage files be identical? I'm probably not saying the right - let me try this:
- "dsync backup mdbox" (with appropriate args) is run for a given user.
- "dsync mirror mdbox" is done just to catch up.
- Old mailstore moved off.
- New mailstore moved to active location.
I'm sure there's a safer way to do the above - but I've got a low-traffic site and I can just shut down mail service altogether for a few minutes if I want during this.
Now - repeat the above four steps. Will mail files m.1 through m.(n-1) be identical to the last run? Is this a valid packing strategy prior to performing an rsync type backup - assuming no changes are being made to the archived mails between pack runs?
If you stop mail delivery and kill any imap/pop3 processes before running 2 (or alternatively run dsync mirror once more as step 5) then they should have identical mails, but the m.* files most likely won't be identical. dsync doesn't sync files, it syncs mails, and it doesn't care how the mails get stored.
Given the above, and SIS - if the backup is performed in the same spool, i.e. original is /var/mail/domain/user, backup is /var/mail/domain/user-new - will this result in any problems with SIS? If after the pack and rename operation, the old mail tree is simply deleted - will that leave SIS files unreferenced if the user later deletes the messages from their active store?
Yes. Don't just rm -rf the old tree, use doveadm expunge to expunge all mails so they get unreferenced.
And yet another one - dsync does not APPEAR to be copying ACL's in this process.
Yeah, it doesn't currently copy ACLs or Sieve scripts.
participants (2)
-
Daniel L. Miller
-
Timo Sirainen