How to increase file upload size

Nginx | CentOS 7
To locate your global php.ini file
php -i | grep “Loaded Configuration File”
Once you have located your global php.ini file, using your favorite editor
 sudo vi /etc/location of php.ini 

Locate and update the following lines within the global php.ini file

 post_max_size = 128M
 upload_max_filesize = 128M
After you have updated your php.ini file, you should restart php. In my example, I restarted the service php-fpm. Click the link for some tips on restarting php.
In your Nginx vhost file add the following into your server block
/etc/nginx/sites-available/yoursite.com
 client_max_body_size 128m; 
Restart nginx safely
 nginx -s reload 

Custom Server Builds

Your Linux version of choice with Apache or Nginx.
Portfolio | Our Team | Home

Server Builds & Managment | Website Development | Technical Project Management

Copyright Ally Drez, L.L.C. 2018

Payments