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.

httpd has failed

Discussion in 'General Discussion' started by fdnven, Feb 17, 2006.

  1. fdnven

    fdnven Well-Known Member

    Joined:
    Feb 14, 2006
    Messages:
    109
    Likes Received:
    0
    Trophy Points:
    16
    httpd has failed (Solved)

    I have been searching thru the forms.

    Seemed like the first step was to check the syntex with: /usr/sbin/httpd configtest

    the answer i recived i have been unable to find in the forum.s this is the return:


    Syntax error on line 1 of /usr/local/apache/conf/httpd.conf:I
    Invalid command 'd', perhaps mis-spelled or defined by a module not included in t
    the server configurationr

    Pretty much stoped me in my tracks right there. any ideas what it might be?
     
    #1 fdnven, Feb 17, 2006
    Last edited: Feb 18, 2006
  2. AndyReed

    AndyReed Well-Known Member
    PartnerNOC

    Joined:
    May 29, 2004
    Messages:
    2,222
    Likes Received:
    3
    Trophy Points:
    38
    Location:
    Minneapolis, MN
    The error message is pretty much self-explanatory. Look into httpd.conf and see if there is no mis-spelled or truncated directive.
     
  3. fdnven

    fdnven Well-Known Member

    Joined:
    Feb 14, 2006
    Messages:
    109
    Likes Received:
    0
    Trophy Points:
    16
    Thanks for the direction i am really new to this sort of thing. I just copyed the first 12 lines or so and this is waht i saw:

    d with the original
    # request will *not* be available to such a script.

    #
    # Customize behaviour based on the browser
    #
    <IfModule mod_setenvif.c>

    #
    # The following directives modify normal HTTP response behavior.
    # The first directive disables keepalive for Netscape 2.x and browsers that
    # spoof it. There are known problems with these browser implementations.
    # The second directive is for Microsoft Internet Explorer 4.0b2
    # which has a broken HTTP/1.1 implementation and does not properly
    # support keepalive when it is used on 301 or 302 (redirect) responses.
    #

    I am just guessing that maybe that first line should not be there at all?
     
  4. AndyReed

    AndyReed Well-Known Member
    PartnerNOC

    Joined:
    May 29, 2004
    Messages:
    2,222
    Likes Received:
    3
    Trophy Points:
    38
    Location:
    Minneapolis, MN
    Comment this line, save httpd.conf and then restart httpd.
     
  5. fdnven

    fdnven Well-Known Member

    Joined:
    Feb 14, 2006
    Messages:
    109
    Likes Received:
    0
    Trophy Points:
    16

    Commented out the line still would not start ran /usr/sbin/httpd configtest.

    And recived the nasty: Invalid command 'BytesLog', perhaps mis-spelled or defined by a module not included in the server configuration

    Been looking at these threads

    http://forums.cpanel.net/showthread.php?t=48411&page=1&pp=15&highlight=httpd

    http://forums.cpanel.net/showthread.php?t=46930&highlight=BytesLog

    and decided to do a /scripts/easyapache

    Which the server is doing as we speak.

    And of course httpd has failed, please contact the sysadmin
     
  6. PWSowner

    PWSowner Well-Known Member

    Joined:
    Nov 10, 2001
    Messages:
    2,948
    Likes Received:
    3
    Trophy Points:
    38
    Location:
    ON, Canada
    Not good. Here's that section of my httpd.conf file:

    #
    # 3) external redirects
    #ErrorDocument 402 http://www.example.com/subscription_info.html
    # N.B.: Many of the environment variables associated with the original
    # request will *not* be available to such a script.

    #
    # Customize behaviour based on the browser

    and that is around line 948, so it looks like somehow you lost a chunk of your file.
     
  7. PWSowner

    PWSowner Well-Known Member

    Joined:
    Nov 10, 2001
    Messages:
    2,948
    Likes Received:
    3
    Trophy Points:
    38
    Location:
    ON, Canada
    If you have backup running, I suggest you get a copy of your old httpd.conf file and use it to replace the missing lines.
     
  8. madaboutlinux

    madaboutlinux Well-Known Member

    Joined:
    Jan 24, 2005
    Messages:
    1,052
    Likes Received:
    2
    Trophy Points:
    38
    Location:
    Earth
    Login to the server as root. Take the backup of your httpd.conf file first and execute the below commands :-
    cp /usr/local/apache/conf/httpd.conf /usr/local/apache/conf/httpd.conf.bak
    vi /usr/local/apache/conf/httpd.conf
    :1,$ s/^BytesLog/#BytesLog/g
    and Save the file.

    OR

    /usr/local/apache/bin/apxs -iac mod_log_bytes.c

    Restart apache in both case :-
    service httpd restart

    Hope the above steps will help you.
     
  9. fdnven

    fdnven Well-Known Member

    Joined:
    Feb 14, 2006
    Messages:
    109
    Likes Received:
    0
    Trophy Points:
    16
    This is what has been completed so far after some restless sleep.

    Re-loaded back up httpd.conf

    /usr/sbin/httpd configtest=Syntex ok

    /usr/local/apache/bin/apachectl start=/usr/local/apache/bin/apachectl start: httpd started

    ps -aux | grep httpd=root 5764 0.0 0.0 1504 456 pts/0 S 09:46 0:00 grep httpd

    According to grep it does not look like it is running.?
    According to system services in Virituzzo it is still off.

    I am going to reload PWSowner httpd default.

    Frank

    OK loaded up PSWsowner httpd config.

    /usr/sbin/httpd configtest=Syntex ok

    /usr/local/apache/bin/apachectl start=/usr/local/apache/bin/apachectl start: httpd started

    ps -aux | grep httpd=

    root 9887 0.0 0.0 4932 2140 ? S 09:59 0:00 /usr/local/apache
    /bin/httpd
    nobody 9893 0.0 0.0 5064 2308 ? S 09:59 0:00 /usr/local/apache
    /bin/httpd
    nobody 9894 0.0 0.0 5064 2308 ? S 09:59 0:00 /usr/local/apache
    /bin/httpd
    nobody 9895 0.0 0.0 5064 2308 ? S 09:59 0:00 /usr/local/apache
    /bin/httpd
    nobody 9896 0.0 0.0 5064 2308 ? S 09:59 0:00 /usr/local/apache
    /bin/httpd
    nobody 9897 0.0 0.0 5064 2308 ? S 09:59 0:00 /usr/local/apache
    /bin/httpd
    root 13338 0.0 0.0 1504 456 pts/0 S 10:00 0:00 grep httpd

    Looks like it has started. Yet the Virituzzo panel still shows as turned off.

    In WHM:
    Server Status =Blank screen
     
    #9 fdnven, Feb 18, 2006
    Last edited: Feb 18, 2006
  10. fdnven

    fdnven Well-Known Member

    Joined:
    Feb 14, 2006
    Messages:
    109
    Likes Received:
    0
    Trophy Points:
    16
    to rebuild the cpanel i did /scripts/upcp --force

    Now WHM has a connetion to apache.

    Even though Virituzzo panel still shows as turned off.

    So i am getting really close.
     
  11. sawbuck

    sawbuck Well-Known Member

    Joined:
    Jan 18, 2004
    Messages:
    1,367
    Likes Received:
    5
    Trophy Points:
    38
    cPanel Access Level:
    Root Administrator
    Because of the directory structure that cPanel uses for Apache implementation, the Virtuozzo power panel will always show failed for httpd.
     
  12. fdnven

    fdnven Well-Known Member

    Joined:
    Feb 14, 2006
    Messages:
    109
    Likes Received:
    0
    Trophy Points:
    16
Loading...

Share This Page