5
Answers

.Net core 2.0 publish

Hi,
 
I have a code in .net core 2.0. it's working fine on local. but when i host on IIS. It's throw an error.
 
Bad Request - Request Too Long
HTTP Error 400. The size of the request headers is too long.
 
on every click
Answers (5)
0
Nitin Bhardwaj

Nitin Bhardwaj

NA 15.5k 6.2m 7y
Still remaining 
0
Nilesh Patil

Nilesh Patil

NA 3.4k 6.9k 7y
Hi,
 
Clear all browsing data :-
  • Clear browsing 
  • historyClear download history
  • Empty the cache
  • Delete cookies and other site data
0
Nitin Bhardwaj

Nitin Bhardwaj

NA 15.5k 6.2m 7y
I have already try it.
0
Nilesh Patil

Nilesh Patil

NA 3.4k 6.9k 7y
Hello,
 
Refer this links hope it will helps you
 
https://stackoverflow.com/questions/37112367/size-of-the-request-headers-is-too-long 
 
http://timourrashed.com/how-to-fix-the-400-bad-request-error-message-from-a-website/ 
-1
Rajkiran Swain

Rajkiran Swain

NA 33.9k 373.2k 7y
Have you tried clearing your cookies within your browser?
 
It could be possible that you have an overly large number of cookies being stored that will be added to any and all requests made within your browser. This can sometimes lead to issues like this. Additionally, you could try running your application within a different browser to see if that affects anything.
 
As an alternate solution, you could consider increasing the size of the MaxRequestLength as mentioned in this article or within your web.config as seen below using :
 
<configuration> <system.web> <httpRuntime maxRequestLength="1048576" /> </system.web> </configuration>
 
and :
 
<system.webServer> <security> <requestFiltering> <requestLimits maxAllowedContentLength="1073741824" /> </requestFiltering> </security> </system.webServer>