Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
Need help using fetchmail for a mail migration project...
View unanswered posts
View posts from last 24 hours

 
Reply to topic    Gentoo Forums Forum Index Networking & Security
View previous topic :: View next topic  
Author Message
GetCool
Guru
Guru


Joined: 23 Nov 2003
Posts: 324
Location: Madison, Wisconsin

PostPosted: Thu Jul 01, 2004 7:10 am    Post subject: Need help using fetchmail for a mail migration project... Reply with quote

I'm currently working on a project that requires me to continuously pull all the new mail that arrives on an old Exchange 5.5 server and forward it to a new mailserver. Since I couldn't get Exchange 5.5's built-in mail forwarding options to work well, I opted to put up a separate box that just runs fetchmail continuously, pulling mail off the old server and forwarding it to the new server. My .fetchmailrc looks like this:

Code:
.fetchmailrc:

poll old.mail.server with proto IMAP user "user1" there with password "pass" is user1 here options warnings 3600
poll old.mail.server with proto IMAP user "user2" there with password "pass" is user2 here options warnings 3600

...etc...


And then I'm running fetchmail like this:

Code:
fetchmail -a -S new.mail.server


This works great, but the problem is that it is only pulling mail from each user's Inbox, and many users have other custom folders with custom filtering rules set up in Exchange. I know that I could add a folder "Folder Name" parameter to my .fetchmailrc to have it target a specific folder in a specific user's account, but I need to do this for around 100 accounts, and I do not know who has custom folders and who doesn't, much less what they are all named.

So, my question is: is there a way to (1) tell fetchmail to download all mails from all folders in the account, or if not, then (2) do some sort of "IMAP query" on an account to generate a list of all of its folder names, and use that list to populate the .fetchmailrc file?

Thanks for any advice.

By the way, I don't care if mail downloaded from a custom folder would be deposited in "Inbox" on the new mail server after it is forwarded, so I don't need to worry about transferring the mail from custom folder to custom folder.
Back to top
View user's profile Send private message
GetCool
Guru
Guru


Joined: 23 Nov 2003
Posts: 324
Location: Madison, Wisconsin

PostPosted: Thu Jul 01, 2004 3:15 pm    Post subject: Reply with quote

Any ideas?
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Networking & Security All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum