The Community Forums

Interact with an entire community of cPanel & WHM users!
  1. This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn More.

Apache Issue - httpd.conf

Discussion in 'EasyApache' started by stephenbrown, Jul 4, 2007.

  1. stephenbrown

    stephenbrown Active Member

    Joined:
    Apr 1, 2004
    Messages:
    31
    Likes Received:
    0
    Trophy Points:
    6
    I know it sounds ridicules, but here goes nothing!

    When a new subdomain, cPanel account of anything which needs to create a entry in the httpd.conf, I have noticed it does something very strange.

    When you create a new account, or a client creates a subdomain, when cPanel puts the record in httpd.conf it completely misses the fact there are records like this first:

    Which should popup the default success page if a domain is pointing to the server but no record can be found for the domain.

    The problem I have is that its popping up a client website! Is there anyway around this as happens to people’s mail.DOMAIN.TLD addresses as well!

    cPanel recognises the NameVirtualHost XXX.XXX.XXX.XXX:80 records and goes after them! Any ideas?

    Regards,
     
  2. bin_asc

    bin_asc Well-Known Member

    Joined:
    Jul 18, 2005
    Messages:
    280
    Likes Received:
    0
    Trophy Points:
    16
    Check the ips, make sure namevirtualhosts aren`t repeated and also make sure each client has it`s own /public_html.

    Edit : you could try to rebuild httpd.conf with the rebuild utility from /scripts.
     
  3. cPDan

    cPDan cPanel Staff
    Staff Member

    Joined:
    Mar 9, 2004
    Messages:
    711
    Likes Received:
    3
    Trophy Points:
    18
    If httpd.conf has these entires for 1.2.3.4:

    default htdoics 1.2.3.4
    foo.com 1.2.3.4
    new_account.com 1.2.3.4

    and you request new_account.com in a browser it serves the last one in that example

    Only if you request domain2.com (which resolves to 1.2.3.4 but does not have a specific vhost entry) you should get the first vhost for that matches that IP

    If foo.com appears before the 'default htdocs' one then domain2.com would render 'foo.com' vhost.

    That is how apache works, cpanel or not.

    What part of this is not happening?
     
  4. stephenbrown

    stephenbrown Active Member

    Joined:
    Apr 1, 2004
    Messages:
    31
    Likes Received:
    0
    Trophy Points:
    6
    I would post some of my httpd.conf but I don’t want to risk it!

    Is it possible for you to enable your PM's so I can send a snippet to you or if anyone knows whats going on to tell me of a fix?

    Regards,
     
    #4 stephenbrown, Jul 13, 2007
    Last edited: Jul 13, 2007
  5. cPDan

    cPDan cPanel Staff
    Staff Member

    Joined:
    Mar 9, 2004
    Messages:
    711
    Likes Received:
    3
    Trophy Points:
    18
    Feel free to create a support ticket at support.cpanel.net, thanks
     
Loading...

Share This Page