Increase upload_max_filesize and post_max_size to 200M

Posted March 23, 2017 2.4k views

Hy i want to increase uploadmaxfilesize and postmaxsize to 200M. I’ve tried to set in php.ini (etc/php5/apache2/php.ini) this two values, i’ve restart apache with the command sudo service apache2 restart, but i don’t upload file exceed 8M, some suggestion?


These answers are provided by our Community. If you find them useful, show some love by clicking the heart. If you run into issues leave a comment, or add your own answer to help others.

2 answers


If the standard location for php.ini isn’t working, one quick way to find which php.ini is being loaded is by creating a temporary file named info.php and within it, place:

<?php phpinfo();

Save and the browse to that file using your browser of choice. You’ll want to modify the php.ini that is showing as Loaded Configuration File. For me, that’s the sixth row from the top.

Once you’ve located the correct file, delete the info.php file, make the changes needed to php.ini and then restart Apache once again.

Submit an Answer