Symptoms
- Unable to log in to Plesk: Plesk login page is returned in a browser without any errors or warnings.
- When uploading a file via Plesk File Manager, one of the following error messages appears:
The file "picture.jpg" is too big. Try to upload this file via FTP.
No upload response
- Cannot upload files in applications, e.g WordPress, Joomla, etc:
The uploaded file exceeds the upload_max_filesize directive in php.ini
- Extension update fails, e.g Joomla:
An error has occurred uploading this file to the server.
The maximum allowed size of PHP to upload files is too low: This is configured from the PHP directives 'upload_max_filesize' and 'post_max_size' (locatable and configurable in your file 'php.ini' or '.htaccess').
Unable to find the installation package
- In some cases, the following error messages might appear in /usr/local/psa/admin/logs/panel.log:
PHP Warning: POST Content-Length of 90378782 bytes exceeds the limit of 67108864 bytes in Unknown on line 0
ERR (3) [panel]: Forgery protection token check failed.
ERR (3) [panel]: Permission denied.#0
Cause
Low values of directives post_max_size and upload_max_filesize are specified either in Plesk php.ini or in the domain settings.
Resolution
Server-wide
1.Connect to the Plesk server via SSH.
2.the file /usr/local/psa/admin/conf/php.ini in a text editor and specify limits for post_max_size and upload_max_file size in bytes.
Note: The default value is 2147483647 (2GB):
#egrep 'post_max_size|upload_max_filesize' /usr/local/psa/admin/conf/php.ini
post_max_size = 2147483647
upload_max_filesize = 2147483647
3.Restart the psa service:
#service psa restart
4.out from Plesk and log in again to apply the changes.
For a specific domain
.Log in to Plesk.
2.Go to Domains > example.com > PHP Settings.
3.Adjust upload_max_filesize and post_max_size values:
(https://pix.cobrasoft.org/images/2024/07/24/mceclip011.png)
4.Click OK to apply the changes.