Re: Qmail migration

[email protected]
Newsgroups gmane.mail.vpopmail
Message-ID <[email protected]>

Thanks to every body for valuable suggestions. I am working to have  
actual migration in next few days.
Another question. I want to install 2 or 3 qmail servers in a load  
balancing and active failover model.
Can any body help suggest the design from your experience....... thanks....

Tariq


Quoting Thibault Richard <[email protected]>:

> Hello,
>
> I'm pretty sure this script is working well but this is what I've  
> recently done :
>
>
> 1° Modify MX test domain
> 2° Stop previous server+ copy DB
>
> previous_server:~# /etc/init.d/apache2 stop
> previous_server:~# /usr/bin/mysqldump -c -C -e -Q --add-drop-table  
> -uroot -p***password*** vpopmail > /backups/vpopmail.sql
> previous_server:~# scp /backups/vpopmail.sql root@new_server
> previous_server:~# qmailctl stop
>
> 3° Copy config files
>
> previous_server:~# cd /var/qmail/control
> previous_server:~# scp morercpthosts rcpthosts virtualdomains  
> root@new_server:/var/qmail/control
> previous_server:~# cd /var/qmail/users
> previous_server:~# scp assign root@news_server:/var/qmail/users/
>
> 4° Import DB + synchronise mails
>
> new_server:~# qmailctl stop
> new_server:~# mysql -Dvpopmail -p***password*** < /root/vpopmail.sql
> new_server:~# sed "s/1007:111/1007:112/g" /var/qmail/users/assign >  
> /var/qmail/users/assign.new
> (ADADT the UID/GID to what you've found in /etc/passwd in  
> previous_server and new_server)
> new_server:~# cat /var/qmail/users/assign.new
> new_server:~# mv /var/qmail/users/assign.new /var/qmail/users/assign
> new_server:~# /var/qmail/bin/qmail-newu
> new_server:~# /var/qmail/bin/qmail-newmrh
> new_server:~# rsync -avz --delete  
> root@previous_server:/home/vpopmail/domains/ /home/vpopmail/domains/
> new_server:~# #find /home/vpopmail -uid 1007 -exec chown vpopmail {} \;
> (ADADT the UID to what you've found in /etc/passwd in  
> previous_server and new_server)
> new_server:~# #find /home/vpopmail -gid 1008 -exec chgrp vchkpw {} \;
> (ADADT the UID to what you've found in /etc/passwd in  
> previous_server and new_server)
> new_server:~# mysql
> use vpopmail;
> update dir_control SET domain='dom_1007' WHERE domain='dom_1054';  
> (ADADT the UID to what you've found in /etc/passwd in  
> previous_server and new_server)
>
> new_server:~# qmailctl start
>
> Hope this help !
>
> Thibault
>
> ----- Original Message ----- From: "Ron Miller" <[email protected]>
> To: <[email protected]>
> Sent: Wednesday, June 16, 2010 2:20 AM
> Subject: RE: [vchkpw] Qmail migration
>
>
>> Here is how:
>>
>> http://qmail.jms1.net/scripts/migrate-domain.shtml
>>
>> Be sure NOT to use IE. Use Firefox instead.
>>
>> I have used this script many times.
>>
>> -Ron
>>
>> -----Original Message-----
>> From: [email protected] [mailto:[email protected]]
>> Sent: Tuesday, June 15, 2010 1:34 PM
>> To: [email protected]
>> Subject: [vchkpw] Qmail migration
>>
>> please suggest
>>
>> I am migrating Qmail from one Machine to another.Have taken following
>> steps but no luck.
>>
>> 1- I have taken dump of Mysql and and restored it on new machine.
>> 2- SCP all Domain and email boxes to new machine.
>> 3- Fixed all permissions.
>>
>> while giving command vdomaininfo or vuserinof it does not find the domain..
>>
>>
>>
>> ----------------------------------------------------------------
>> This message was sent using IMP, the Internet Messaging Program.
>>
>>
>>
>>
>>
>>
>>
>>
>
>
>
> 
>
>



----------------------------------------------------------------
This message was sent using IMP, the Internet Messaging Program.


!DSPAM:4c18cf5132711705318265!
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.