在 Cent OS VPS 上运行的 wordpress 中的权限 - 无法更新 theme/plugin/wordpress

Permissions in wordpress running on Cent OS VPS - unable to update theme/plugin/wordpress

我在 Cent OS powered VPS 上运行 wordpress 4.0。安装运行顺利,在我的管理仪表板中我看到 wordpress/plugins/themes 的更新。当我尝试从 dasboard

升级它们时遇到以下错误

正在将 Wordpress 从 4.0 更新到 4.1

Update WordPress

Downloading update from https://downloads.wordpress.org/release/wordpress-4.1-new-bundled.zip…

Unpacking the update…

Could not create directory.

Installation Failed

正在更新插件

Update Plugin

Downloading update from https://downloads.wordpress.org/plugin/google-sitemap-plugin.2.9.5.zip…

Unpacking the update…

Could not create directory.

正在更新主题

Updating Theme Twenty Fourteen (1/1)

Downloading update from https://downloads.wordpress.org/theme/twentyfourteen.1.3.zip…
Unpacking the update…

An error occurred while updating Twenty Fourteen: Could not create directory.

All updates have been completed.

我知道我弄乱了文件权限,我也尝试过设置文件的权限。我尝试将它们分配给各种 groups/users,例如 apache、root 和 nginx。

这些是我的 wordpress 目录的当前文件权限。

-rwxr-xr-x  1 apache apache  3070 Jan  2 10:59 wp-config.php
drwxr-xr-x 12 apache apache  4096 Jan  1 23:31 wp-includes
drwxrwxrwx  6 apache apache  4096 Jan  1 22:37 wp-content
drwxr-xr-x  9 apache apache  4096 Jan  1 22:31 wp-admin
-rwxr-xr-x  1 apache apache   435 Jan  1 22:25 index.php
-rwxr-xr-x  1 apache apache 19930 Jan  1 22:25 license.txt
-rwxr-xr-x  1 apache apache  7290 Jan  1 22:25 readme.html
-rwxr-xr-x  1 apache apache  3824 Jan  1 22:25 sitemap.backup.xml
-rwxr-xr-x  1 apache apache  5082 Jan  1 22:25 wp-activate.php
-rwxr-xr-x  1 apache apache   289 Jan  1 22:25 wp-blog-header.php
-rwxr-xr-x  1 apache apache  5110 Jan  1 22:25 wp-comments-post.php
-rwxr-xr-x  1 apache apache  2826 Jan  1 22:25 wp-config-sample.php
-rwxr-xr-x  1 apache apache  3071 Jan  1 22:25 wp-cron.php
-rwxr-xr-x  1 apache apache  2460 Jan  1 22:25 wp-links-opml.php
-rwxr-xr-x  1 apache apache  2787 Jan  1 22:25 wp-load.php
-rwxr-xr-x  1 apache apache 34185 Jan  1 22:25 wp-login.php
-rwxr-xr-x  1 apache apache  8512 Jan  1 22:25 wp-mail.php
-rwxr-xr-x  1 apache apache 11489 Jan  1 22:25 wp-settings.php
-rwxr-xr-x  1 apache apache 27005 Jan  1 22:25 wp-signup.php
-rwxr-xr-x  1 apache apache  4153 Jan  1 22:25 wp-trackback.php
-rwxr-xr-x  1 apache apache  3132 Jan  1 22:25 xmlrpc.php

请指导我获得合适的权限。

遇到同样的问题...您是否尝试过禁用所有插件?您也可以尝试将权限更改为 777