How to Increase the MySQL Database Upload Size in PhpMyAdmin on a cPanel Server?
The cPanel server restricts the number of databases that can be transferred to PhpMyAdmin. The limit is constrained to 50MB by default. In this case, uploading a sizable database to PhpMyAdmin will be extremely challenging. To conceal this, we can increase the database file submission size in PhpMyAdmin. You will need to modify some values in the server’s WHM to accomplish this. Let’s examine how to increase the import file size in PhpMyAdmin in this tutorial.
- Login to the WHM of your server by accessing the link https://yourIPaddress:2087 or https://yourserverhostname:2087
- Navigate to “Server Configuration”.
- Select “Tweak Settings” from it.
- Navigate to PHP in Tweak settings.
Here you can see cPanel max POST size and cPanel max upload size values, change the values according to your preferred and save it. Now login to your PhpMyAdmin and verify the values, there you can see the value will be replaced with the changed one.
You can perform the same procedure via the CLI also.
- Login to your server via SSH.
# ssh root@IPaddress
- Execute the following command, which will display the default PHP ini file of your server.
# php –ini
- Open it with your favorite text editor.
# vi path_to_php.ini (Replace this with the original file path)
- Search for the upload and post. There you can see entries like the following.
upload_max_filesize = 500M
post_max_size = 400M
Change both the values with your preferred value.
- Finally, restart the apache service.
# service httpd restart or
# systemctl restart httpd
Thus we have learned how to increase the upload size in PhpMyAdmin.