Home  >  Article  >  How to solve 414request

How to solve 414request

anonymity
anonymityOriginal
2019-05-08 10:51:2311209browse

What does 414 mean?

The Get method was used during the request. Because the spliced ​​URL was too long and exceeded the server limit, a "414 request-uri too large" error occurred.

How to solve 414request

The HTTP protocol does not place any a priori limit on the length of a URI. Servers MUST be able to handle the URI of any resource they serve, and SHOULD be able to handle URIs of unbounded length if they provide GET-based forms that could generate such URIs. A server SHOULD return 414 (Request-URI Too Long) status if a URI is longer than the server can handle (see section 10.4.15).

Note: Servers ought to be cautious about depending on URI lengths above 255 bytes, because some older client or proxy implementations might not properly support these lengths.

Solution:

1. nginx server modification

Modify the following parameters in nginx.conf of nginx:

 client_header_buffer_size 512k;
 large_client_header_buffers 4 512k;

2. Tomcat server modification

In Apache’s httpd.conf (path: Apache\conf) configuration file (just add it directly)

Pay attention to the position when adding

How to solve 414request

LimitRequestLine 40940
LimitRequestFieldSize 40940
Problem solved.

The above is the detailed content of How to solve 414request. For more information, please follow other related articles on the PHP Chinese website!

Statement:
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn