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!

Preview site using ip/~user not working

Discussion in 'General Discussion' started by ASTRAPI, Oct 31, 2014.

  1. ASTRAPI

    ASTRAPI Well-Known Member

    Joined:
    Jul 8, 2008
    Messages:
    321
    Likes Received:
    0
    Trophy Points:
    66
    Hi

    I just upload a index.php and one file.html with simple valid code to test using the ip before change the nameservers like this:

    Code:
    http://123.456.789.000/~userx    (userx is the cpanel account name)
    also as

    Code:
    http://123.456.789.000/~userx/file.html   
    And i am getting this:

    Code:
    404 Not Found
    
    The server can not find the requested page:
    
        123.456.789.000/~userx (port 80) 
    mod_userdir Protection is not enabled ...

    Also when i try to rebuild i am getting also this error that i smaybe related:

    Code:
    [[error] [client 123.456.789.000] File does not exist: /usr/local/apache/htdocs/~userx
    Any ideas?

    Thanks
     
    #1 ASTRAPI, Oct 31, 2014
    Last edited: Oct 31, 2014
  2. Infopro

    Infopro cPanel Sr. Product Evangelist
    Staff Member

    Joined:
    May 20, 2003
    Messages:
    16,339
    Likes Received:
    402
    Trophy Points:
    583
    Location:
    Pennsylvania
    cPanel Access Level:
    Root Administrator
    Twitter:
    Have you enabled the option?
    WHM » Security Center » Apache mod_userdir Tweak
     
    Stop hovering to collapse... Click to collapse... Hover to expand... Click to expand...
  3. ASTRAPI

    ASTRAPI Well-Known Member

    Joined:
    Jul 8, 2008
    Messages:
    321
    Likes Received:
    0
    Trophy Points:
    66
    Yes i enable it but i can't test it as it seems that i have a rebuild problem as i can see from the error and i am just use the basic cpanel template:

    Code:
    File does not exist: /usr/local/apache/htdocs/~userx
    The problem seems to be with the Apache httpd.conf i think :(
     
  4. Solokron

    Solokron Well-Known Member

    Joined:
    Aug 8, 2003
    Messages:
    850
    Likes Received:
    1
    Trophy Points:
    168
    Location:
    Seattle
    cPanel Access Level:
    DataCenter Provider
    Sounds like you are using ruid2 which does not work with this. The work around is to provide them with a dedicated IP.
     
    Stop hovering to collapse... Click to collapse... Hover to expand... Click to expand...
  5. ASTRAPI

    ASTRAPI Well-Known Member

    Joined:
    Jul 8, 2008
    Messages:
    321
    Likes Received:
    0
    Trophy Points:
    66
    On the new rebuild Ruid2 is not selected and i just get the rebuild done without errors.

    I was select to get a new config for Apache and it seems ok ...

    Is suphp and suexec related to my problem?

    - - - Updated - - -

    Not working again i can't preview a simple html :(

    Now i test it with:

    Default PHP Version (.php files) 5
    PHP 5 Handler fcgi

    Apache suEXEC off
    Apache Ruid2 off

    But nothing :(
     
  6. ASTRAPI

    ASTRAPI Well-Known Member

    Joined:
    Jul 8, 2008
    Messages:
    321
    Likes Received:
    0
    Trophy Points:
    66
    Ok i got it working for the index.html :)

    But when i try to load a simple hello word php script is not running and i am getting this:


    Code:
    Service Temporarily Unavailable
    
    The server is temporarily unable to service your request due to maintenance downtime or capacity problems. Please try again later.
    
    Additionally, a 404 Not Found error was encountered while trying to use an ErrorDocument to handle the request.
    I also try to enable the Apache suEXEC on but nothing :(
     
    #6 ASTRAPI, Oct 31, 2014
    Last edited: Oct 31, 2014
  7. ASTRAPI

    ASTRAPI Well-Known Member

    Joined:
    Jul 8, 2008
    Messages:
    321
    Likes Received:
    0
    Trophy Points:
    66
    Ok i found this that maybe is my solution but is for suphp only and i am using fcgi :(

    Code:
    http://forums.cpanel.net/f5/php-not-working-site-preview-70719.html
     
  8. cPanelMichael

    cPanelMichael Technical Support Community Manager
    Staff Member

    Joined:
    Apr 11, 2011
    Messages:
    44,749
    Likes Received:
    1,885
    Trophy Points:
    363
    cPanel Access Level:
    Root Administrator
    Twitter:
    Hello :)

    UserDir requests will not function correctly when using Mod_FCGI. This is documented at:

    FCGI Considerations

    Disabling SuExec will allow the URL to load, but it reduces the overall security of FCGI.

    Thank you.
     
    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