player_analytics icon indicating copy to clipboard operation
player_analytics copied to clipboard

cache folder doesn't regenerate once deleted

Open fleabeard69 opened this issue 1 year ago • 9 comments

I'm fairly sure I've deleted my cache folder before and it gets regenerated after, but it doesn't appear to be doing so anymore. Am I missremembering things, or is there another way to regenerate the cache folder?

For reference it's the www/cache folder I'm talking about here.

fleabeard69 avatar Mar 11 '24 13:03 fleabeard69

It will be auto-generated once you visit the site again. There's no other way.

theChaosCoder avatar Mar 11 '24 17:03 theChaosCoder

I was hoping it would auto-generate after visiting the site again but it has not. I've even gone as far as to reboot the server that I host it on and it never comes back.

Looking at the nginx error.log I show this: 2024/03/11 14:28:26 [error] 248#248: *1 FastCGI sent in stderr: "PHP message: PHP Fatal error: Uncaught Error: Call to a member function prepare() on null in /config/www/inc/database.class.php:39 Stack trace: #0 /config/www/index.php(16): Database->query() #1 {main} thrown in /config/www/inc/database.class.php on line 39" while reading response header from upstream, client: 172.18.0.4, server: _, request: "GET / HTTP/1.1", upstream: "fastcgi://127.0.0.1:9000", host: "analytics.website.com"

fleabeard69 avatar Mar 11 '24 17:03 fleabeard69

Did you check cache folder permissioins?

theChaosCoder avatar Mar 11 '24 17:03 theChaosCoder

That's the problem. I've deleted the cache folder and it's not auto-generating. I can re-create it on my own and give it the same exact permissions as all the others and it never generates any files in it.

fleabeard69 avatar Mar 11 '24 18:03 fleabeard69

Please try 777 to make sure its not a permission problem. And make sure user and/or group is the correct one. I think the system expects a cache folder, but does not create one itself.

theChaosCoder avatar Mar 11 '24 18:03 theChaosCoder

Here's what I've had this whole time on that newly created cache folder.

drwxrwxr-x 2 fleabeard fleabeard 4096 Mar 11 13:18 cache

fleabeard69 avatar Mar 11 '24 18:03 fleabeard69

That's 775. Please try 777 on cache. Depending on how your php+webserver is running you need a different user owner (like www-data). This could be the reason why it can not write anything.

theChaosCoder avatar Mar 11 '24 18:03 theChaosCoder

Thanks, I've since tried 777 but no love. All my other folders are showing my name/group as the owner and seems to working fine. I don't really need to track analytics anymore anyway, so I'm just going to go ahead and delete things and dismantle it all together.

Thanks anyways for your help as always!

fleabeard69 avatar Mar 11 '24 18:03 fleabeard69

Did you upgrade to a newer php version? Not sure if it supports 8.3...

theChaosCoder avatar Mar 11 '24 18:03 theChaosCoder