all subdomains work except www

Discussion in 'Installation/Configuration' started by jasondavis87, Jul 11, 2011.

  1. jasondavis87

    jasondavis87 New Member

    Hello all,

    I've searched the forums but didn't find anything on this:

    My issue is that I have a website:
    In my website i need all subdomains to goto the same place. I have a php file that parses the subdomain out and displays different data. So for example,,, need to point to the same place and the php script will handle displaying the different data.

    I've gotten everything to work, except ""

    Here's the other catch: i can ping and trace-route the "" and the "" and everything else and they come back with successful pings and correct IP address for traceroute.

    I thought it was my DNS settings at first but since ping and trace-route work i'm not sure. either way, just to put all the information out there, I currently have these settings in my DNS:
    www    A    300
    @        A    300
    @        ns   7200
    @        ns   7200
    These are my current settings. I've tried using the fqdm, "" tried using www CNAME 7200, tried using * A 300 Those didnt work either.

    Now for my ISPConfig, I run CentOS 5.5 x64 and followed the perfect server guidelines for setting this up from this website. I should state, I am using a VPS from as well. There were some things i wasnt able to do and found workarounds for them, but this was with BIND server, which i currently have turned off due to using DNS and suPHP(i think). From what i read, this is due to the fact that I was using a vps.

    In ISPConfig, I've created the website, the ftp connection for this and that all works, email works, etc. I set the website to use domains for all 3 options for subdomains, "none", "www", "*" - all actually produce the same result: all subdomains work except "www."

    Any Help is appriciated. Thanks
  2. jasondavis87

    jasondavis87 New Member


    Ok so i just made a mistake and accidently deleted the site. (thought i was deleting a subdomain). - I've got everything back up and running and same problem.

    This time however, I had to add a dns record:

    * A 300

    Without this the other sub-domains didnt work. Now its back to everything works but
  3. falko

    falko Super Moderator ISPConfig Developer

    Can you post the Apache vhost configuration of
  4. jasondavis87

    jasondavis87 New Member

    <Directory /var/www/>
        AllowOverride None
        Order Deny,Allow
        Deny from all
    <VirtualHost *:80>
          DocumentRoot /var/www/
        ServerAdmin [email protected]
        ErrorLog /var/log/ispconfig/httpd/
        ErrorDocument 400 /error/400.html
        ErrorDocument 401 /error/401.html
        ErrorDocument 403 /error/403.html
        ErrorDocument 404 /error/404.html
        ErrorDocument 405 /error/405.html
        ErrorDocument 500 /error/500.html
        ErrorDocument 503 /error/503.html
        <Directory /var/www/>
            Options FollowSymLinks
            AllowOverride All
            Order allow,deny
            Allow from all
        <Directory /var/www/clients/client1/web5/web>
            Options FollowSymLinks
            AllowOverride All
            Order allow,deny
            Allow from all
        # Clear PHP settings of this website
        <FilesMatch "\.ph(p3?|tml)$">
            SetHandler None
        # mod_php enabled
        AddType application/x-httpd-php .php .php3 .php4 .php5
        php_admin_value sendmail_path "/usr/sbin/sendmail -t -i [email protected]"
        php_admin_value upload_tmp_dir /var/www/clients/client1/web5/tmp
        php_admin_value session.save_path /var/www/clients/client1/web5/tmp
            # PHPIniDir /var/www/conf/web5
        php_admin_value open_basedir /var/www/clients/client1/web5/web:/var/www/clients/client1/web5/tmp:/var/www/$
        # add support for apache mpm_itk
        <IfModule mpm_itk_module>
          AssignUserId web5 client1
        <IfModule mod_dav_fs.c>
          # WEBDAV BEGIN
          # WEBDAV END
  5. jasondavis87

    jasondavis87 New Member

    Wow ... I'm an idiot ... I just found the issue:

    I forgot that I changed my c:\windows\system32\drivers\etc\hosts File to redirect my to my internal IP because i used to host it from my house and the router couldnt handle the loop back.

    Thanks everyone for your help.

Share This Page