I\'m using WordPress on centos 6.
I try to install a plugin. But I got this error:
Installing Plugin: bbPress 2.5.9 Downloading install package
CentOS7 or Ubuntu 16
WordPress uses ftp
to install themes and plugins.
So the ftpd
should have been configured to create-directory
vim /etc/pure-ftpd.confg
and if it is no then should be yes
# Are anonymous users allowed to create new directories?
AnonymousCanCreateDirs yes
lastly
sudo systemctl restart pure-ftpd
Maybe there is an ownership issue with the parent directories. Find the Web Server user name and group name if it is Apache Web Server
apachectl -S
it will print
...
...
User: name="apache" id=997
Group: name="apache" id=1000
on Ubuntu it is
User: name="www-data" id=33 not_used
Group: name="www-data" id=33 not_used
then
sudo chown -R apache:apache directory-name
Sometimes it is because of directories permissions. So try
sudo chmod -R 755 directory-name
in some cases 755
does not work. (It should & I do not no why) so try
sudo chmod -R 777 directory-name
Maybe it is because of php safe mode. So turn it off in the root of your domain
vim php.ini
then add
safe_mode = Off
NOTE:
For not entering FTP username and password each time installing a theme we can configure WordPress to use it directly by adding
define('FS_METHOD','direct');
to the wp-config.php file.