Linux ownership of runtime, application.log and cache

Hello,

I have a strange problem, in the runtime directory, the application.log and the files generated by CFileCache are sometimes owned by apache:apache and other times owned by domain_user:psaserv (The user from PLESK that runs this domain)

The point is that I don’t understand why are files created under apache:apache ownership? I cannot delete those files with the user domain_user:psaserv, so if I try to create a PHP function or a cron job for that user to clear the cache directory, it gives me permission errors because the files are owned by apache.

I also upload photos from outside the framework under the same domain, and the ownership is always domain_user:psaserv and I’ve got no problem to delete them later.

Could be something related to php commands?

Safe Mode is disabled for this domain too.

If someone knows what should I look for I would really apreciate it. Thanks!

Example of permissions:


[root@s15412399 runtime]# ls -al

total 3060

drwxrwxrwx 3 elusuario psaserv 88 Mar 30 12:37 .

drwxr-xr-x 16 elusuario psaserv 4096 Mar 27 18:18 …

-rw-r–r-- 1 apache apache 995074 Mar 30 12:41 application.log

-rw-r–r-- 1 apache apache 1071874 Mar 30 12:36 application.log.1

-rw-r–r-- 1 apache apache 1058447 Mar 30 12:26 application.log.2

drwxr-xr-x 2 apache apache 49 Mar 30 12:18 cache

[root@s15412399 runtime]#

This tip may help.

/Tommy