"Update mislukt: De update kan niet worden geïnstalleerd omdat sommige bestanden niet konden worden gekopieerd"

AI-generated summary

haydenjames encountered an update error for the WP-Discourse plugin: “Update failed: The update cannot be installed because some files could not be copied,” typically linked to file permissions. Despite confirming permissions and ownership matched other plugins, the issue persisted. angus noted this is usually a server setup issue, not plugin-specific, and linked to a DigitalOcean article on WordPress plugin permission problems. haydenjames resolved it by deleting and reinstalling the plugin via wp-admin, suggesting it may have been a temporary glitch. Jagster proposed ownership changes (e.g., chown -R www-data:www-data) as a common fix, but haydenjames confirmed ownership and permissions were already correct. Jagster speculated about security plugins, Fail2ban, or plugin origin issues, and suggested WP-CLI for more detailed error logs. haydenjames verified directory permissions with ls -lR and found no anomalies. The consensus leans toward a transient system or plugin-state issue rather than misconfigured permissions.

Got this error on WP-Discourse latest update:

Update failed: The update cannot be installed because some files could not be copied. This is usually due to inconsistent file permissions.

I updated 3 other plugins without issue. Only this plugin gave the error:

Have not made any permission changes, period. (other plugins updated without issue) Any ideas?

Navigating to /wp-content/plugins/ and /wp-content/plugins/wp-discourse/, all the file and dir permissions/ownership are identical to all other plugins.

Edit: Just deleting the plugin and reinstalling it via wp-admin fixed the issue. Hopefully nothing is screwed up. Not been smooth sailing with this plugin yet.

Hey @haydenjames,

While I understand you didn’t experience the issue in other updates, this error is not to do with the plugin. It’s concerned with your server setup. You can read more about it here

Thanks. I didn’t have to make any changes to the server setup. Just deactivated, deleted, and reinstalled via wp-admin UI. So probably a glitch. thanks!

That happens quite often because owner of directories under Wordpress has been changed to root. If that’s true then chown -R www-data:www-data /var/www/public_html or similar depending of distro and paths helps.

Yup, checked that before posting. chown was correct and recursively correct. both ownership and permissions.

thanks

Yeah, in the most of cases poor admin sees that issue every time when month has changed and tries upload media.

I’ve got same error with other plugins, but not recently. But I can’t remember what was the issue then — but I have very weak memory image of badly behaving origin of plugin. Or I did some funny things with geo-ip and/or blocking IPs.

Do you use any security plugins? Or Fail2ban?

WP-CLI could give a bit more informative error. Or not.

ls -lR wp-discourse/
…came back correctly.