Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Chris Miller on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Move mail users to another server 1

Status
Not open for further replies.

bobcat

IS-IT--Management
May 15, 2001
53
US
I have two Red Hat servers, one running 7.0 and the other 7.3. I am wanting to move some of the users from the 7.0 machine to the 7.3 machine. I've created the users on the 7.3 box and got sendmail, ipop3, etc running fine. My problem is there is a lot of the users have mail left on the 7.0 server. How can I move that mail from the old server to the new one? I've tried just copying the files from /var/spool/mail but when the 7.3 box's procmail reads it, it calls it a bogus file and discards.

What's the preferred method of doin this?

 
Hi,

Make sure - when you copy the files - the file ownership and permissions are appropriate on the new system.

Worst case if it still doesn't work, you could try to use the formail program with the old mailboxes for each user as the input. Formail will read the old spool file, and process each mail message individually - passing on the message to procmail for delivery to the 'new' spool files.

It's been a while since I did something like this so I can't recall the formail options but it should be clear from the man page or searchable via google or such. I think you'll need the -d option and the -s option passing the mail to procmail.

Formail -ds procmail < oldmailfile

BUT CHECK AND TEST FIRST!

Hope this helps
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top