<<< Date Index >>>     <<< Thread Index >>>

Re: Using rsync with Mail-tree



On Wed, Feb 18, 2004 at 09:01:00PM +0100, Ton Boelens wrote:
> Fellow Mutt-users,
> 
> Please inform me if this is off-topic.
> 
> I have a regular desktop pc that I use to retrieve mail and read and
> write messages. I use getmail, procmail, postfix and of course Mutt. I
> have a directory called ~/Mail that contains a number of
> maildir-subdirectories. Polling with getmail is automated with cron and
> so is archiving and backing up. At the moment, this machine is
> constantly switched on.
> 
> Also, I have a laptop and I would like to take my whole collection of
> mails with me when I travel.
> 
> What I am thinking about to do is: use rsync to copy all the changes to
> ~/Mail on the desktop pc to the ~/Mail directory on the laptop. Then use
> the laptop to read and write mail while I am away. Afterwards, when I
> return home from the trip, use rsync again to copy the changed mails
> (status of the mails has changed) back to the desktop pc. The mails that
> I have written will be send-off from the laptop directly.
> 
> My question is: does anybody have experience with such a setup? If so, I
> would be very happy when you gave me some tips and pointers.
> 
I've used rsync with a quite complex hierarchy of mail, it works quite
well, I was using it to make my 'current' Mail tree available on
another system (and to back it up), not quite the same as you're
doing. There are a couple of things to note however:-

    1 - rsync wont work its wonders on individual messages, it will
    compare mailbox files which contain many messages.  Thus if you
    rsync a mailbox from system A to system B, then delete a message in
    the mailbox on system B, then rsync it back the message will be
    deleted on system A as well.  This may well be exactly what you
    want it to do.

    2 - If you use a maildir hierarchy rather than an mbox one then
    messages will never disappear unless you change from the default
    rsync options.  I actually used this so that my system B was an
    archive of every message that had been on system A even though
    many had since been deleted.  I just copied daily  using rsync
    from system A to systemm B.

-- 
Chris Green (chris@xxxxxxxxxxx)