[Resolved] 404 error or File not found

Status
Not open for further replies.
#1
Hello

In the begining, sorry for my english !

I open this post because I don't know how to resolve my problem.

I have à CPANEL VPS, with CloudLinux, CafeFS enable (after LiteSpeed installation). I don't encounter any problem with Apache 2.4.9, xcache, xend, ioncube, SuPHP, Mod Ruid2 and empty Mod security.

But, when i want to start LiteSpeed, I have a 404 error or the message
Code:
[ERROR] Can not open directory for URI: /!
I try to follow some thread in that forum, enable CageFS (now for fine on Apache), rebuild LSPHP, buy a 1CPU licence and don't use the Trial one , folow some instructions like ( http://blog.litespeedtech.com/2012/...en_basedir-in-the-shared-hosting-environment/ )....

I encounter the same problem in the log :
Code:
[HTAccess] Failed to open [/home/****/public_html/client/.htaccess]: Permission denied
or
Code:
INFO[****:45554-0#APVH_****] File not found [/home/****/public_html/client/]
File not found [/home/*****/public_html/client/404.shtml]
Cannot found appropriate handler for [/404.shtml]
I don't know where i'm wrong in my server config


Code:
Server Process        Edit
Server Name  


    $HOSTNAME
Running As  


    user(nobody) : group(nobody)
Priority  




    0
chroot Path  






    /
Enable chroot  




    No
Cloud Linux  




    CageFS
Memory I/O Buffer  




    60M
Swapping Directory  






    /tmp/lshttpd/swap
Auto Restart  








    Yes
Auto Fix 503 Error  




    Yes
Graceful Restart Timeout (secs)  




    Not Set
General Settings        Edit
MIME Settings  




    $SERVER_ROOT/conf/mime.properties
Disable Initial Log Rotation  




    Yes
Server Signature  




    Hide Version
Hide Error Page Signature  






    Not Set
Enable IP GeoLocation  




    Not Set
Use Client IP in Header  






    Not Set
External Application Abort  






    Not Set
Check For Update  




    Daily
Download Updates  




    Yes
Administrator Email  




    root@localhost
Index Files        Edit
Index Files  




    index.html, index.php, index.php5, index.htm
Auto Index  




    Not Set
Auto Index URI  




    Not Set
HT Access   



       Edit
Allow Override  






    Limit    Auth    FileInfo    Indexes    Options    None 
Access File Name  




    .htaccess
Expires Settings        Edit
Enable Expires  






    Yes
Expires Default  





    Not Set
Expires By Type  






    image/*=A604800, text/css=A604800, application/x-javascript=A604800, application/javascript=A604800
IP to GeoLocation DB   


       Add
          DB File Path     DB Cache Type     Action
Using Apache Configuration File        Edit
Load Apache Configuration  




    Yes
Auto Reload On Changes  




    Use Apache binary wrapper
Apache Binary Path  


    /usr/local/apache/bin/httpd
Apache Configuration File  


    /usr/local/apache/conf/httpd.conf
Apache Port Offset  



    2000
Apache IP Offset  




    0
Apache Handled Content  




    Not Set
Ignore Apache Modules  




    Not Set
Just In Time Configuration  




    Yes
PHP suEXEC  




    Yes
PHP suEXEC Max Conn  




    10
Enable FrontPage Extension  




    Yes
Apache Environment  




    Not Set
Apache Style Configurations   




       Edit
Apache Style configurations  




    Not Set

My security section :

Code:
File Access        Edit
Follow Symbolic Link  








    Yes
Check Symbolic Link  




    No
Force Strict Ownership  




    Yes
Required Permission Mask  




    000
Restricted Permission Mask  






    000
Script Restricted Permission Mask  






    002
Script Restricted Directory Permission Mask  






    002
Per Client Throttling   


       Edit
Static Requests/second  






    0
Dynamic Requests/second  






    0
Outbound Bandwidth (bytes/sec)  





    0
Inbound Bandwidth (bytes/sec)  




    0
Connection Soft Limit  










    10000
Connection Hard Limit  








    10000
Block Bad Request  




    Not Set
Grace Period (sec)  




    15
Banned Period (sec)  




    300
CGI Settings   


       Edit
CGI Daemon Socket  




    Not Set
Max CGI Instances  




    20
Minimum UID  




    11
Minimum GID  




    10
Force GID  






    Not Set
Priority  






    0
CPU Soft Limit (sec)  




    60
CPU Hard Limit (sec)  




    120
Memory Soft Limit (bytes)  








    450M
Memory Hard Limit (bytes)  






    500M
Process Soft Limit  






    400
Process Hard Limit  




    450
Access Denied Directories   




       Edit
/
/etc/*
/dev/*
$SERVER_ROOT/conf/*
$SERVER_ROOT/admin/conf/*
Access Control   






       Edit
Allowed List   




ALL
Denied List   




Not Set
Thank you in advance for your help !

Paul-Henri P.
 
Last edited by a moderator:
#3
Thank you for your quick response!

I try different chmod on .htacces (755, 766, ..) and I encounter the same issue.
For joomla and whmcs based website (no .htaccess) I have this message :
Code:
[ERROR] Can not open directory for URI: /!
Do you have an other track ? Do you need something for me for provide better helping ?

Paul-Henri P.
 
Last edited by a moderator:

NiteWave

Administrator
#4
how about change
Force Strict Ownership :Yes
to "No"

>Do you need something for me for provide better helping ?

yes, the quickest way is to provide the root access to the server, you can PM me these info in this forum.
 
#5
Hello !

Once again thank you for your reply!
I just tried the "Force Strict Ownership No", reboot litespeed server, and I encounter the same problem.

I PM NiteWave Rot acces to SSH console and WHM.

Thanks a lot for your support.
 

NiteWave

Administrator
#6
it's because of
drwxr-x--- 24 user01 user01 4096 May 22 01:13 public_html/

I made following change:
/home/user01>chgrp nobody public_html
now it is:
drwxr-x--- 24 user01 nobody 4096 May 22 01:13 public_html/

after the change,
Code:
http://user-domain.com:2080/
is ok now.

in WHM/cPanel, as a usual practice, public_html's group is nobody.

if the group still be user01, litespeed process which running as nobody can't access
/home/user01/public_html/.htaccess
hence the errors.
 
Last edited by a moderator:
Status
Not open for further replies.
Top