Re: [Dovecot] Want to have some users with Maildir, some with mbox

2010-02-01 Thread Stewart Dean

GREAT!

Timo Sirainen wrote:

Yes.
Yes.

  

:) Getting to Yes! :)

Question 3: When converting existing users from mbox to maildir, should

I delete the index contents?



They'll be created into different directories. mbox is in .imap/ dirs,
while Maildir doesn't use it. So you can delete the .imap/ dirs
afterwards from wasting space.
  
Does this mean that DC with Maildir doesn't use indices OR that it 
doesn't use that directory tree?


Timo: Thanks SO much for your help.  Do you still have an Amazon wish 
list :)?


--
Grant us, in our direst need, the smallest gifts: the nail of the 
horseshoe, the pin of the axle, the feather at the pivot point, the 
pebble at the mountain's peak, the kiss in despair, the one right word. 
In darkness, understanding.

Paladin of Souls by Lois McMaster Bujold
--
Stewart Dean, Unix System Admin, Henderson Computer Center, Bard 
College, Annandale, New York 12504 sd...@bard.edu voice: 845-758-7475, 
fax: 845-758-7035


Re: [Dovecot] Want to have some users with Maildir, some with mbox

2010-02-01 Thread WJCarpenter


http://wiki.dovecot.org/Migration/MailFormat shows a bunch of 
scripts, one of them claims to preserve UIDs.


Does anyone here have direct successful experience with this?  I only 
asked about this because a comment on that same page says, None of 
the solutions described below preserve the message UIDs.


Answering my own question.  I did some experiments last night, and 
JulianFitzell's patched version of mb2md.pl, along with his 
migrateuser.sh script, looks like it works as advertised.  (Local 
tweaks to the migrate scripts, but that's fair enough.)   Thanks, Julian!



Commenting on my answer to my own question... :-)

For one MBOX folder for one user, total of over 5000 messages, a couple 
of dozen messages got a warning to the effect of can't parse date for 
this message.  Although I imagined that the resulting MAILDIR messages 
would have bogus dates, it turned out that they had no headers at all.  
The message files contained only the message bodies.  (The user 
complained, but I had him whacked so word wouldn't get out.  :-)





Re: [Dovecot] Want to have some users with Maildir, some with mbox

2010-01-30 Thread WJCarpenter

On 1/29/2010 4:11 PM, WJCarpenter wrote:


http://wiki.dovecot.org/Migration/MailFormat shows a bunch of 
scripts, one of them claims to preserve UIDs.


Does anyone here have direct successful experience with this?  I only 
asked about this because a comment on that same page says, None of 
the solutions described below preserve the message UIDs.


Answering my own question.  I did some experiments last night, and 
JulianFitzell's patched version of mb2md.pl, along with his 
migrateuser.sh script, looks like it works as advertised.  (Local tweaks 
to the migrate scripts, but that's fair enough.)   Thanks, Julian!




[Dovecot] Want to have some users with Maildir, some with mbox

2010-01-29 Thread Stewart Dean
Want to have some users with Maildir, some with mbox, as I migrate from 
mbox format to maildir over the space of a month.  After everyone is 
converted to maildir, I'll change the mail_location in dovecot.conf.  
During the interim, can I use the Custom mailbox location script (at the 
bottom of the Mail Location DC Wiki page)?



if [ -d $HOME/.maildir ]; then
  export MAIL=maildir:$HOME/.maildir
else
  export MAIL=mbox:$HOME/mail:INBOX=/var/mail/$USER
fi
  

Questions:
1) What does explicitly specifying MAIL this way override?  The 
dovecot.conf mail_location variable?

2) My mail_location var is defined as:

mail_location: mbox:~/mail:INBOX=/var/spool/mail/%u:INDEX=/var/dcindx/%u

and my prospective maildir INBOX and mail folder root is to be 
~/Maildir.  So would I change the above to:

if [ -d $HOME/Maildir ]; then
  export MAIL=maildir:$HOME/Maildir:INDEX=/var/dcindx/$USER
else
  export MAIL=mbox:$HOME/mail:INBOX=/var/spool/mail/$USER:
INDEX=/var/dcindx/$USER
fi 
Question 3:  When converting existing users from mbox to maildir, should 
I delete the index contents?


Thanks in advance!

dovecot -n output

# 1.2.8: /usr/local/etc/dovecot.conf
# OS: AIX 3 0001378F4C00  
listen: *:143

ssl_listen: *:993
disable_plaintext_auth: no
verbose_ssl: yes
login_dir: /var/run/dovecot/login
login_executable: /usr/local/libexec/dovecot/imap-login
login_processes_count: 12
login_max_processes_count: 774
max_mail_processes: 1280
mail_max_userip_connections: 12
verbose_proctitle: yes
first_valid_uid: 200
mail_location: mbox:~/mail:INBOX=/var/spool/mail/%u:INDEX=/var/dcindx/%u
mbox_write_locks: fcntl
mbox_dirty_syncs: no
lda:
 postmaster_address: postmas...@example.com
