Skip to main content

(13)Permission denied: [client xyz:63932] AH00529: /home/username/public_html/.htaccess pcfg_openfile: unable to check htaccess file, ensure it is readable and that '/home/username/public_html/' is executable

Answered

Comments

10 comments

  • quietFinn

    In our servers public_html is 750, owner:group is CPANELUSER:nobody

     

    0
  • cPRex Jurassic Moderator

    It depends on how your server is configured, but yes, cPanel should be setting this properly by default:

    https://support.cpanel.net/hc/en-us/articles/360050418594-What-are-the-default-file-permissions-for-public-html

    Are you sure those entries in the log are legitimate requests for the file?  Can you open that file normally on the system?

    0
  • CharlesGLondon

    Yes, so that's what I thought. I've already read the post. 

    There is a thread on this https://stackoverflow.com/questions/20627084/permission-denied-var-www-abc-htaccess-pcfg-openfile-unable-to-check-htacces

    The .htaccess file is obviously not publicly accessible. Not sure what this error means. Still trying to figure out. Apache error log just keeps dumping these errors for all accounts. 

    0
  • cPRex Jurassic Moderator

    Thanks for the additional details.  I have the following permissions on a default AlmaLinux 8 machine:

    /home - 711 root:root
    /home/username - 711 username:username
    /home/username/public_html - 755 username:username

    0
  • CharlesGLondon

    AL9

    /home - 711 root:root
    /home/username - 711 username:username
    /home/username/public_html - 750 username:username

    for me public_html is being set to 750 by default by cpanel. I haven't touched any permissions so I'm assuming it is set by cPanel.  

    So where we go from here?

    Which permission for public_html is correct? 755 or 750 ?

    0
  • cPRex Jurassic Moderator

    If you're on Alma9 that's fine.

    What error do you get when you manually try to access that .htaccess file in a browser?

    0
  • CharlesGLondon

    .htaccess is not supposed to be publicly accessible so it is giving 404 not found when I try to access in browser. 

    0
  • cPRex Jurassic Moderator

    If your .htaccess isn't accessible, then things are working as intended and you're just seeing the result of that show up in the server logs.  It's very common for automated bots to try and access those files to see if they can get useful data about your account.

     

    0
  • CharlesGLondon

    "automated bots" yes that's what I'm also thinking. Thanks for the help.

    0
  • cPRex Jurassic Moderator

    Sure thing!

    0

Please sign in to leave a comment.