Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

matomo /tmp/cache/tracker/" is not writable. #15964

Closed
ghost opened this issue May 19, 2020 · 5 comments
Closed

matomo /tmp/cache/tracker/" is not writable. #15964

ghost opened this issue May 19, 2020 · 5 comments
Labels
worksforme The issue cannot be reproduced and things work as intended.

Comments

@ghost
Copy link

ghost commented May 19, 2020

after changing PHP mode to fcgi, matomo does not work...

sudo a2enmod proxy_fcgi setenvif
sudo a2enconf php7.3-fpm
sudo service apache2 restart

The directory "/tmp/cache/tracker/" is not writable

this needs to be fixed

@tsteur
Copy link
Member

tsteur commented May 19, 2020

Hi @broros thanks for creating the issue. Most likely this is a server configuration issue. Be good to check the file permissions and that the correct user can write these directories. Does your solution in #15509 (comment) not work anymore?

If PHP tells us a directory is not writable, then more than likely it is actually not writable for PHP. Maybe check what permissions these run.

@ghost
Copy link
Author

ghost commented May 19, 2020

I don't think you get it... it's not the folder permission. This happens when I change to FastCGI PHP mode Vs FPM

@ghost
Copy link
Author

ghost commented May 19, 2020

This should not be happening :(

@fealXX
Copy link

fealXX commented May 20, 2020

If the problem happens after the change, the php-fpm service might run under a different user than the apache2 does and therefore has no write permission for the tracker folder.
Check your pool-Config for "Unix user/group of processes" and/or check with ps aux | grep php-fpm what user is running fpm.

@ghost
Copy link
Author

ghost commented May 20, 2020

  1. Limit the file systems writes your PHP application needs to do when running in a web context
  2. Keep those writes under a limited number of directories (ideally one)
  3. Abstract any file system read/writes to a single system which allows you to
  • Control the PHP umask when making file system read/writes
  • Provide user-friendly error-messaging/experience when you run into a permission problem
  • Swap in a different system for reads and writes (everything from transfers/writes via SFTP, or replacing the whole thing with redis)

Off the top of my head — Joomla, WordPress, Drupal, Laravel — they all have (intentionally or not) created platforms that hew to the above.

@tsteur tsteur added the worksforme The issue cannot be reproduced and things work as intended. label May 20, 2020
@ghost ghost closed this as completed May 22, 2020
This issue was closed.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
worksforme The issue cannot be reproduced and things work as intended.
Projects
None yet
Development

No branches or pull requests

2 participants