0

I'm working on a legacy PHP project I cannot start the project I got the error,

failed to open stream: Permission denied in /opt/lampp/htdocs/vendor/laravel/framework/src/Illuminate/Filesystem/Filesystem.php:81

It is running on XAMPP on Ubuntu server.

I've have been try a lot of commands (below) but nothing works.

  1. sudo chmod -R 777 storage
  2. sudo chmod -R 775 storage
  3. php artisan view:clear
  4. php artisan config:clear
  5. php artisan config:cache
  6. php artisan key:generate
  7. composer dump-autoload
  8. sudo chown -R daemon /opt/lampp/htdocs
  9. sudo chmod -R 775 bootstrap/cache

Please help.

Hikaru Shindo
  • 2,611
  • 8
  • 34
  • 59
  • can you check you storage folder there must be these folder present `storage/framework/cache` and `storage/framework/views` rest you can match with https://github.com/laravel/laravel/tree/8.x/storage/framework – Kamlesh Paul Nov 23 '21 at 10:29
  • Thanks @KamleshPaul Already created but it's not working. – Hikaru Shindo Nov 23 '21 at 10:47
  • check [this](https://stackoverflow.com/a/37266353/6274211) SO answer by @bgies – iamab.in Nov 23 '21 at 11:13
  • FileSystem.php is trying to access a file that is somewhere on the disk. It might be that it is outside of the /opt/lampp/htdocs directory. Find out the path and set the permission for that path. – geldek Nov 23 '21 at 11:28
  • Hey!! How did you solve your issues? – Cherryl Rarewings Jul 31 '22 at 06:03

0 Answers0