安装失败:无法在ubuntu的wordpress nginx中创建目录

时间:2018-09-06 17:25:47

标签: php wordpress ubuntu nginx

我在本教程的帮助下设置了wordpress ... how to install wordpress with LEMP on ubuntu 18.04 当我尝试安装主题或插件时,显示如下错误消息

Installation failed: Could not create directory

我也尝试给予许可:

sudo chown -R www-data:www-data /var/www/domain_name.com/html/wp-content/plugins
sudo find /var/www/domain_name/html/ -type d -exec chmod 7555 {} \;
sudo find /var/www/c-linkons.com/html/ -type f -exec chmod 644 {} \;

我对此进行了检查

ps aux|grep nginx|grep -v grep

826  0.0  0.9 142688  9184 ?        Ss   Sep03   0:00 nginx: master process /usr/sbin/nginx -g daemon on; master_process on;
www-data 13818  0.0  0.8 144988  8748 ?        S    Sep04   0:00 nginx: worker process

并与此

ps -ef |grep php

root       759     1  0 Sep03 ?        00:00:11 php-fpm: master process    (/etc/php/7.2/fpm/php-fpm.conf)

www-data   834   759  0 Sep03 ?        00:00:03 php-fpm: pool www
www-data   835   759  0 Sep03 ?        00:00:05 php-fpm: pool www
root      8843  8831  0 15:58 pts/0    00:00:00 grep --color=auto php
www-data 19731   759  0 Sep04 ?        00:00:00 php-fpm: pool www

1 个答案:

答案 0 :(得分:3)

以此更改所有权,就像魅力一样

sudo chown -R www-data:www-data /var/www/domain_name.com/html/
sudo systemctl reload nginx