hi all.
I'm trying to back up my scalix server to a vanilla dovecot install so I can play with the mail outside the production environment.
I'm having some issues getting imapsync working.
I've been going through the imapsync help, Scalix help, Dovecot help, Hell, prayer and several bucketloads of coffee on this one.
The issue seems to be that it won't sync anything with an attachment because Scalix appends the flag \X-HAS-ATTACH to the individual emails and dovecot can't deal with it / doesn't know what to do with it (I think)
Initial error reads: "Couldn't append msg #478 (Subject:[0]) to folder Trash: Error trying to append string: 926 BAD Invalid system flag \X-HAS-ATTACH"
To get around this I tried the command --regexflag s/\\X-Has-Attach//g
Whole command now looks like:
andrew@pintsized:~]$ imapsync --host1 scalix --user1 andrew.sharp --password1 mypassword --host2 dovecot --user2 andrew --password2 mypassword --noauthmd5 --regexflag s/\\X-Has-Attach//g
Which churns through everything throwing this error (msg # xxx changes per email) on every email with an attachment:
"Couldn't append msg #478 (Subject:[0]) to folder Trash: Error trying to append string: 926 BAD Invalid system flag \"
So I tried using --fast (which the man page says makes it not sync flags) and got the \X-HAS-ATTACH error again so I combined the 2 switches like this:
imapsync --host1 scalix --user1 andrew.sharp --password1 mypassword --host2 dovecot --user2 andrew --password2 mypassword --fast --noauthmd5 --regexflag s/\\X-Has-Attach//g
and got the "BAD Invalid system flag \" error again.
adding the switch --regexflag s/\\//g or --regexflag s/\\*//g or --regexflag s/\\*\//g doesn't achieve anything either, I still get the "BAD Invalid system flag \" error.
Can anyone spot the error of my ways on this one or offer some advice of where to look?
I'm guessing I might need to preprocess the stream to remove the flags from the headers but I'm just not sure.
Any advice appreciated.
Thanks,
Andrew