I have gone through guides where it's stated that clearing the files in /var/cache directory is perfectly safe.

After I cleared it I experienced a backend issue. Saving configurations ended up with a server error, and didn't go through.

Stopping nginx and starting it generated an error:

Starting nginx: nginx: [emerg] mkdir() "/var/cache/nginx/client_temp" failed (2: No such file or directory)

Luckily I had a backup tarball of the /var/cache dir.


The guides mean /path/to/your/store/var/cache/

eg. /var/www/vhosts/mywebsite.co.uk/httpdocs/var/cache/

NOT /var/cache on a Linux machine. Note the starting forward slash relates to the root of the file-system.

  • That's how all those guides I went through stated the path. /var/cache. – nicoX Jun 24 '14 at 14:59
  • Hi NicoX - that might well be the case, but they'll be refering to "/" being the root of your application, not the root of the machine's filesystem. They probably also refer to directories such as /app/etc/ or /app/code/ I'd guess. Again, these are relative to your application. – Douglas Radburn Jun 24 '14 at 15:01
  • Always from Magento Root. Which is either your http doc root or the subfolder off the http doc root that you installed Magento in. – Fiasco Labs Jun 24 '14 at 16:55

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.