# Cache Directory not present or writable issue

**URL:** https://discourse.roots.io/t/cache-directory-not-present-or-writable-issue/25217
**Category:** acorn
**Tags:** sage10
**Created:** 2023-04-21T15:28:59Z
**Posts:** 10

## Post 1 by @RobHowdle — 2023-04-21T15:28:59Z

Hi there,

Having this issue when installing Acorn. I get no errors when installing or when I build however after I set my sage theme as the WP site theme, I am given this error. Can’t find any information on it really. When i install Acorn, the directory it points to doesn’t exist. I’d assume if it was needed it would create it as i don’t believe this would come standard in sage (at least it doesn’t in sage 9). I have tried to create the directory manually and give it the correct permissions but I still get the same error.

/var/www/portfolio/wp-content/cache/acorn/framework/cache directory must be present and writable.

Any thoughts at all?  
thanks  
Rob

---

## Post 2 by @AlexHay — 2023-04-21T16:26:39Z

Have you tried any of the Acorn WP CLI commands? Might worth giving the following a try:

```
wp acorn vendor:publish
```

---

## Post 3 by @RobHowdle — 2023-04-21T16:27:34Z

Thank you. I’ll try those, I don’t usually use any of WP CLI stuff as I’ve never needed them before but I’ll give it a try, thanks!

---

## Post 4 by @thunderdw — 2023-04-21T16:32:24Z

You can also try manually creating that directory,

---

## Post 5 by @RobHowdle — 2023-04-21T16:43:34Z

> I have tried to create the directory manually and give it the correct permissions but I still get the same error.

Already tried that, didn’t work.

---

## Post 6 by @talss89 — 2023-04-21T16:51:25Z

Have you checked ownership as well as permissions? The directory should be writeable from the point of view of the running `php-fpm` process. For Trellis, I believe that’s `web:www-data`, but it may be different for you.

Try `chown -R web:www-data /var/www/portfolio` and make sure everything is mode 755 (`chmod -R 755 /var/www/portfolio`).

---

## Post 7 by @thunderdw — 2023-04-21T16:55:10Z

Sorry about that, missed it in your post.

---

## Post 8 by @RobHowdle — 2023-04-21T17:11:32Z

Managed to solve the issue, chose the solution answer. It has presented me with another issue but I’ll open a new thread for that one.

Thanks for the help.

---

## Post 9 by @etiennesamson — 2024-02-21T08:03:35Z

Hi @RobHowdle, I am facing the same issue on my side today.  
I was wondering how you where passing through that one ?  
Can you share ?

---

## Post 10 by @etiennesamson — 2024-02-21T13:59:21Z

Ok, there was a confuse under users/group rights between my local, my vm’s /vagrant-nfs/… and /srv/www/… directories and files :man_facepalming:

Trashed my vm and rebuild it from the grave with “trellis up” did the cleanup.
