mail alias

Discussion in 'ISPConfig 3 Priority Support' started by fluiz, Feb 20, 2015.

  1. fluiz

    fluiz New Member HowtoForge Supporter

    I would like to access the http://domain.com/webmail through http://email.domain.com

    what would be the correct way to do this through ispconfig?
     
  2. inside83

    inside83 Member

    Id like to know that too.
     
  3. till

    till Super Moderator Staff Member ISPConfig Developer

    Thats a subdomain vhost in apache and not an alias. You will have to create a website email.domain.com in ISPConfig, select php mode mod_php and then add:

    DocumentRoot /usr/share/squirrelmail

    in the apache directives field. You might have to add ":/usr/share/squirrelmail" to the PHP open_basedir field of the website as well.
     
    fluiz likes this.
  4. fluiz

    fluiz New Member HowtoForge Supporter

    thanks again,

    "Thats a subdomain vhost in apache and not an alias."
    I can not add a 'vhost subdomain' through Sites > Websites > Subdomain (Vhost) ??

    but excuse my ignorance ...
    but I found hundreds of articles on how to do this in apache ...
    the ones I tried not work.
    could you please suggest a tutorial or more specific page?


    "You will have to create a website email.domain.com in ISPConfig, select php mode mod_php"
    I create as "Sites > Add new website" or as "Subdomain (Vhost)" ??
     
  5. till

    till Super Moderator Staff Member ISPConfig Developer

    Sure, you can do that, but it does not make much sense for that what you described above.

    I asked you to create a new website and not a vhost subdomain.
     
    fluiz likes this.
  6. fluiz

    fluiz New Member HowtoForge Supporter

    you know any tutorial to show me how to do this with apache?
     
  7. till

    till Super Moderator Staff Member ISPConfig Developer

    Here is your tutorial:

    1) create a website email.domain.com in ISPConfig, select php mode mod_php
    2) Add:
    DocumentRoot /usr/share/squirrelmail

    in the apache directives field of that website.
    3) Add ":/usr/share/squirrelmail" to the PHP open_basedir field of the website.
     
    fluiz and florian030 like this.
  8. fluiz

    fluiz New Member HowtoForge Supporter

    i did that...
    but only appears that page "It works!"

    the only thing I did different was that instead of email.dominio.com, I used webmail.dominio.com

    I have to do any changes to the dns zones?
     
  9. till

    till Super Moderator Staff Member ISPConfig Developer

    Did you select * or the IP address in the ip address field?
     
    fluiz likes this.
  10. fluiz

    fluiz New Member HowtoForge Supporter

    i select *
     
  11. till

    till Super Moderator Staff Member ISPConfig Developer

    Then you must have set an IP address in your apache default vhost file so that it takes precedence over other vhosts. Change the Ip address in the vhost file back to _default_ or change it to * and restart apache.
     
    fluiz likes this.
  12. fluiz

    fluiz New Member HowtoForge Supporter

    you know any specific tutorial that I can follow to change the correct apache files without destroying my server? :D

    there any other way to add this IP to the list? in order to use the ispconfig and not need to change any configuration of the server?
     
  13. till

    till Super Moderator Staff Member ISPConfig Developer

    The steps I posted above are the ones that i used on friday on a custmer serve, so they should work. but it mighte be that oyu changed already things before that make them fail now.

    You can add the Ip under System > Server IP in ispconfig.
     
    fluiz likes this.
  14. fluiz

    fluiz New Member HowtoForge Supporter

    happened some strange things here. I would like to your help again, for kindness...

    I will describe and detail what I did, and what happened:
    1) i have one certain domain, as domain.com
    2) in dns zones, i added a new zone record to this domain
    2.1) a added a cname record, in the hostname i put 'webmail' and in 'target hostname' i put domain.com. (with dot at end)
    3) i added a site, and:
    3.1) in field 'IPv4-Address' i put the ip address of my server, that was previously added to "System> System> IP Server addesses"
    3.2) in field PHP i put 'mod-php'
    3.3) in tab 'Options', in 'PHP open_basedir' i added :/usr/share/squirrelmail at the end
    3.4) in tab 'Options', in 'Apache Directives' i added DocumentRoot /usr/share/squirrelmail

    after that, the webmail.domain.com show the squirrelmail correctly.
    but, happens that when I open all the domains that have on my server, for example, aaa.com bbb.com ccc.com etc.com ... all of them open the squirrelmail. they all open the same squirrelmail without the subdomain 'webmail'...

    then, i back in Sites, and i edited the domain.com, i remove the Ip address and back the * in field. well, that made all the sites returned to normal and the webmail.domain.com works normally.

    I wonder if I did something wrong.... I did?
     
  15. till

    till Super Moderator Staff Member ISPConfig Developer

    you have to select the IP address in all sites instead of *. If you mix ip address and * on a server, then all request will go to the site that has the ip address selected. regardless of the domain name.
     
    fluiz likes this.
  16. fluiz

    fluiz New Member HowtoForge Supporter

    right, then the correct is, or let all with *, or set all with their respective and correct ip, is it?
     
  17. till

    till Super Moderator Staff Member ISPConfig Developer

    Yes. either set all to *or set all to the IP, but dont mix them.
     
    fluiz likes this.
  18. fluiz

    fluiz New Member HowtoForge Supporter

    that's perfect. thank you again
     

Share This Page