您好,欢迎来到三六零分类信息网!老站,搜索引擎当天收录,欢迎发信息

centos下更改目录权限后仍不可写怎么办

2025/12/29 23:46:46发布40次查看
问题描述:
在 centos 上搭建环境时,无论如何修改用户权限为 777 或者 755 、变更文件所属用户, laravel 框架总是报错 the stream or file /var/www/laravel56/storage/logs/laravel.log could not be opened: failed to open stream: permission denied。
解决方法:
关闭selinux即可。
编辑 /etc/selinux/config 文件,将 selinux 项修改为:selinux=disabled
#this file controls the state of selinux on the system. # selinux= can take one of these three values: # enforcing - selinux security policy is enforced. # permissive - selinux prints warnings instead of enforcing. # disabled - no selinux policy is loaded. selinux=disabled # selinuxtype= can take one of these two values: # targeted - only targeted network daemons are protected. # strict - full selinux protection. selinuxtype=targeted
推荐教程:centos教程
以上就是centos下更改目录权限后仍不可写怎么办的详细内容。
该用户其它信息

VIP推荐

免费发布信息,免费发布B2B信息网站平台 - 三六零分类信息网 沪ICP备09012988号-2
企业名录 Product