Increase max upload file size PHPMyAdmin - cPanel / WHM

There is a Mobile Optimized version of this page (AMP). Open Mobile Version.

on cPanel / WHM servers for some reason PHPMyAdmin has a ridiculously low upload_max_filesize setting of usually 50MB, this makes PHPMyAdmin useless for large SQL imports, especially with systems such as Magento where databases can be 900MB+. Fortunately you can increase this limit to something more useful, to be able to do this though you will need to have root access to your WHM server, either root FTP or SSH.  

Increasing PHPMyAdmin's upload_max_filesize with SSH

Login to your SSH using PuttY and follow these commands: CD to the directory which holds the php.ini file:

cd /usr/local/cpanel/3rdparty/etc/
Edit the php.ini file in nano (or use your preferred editor if you have one):
nano php.ini
Find and change the below values in the file, you can use CTRL + W to find each line:
post_max_size = 950M upload_max_filesize = 950M memory_limit = 558M
With nano you can save your changes by holding CTRL + O and press ENTER. Hold CTRL + X   You need to restart cPanel service using:
service cpanel restart
PHPMyAdmin should now have a much higher upload limit, play with the above values if you need more!  

Increasing PHPMyAdmin's upload_max_filesize with FTP

Login to your FTP server as root using your preferred FTP client and navigate to this directory:

/usr/local/cpanel/3rdparty/etc/
Edit the php.ini file and change the below values in the file:
post_max_size = 950M upload_max_filesize = 950M memory_limit = 558M
save the file and restart the server, or if you can enter SSH restart cPanel service using:
service cpanel restart
PHPMyAdmin should now have a much higher upload limit, play with the above values if you need more!

Author: Dean Williams

I'm a Web Developer, Graphics Designer and Gamer, this is my personal site which provides PHP programming advice, hints and tips