NameVirtualHosts

Discussion in 'Installation/Configuration' started by paurosi, Mar 27, 2013.

  1. paurosi

    paurosi New Member

    Hi everyone

    I am new to linux, I recently installed using the how tos open suse12.2 apache2 and Ispconfig 3. Now the installation went fine but now how do i make my namevirtualhosts work every time i try to access a site create in ispconfig admin i am taken to the default site. I had edited my httpd.conf file to have these

    Include /etc/apache2/vhosts.d/*.conf
    NameVirtualHost *:80
    <VirtualHost *:80>
    ServerName ibs-kal.bw
    ServerAlias www.ibs-kal.bw
    DocumentRoot /srv/www/ibs-kal.bw/web
    </VirtualHost>


    <VirtualHost *:80>
    ServerName kal.bw
    ServerAlias ww3.kal.bw
    DocumentRoot /srv/www/kal.bw/web
    </VirtualHost>

    But still i cant view the second site, the name server entries are ok only i am always taken to the default site

    Can someone please help
     
  2. dclardy

    dclardy New Member

    Are you creating these sites in the ISPConfig Admin area? You should not have to make these changes to the file s themselves. ISPConfig will create a virtual host configuration for you in /etc/apache2/sites-enabled with the settings that you have set in the admin area.
     
  3. paurosi

    paurosi New Member

    Thanks Dclardy

    I created the sites in ISPconfig 3 and because after loading content I was always being taken to the default website, so I started reading thats why I had to try to make the changes in httpd.conf. All iwant to achieve is to have my sites running ok, what shuld be my next move from here
     
  4. till

    till Super Moderator

    Undo all changes you made to httpd.conf as they will prevent the system to work properly.

    Then add the IP address of your server in ispconfig under System > server IP and select that IP address in the website settings.
     

Share This Page