Question: What ownership does Apache need so that it does not require execute permissions for the world on public_html
(751
)?
Background: When I changed the php.ini settings through cPanel, there was an error "Error: The EUID, 1005, does not own /home/my_user_name/public_html/.htaccess." I understood this because it was the .htaccess
file was owned by root:root
,
So, as a green SHELL user I changed the ownership of every file using chown -R my_user_name:my_user_name .[^.]*
. Sweet, I could now save my php.ini through MultiPHP INI in cPanel.
That's when this pretty error appeared when trying to visit any page on my Drupal 8 site:
Forbidden You don't have permission to access / on this server. Server unable to read htaccess file, denying access to be safe
Additionally, a 403 Forbidden error was encountered while trying to use an ErrorDocument to handle the request.
Even after deleting, reuploading, and changing the ownership back to root:root
, it didn't work.
The only thing that worked was changing public_html
to 751 (instead of 750). Why does Apache need the execute permissions for the world? And which owner/group do I need to change it to fix it?
754 also didn’t work