Alberto Rodríguez wrote:
> 
> I have some email users in /etc/passwd and now I´d like move them to
> vpopmail.
> 
> We could suppose that my domain is domain.org. domain.org is my
> defaultdomain too, so it´s on /var/qmail/control/defaultdomain.
No, qmailds defaultdomain file and vpopmails "default domain" concept
are different.
> 
> So I think that following steps are necesary:

0. Stop qmail

> 
> First. I make a domain named false.domain.org.

1. ~vpopmail/bin/vadddomain domain.org postmaster-password

> 
> Second. With a script I make all users who are in /etc/passwd under
> /home/vpopmail/domains/false.domain.org.

2. ~vpopmail/bin/vconvert domain.org

> 
> Three. I copy all their messages which are in /home/user/Maildir to
> /home/vpopmail/domains/false.domain.org/user/Maildir.

cp /home/user/Maildir/new/*
/home/vpopmail/domains/domain.org/user/Maildir/new

This will work if you have less than 100 users.

> 
> Four. with vaddaliasdomain I make an alias domain to false.domain.org.

No, don't confuse everyone with a temporary aliased domain. 
Just stop qmail and and the domain name you really want, 
then run vconvert. vconvert will create pop accounts from /etc/passwd
non root users into the domain you specify. Then it sets all thier
passwords to match the /etc/passwd password. A pretty nifty trick
considering /etc/passwd has only the encrypted password ;]

> 
> Please, could anyone say if it´s all ok?

Try my way, it's worked plenty of times for me before.

And for the bonus points try this kids:

1) Modify vconvert.c so when it converts a user in /etc/passwd it
   also searches for a Maildir directory in thier home directory
   and copies over the mail files with the correct permissions.

2) extra bonus
   If a Maildir file doesn't exist, go look in /var/spool/mail/user
   for a Mailbox file and convert it into Maildir files.

Cheers
Ken Jones
> 
> Thanks in advance.

Reply via email to