简体   繁体   中英

installation failed: could not create directory in wordpress nginx on ubuntu

I setup wordpress with the help of this tutorial... how to install wordpress with LEMP on ubuntu 18.04 when I tried to install theme or plugins the error message shown like this

Installation failed: Could not create directory

I tried also to give permission with this:

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 {} \;

I checked by this

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

and with this

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

changing ownership with this it works like charm

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

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