[Dovecot] Backing Up
Ken A
ka at pacific.net
Thu Oct 30 15:51:04 EET 2008
Calvin Gordon wrote:
> I use the tar/bzip method, and have been wondering about the rsync. All
> my users have system accounts on the dovecot server, and use Maildir
> format. If i rsync the mail to another box where the users do not have
> system accounts, will the ownerships/ permissions etc. be goofed up ?
>
> Correctly, or incorrectly, I've been using tar to preserve all that
> information.
rsync preserves all that too, but you should preserve uid->username and
gid->groupname mappings too, otherwise all that information is not as
useful. Saving the password files is usually sufficient, assuming you
are doing backups for disaster recovery, and not just for the occasional
restore after an "oops, I deleted all my mail!" phonecall.
rsnapshot is nice too. It uses rsync and hard links to make as many
snapshots of the filesystem as you like. This creates many 'restore
points' with total disk usage being just over what a single full backup
would take.
Ken
>
> Cal Gordon
>
> Sotiris Tsimbonis wrote:
>> Scott Silva wrote, On 10/30/2008 12:34 AM:
>>> on 10-29-2008 3:18 PM Dave McGuire spake the following:
>>>> On Oct 29, 2008, at 5:32 PM, Arkadiusz Miskiewicz wrote:
>>>>>>>> What is the best way to do a (server-side) backup of all mail in a
>>>>>>>> user's mail?
>>>>>>> I usually just rsync the /home directories to another server. The
>>>>>>> inital sync
>>>>>>> can take a while, but it gets faster after there is a base to work
>>>>>>> from.
>>>>>> ...and it's much less painful if you're using maildir instead of
>>>>>> mbox!
>>>>> Not for rsyncing. Tons of small files means much slower rsync.
>>>> Due to connection turnaround latency, I assume? (I've never
>>>> looked at
>>>> the rsync protocol) If that's the case, then I stand very much
>>>> corrected, thank you. I was going from the same logic regarding mbox
>>>> vs. maildir in the context of backups. One new message delivered and a
>>>> 400MB mail spool gets backed up again..
>>>>
>>>> -Dave
>>>>
>>> Rsync adds some latency as it indexes and compares files on both ends.
>>> Obviously it would take more time to compare 40,000 1K files then
>>> 1000 40K
>>> files even though the data size is similar. It would still be better
>>> than
>>> tar/bzip/scp which has to compress everything and transfer the lot
>>> every time.
>>>
>>
>> Maildirsync it an "Online synchronizer for Maildir-format mailboxes"
>> See http://hacks.dlux.hu/maildirsync/
>>
>> Sot.
>>
>
--
Ken Anderson
Pacific.Net
More information about the dovecot
mailing list