WordPress Update – This is usually due to inconsistent file permissions.: wp-admin/includes/update-core.php

I solved this by making the webserver user the owner and the group of all the files in the WordPress directory.

I figured out the webserver user was daemon with:

ps aux | egrep '(apache|httpd)'

Then I changed the permissions with:

sudo chown -R daemon:daemon /your-path-to-wordpress