Cache unable to write to /cache/. - Printable Version +- CodeIgniter Forums (https://forum.codeigniter.com) +-- Forum: Using CodeIgniter (https://forum.codeigniter.com/forumdisplay.php?fid=5) +--- Forum: Installation & Setup (https://forum.codeigniter.com/forumdisplay.php?fid=9) +--- Thread: Cache unable to write to /cache/. (/showthread.php?tid=82671) |
Cache unable to write to /cache/. - notme - 08-06-2022 Hello, I just set up a new instance of CodeIgniter. Unfortunately I get the following error "Cache unable to write to /cache/.". For some reason, CodeIgniter has a need to cache write to /cache among other system folders, not in web folder. If I create a folder, I get an error that mkdir cannot be executed. CodeIgniter is running under www-data:www-data. For some reason constant WRITEPATH is "/". PHP - 8.1.8 Do you have any idea how fix? Thank you RE: Cache unable to write to /cache/. - captain-sensible - 08-08-2022 so your obviously using linux looking at /var/www inside the main folder of your web app there are directories eg app, writable inside writable there is a cache directory. From a terminal emulator cd into main web root . I just did mine like this: sudo chmod 777 writable -R my understanding is that you need to have execute permission on a directory in order for the 'system' to be able to enter the directory in question. -R is recursive so it should make cache directory also read, write, execute so your using apache on which linux distro ? i dont know of this is going to help but on my linux this is my structure. CodeIgniter4 is contained within a directory called ads.com Code: [andrew@darkstar:/srv/http]$ tree -L 1 ads.com (08-08 16:28) i find it easier to use virtual host config RE: Cache unable to write to /cache/. - notme - 08-08-2022 Quote:I just did mine like this: sudo chmod 777 writable -R Yes, I missed it. Problem solved. Thank you. |