Search The ForumSearch   RegisterRegister  LoginLogin

AfterLogic WebMail Pro

 AfterLogic Forum : AfterLogic WebMail Pro
Subject Topic: Import old mail Post ReplyPost New Topic
Author
Message << Prev Topic | Next Topic >>
rob
Groupie
Groupie


Joined: 03 September 2008
Location: Canada
Online Status: Offline
Posts: 60
Posted: 08 September 2008 at 1:57pm | IP Logged Quote rob

Now that we almost have our webmail pro up and running we are wanting to import all of our clients existing mail that currently resides in qmail Maildir folders into the webmail pro database.

For example, for each email account on our system there may be any number of custom imap folders that the user previously created and within each of these folders could be any number of email messages each having their own file as per the qmail standard maildir format.

Do you have a premade script that we can use to assist us in this import routine?

Please let me know.

Rob
Back to Top View rob's Profile Search for other posts by rob
 
Igor
AfterLogic Support
AfterLogic Support


Joined: 24 June 2008
Location: United States
Online Status: Offline
Posts: 6092
Posted: 09 September 2008 at 2:35am | IP Logged Quote Igor

There is another way.

If you set the "Allow automatic registration of new users on first login" checkbox to "on" in WebMail admin console and configure WebMail to use IMAP connection by default, you wouldn't have to import mail messages. Instead, when user logs into WebMail for the first time, WebMail account would be created automatically. All the folders would be synchronized and mail messages downloaded to WebMail storage either automatically or on user request depending on account settings.

This is exactly the same approach as if you install an email client (e.g. Outlook Express or Mozilla Thunderbird), specify account data, and email client performs folder synchronization and downloads messages.

Does this approach suit you?

Regards,
Igor
Back to Top View Igor's Profile Search for other posts by Igor
 
rob
Groupie
Groupie


Joined: 03 September 2008
Location: Canada
Online Status: Offline
Posts: 60
Posted: 11 September 2008 at 3:05pm | IP Logged Quote rob

We have been using this method to try and import old emails, however some of our mailboxes have in excess of 20000 messages in them. We are finding that something is timing out after about 700-1000 messages and the process stops.

I noticed a setting /common/inc_constants.php that says TIMELIMIT of 3000, which i bumped to 30000. This didnt seem to make a difference.

I also adjusted php.ini max_execution_time to 30000 which had no impact.

Any other ideas to keep this process running until all messages are imported?

Back to Top View rob's Profile Search for other posts by rob
 
Igor
AfterLogic Support
AfterLogic Support


Joined: 24 June 2008
Location: United States
Online Status: Offline
Posts: 6092
Posted: 12 September 2008 at 3:40am | IP Logged Quote Igor

Increasing memory_limit configuration option value of PHP along with setting time limit might help:
Code:
ini_set('memory_limit', '200M');
set_time_limit(3000);

For debugging purposes, you should also consider enabling maximum error reporting level:
Code:
error_reporting(E_ALL);
ini_set('display_errors', 'on');

Of course, you can alter those values in your php.ini file as well.

Regards,
Igor
Back to Top View Igor's Profile Search for other posts by Igor
 

If you wish to post a reply to this topic you must first login
If you are not already registered you must first register

  Post ReplyPost New Topic
Printable version Printable version

Forum Jump

Powered by Web Wiz Forums version 7.9
Copyright ©2001-2004 Web Wiz Guide