Прескочи към главното съдържание

Data directory is not writable even after chmod - База знание / Deskpro Legacy - Deskpro Support

Data directory is not writable even after chmod

Списък с автори


The installer tells me that my data directory isn't writable. I used chmod to make it writable, but I still get the message. It seems like chmod is not working. What's going on?


Answer (Apache)

This can happen in distributions that use the SE Linux access control mechanism. SE Linux access policies are separate from file permissions. You likely have an SE Linux policy that prevents Apache from writing to files within its root folder (e.g. /var/www).

To test this, temporarily disable SE Linux:


$ echo 0 >/selinux/enforce$ cat /selinux/enforce # should output "0"


If it is SELinux causing the problem, you can either leave it off (losing the security benefits) or turn it back on and fine-tune your SELinux access controls.

This command will make the data directory writable with SE Linux on:


chcon --type=httpd_sys_rw_content_t /var/www/data/ 


 Answer (Nginx)

You will want to set SELinux into permissive mode:

$ semanage permissive -a httpd_t

See Nginx documentation for further assistance.
Полезно Не беше полезно

35 от 84 души смятат тази страница за полезна

Добави коментар

Моля, логнете се или се регистрирайте, за да оставите коментар.

Нуждаете се от подсещане за парола?