This file exceeds the maximum upload size for this site

This is related to the WordPress error you may get when trying to upload a file greater than 2MB:

While you can install plugins to get around this I found this did not work for me and I then got the error:

My install of WordPress or more specifically PHP follows the instructions in CentOS 7 + PHP 7.2 + Python 3.6 + Apache 2.4 so in this case I needed to update the php.ini.

My php.ini file was at

/etc/opt/rh/rh-php73/php.ini

Change the “upload_max_filesize” to say 10MB:

; Maximum allowed size for uploaded files.
; http://php.net/upload-max-filesize
upload_max_filesize = 10M

Then, since I am using fpm, you need to restart that:

systemctl restart rh-php73-php-fpm.service