File ownership for file tree php user ID - Folder permission 775

I have the same issue as the below topic, where all my folder are set to 755 but I am unable to run updates or upload new media due to folder permissions. Once I set it to 775, the problem is resolved.

https://wordpress.org/support/topic/folder-uploads-permission-to-775/

However, in this thread above it mentioned to set ownership of your file tree php user id. In my namesco account I have the below FTP accounts:

example.com  
example.com_thisisme

The website was uploaded using the example.com_admin

The owner/group of the files and folders for the website are:

example.com_thisisme example.com

If I am able to access the files and folders with the example.com and reset the permissions to 755. Will this set ownership of your file tree php user id and also fix the problem?

Topic filesystem Wordpress

Category Web


If, on your wp-content/uploads directory, 755 doesn't work, but 775 does it means that the group example.com already contains the 'php user id', so you don't need to do anything else.

More specifically, the web server process (like apache or nginx) both serves your files and runs PHP, so 'php user id' really means (is the same as) the web server user ID. It has its own user and group just like you have a user and group. If 775 makes things work it means that the web server process is in the example.com group.

Does that help?

About

Geeks Mental is a community that publishes articles and tutorials about Web, Android, Data Science, new techniques and Linux security.