Upgrade WordPress permissions error message: cannot create directory copy file installation failed requires ftp

upgradeWordPressPermission error message:

Failed to create directory copy file installation failed requires ftp

We just installed WordPress, orWordPress site move for spaceAfter that, want to upgradeWordPress plugin, programs, or topics, these common problems are often encountered:

  1. Error: wordpress upgrade failed to create directory.installation failed
  2. vsftpd cannot create directory
  3. wordpress cannot install theme
  4. Updating translations for wordpress en_cn Failed to create table of contents
  5. wordpress installation failed unable to copy files
  6. wordpress cannot copy file
  7. wordpress update permissions
  8. wordpress theme installation failed unable to copy files
  9. Installation failed Failed to find wordpress content directory wp content
  10. To perform the requested action, WordPress needs permission to access your web server.Please enter your FTP login credentials to continue.If you forget your login credentials (eg username, password), please contact your web host.

The reason why WordPress will have the above problems is usually caused by incorrect permission settings:

  • FTP users have permissions, but Web users do not necessarily have permissions.

It is not recommended to set 777 permissions

For example: WordPress installation plugin prompts "Cannot create directory", which is caused by directory permission settings.

Under normal circumstances, you can directly set 777 permissions to these directories ▼

  1. / wp-content / plugins
  2. / Wp-content / themes
  3. / wp-content / uploads
  4. /wp-content/upgrade

However, this will cause the server configuration to be insecure. Once the website is invaded, it is very unfavorable.SEOranking, so it is not recommended that you do this.

Chen WeiliangI suggest you use the following better solution.

SSH set 775 permissions

If you are using a VPS, these directories The default owner is root,The FTP used is vsftpd,The server is Apache2.

These conditions mainly restrict the default user group names.

如果LinuxDepending on the installed system, the user group names may need to be adjusted.

The following is the SSH setting 775 permission process ▼

Step 1:login SSH

Step 2:Go to the /wp-content/ directory ▼

cd /home/admin/web/你的域名文件夹/public_html/wp-content/

Step 3: Set 755 permissions to these directories, that is, only the owner has permission to write ▼

chmod -R 755 plugins/
chmod -R 755 themes/
chmod -R 755 uploads/
chmod -R 755 upgrade/

VestaCPChange folder permissions

If youInstall the VestaCP panel, to quickly modify the permissions of the WordPress website directory, you can use the following commands ▼

chown -R admin:admin /home/admin/web/你的域名文件夹/public_html/*

CWP Control PanelSet 755 permissions

If your VPS is installed with the CWP control panel, please log in directly to the background of the CWP control panel to set permissions.

Step 1:Go to Fix Permissions page

  • CWP menu –> User Accounts –> Fix Permissions (fix permissions and select user)

Step 2:Choose your user ▼

After the WordPress website is moved, the front page of the front page is blank and the back end is blank, what should I do?

Step 3:Click Fix Account Permissions ▲

  • CWP control panel setting 755 permissions is really simple and fast ^_^

Virtual host setting permissions

If you are using a virtual host, not a VPS, then the above setting method does not apply.

Please add the following code to the wp-config.php file in the root directory of your WordPress website ▼

define("FS_METHOD","direct");
define("FS_CHMOD_DIR", 0755);
define("FS_CHMOD_FILE", 0755);

Basically doing this will make your WordPress program both more secure and able to upgrade.

In order to do wellInternet marketingtasks, you can now start testing installations and upgrades, variousWeb PromotionPlugin ^_^

Hope Chen Weiliang Blog ( https://www.chenweiliang.com/ ) shared "Upgrade WordPress permissions error prompt: unable to create directory copy file installation failed requires ftp", which is helpful to you.

Welcome to share the link of this article:https://www.chenweiliang.com/cwl-666.html

Welcome to the Telegram channel of Chen Weiliang's blog to get the latest updates!

🔔 Be the first to get the valuable "ChatGPT Content Marketing AI Tool Usage Guide" in the channel top directory! 🌟
📚 This guide contains huge value, 🌟This is a rare opportunity, don’t miss it! ⏰⌛💨
Share and like if you like!
Your sharing and likes are our continuous motivation!

 

Comment

Your email address will not be published. Required fields * Callout

scroll to top