Help, what kind of error is this?

Permalink
Hello all. I've installed a new site (5.5) and it's showing errors all over it. It's been installed on a Linux server which uses Plesk (php5.2.4/Ubuntu5.14). I've installed it on another Linux server and it works fine. Here's the error message:

Warning: imagejpeg() [function.imagejpeg]: Unable to open '/var/www/vhosts/recycle-scotland.co.uk/httpdocs/new-web-site/files/cache/f3cfb5558e6fe6457b02daefa1e3698e.jpg' for writing: Permission denied in /var/www/vhosts/recycle-scotland.co.uk/httpdocs/new-web-site/packages/advanced_slider/helpers/advanced_image.php on line 179

If anyone could give me even a rough idea of what type of error this is it would help hugely as the only guy who can give me tech support from the server company is on holiday...
Thanks. JP.

 
xaritas replied on at Permalink Reply
Best guess: this lines appears to be from something trying to create a temporary image file for display purposes. It's trying to store the result temporarily in the directory "files/cache" of your C5 root.

However, the web server can't write to your files/cache directory for some reason. C5 checks to make sure that the files directory is writeable when it installs, and attempts to create the subdirectories as writeable, but something has come along to change permissions.

Unless you can log in and change the permissions yourself, you're going to have to wait for your host to fix it.

Why does your host only have one person capable of doing tech support? That sounds like a nightmare.
DanK replied on at Permalink Reply
Thanks xaritas,

So if I can find a way to change all permissions to 755 that should fix it, is that what you mean?

It's not my hosting (wish it was), it's hosting the client has supplied. Nightmare!

Thanks for your help.
JP
xaritas replied on at Permalink Best Answer Reply
Assuming that is the problem, it should work. Actually, only the web server itself needs to be able to be able to write to the cache directory, so 700 should work. However, that assumes your host is using basically sane settings. I would try the most conservative approach (700) and work your way up to more permissive settings until it works. I wouldn't be surprised if your host sweeps for directories which are world or group accessible, and closes them, so the fix may only be temporary.
DanK replied on at Permalink Reply
Brilliant, thanks again. Once quick wee question. Can I go each of the directories at the root level (starting with blocks and ending in updates) and change these using my ftp client? I'm quite new to all this, not sure if that would work or not and I'm not familiar at all with the Plesk Control Panel so don't think I can do it from there.
xaritas replied on at Permalink Reply
Did the other directories flip to non-writeable, too? There is a legitimate need for files/cache to be writeable at all times, and it's not going to hurt anything to make all of the other directories writeable, although it's probably not necessary unless you start installing things from the marketplace.

I think your next step is to wait until you can reach tech support to see if they can figure out why that directory flipped to non-writeable, and then make them fix it. Something related to their configuration or policies might be the root cause.