file ownership

Discussion in 'General' started by smokinjo, Jul 17, 2018.

  1. smokinjo

    smokinjo Member

    Hello,

    I recently had ispconfig installed for me. Works fine.

    But, I have tried installing word press a cople fo times. This seems ot work.

    I also installed suitecrm (a fork of sugarcrm). It worked once, but failed another time.
    After looking around, and asking a few questions, it turned out that in the second install, the ownerships were off.

    I am trying to understand how things work :)

    In the first install, the suitecrm was install in a domain where the ownership was: web3:client2
    suite crm worked fine with these ownership.

    But, in the second domain, the ownership was: web2:client2
    It did nto work.

    It turned out that I needed to chnge the ownership to:

    www-data:www-data

    Why might it be that on the same server, with n modifications, would the ownership need be different like that for the same software, just in a different domain?

    It is fixed, so I am not looking to fix anything. I want to know for future reference if this issue comes up again. Or, just find away to avoid this issue:)

    Thanks

    Joseph
     
  2. ztk.me

    ztk.me ISPConfig Developer ISPConfig Developer

    If you use mod_php to execute php files, the username/group of the webserver is used usually withh some exceptions, but usually it is that.

    If you run PHP using CGI ( don't ever do that ) or fastcgi or fcgi ( both are not the mentioned CGI mode, but better use: ) or fpm
    the process has client/web ownerships.

    If you upload your files you usually have client/web ownership, if the php process using mod_php creates a file it a) can only do that in folders having the read/write flag set for "all", yes anyone on the server could read/write in this folder then, and the owner is www-data then, so it can be read by "all" ... but it can't change a file owned by web/client having a chmod of 640 for example.
     
  3. till

    till Super Moderator Staff Member ISPConfig Developer

    Then you are using a wrong PHP mode as @ztk.me pointed out or you missed enabling the suexec checkbox. PHP mode should be php-fpm or php-fcgi and the suexec checkbox must be switched on.
     

Share This Page