Some sites open wrong site (virtual host) - some open the right site (virtual host)

Discussion in 'Installation/Configuration' started by Isterklister, Apr 5, 2016.

  1. Isterklister

    Isterklister New Member

    Hi,
    I have a newly installed ISPConfig-server (Ubuntu 14.40). I have around 10 virtual sites and some of them are working but some opens the wrong site (they are all open the default site instead, backup.mtua.se). I cannot find anything wrong. Can someone help me?
    Here are some info:
    Code:
    apache2ctl -S
    Code:
    AH00548: NameVirtualHost has no effect and will be removed in the next release /etc/apache2/sites-enabled/000-ispconfig.conf:61
    VirtualHost configuration:
    192.168.19.43:443  is a NameVirtualHost
      default server home.tillvaxtanalys.se (/etc/apache2/sites-enabled/100-home.tillvaxtanalys.se.vhost:101)
      port 443 namevhost home.tillvaxtanalys.se (/etc/apache2/sites-enabled/100-home.tillvaxtanalys.se.vhost:101)
      port 443 namevhost personal.mtuas.se (/etc/apache2/sites-enabled/100-personal.mtuas.se.vhost:92)
    192.168.19.43:80  is a NameVirtualHost
      default server backup.mtua.se (/etc/apache2/sites-enabled/100-backup.mtua.se.vhost:6)
      port 80 namevhost backup.mtua.se (/etc/apache2/sites-enabled/100-backup.mtua.se.vhost:6)
      port 80 namevhost buhu.mtua.se (/etc/apache2/sites-enabled/100-buhu.mtua.se.vhost:6)
      port 80 namevhost home.tillvaxtanalys.se (/etc/apache2/sites-enabled/100-home.tillvaxtanalys.se.vhost:6)
      port 80 namevhost images.mtua.se (/etc/apache2/sites-enabled/100-images.mtua.se.vhost:6)
      port 80 namevhost ipplan.mtua.se (/etc/apache2/sites-enabled/100-ipplan.mtua.se.vhost:6)
      port 80 namevhost it.tillvaxtanalys.se (/etc/apache2/sites-enabled/100-it.tillvaxtanalys.se.vhost:6)
      port 80 namevhost itweb.mtau.se (/etc/apache2/sites-enabled/100-itweb.mtau.se.vhost:6)
      port 80 namevhost kompetens.mtua.se (/etc/apache2/sites-enabled/100-kompetens.mtua.se.vhost:6)
      port 80 namevhost pelle.mtua.se (/etc/apache2/sites-enabled/100-pelle.mtua.se.vhost:6)
      port 80 namevhost personal.mtuas.se (/etc/apache2/sites-enabled/100-personal.mtuas.se.vhost:6)
      port 80 namevhost personal_utv.mtua.se (/etc/apache2/sites-enabled/100-personal_utv.mtua.se.vhost:6)
      port 80 namevhost piposweb.mtua.se (/etc/apache2/sites-enabled/100-piposweb.mtua.se.vhost:6)
      port 80 namevhost rapport.mtua.se (/etc/apache2/sites-enabled/100-rapport.mtua.se.vhost:6)
      port 80 namevhost systemkod.mtua.se (/etc/apache2/sites-enabled/100-systemkod.mtua.se.vhost:6)
      port 80 namevhost tillsalu.mtua.se (/etc/apache2/sites-enabled/100-tillsalu.mtua.se.vhost:6)
    *:8081  as214.mtua.se (/etc/apache2/sites-enabled/000-apps.vhost:9)
    *:80  as214.mtua.se (/etc/apache2/sites-enabled/000-default.conf:1)
    *:8080  as214.mtua.se (/etc/apache2/sites-enabled/000-ispconfig.vhost:9)
    ServerRoot: "/etc/apache2"
    Main DocumentRoot: "/var/www"
    Main ErrorLog: "/var/log/apache2/error.log"
    Mutex fcgid-proctbl: using_defaults
    Mutex ssl-stapling: using_defaults
    Mutex ssl-cache: using_defaults
    Mutex default: dir="/var/lock/apache2" mechanism=fcntl
    Mutex mpm-accept: using_defaults
    Mutex fcgid-pipe: using_defaults
    Mutex authdigest-opaque: using_defaults
    Mutex watchdog-callback: using_defaults
    Mutex rewrite-map: using_defaults
    Mutex authdigest-client: using_defaults
    PidFile: "/var/run/apache2/apache2.pid"
    Define: DUMP_VHOSTS
    Define: DUMP_RUN_CFG
    Define: ENABLE_USR_LIB_CGI_BIN
    User: name="www-data" id=33
    Group: name="www-data" id=33
     
  2. Jesse Norell

    Jesse Norell Well-Known Member Staff Member Howtoforge Staff

    You probably have '*' selected as the IP address for those sites, change that to the correct ip address, or use * everywhere, but don't mix them.
     
  3. Isterklister

    Isterklister New Member

    Thanks, but all sites have the correct IP-adress. I had to use IP instead of * because I have one site using https.
     
  4. till

    till Super Moderator Staff Member ISPConfig Developer

    You can use * or IP for https, this does not matter. What you can not do is to mix * and IP and this caused your issue.
     

Share This Page