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.

All domains on new cPanel / CloudLinux server show 404

Discussion in 'CloudLinux' started by Judd Taylor, Aug 4, 2014.

  1. Judd Taylor

    Judd Taylor Member

    Joined:
    Aug 4, 2014
    Messages:
    10
    Likes Received:
    0
    Trophy Points:
    1
    Location:
    Melbourne, Victoria, Australia, Australia
    cPanel Access Level:
    Root Administrator
    Hi,

    Have created a new server on AWS based on a cPanel - CloudLinux AMI.

    Have one show stopper which I've not yet been able to resolve.

    Sites on the server can be viewed via temporary URL but not when using the site domains. this is consistent with 5 different accounts I've created on the server.

    eg:

    /http://54.79xx.xx/~domain/test.htm works fine

    But...

    /http://test123.domain.com.au/test.htm fails with a 404

    Both URL's point to the same account etc. There is not htaccess file.

    Any suggestions appreciated !
     
  2. someB0dy

    someB0dy Member

    Joined:
    May 24, 2010
    Messages:
    20
    Likes Received:
    2
    Trophy Points:
    3
    cPanel Access Level:
    Root Administrator
    Hi,

    That really looks like some misconfiguration on the server, is DocumentRoot for test123.domain.com.au really leads to /home/domain/public_html/ (check /usr/local/apache/conf/httpd.conf for that domain)? Or could you please post here full VirtualHost section for it?

    And what does /usr/local/apache/logs/error_log says ?
     
  3. cPanelMichael

    cPanelMichael Forums Analyst
    Staff Member

    Joined:
    Apr 11, 2011
    Messages:
    30,678
    Likes Received:
    653
    Trophy Points:
    113
    cPanel Access Level:
    Root Administrator
    Hello :)

    What's the full error message in /usr/local/apache/logs/error_log when opening the website through the domain name? Is the content uploaded to the correct directory?

    Thank you.
     
  4. Judd Taylor

    Judd Taylor Member

    Joined:
    Aug 4, 2014
    Messages:
    10
    Likes Received:
    0
    Trophy Points:
    1
    Location:
    Melbourne, Victoria, Australia, Australia
    cPanel Access Level:
    Root Administrator
    Here's an extract from the httpd.conf....

    - Removed -
     
    #4 Judd Taylor, Aug 4, 2014
    Last edited by a moderator: Aug 4, 2014
  5. Infopro

    Infopro cPanel Sr. Product Evangelist
    Staff Member

    Joined:
    May 20, 2003
    Messages:
    14,451
    Likes Received:
    195
    Trophy Points:
    63
    Location:
    Pennsylvania
    cPanel Access Level:
    Root Administrator
    Twitter:
    Please do not just simply cut and paste into a post on these forums.

    Don't use the quick reply when making a post like that either.

    Go to the full editor to post.
    Use the CODE tags to wrap your content to add it here.
    Below the reply editor there are 2 checkboxes:

    Automatically parse links in text
    Automatically retrieve titles from external links

    Uncheck both.

    Finally, modify any post you make to remove personal details like IP addresses, emails, or domain names.

    Your post has been edited for these reasons.

    Feel free to go again.
     
  6. Judd Taylor

    Judd Taylor Member

    Joined:
    Aug 4, 2014
    Messages:
    10
    Likes Received:
    0
    Trophy Points:
    1
    Location:
    Melbourne, Victoria, Australia, Australia
    cPanel Access Level:
    Root Administrator
    extract from error_log (with my local ip replaced with xx.xx...):

    Code:
    [Tue Aug 05 09:28:47 2014] [error] [client 203.217.31.125] File does not exist: /usr/local/apache/htdocs/test.htm
    [Tue Aug 05 09:28:48 2014] [error] [client 203.217.31.125] File does not exist: /usr/local/apache/htdocs/favicon.ico
    
     
  7. someB0dy

    someB0dy Member

    Joined:
    May 24, 2010
    Messages:
    20
    Likes Received:
    2
    Trophy Points:
    3
    cPanel Access Level:
    Root Administrator
    It is looking for a file in main apache folder, not in users directory. Really need a virtualhost section for that domain, could you please paste it properly?
     
  8. Judd Taylor

    Judd Taylor Member

    Joined:
    Aug 4, 2014
    Messages:
    10
    Likes Received:
    0
    Trophy Points:
    1
    Location:
    Melbourne, Victoria, Australia, Australia
    cPanel Access Level:
    Root Administrator
    Code:
    <VirtualHost 54.79.xx.xx:80>
        ServerName test123.domain.com.au
        ServerAlias www.test123.domain.com.au
        DocumentRoot /home/domain/public_html
        ServerAdmin webmaster@test123.domain.com.au
        UseCanonicalName Off
        CustomLog /usr/local/apache/domlogs/test123.domain.com.au combined
        CustomLog /usr/local/apache/domlogs/test123.domain.com.au-bytes_log "%{%s}t %I .\n%{%s}t %O ."
        ## User domain # Needed for Cpanel::ApacheConf
        UserDir enabled domain
        <IfModule mod_suphp.c>
            suPHP_UserGroup domain domain
        </IfModule>
        <IfModule concurrent_php.c>
            php4_admin_value open_basedir "/home/domain:/usr/lib/php:/usr/php4/lib/php:/usr/local/lib/php:/usr/local/php4/lib/php:/tmp"
            php5_admin_value open_basedir "/home/domain:/usr/lib/php:/usr/local/lib/php:/tmp"
        </IfModule>
        <IfModule !concurrent_php.c>
            <IfModule mod_php4.c>
                php_admin_value open_basedir "/home/domain:/usr/lib/php:/usr/php4/lib/php:/usr/local/lib/php:/usr/local/php4/lib/php:/tmp"
            </IfModule>
            <IfModule mod_php5.c>
                php_admin_value open_basedir "/home/domain:/usr/lib/php:/usr/local/lib/php:/tmp"
            </IfModule>
            <IfModule sapi_apache2.c>
                php_admin_value open_basedir "/home/domain:/usr/lib/php:/usr/php4/lib/php:/usr/local/lib/php:/usr/local/php4/lib/php:/tmp"
            </IfModule>
        </IfModule>
        <IfModule !mod_disable_suexec.c>
            <IfModule !mod_ruid2.c>
                SuexecUserGroup domain domain
            </IfModule>
        </IfModule>
        <IfModule mod_ruid2.c>
            RMode config
            RUidGid domain domain
        </IfModule>
        <IfModule itk.c>
            # For more information on MPM ITK, please read:
            #   http://mpm-itk.sesse.net/
            AssignUserID domain domain
        </IfModule>
    
        ScriptAlias /cgi-bin/ /home/domain/public_html/cgi-bin/
        # To customize this VirtualHost use an include file at the following location
        # Include "/usr/local/apache/conf/userdata/std/2_2/domain/test123.domain.com.au/*.conf"
    
    </VirtualHost>
    
    
     
  9. cPanelMichael

    cPanelMichael Forums Analyst
    Staff Member

    Joined:
    Apr 11, 2011
    Messages:
    30,678
    Likes Received:
    653
    Trophy Points:
    113
    cPanel Access Level:
    Root Administrator
    You can open a support ticket so we can take a closer look. Post the ticket number here so we can update this thread with the outcome.

    Thank you.
     
  10. someB0dy

    someB0dy Member

    Joined:
    May 24, 2010
    Messages:
    20
    Likes Received:
    2
    Trophy Points:
    3
    cPanel Access Level:
    Root Administrator
    well, everything really looks properly, it should works, so I agree support ticket would be the best way here

    - - - Updated - - -

    or, maybe something is wrong with apache configs so it failed to restart/apply your new virtualhost. Try to run syntax check:

    httpd -t
     
  11. Judd Taylor

    Judd Taylor Member

    Joined:
    Aug 4, 2014
    Messages:
    10
    Likes Received:
    0
    Trophy Points:
    1
    Location:
    Melbourne, Victoria, Australia, Australia
    cPanel Access Level:
    Root Administrator
    I think my issue may be name server related. When initially setting up the server I entered incorrect name servers. I've now corrected them.

    However, I notice a on an older cPanel server I manage, when I create a new account and tick the option "Use the nameservers specified at the Domain's Registrar", the server identifies the correct current namesevers for the new accounts domain.

    On this new server when I tick the same option, the server appears unable to obtain the current nameservers for the domain and leaves them set to the default ns.
     
  12. cPanelMichael

    cPanelMichael Forums Analyst
    Staff Member

    Joined:
    Apr 11, 2011
    Messages:
    30,678
    Likes Received:
    653
    Trophy Points:
    113
    cPanel Access Level:
    Root Administrator
    You can use a website such as IntoDNS to review the DNS for a domain name if you are concerned it's not configured properly. Otherwise, please open a support ticket so we can take a closer look.

    Thank you.
     
Loading...

Share This Page