Please whitelist cPanel in your adblocker so that you’re able to see our version release promotions, thanks!

The Community Forums

Interact with an entire community of cPanel & WHM users!

HELP PLEASE!! $25 For help! <VirtualHost> cannot occur within <VirtualHost> section

Discussion in 'General Discussion' started by Mallclerks, Nov 17, 2003.

  1. Mallclerks

    Mallclerks Member

    Joined:
    Aug 3, 2003
    Messages:
    13
    Likes Received:
    0
    Trophy Points:
    151
    Nov 16 21:21:06 intellects httpd: [Sun Nov 16 21:21:06 2003] [warn] module mod_asis.c is already added, skipping
    Nov 16 21:21:06 intellects httpd: [Sun Nov 16 21:21:06 2003] [warn] NameVirtualHost 66.98.131.237:80 has no VirtualHosts
    Nov 16 21:21:06 intellects httpd:
    Nov 16 21:21:08 intellects httpd: /etc/rc3.d/S85httpd start: httpd started
    Nov 16 21:21:08 intellects rc: Starting httpd: succeeded
    Nov 17 15:39:17 intellects httpd: [Mon Nov 17 15:39:17 2003] [warn] module mod_asis.c is already added, skipping
    Nov 17 15:39:17 intellects httpd:
    Nov 17 15:39:17 intellects httpd: [Mon Nov 17 15:39:17 2003] [warn] NameVirtualHost 66.98.131.237:80 has no VirtualHosts
    Nov 17 15:39:17 intellects httpd:
    Nov 17 15:39:19 intellects httpd: /etc/rc3.d/S85httpd start: httpd started
    Nov 17 15:39:19 intellects rc: Starting httpd: succeeded
    Nov 17 21:26:38 intellects httpd: [Mon Nov 17 21:26:38 2003] [warn] module mod_asis.c is already added, skipping
    Nov 17 21:26:38 intellects httpd:
    Nov 17 21:26:39 intellects httpd: Syntax error on line 3017 of /usr/local/apache/conf/httpd.conf:
    Nov 17 21:26:39 intellects httpd: <VirtualHost> cannot occur within <VirtualHost> section
    Nov 17 21:26:39 intellects httpd: /etc/rc3.d/S85httpd start: httpd could not be started
    Nov 17 21:26:39 intellects rc: Starting httpd: failed
    httpd has failed, please contact the sysadmin.




    Anyone happen to know which line of code is missing or something. I went to delete the code shown in this thread
    http://forums.cpanel.net/showthread.php?s=&threadid=3628&highlight=uninstall+tomcat
    to uninstall tomcat but now my http wont start back up :(

    Any help would be GREATLY APPRECIATED!
     
  2. jsteel

    jsteel Well-Known Member

    Joined:
    Jul 4, 2002
    Messages:
    646
    Likes Received:
    0
    Trophy Points:
    166
    Location:
    Atlanta, GA
    Re: HELP PLEASE!! $25 For help! <VirtualHost> cannot occur within <VirtualHost> secti

    It measn that somewhere in your httpd.conf you have the following:

    <VirtualHost>
    ...
    <VirtualHost>
    ...
    </VirtualHost>


    In other words, you are defining a Virtual Host entry within another one, which isn't allowed - each VirtualHost entry must be opened and closed properly.
     
  3. Mallclerks

    Mallclerks Member

    Joined:
    Aug 3, 2003
    Messages:
    13
    Likes Received:
    0
    Trophy Points:
    151
    Is there away to see which line is which?

    When I log in via root using putty is doesnt show which line each is? So is there a easy way to find line 3017???
     
  4. Mallclerks

    Mallclerks Member

    Joined:
    Aug 3, 2003
    Messages:
    13
    Likes Received:
    0
    Trophy Points:
    151
    Now im getting this....



    [6]+ Stopped pico -w -z httpd.conf
    root@intellects [/usr/local/apache/conf]# /scripts/updatenow
    receiving file list ... done
    wrote 101 bytes read 7718 bytes 15638.00 bytes/sec
    total size is 2874520 speedup is 367.63
    root@intellects [/usr/local/apache/conf]# /etc/init.d/httpd stop
    /etc/init.d/httpd stop: httpd (no pid file) not running
    root@intellects [/usr/local/apache/conf]# killall -9 httpd
    httpd: no process killed
    root@intellects [/usr/local/apache/conf]# /etc/init.d/httpd start
    [Mon Nov 17 22:17:32 2003] [warn] module mod_asis.c is already added, skipping
    Syntax error on line 444 of /usr/local/apache/conf/httpd.conf:
    Invalid command '</VirtualHost></IfModule>', perhaps mis-spelled or defined by a module not included in the server configuration
    /etc/init.d/httpd start: httpd could not be started
    root@intellects [/usr/local/apache/conf]#




    If anyone would be willing to try and log in and figure this out I could send ya $25 via paypal right now! I really wanna get this fixed asap as I got things to do and really dont feel like having these problems tonight, lol!


    AIM - rockinstan
    email - stan@thrillinghill.com

    If anyone is willing to try and fix it please let me know :(
     
    #4 Mallclerks, Nov 17, 2003
    Last edited: Nov 17, 2003
  5. casey

    casey Well-Known Member

    Joined:
    Jan 17, 2003
    Messages:
    2,303
    Likes Received:
    0
    Trophy Points:
    191
    If it just now stopped you could try to fix it by doing
    cd /usr/local/apache/conf/
    mv httpd.conf.bak httpd.conf
    cp httpd.conf httpd.conf.bak
    service httpd stop
    service httpd start
     
  6. Mallclerks

    Mallclerks Member

    Joined:
    Aug 3, 2003
    Messages:
    13
    Likes Received:
    0
    Trophy Points:
    151
    finally fixed. Thanks to everyone who helped!
     
  7. B12Org

    B12Org Well-Known Member

    Joined:
    Jul 15, 2003
    Messages:
    692
    Likes Received:
    1
    Trophy Points:
    168
    Location:
    Seattle Washington
    cPanel Access Level:
    Root Administrator
    how did you fix this? I am in dire need of assistance here, I am getting the

    [warn] NameVirtualHost 66.135.33.201:80 has no VirtualHosts

    message as well. Thanks in advance!
     
    Stop hovering to collapse... Click to collapse... Hover to expand... Click to expand...
  8. casey

    casey Well-Known Member

    Joined:
    Jan 17, 2003
    Messages:
    2,303
    Likes Received:
    0
    Trophy Points:
    191
    Search httpd.conf for 66.135.33.201:80 and make sure that each instance has the </VirtualHost> tag. Fix the one(s) that doesn't and then restart apache.
     
  9. B12Org

    B12Org Well-Known Member

    Joined:
    Jul 15, 2003
    Messages:
    692
    Likes Received:
    1
    Trophy Points:
    168
    Location:
    Seattle Washington
    cPanel Access Level:
    Root Administrator
    I did, and they all do, it still fails.
     
    Stop hovering to collapse... Click to collapse... Hover to expand... Click to expand...
  10. PWSowner

    PWSowner Well-Known Member

    Joined:
    Nov 10, 2001
    Messages:
    2,948
    Likes Received:
    4
    Trophy Points:
    343
    Location:
    ON, Canada
    Does the httpd.conf file have a line like

    NameVirtualHost 66.135.33.201:80


    before any accounts using that IP?

    And does it have accounts using that IP with

    <VirtualHost 66.135.33.201>


    before the account and with

    </VirtualHost>


    after the account?
     
    Stop hovering to collapse... Click to collapse... Hover to expand... Click to expand...
  11. B12Org

    B12Org Well-Known Member

    Joined:
    Jul 15, 2003
    Messages:
    692
    Likes Received:
    1
    Trophy Points:
    168
    Location:
    Seattle Washington
    cPanel Access Level:
    Root Administrator
    all hosts have the
    <VirtualHost 66.135.33.201></virtualhost>
    tags, none use direct IP.

    Yes, it does have a namedvirtualhost 66.135.33.201:80 tag in there, three of them.

    I left them all there, it fails. I commented them all out, it fails.

    I tried deleting them, restarting, and then looking at the file again, and they are back again, so cpanel is creating those entries there.
     
    Stop hovering to collapse... Click to collapse... Hover to expand... Click to expand...
  12. PWSowner

    PWSowner Well-Known Member

    Joined:
    Nov 10, 2001
    Messages:
    2,948
    Likes Received:
    4
    Trophy Points:
    343
    Location:
    ON, Canada
    You said "Yes, it does have a namedvirtualhost 66.135.33.201:80 tag in there, three of them.".

    Does it say "namedvirtualhost 66.135.33.201:80" or does it say "NameVirtualHost 66.135.33.201:80"?

    Notice the capitalization and no "d"?

    If the line does actually say
    NameVirtualHost 66.135.33.201:80
    then I have no idea what else the problem could be.

    It is safe to delete extra lines. I do it all the time. Just be sure to leave one there.
     
    Stop hovering to collapse... Click to collapse... Hover to expand... Click to expand...
  13. B12Org

    B12Org Well-Known Member

    Joined:
    Jul 15, 2003
    Messages:
    692
    Likes Received:
    1
    Trophy Points:
    168
    Location:
    Seattle Washington
    cPanel Access Level:
    Root Administrator
    Yes, sorry, it does say
    NameVirtualHost , in my hurry I must have thought it said named. Sorry for the confusion. It does have them there.
     
    Stop hovering to collapse... Click to collapse... Hover to expand... Click to expand...
Loading...

Share This Page

  1. This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
    By continuing to use this site, you are consenting to our use of cookies.
    Dismiss Notice