R
R
Radren2015-09-23 10:51:26
Django
Radren, 2015-09-23 10:51:26

Why is nginx returning 414 Request-URI Too Large?

The Django-UWSGI-Nginx bundle is installed on the server. Sometimes you have to process GET requests in which the number of characters is ~ 40000 pieces.
For such requests, Nginx returns 414 Request-URI Too Large. I added a line to the server settings large_client_header_buffers 4 6000k
It seems like it should be enough. But no, I started getting an error 400 (Bad Request), which, according to the Nginx documentation, means "the request header field exceeds the size of one buffer."
Can you please tell me what needs to be adjusted so that the problem disappears?

Answer the question

In order to leave comments, you need to log in

4 answer(s)
R
Radren, 2015-09-23
@Radren

Convert GET request to POST request.

Z
zigen, 2015-09-23
@zigen

You set the buffer size in Kilobytes, and measure the length of the string in the query in the number of characters.

V
Vlad Zhivotnev, 2015-09-23
@inkvizitor68sl

Place the setting in the http {} section.
And with such questions, it is better to apply configs so as not to play telepathy.

J
jsse, 2015-09-23
@jsse

400 Bad Request - The server encountered a syntax error in the client's request. Appeared in HTTP / 1.0 as Radren
wrote above , it is better to remake it in post

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question