简体   繁体   中英

No write permissions in /var/www/html

I am trying to run GLPi application on my Oracle Linux 7.0 where is only root user.

I have installed Apache, PHP and MySQL. But when I run application with GLPi in /var/www/html/glpi on http://example.com/gpli/ . I get this errors after selecting language and accepting terms of licence.

在这里你可以看到我正在谈论的问题

Here you can see problem I am talking about.

I tried change user and group to apache with chown -R apache:apache /var/www/html/gpli and grant full access with chmod -R a+rwx /var/www/html/gpli , but it doesn't help at all.

I think there is simple solution but I tried read some manuals and it doesn't help at all. Can you help me figure it out? Thank you.

SOLUTION:

Problem was with SELinux I don't know there is something like that. I had to disable enforcing in /etc/sysconfig/selinux . After that everything was ok.

After disabling SELinux I run this commands:

chmod 755 files && chown apache /[PATH_TO_GLPI]/files
find /[PATH_TO_GLPI]/files -type d -exec chown apache {} \;
find /[PATH_TO_GLPI]/files -type d -exec chmod 755 {} \;
chmod 755 config && chown apache /[PATH_TO_GLPI]/config

Does GPLI create its own user? If so, you will have to give wheel permissions to that user. You could also give every user read, write, and execute permissions. Also, I see that you gave permissions to an account called "apache". Apache doesn't always create its own user. If it were me, I would just give everyone all permissions so that GPLI could definitely access it.

您是否尝试过: chmod 775 /var/www/html/gpli

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM