hMailServer5.1版安装配置

    技术2024-06-29  65

    hMailServer5.1版安装配置

    1、准备

        下载hMailServer-5.1.1-B341.exe

        安装SQL Server 2000数据库,sa用户口令设为sa

    2、安装hMailServer

        运行hMailServer-5.1.1-B341.exe并选择设置

            位置    D:/hMail/hMailServer

            组件    Full installation

            数据库  Use external database engine(MSSQL,MySQL or PostgreSQL)

        配置数据库(系统会自动创建数据库hMail及相关表)

            选择    新建hMailServer数据库

            数据库  Microsoft SQL Server

            数据库连接信息

                   数据库服务器地址     本机IP地址

                   数据库名            hMailServer

                   使用SQL服务器验证   用户名sa,密码sa

        配置系统管理员口令(系统完成数据库向导后,自动要求输入系统管理员口令)

            输入管理员口令

    3、运行系统管理

        选择开始菜单 - 所有程序 - hMailServer - hMailServer Administrator即可进入管理界面

            创建新域hmail.com

            创建帐户

            进入Setting - Advanced,设置缺省域为hmail.com(否则客户端访问必须使用邮箱名登录)

            开启日志功能并选择需要记录的日志类型

    4、配置Outlook Express

    配置好后即可通过Outlook Express收发邮件了。

    5、web管理系统配置

    1、安装PHP5.2.1

        从http://www.php.net官方网站下载php-5.2.1-Win32.zip

        解压缩到本地计算机d:/hMail/PHP

        拷贝d:/hMail/PHP/php.ini-dist文件到C:/Windows/php.ini

        拷贝d:/hMail/PHP/php5ts.dll文件到C:/Windows/system32/php5ts.dll,如果已经存在则不覆盖

        修改C:/Windows/php.ini

            ;因为没有目录d:/hMail/PHP/includes

            ;include_path="d:/hMail/PHP/includes"

            ;设置扩展目录

            extension_dir="d:/hMail/PHP"

            ;设置扩展动态库(因为只用到IMAP和MSSQ,所以只开启了这两个设置)

            extension=php_imap.dll

            extension=php_mssql.dll

    ;设置附件大小(注意:upload_max_filesize<post_max_size<memory_limit)

            max_execution_time = 120      ; Maximum execution time of each script, in seconds

            max_input_time = 240       ; Maximum amount of time each script may spend parsing request data

            memory_limit = 128M           ; Maximum amount of memory a script may consume (128MB)

            post_max_size = 70M           ; Maximum size of POST data that PHP will accept.

            upload_max_filesize = 50M     ; Maximum allowed size for uploaded files.

    2、配置Internet信息服务

        选择:默认Web站点,并打开其属性

        设置:ISAPI筛选器--添加

              筛选器名称:php

              可执行文件:d:/hMail/PHP/php5isapi.dll

        设置:主目录--配置

              可执行文件:D:/hMail/PHP/php5isapi.dll

              扩展名:php

    3、修改配置PHPWebAdmin

        进入目录D:/hMail/hMailServer/PHPWebAdmin

        拷贝文件config-dist.php到config.php

        修改Config.php

              $hmail_config['rootpath']  ="d:/hMail/hMailServer/PHPWebAdmin";

              $hmail_config['rooturl']  ="http://localhost/AdminMail";

       $hmail_config['includepath']  =$hmail_config['rootpath'] . "/include/";

              $hmail_config['temppath']  =$hmail_config['rootpath'] . "/temp/"; 

              $hmail_config['defaultlanguage'] = "english";

        在默认Web站点中新建虚拟目录AdminMail,路径选择为D:/hMail/hMailServer/PHPWebAdmin

        创建目录d:/hMail/hMailServer/PHPWebAdmin/temp        

    6、Web方式邮件收发系统安装配置

        将squirrelmail-1.4.9a.zip解压到d:/hMail/WebMail

        将解压所得的所有文件及目录整理到d:/hMail/WebMail

        进入目录d:/hMail/WebMail

        创建目录temp。

        创建目录temp/userpref、temp/upload

        进入目录d:/hMail/WebMail/config

        拷贝文件config_default.php到config.php

        在文件config_local.php中添加如下内容(说明:全局配置可以在本文件中修改,以替换config.php中的配置信息)

              $domain = 'hmail.com';

              $imap_server_type = 'hmailserver';

              $data_dir = '../temp/userpref';

              $attachment_dir = '../temp/upload';

              $default_left_size = '160';

              $squirrelmail_default_language = 'zh_CN';

              $default_charset = 'gb2312';

        将中文zh_CN-1.4.9-20070106.zip解压到d:/hMail/WebMail

        将默认Web站点的主目录设置为d:/hMail/WebMail

        在配置Internet信息服务中将d:/hMail/WebMail/temp配置为可写。

    7、新的漂亮的WebMail2007-10-30 09:45最近上hMailServer论坛看了下,发现了一个新的WebMail Client:RoundCube Webmail。

    官方主页:http://www.roundcube.net/,上去看了下,觉得比SquirrelMail漂亮多了,马上下载安装配置了下。

    1.下载RoundCube Webmail,最新版本0.1 RC2

    2.安装好Apache2,安装好MySQL,安装好PHP,安装好Pear(包含以下组件DB,Mail_Mime,Net_SMTP,通过pear install DB/Mail_Mime/Net_SMTP安装组件),我一开始就是因为没有安装pear的这些组件,一直报错。

    3.解压下载的压缩文件,路径如:D:/roundcubemail,打开D:/roundcubemail/config文件夹,把db.inc.php.dist,main.inc.php.dist重命名为db.inc.php,main.inc.php。

    4.MySQL新建一个数据库roundcube,通过执行D:/roundcubemail/SQL/mysql5.initial.sql初始化数据库。

    5.修改db.inc.php中$rcmail_config['db_dsnw']的为数据库字符串值,如:mysql://root:root@localhost/roundcube

    6.修改main.inc.php中$rcmail_config['default_host']值,我因为是本机邮件服务,所以填了localhost;$rcmail_config['temp_dir']值,如D:/MyAMP/roundcubemail/temp;$rcmail_config['log_dir']值,如D:/MyAMP/roundcubemail/logs。

    7.Apache中增加一个虚拟目录,如WebMail,浏览器中打开http://localhost/webmail,可以看到RoundCube Webmail的登陆界面了。

    最新回复(0)