Learn how to increase the maximum upload filesize on PHPMyAdmin in Plesk.

How to increase maximum upload filesize on PHPMyAdmin for Plesk

Yeah well, sometimes we are too lazy to manipulate database information on the server through the command line, so we can just use a graphical user interface. PHPMyAdmin is without a doubt the best tool for this, as it allow us to see all the databases available on the server (as long as we have access to them), modify their structure, tables etc. One of those useful features, is the possibility to import a database from a .sql,.zip from your computer via web. The problem is basically, when you have large database backups whose size is higher than 2MB, because that's the limit imposed on the php.ini configuration used by plesk:

PHPMyAdmin Plesk 2MB Upload File Limit

In this article, we will show you how to increase the maximum upload file size globally for Plesk (including PHPMyAdmin).

1. Edit Plesk Admin php.ini

On PHP, the solution for this problem is to simply adjust the configuration properties of post_max_size and upload_max_filesize in the php.ini file. In Plesk, the used configuration file is located at /usr/local/psa/admin/conf/php.ini. You are free to modify this file as you want, you can use a terminal based text editor or download the file via SFTP and upload it later.

In our case, we will edit it using nano in our terminal:

nano /usr/local/psa/admin/conf/php.ini

Then, register the new properties on the file in case they doesn't exist already with the new values that you want, in our case we will set both with 64MB:

post_max_size=64M
upload_max_filesize=64M

In the terminal our file will look like:

Putty Update Max Upload Filesize PHP.ini on Plesk

Save the changes to the file and proceed with the next step.

2. Restart Plesk Web Server

Finally, to make the changes take effect, you will need to restart the plesk web server running the following command:

/etc/init.d/psa restart

It shouldn't take so long and you will be able to check immediately the new max allowed upload file size:

PHPMyAdmin Max FileUploadSize Plesk

Happy coding !


Senior Software Engineer at Software Medico. Interested in programming since he was 14 years old, Carlos is a self-taught programmer and founder and author of most of the articles at Our Code World.

Sponsors