1. Please take a little time for this simple survey! Thank you for participating!
    Dismiss Notice

ServerAlias :confused:

Discussion in 'Plesk for Linux - 8.x and Older' started by kklemenss, Oct 24, 2005.

  1. kklemenss

    kklemenss Guest

    0
     
    I know that this problem has been writen, i searched the forum readed everything but still i have that problem.
    i have subdomain test.mydomain.com
    and www.testdomain.com is pointed to my IP. In httpd.include i have like ServerAlias www.testdomain.com
    And it works just fine, but when i restart apache or add new domain.. it erase that ServerAlias. I`ve readed in forum that i must create vhost.conf... i created it and puted in that file ServerAlias www.testdomain.com like i have read in faq

    but still doesnt work.. can somebody help me about this problem? :confused:

    thanks for your answers!
    Best regards,
    Klemen
     
  2. CoKo

    CoKo Guest

    0
     
    Did you run

    /usr/local/psa/admin/bin/websrvmng --reconfigure-all

    after creation of the vhost.conf?
     
  3. kklemenss

    kklemenss Guest

    0
     
    yes but when i do that i get in my domains the default plesk page... its not working at all
     
  4. CoKo

    CoKo Guest

    0
     
    ok, I think its time to show your configuration files.

    can you please post the content and path of the files httpd.include and vhost.conf for the domain in question?
     
  5. kklemenss

    kklemenss Guest

    0
     
  6. CoKo

    CoKo Guest

    0
     
    First of all:

    Please remove the port from the ServerAlias directive. ServerAlias should read like

    ServerAlias *.smartno-litija.si smartno-litija.si


    With this change - and after a restart of Apache of course - www.smartno-litija.si should display the content of www.trioserve.com. (If the vhost.conf is placed in /var/www/vhosts/trioserve.com/conf/ )
     
  7. kklemenss

    kklemenss Guest

    0
     
  8. CoKo

    CoKo Guest

    0
     
    If you want to have being an alias for http://smartno.trioserve.com/ - which is a subdomain - you need to place the vhost.conf file in the appropriate directory, which is in this case /var/www/vhosts/trioserve.com/subdomains/smartno/conf/

    (Its explained in the header comments in httpd.include where to place vhost.conf files)
     
  9. CoKo

    CoKo Guest

    0
     
    Don't forget to run

    /usr/local/psa/admin/bin/websrvmng --reconfigure-all

    after placing a new vhost.conf file anywhere on the server.
     
  10. kklemenss

    kklemenss Guest

    0
     
    uf thanks coko!!

    i didnt read carefully the header..
    it works now!!
    10x!
     
Loading...