auth default:
 passdb:
   driver: pam
 userdb:
   driver: passwd


--
 Once upon a time, the Internet was a friendly, 
neighbors-helping-neighbors small town, and no one locked their doors. 
Now it's like an apartment in Bed-Stuy: you need three heavy duty 
pick-proof locks, one of those braces that goes from the lock to the 
floor, and bars on the windows  Stewart Dean, Unix System Admin, 
Bard College, New York 12504 sd...@bard.edu voice: 845-758-7475, fax: 
845-758-7035




Re: [Dovecot] Want to have some users with Maildir, some with mbox

2010-01-29 Thread Timo Sirainen
On Fri, 2010-01-29 at 16:04 -0500, Stewart Dean wrote:
 Questions:
 1) What does explicitly specifying MAIL this way override?  The 
 dovecot.conf mail_location variable?

Yes.

 2) My mail_location var is defined as:
 
 mail_location: mbox:~/mail:INBOX=/var/spool/mail/%u:INDEX=/var/dcindx/%u
 
 and my prospective maildir INBOX and mail folder root is to be 
 ~/Maildir.  So would I change the above to:

Yes.

  if [ -d $HOME/Maildir ]; then
export MAIL=maildir:$HOME/Maildir:INDEX=/var/dcindx/$USER
  else
export MAIL=mbox:$HOME/mail:INBOX=/var/spool/mail/$USER:
  INDEX=/var/dcindx/$USER
  fi 

Although the else part is unnecessary, since it's the default anyway.

 Question 3:  When converting existing users from mbox to maildir, should 
 I delete the index contents?

They'll be created into different directories. mbox is in .imap/ dirs,
while Maildir doesn't use it. So you can delete the .imap/ dirs
afterwards from wasting space.

BTW. Are you also using a script that preserves IMAP UIDs? Otherwise
IMAP clients will re-download all the mail.


signature.asc
Description: This is a digitally signed message part


Re: [Dovecot] Want to have some users with Maildir, some with mbox

2010-01-29 Thread WJCarpenter


BTW. Are you also using a script that preserves IMAP UIDs? Otherwise 
IMAP clients will re-download all the mail.


Does the convert plugin preserve the UIDs?  The wiki implies that it 
doesn't, but I thought maybe since it's implemented as a plugin that 
maybe it does (or that maybe the caution is about converting to/from 
dovecot and some other server).





Re: [Dovecot] Want to have some users with Maildir, some with mbox

2010-01-29 Thread Timo Sirainen
On 30.1.2010, at 0.26, WJCarpenter wrote:

 
 BTW. Are you also using a script that preserves IMAP UIDs? Otherwise IMAP 
 clients will re-download all the mail.
 
 Does the convert plugin preserve the UIDs?  The wiki implies that it 
 doesn't, but I thought maybe since it's implemented as a plugin that maybe it 
 does (or that maybe the caution is about converting to/from dovecot and some 
 other server).

It doesn't. In v2.0 dsync does. In v2.0 convert plugin has been removed.

Re: [Dovecot] Want to have some users with Maildir, some with mbox

2010-01-29 Thread WJCarpenter



BTW. Are you also using a script that preserves IMAP UIDs? Otherwise IMAP 
clients will re-download all the mail.
   

Does the convert plugin preserve the UIDs?  The wiki implies that it doesn't, 
but I thought maybe since it's implemented as a plugin that maybe it does (or that maybe 
the caution is about converting to/from dovecot and some other server).
 

It doesn't. In v2.0 dsync does. In v2.0 convert plugin has been removed.



So, what is the answer for pre-2.0 folks who want to do mbox-Maildir 
conversion?  I have not yet found a script that claims to preserve 
UIDs.  Is there one that people use?




Re: [Dovecot] Want to have some users with Maildir, some with mbox

2010-01-29 Thread Timo Sirainen
On 30.1.2010, at 1.39, WJCarpenter wrote:

 So, what is the answer for pre-2.0 folks who want to do mbox-Maildir 
 conversion?  I have not yet found a script that claims to preserve UIDs.  Is 
 there one that people use?

http://wiki.dovecot.org/Migration/MailFormat shows a bunch of scripts, one of 
them claims to preserve UIDs.



Re: [Dovecot] Want to have some users with Maildir, some with mbox

2010-01-29 Thread WJCarpenter



http://wiki.dovecot.org/Migration/MailFormat shows a bunch of scripts, one of 
them claims to preserve UIDs.
   


Does anyone here have direct successful experience with this?  I only 
asked about this because a comment on that same page says, None of the 
solutions described below preserve the message UIDs.


(Some of my users have  1 GB of email, so any UID disruption would 
likely be seriously annoying to them.)