Issue
I've been filtering through google to try to find an answer to this, but I still can't find one that fixes my issue. I have migrated a website to a new server. The framework is Symfony 2.8 on php5.6 using Nginx and PHP-FPM.
Here is a screenshot of the config.php page.
To resolve this, i've tried...
- Changing the user for Nginx and php-fpm to both the user I log in with and Nginx, both didn't work
- I've opened up the privileges on the cache and log folder to 777 within the app folder, and that didn't work, nope.
- I've tried assigning the cache and logs folder to nginx:nginx, no go.
- I've manually assigned app.php, app_dev.php, and the console file to have the umask(0000) and umask(0002), nope.
- Restarted the Nginx service and php-fpm service after each change, nodda.
- I've restarted the entire server thinking something might be stuck, but you guessed it. No!
That leaves me here. I've gone through everything that I can think of and it baffles me that Symfony still won't recognize the directory as writable. It seems like the most simple thing, but... nope.
Anything will help, please pass anything along.
Solution
After countless hours of research and scraping the internet for details, I have found the answer! I'm posting it here in case someone else is having the same issue... and hopefully I can save them some time. This took up two days of my life that i'll never get back.
For whatever reason, SELinux was causing this error. I came across this issue on superuser stack exchange, and it told me to temporarily disable SELinux to test. After running sudo setenforce 0
everything came back up. I then completely disabled it and everything has been working fine since.
This happened suddenly and i'm still unsure of the reason. The site worked for about a week before this was triggered.
Answered By - Doug Morin Answer Checked By - Marilyn (WPSolving Volunteer)