Not Able to Upload a File to Patient's Documents if its Size is Larger than 2MB

Title tells pretty much the entire story.

I was working with a scanned Lab Report that is quite long, and after scanning to PDF the resulting file ended up being larger than most.

As I was trying to upload it to patient’s document folder I was given a rude awakening in the form of the following message:
Error number: 1 occurred while uploading file named [my filename goes here]
The system does not permit uploading files of with size 0.

With some trial-and-error testing I realized that anything under 2MB uploads just fine, and anything just north of 2MB mark results in the error message and failed upload.

So the obvious question is: how do I increase that limit?
Also, are there any issues that would make me stay with the current 2MB limit (I can always either rescan new files at lower res or higher compression, or process old scans to shrink their size footprint)

Oh well… after posting I have found the solution in the FAQ document

So just in case that another user is looking for a quick fix.

Log in to your server with admin privileges, start terminal, and enter the following:
$ sudo [yourFavoriteTextEditorHere] /etc/php/7.2/apache2/php.ini

Note that your versions, and therefore file locations, may differ.

Than look right here: [https://www.open-emr.org/wiki/index.php/FAQ#What_are_the_correct_PHP_settings_.28can_be_found_in_the_php.ini_file.29.3F](http://FAQ section on Correct PHP Settings)
Find the appropriate settings in the php.ini and adjust accordingly.

Save the updated php.ini

Restart Apache
$ sudo /etc/init.d/apache2 restart

2 Likes