Welcome! Log In Create A New Profile

Advanced

download in nginx

Posted by wellington09 
download in nginx
September 14, 2011 08:35AM
When trying to upload to the server nginx it shows me the following error

Request Entity Too Large (413)

so I had to go in the /opt/nginx/conf/nginx.conf and add the following line in order to upload the file

client_max_body_size 10M; upload # Maximum size

The file now is inside the folder of my app /home/app/uploads/Manual.pdf

The nginx is giving me a headache when it comes to download the file (Manual.pdf 6MEGA BYTE )
By downloading this file, it shows that the file has a size 0 and trying to open this file with Adobe Acrobat it shows the following error

Unable to open the document

Is not supported file type text-only document (text / plain)





Observation:
if I leave the uploads folder inside the public folder system, you download the file and it opens Mega 6 normal, only then I lose security and let users pick up all the files, because they be published now.
In WEBrick no longer have this problem, but in nginx in production I am having.
I think some setting in nginx.conf missing and not in my application.
someone can give a little help ?
Sorry, only registered users may post in this forum.

Click here to login

Online Users

Guests: 252
Record Number of Users: 8 on April 13, 2023
Record Number of Guests: 421 on December 02, 2018
Powered by nginx      Powered by FreeBSD      PHP Powered      Powered by MariaDB      ipv6 ready