how to configure webmail.domain.com

  • please anybody help me. how to configure webmail.domain.com in i-mscp

  • Modify your /etc/imscp/apache/00_master.conf or /etc/imscp/apache/00_master_ssl.conf and add this vhost to the end:


    Code
    1. <VirtualHost {BASE_SERVER_IP}:80> ServerAdmin {DEFAULT_ADMIN_ADDRESS} DocumentRoot {ROOT_DIR}/gui/public/tools/webmail ServerName {BASE_SERVER_VHOST} ServerAlias webmail.* <IfModule mpm_itk_module> AssignUserID {SYSTEM_USER_PREFIX}{SYSTEM_USER_MIN_UID} {SYSTEM_USER_PREFIX}{SYSTEM_USER_MIN_UID} </IfModule> # Only enable suexec when not running with the itk mpm <IfModule !mpm_itk_module> <IfModule suexec_module> SuexecUserGroup {SYSTEM_USER_PREFIX}{SYSTEM_USER_MIN_UID} {SYSTEM_USER_PREFIX}{SYSTEM_USER_MIN_UID} </IfModule> </IfModule> <Directory {ROOT_DIR}/gui/public/tools/webmail> Options -Indexes Includes FollowSymLinks MultiViews AllowOverride All Order allow,deny Allow from all </Directory> <IfModule mod_fcgid.c> <Directory {ROOT_DIR}/gui/public/tools/webmail> FCGIWrapper {PHP_STARTER_DIR}/master/php{PHP_VERSION}-fcgid-starter .php Options +ExecCGI </Directory> <Directory "{PHP_STARTER_DIR}/master"> AllowOverride None Options +ExecCGI MultiViews -Indexes Order allow,deny Allow from all </Directory> </IfModule> <IfModule mod_fastcgi.c> ScriptAlias /php5/ {PHP_STARTER_DIR}/master/ <Directory "{PHP_STARTER_DIR}/master"> AllowOverride None Options +ExecCGI MultiViews -Indexes Order allow,deny Allow from all </Directory> </IfModule> <IfModule php5_module> <Directory {ROOT_DIR}/gui/public/tools/webmail> php_admin_value sendmail_path '/usr/sbin/sendmail -f webmaster@{BASE_SERVER_VHOST} -t -i' php_admin_value open_basedir "{ROOT_DIR}/gui/:{CONF_DIR}/:{MR_LOCK_FILE}:/proc/:/bin/df:/bin/mount:{RKHUNTER_LOG$ php_admin_value session.save_path "{ROOT_DIR}/gui/data/sessions/" php_admin_value upload_tmp_dir "{ROOT_DIR}/gui/data/tmp/" php_value include_path ".:{ROOT_DIR}/gui/library/:/usr/share/php" php_admin_value suhosin.session.encrypt "off" </Directory> </IfModule></VirtualHost>


    Then modify /etc/imscp/bind/parts/db_e.tpl and add this after the ftp CNAME:

    Code
    1. ; CNAME for webmail subdomain
    2. webmail IN CNAME www


    Rebuild all configuration files using /var/www/imscp/engine/setup/imscp-setup and everything should be ok, if something isn't working don't panic and report any error here ;)

    Edited once, last by Zero ().



  • Thanks for this post


    Your come online in any messenger ?
    i need your online help

  • Hello, if you don't want to post publically you can use PMs, I'm not using any messenger at this time.

  • Hey, when i add this in my config. i became one error:


    [code=php]apache2: Syntax error on line 230 of /etc/apache2/apache2.conf: Syntax error on line 30 of /etc/apache2/sites-enabled/00_master.conf: /etc/apache2/sites-enabled/00_master.conf:30: <VirtualHost> was not closed.
    Action 'configtest' failed.
    [/php]


    Somebody an Idea? i try to close it with </VirtualHost> but still the same error.


    Thanky mech[/php]

  • Please post the listed lines + one line bevor and after.
    May you closed it in the wrong section.


    Greez BeNe

  • My Config:


    [code=php]# i-MSCP a internet Multi Server Control Panel
    #
    # Copyright (C) 2006-2010 by isp Control Panel - http://ispcp.net
    # Copyright (C) 2010-2012 by internet Multi Server Control Panel - http://i-mscp.net
    #
    #
    # The contents of this file are subject to the Mozilla Public License
    # Version 1.1 (the "License"); you may not use this file except in
    # compliance with the License. You may obtain a copy of the License at
    # http://www.mozilla.org/MPL/
    #
    # Software distributed under the License is distributed on an "AS IS"
    # basis, WITHOUT WARRANTY OF ANY KIND, either express or implied. See the
    # License for the specific language governing rights and limitations
    # under the License.
    #
    # The Original Code is "ispCP Ï^É (OMEGA) a Virtual Hosting Control Panel".
    #
    # The Initial Developer of the Original Code is ispCP Team.
    # Portions created by Initial Developer are Copyright (C) 2006-2010 by
    # isp Control Panel. All Rights Reserved.
    #
    # Portions created by the i-MSCP Team are Copyright (C) 2010-2012 by
    # internet Multi Server Control Panel. All Rights Reserved.
    #
    # The i-MSCP Home Page is:
    #
    # http://i-mscp.net
    #


    <VirtualHost {BASE_SERVER_IP}:80>


    ServerAdmin {DEFAULT_ADMIN_ADDRESS}
    DocumentRoot {ROOT_DIR}/gui/public


    ServerName {BASE_SERVER_VHOST}


    Alias /errors {ROOT_DIR}/gui/public/errordocs/


    ErrorDocument 401 /errors/401.html
    ErrorDocument 403 /errors/403.html
    ErrorDocument 404 /errors/404.html
    ErrorDocument 500 /errors/500.html
    ErrorDocument 503 /errors/503.html


    Alias /pma {ROOT_DIR}/gui/public/tools/pma/
    Alias /webmail {ROOT_DIR}/gui/public/tools/webmail/
    Alias /ftp {ROOT_DIR}/gui/public/tools/filemanager/
    Alias /ispLogos {ROOT_DIR}/gui/data/ispLogos


    <IfModule mpm_itk_module>
    AssignUserID {SYSTEM_USER_PREFIX}{SYSTEM_USER_MIN_UID} {SYSTEM_USER_PREFIX}{SYSTEM_USER_MIN_UID}
    </IfModule>


    #Â Only enable suexec when not running with the itk mpm
    <IfModule !mpm_itk_module>
    <IfModule suexec_module>
    SuexecUserGroup {SYSTEM_USER_PREFIX}{SYSTEM_USER_MIN_UID} {SYSTEM_USER_PREFIX}{SYSTEM_USER_MIN_UID}
    </IfModule>
    </IfModule>


    <Directory {ROOT_DIR}/gui/public>
    Options -Indexes Includes FollowSymLinks MultiViews
    AllowOverride All
    Order allow,deny
    Allow from all
    </Directory>


    <Location /ispLogos>
    Options -Indexes
    Order allow,deny
    Allow from all
    </Location>


    <IfModule mod_fcgid.c>
    <Directory {ROOT_DIR}/gui/public>
    FCGIWrapper {PHP_STARTER_DIR}/master/php{PHP_VERSION}-fcgid-starter .php
    Options +ExecCGI
    </Directory>
    <Directory "{PHP_STARTER_DIR}/master">
    AllowOverride None
    Options +ExecCGI MultiViews -Indexes
    Order allow,deny
    Allow from all
    </Directory>
    </IfModule>


    <IfModule mod_fastcgi.c>
    ScriptAlias /php5/ {PHP_STARTER_DIR}/master/
    <Directory "{PHP_STARTER_DIR}/master">
    AllowOverride None
    Options +ExecCGI MultiViews -Indexes
    Order allow,deny
    Allow from all
    </Directory>
    </IfModule>


    <IfModule php5_module>
    <Directory {ROOT_DIR}/gui/public>
    php_admin_value sendmail_path '/usr/sbin/sendmail -f webmaster@{BASE_SERVER_VHOST} -t -i'
    php_admin_value open_basedir "{ROOT_DIR}/gui/:{CONF_DIR}/:{MR_LOCK_FILE}:/proc/:/bin/df:/bin/mount:{RKHUNTER_LOG}:{CHKROOTKIT_LOG}:{PEAR_DIR}/{O$
    php_admin_value session.save_path "{ROOT_DIR}/gui/data/sessions/"
    php_admin_value upload_tmp_dir "{ROOT_DIR}/gui/data/tmp/"
    php_value include_path ".:{ROOT_DIR}/gui/library/:/usr/share/php"
    php_admin_value suhosin.session.encrypt "off"
    </Directory>
    </IfModule>
    <VirtualHost {BASE_SERVER_IP}:80>
    ServerAdmin {DEFAULT_ADMIN_ADDRESS}
    DocumentRoot {ROOT_DIR}/gui/public/tools/webmail
    ServerName {BASE_SERVER_VHOST}
    ServerAlias webmail.*
    <IfModule mpm_itk_module>
    AssignUserID {SYSTEM_USER_PREFIX}{SYSTEM_USER_MIN_UID} {SYSTEM_USER_PREFIX}{SYSTEM_USER_MIN_UID}
    </IfModule>
    #Â Only enable suexec when not running with the itk mpm
    <IfModule !mpm_itk_module>
    <IfModule suexec_module>
    </VirtualHost>[/php]

    Edited once, last by mech ().

  • Search the following Text:

    Code
    1. <VirtualHost {BASE_SERVER_IP}:80> ServerAdmin {DEFAULT_ADMIN_ADDRESS} DocumentRoot {ROOT_DIR}/gui/public/tools/webmail ServerName {BASE_SERVER_VHOST} ServerAlias webmail.*


    Add this line before:

    Code
    1. </VirtualHost>
  • Code
    1. root@kaldig:/etc/apache2/sites-enabled# nano 00_master.conf
    2. root@kaldig:/etc/apache2/sites-enabled# /etc/init.d/apache2 restart
    3. apache2: Syntax error on line 230 of /etc/apache2/apache2.conf: Syntax error on line 120 of /etc/apache2/sites-enabled/00_master.conf: </VirtualHost> without matching <VirtualHost> section
    4. Action 'configtest' failed.
    5. The Apache error log may have more information.
    6. failed!


    Another Idea ? ;)