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!
  1. This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn More.

Why would I not have direct access to httpd.conf?

Discussion in 'General Discussion' started by GreenAce92, Nov 30, 2014.

  1. GreenAce92

    GreenAce92 Registered

    Nov 30, 2014
    Likes Received:
    Trophy Points:
    cPanel Access Level:
    Root Administrator
    This question may not be appropriate as it mostly has to do with GoDaddy although I am using CPanel.

    I recently setup my laptop as a server using Linux and Apache.
    I had access to the httpd.conf file
    I would open it up in pico and do as I please

    GoDaddy, I have to edit within ranges? Like before and after the Virtual Host area?

    Well I was blindly adding Virtual Hosts and I duplicated one of them, I thought to myself "hmm... it is currently working, is it bad to duplicate it?" Which in my linux apache setup I had duplicated virtual hosts before and I was able to get my server to run.

    Now when I try to run the server after adding several virtual hosts I get this error :

    I should note it takes like at least 10 seconds for the error to pop up saying restart failed. I would guess that it is stuck in a loop but I have no idea.

    I just wish I could actually access the httpd.conf file. I don't know where it is. I read people saying "oh it's in your usr/local/..." but isn't that suggestion on my own computer?

    I tried to use putty to access via SSH, I didn't even see an option to enter a password, so when I hit enter, it says connection refused.

    I think the first line is what you want

    Thanks for any help

    Yeah I color coded it in red as in bad haha
  2. 24x7ss

    24x7ss Well-Known Member

    Sep 30, 2014
    Likes Received:
    Trophy Points:
    cPanel Access Level:
    Root Administrator
    First of all can you confirm us whether you are having root SSH access of the server. If yes then give httpd -t command to check if there is any issue with apache config file. If it gives error then you have to resolve that first. If everything is Ok then try running below command. It will show some light on your issue.


    If still you are facing the issue then try rebuilding apache /scripts/rebuildhttpdconf. This will definitely fix your issue
  3. cPanelMichael

    cPanelMichael Forums Analyst
    Staff Member

    Apr 11, 2011
    Likes Received:
    Trophy Points:
    cPanel Access Level:
    Root Administrator
    Hello :)

    The following document explains how to manually modify the Apache configuration file:

    Advanced Apache Configuration

    Feel free to open a support ticket using the link in my signature if you are unable to get Apache started. You can post the ticket number here so we can update this thread with the outcome.

    Thank you.

Share This Page