|
GetMail Configuration for Microsoft Windows
-
All of the configuration takes place
on the computer where you wish to relay mail. Normally this
would be the same server used for in-house mail, but there is no
restriction that the destination mail server be on the same computer
that runs the script.
-
Download the script
getmail.pl (it's in a zip file).
-
Verify that Active State Perl is
installed on your computer. Active State Perl is a free
download available from
http://www.activestate.com.
This version of Perl includes the Net::POP3 and Net::SMTP modules.
As an alternative you can install Perl from the Microsoft Windows
2003 Resource Kit. In that case verify that the two modules
are also installed. If they are not, you can obtain them from
http://www.cpan.org.
-
Configure one mailbox at your domain
through the H-sphere interface, and select the
"catch-all" checkbox. Tip: click on the e-mail icon on
the main page of account configuration, or select mail info ->
mail manager from the menu. In the mail manager select the
mailbox you wish to modify, or create a new one. Using a
catchall mailbox eliminates the need to configure mailboxes for each
user of the in-house system, since all mail that doesn't match a
mailbox name on our server will be delivered here.
-
Install the script on your server,
we recommend that you place it in the directory c:\windows\system32.
Change the configuration settings
in the script to use the mailbox at your domain which receives the mail, and the
address of your in-house mail server. If the $verbose variable
is true then the script will log its actions and an entry for each
message retrieved to the file specified by $logfile, we suggest
c:\windows\system32\logfiles\getmail.log (in the script use forward
slashes in the path).
$domain = '3k1ponce.com';
$popserver = 'mail.3k1ponce.com';
%mailboxes = ( 'postmaster@3k1ponce.com' => 'password' );
$localsmtpserver = 'localhost';
$verbose = true;
$logfile = 'c:/windows/system32/logfiles/getmail.log';
-
Schedule the script to run
approximately once ever ten minutes. From the control panel
select scheduled tasks and start the wizard to create a new
task. Click next and on the second dialog use the browse
button to find the GetMail.pl script. When you select the
file, you will automatically be taken to the next screen (step 7).
-
On this dialog name
the task getmail, and instruct the wizard to perform the task daily.
Click next, and on the following dialog set the task to start at 8:00AM every day, and
to start on the current day, and then click next.
-
The task must be
assigned a user and password. It is not necessary to run the
task as an administrator, but the user must have permission to log
onto the server where the task is configured. Click next to
proceed.
-
Select the checkbox to
edit the advanced properties, and click finish to open the Task
Configuration dialog. Note: you can always open the dialog
by opening the task in the Scheduled Tasks list in the
Windows control panel.
-
In the Task
Configuration dialog, click the Schedule tab, click on the
Advanced button to display the
Advanced Schedule Options dialog. Select Repeat Task
and set the frequency to every ten minutes (recommended).
Select the Duration unit measure and set the duration period
to twenty four hours (all day).
These settings define a schedule that starts at 8:00 A.M. every date
or at system startup, runs every ten minutes for twenty four hours
and then starts it all over again the next day. Click on OK to close each window, and the configuration of the GetMail task is complete.
Notes: The script will not
execute and mail will be left on our server if a connection to the local
SMTP server cannot be established, or the POP3 mailbox cannot be
entered. Messages are deleted from our server as they are
delivered to the local SMTP server. The script will discard (and
delete from our server) any messages that the local SMTP server refuses
to accept.
While the GetMail script may be
downloaded and used without charge, full support is available for a
registration fee of $29.95. Or, if you like the program then
please consider registering to help support future development of this
and other products from Smallrock Internet.
|
|