Setting up SQUIRRELMAIL on Win2K
or WinXP 2000
with IIS and
Macallan Mail Solution
Upon setting up Macallan Mail Solution to receive your domain's email, you can also add
additional functionality of a web mail server by installing
This will serve as a web interface for users to read their emails via a web
browser from a remote location.
Setting up Squirrel Mail on a Windows 2000 machine can be tough due to the lack
of documentation for Windows users along with the idiosyncracy of Windows'
operational behaviour varying with different patches.
- Install Windows 2000 with IIS enable fully patched with all service packs and
- Setup your site www.yourdomain.com using IIS Internet Services Manager.
- Extract all Squirrelmail files within zip to a folder call "MAIL".
- Setup Internet Services Manager to point to this folder "MAIL" by creating a
virtual directory within your site. (Right click on site, select New, select
Virtual Directory, give it a alias eg "mail" (this will be accessible via
www.yourdomain.com/mail). Remember to set the default document to "index.php" so
that it is executed first.
- Install Perl and it will auto config itself to work on *.pl and *.plx files.
- Download both version of PHP (the installer and the zipped version) from the
same release and extract the zipped version first into a folder "PHP".
- Run the installer version of PHP over the existing "PHP" version and it will
save you the headaches of having to configure the program paths to work in
- Copy all DLL files from the folder DLL within "PHP" directory into
- Next locate the php.ini file in eithier your WINDOWS or WINDOWS\SYSTEM32
directory and open it up with a text editor.
- Within the file, do a search for "extension_dir" and replace the default
"./DATA" to "C:\PHP\extensions".
- Look further down or do a search for "Windows Extensions" and unREM (mean
remove the ;) from "extension=php_gettext.dll", "extension=php_imap.dll" and
"extension=php_ldap.dll". As describe in the documentation, these are the
support dll modules needed.
- Create a test file call "PHPINFO.PHP" with the text "<? phpinfo(); ?>" and
copy it to your "MAIL" folder and do a test by typing "www.yourdomain.com/mail/phpinfo.php"
in IE. If there is no error, PHP is working. If not, check your virtual
directory's PHP mapping by clicking on Properties, Configuration and App
- Add PHP if it is not configured in your virtual directory by clicking on
Add, the browse to your PHP executable (eg C:\PHP\PHP.EXE) and set extension to
- Sometimes, you may need to restart Windows 2000 machine for it to work after
doing alot of amendments.
- Next you can configure Squirrelmail by browsing in your Windows explorer and
double-click on "conf.pl" file in "config" folder in SquirrelMail directory and
make the neccessary changes. I would change Organisation Name, Domain, localhost
to static IP address of your mail server machine, IMAP from default setting "cyrus"
to "other" as I use Macallan Mail Solution.
- Next locate the text "header("Location: $redirect_url");" in redirect.php
found in your SquirrelMail "src" directory and replace it with the
echo "<html><head><META HTTP-EQUIV=\"Refresh\" CONTENT=\"0;
- Finally, before testing your SquirrelMail installation, remember to give
write access to your folder "DATA" within SquirrelMail directory and "sessiondata"
and "uploadtemp" within PHP.
- Test the Web Mail Server and it should work fine. Check through the steps
again if you face problem with the installation.
This page originally was at