I am facing folder permission problem in my xampp server. when i am running laravel command php artisan route:list. then i am getting error
[ErrorException]
Key file "file://G:\Local Server\xampp\htdocs\Examples\example
1\laravel\storage\oauth-private.key" permissions are not correct, should be
600 or 660 instead of 666.
Related
iam installed laravel project using laravel documents details.and installed my project into my lampp directory path (htdocs/myproject).After that i run my project in browser.But i didt get the intro page of laravel showing Permission denied messege Like:
The stream or file "/opt/lampp/htdocs/dotgo/storage/logs/laravel.log" could not be opened in append mode: Failed to open stream: Permission denied
given all permissions to the laravel project folder by using the following command:
chmod 777 dotgo
Still i cant run the project file.Any one please help me to solve this one.....
try this chmod ugo+ rwx “lampp” inside your lampp dir
Each time I edit a blade file I have to run php artisan view:clear in order for the page to load correctly otherwise I get the following error
ErrorException (E_ERROR)
file_put_contents(/home/vagrant/Code/app/storage/framework/views/fsfsawe8bde92c95bad12ddfcfaea1738afsac0.php): failed to open stream: Permission denied (View: /home/vagrant/Code/app/resources/views/header.blade.php)
I am using the following:
Homestead v7.14.2
Vagrant (2.1.2)
I also recently ran sudo apt-get upgrade on my vm.
The Homestead update script did not install php 7.2 so I did that manually.
The permissions on my storage folders are all 777.
How do I setup laravel so that I do not have to keep running php artisan view:clear each time I make a change?
What has worked for me regarding this same issue, is to change apache or nginx to run as your local user or another that you have created and then change the laravel application directory ownership to this user using a chmod user -R. Or conversely you could change the project ownership to the web server user account.
I have a website which works locally (through VM), but when I upload it to the server I get this error
ErrorException in Filesystem.php line 111:
file_put_contents(/home/vagrant/Code/xxxx/storage/framework/sessions
/Ec2ceBoBBnKIOx8SzMXOf4akbzA5g5aI9WHBEhn6):
failed to open stream: No such file or directory
Things I've tried that didn't help: running composer update, running dump-autoload, running cache:clear, running config:cache, deleting everything on server and re-uploading everything after, creating directory/file manually, setting permissions to 777.
Any insights?
I have successfully installed Laravel project on the server but its not working. I am getting error like "page isn’t working
HTTP ERROR 500".
I have execute command
composer create-project --prefer-dist laravel/laravel
and created a directory name Laravel. But it's not working while same thing I have done on my local server and it's working fine.
in local you serve laravel project by internal web server using below command:
php artisan serve
but in your server env you must use apache conf and you must set document root like this:
your_project_directory/public/index.php
if every thing ok till now, your error must made by laravel error handling.
if so, then you can check your laravel log to find out exactly 500 error reason:
go to your project directory, then navigate to storage directory, here is logs directory and it has a laravel.log
tail -f your_project_directory/storage/logs/laravel.log
your generated log are here so read and solve it :)
tips: you must set privilages to your storage directory in server.
I run composer update and it resolve the problem. Known I run the following command from the root path of the application:
It was not the .htaccess file that was the problem nor the index.php. The problem was on accessing the files and requiring permissions.
For solving the problem i ran the following commands through terminal.
sudo chmod 755 -R laravel_blog
and then type below to allow laravel to write file to storage folder
chmod -R o+w laravel_blog/storage
This two commands solved the problem.
Please insert below command and try to access.
setenforce 0
it's working for me.
Error States:
The localhost page isn’t working
localhost is currently unable to handle this request.
HTTP ERROR 500
my project is in htdocs>laravel>project1>public>index.php
any more details like installation etc?
how did you install the laravel project by php artisan command or by composer or by zip package? and why you want to run your laravel project with the xammp file structure.. you can simply write the "php artisan serve" in your command line.. also make sure the .env variables set properly.. also try to clear all cache browser and run following query and try again
php artisan cache:clear
you need to know that the default port of laravel project is localhost:8000
When you meet 500 error, it's usually permissions related problem. Set write permissions on a storage directory. For Linux:
sudo chmod -R 775 storage
If it didn't help, look into Laravel error log.