After .net core is deployed to IIS, after a while 502

my website worked normally for a period of time after it was released, but after a period of time, there were 502 visits, and all visits were 502. Only after restarting the IIS application pool can I access it properly. But the same problem will arise after a while.


502 Bad Gateway
means that 500 errors have occurred in the application behind the gateway. So what you need to do is to find out exactly what the 500 error is, and look at the error message and the stack. Depending on how you handle exceptions, error messages may be in your application log, or in Windows events, find out for yourself.

The question of

PS: seems to have nothing to do with MongoDB, and the label is not quite right.

Menu