Вопрос

I have used Elmah ,log4net and nlog for logging exceptions.

I m curious how I can catch exceptions for any applications of websites that runs under same IIS.

Do i need to develop and IIS Module and bind it?

Not sure, how can i catch exceptions that happens in any apps within IIS?

I m interested in intercepting the exceptions and such to log myself.

Это было полезно?

Решение 2

I have never tried but whats stopping you from adding elmah to machine config?

This solution should suitable for you check it http://www.christiaanverwijs.nl/post/2012/06/27/NET-HttpModule-to-log-all-unhandled-exceptions-in-IIS-75-through-Log4NET-(globally-or-per-site).aspx

Другие советы

You can do that via IIS configuration. Check detailed description here http://technet.microsoft.com/en-us/library/cc725786%28v=ws.10%29.aspx

Лицензировано под: CC-BY-SA с атрибуция
Не связан с StackOverflow
scroll top