Questions tagged [elmah]

ELMAH (Error Logging Modules and Handlers) is an application-wide error logging facility for ASP.NET that is completely pluggable.

ELMAH (Error Logging Modules and Handlers) is an application-wide error logging facility that is completely pluggable. It can be dynamically added to a running ASP.NET web application, or even all ASP.NET web applications on a machine, without any need for re-compilation or re-deployment.

To learn more about ELMAH, see the MSDN article “Using HTTP Modules and Handlers to Create Pluggable ASP.NET Components” by Scott Mitchell and Atif Aziz.

Installing ELMAH can most easily be done using its NuGet package:

Install-Package elmah
968 questions
21
votes
4 answers

Elmah log files deletion, manually or is there a setting?

How do I delete the log files that Elmah generates on the server? Is there a setting within Elmah that I can use to delete log files? I would prefer to specify some criteria (e.g. log files that are older than 30 days). Or should I write my own…
danielovich
  • 9,217
  • 7
  • 26
  • 28
19
votes
2 answers

Elmah reporting unwanted 404 errors

I am using Elmah for logging in a ASP.NET MVC project and I am recieving lots of 404 errors for a path /prx2.php which in turn is passing a hash as a querystring param. I assume this is a scanner trying to find vulnerabilities. Because I am not…
Rippo
  • 22,117
  • 14
  • 78
  • 117
19
votes
2 answers

Elmah.MVC vs. Elmah.contrib.Mvc

I'm new to ASP.NET MVC and I'm looking for the least painful way to get global error handling, logging, and reporting (via email) set up. FYI, my ASP.NET MVC app is being hosted as a web role in Azure, but I'm trying to avoid using any…
Bob.at.Indigo.Health
  • 11,023
  • 13
  • 64
  • 111
18
votes
1 answer

ELMAH on ASP.NET vNext?

Is it possible to configure ELMAH with ASP.NET vNext? If so, how? I am lost as to where even start, given there's not even a web.config anymore. If anyone has or can figure it out, please share with us. Thank you
georgiosd
  • 3,038
  • 3
  • 39
  • 51
18
votes
2 answers

Why would one use ELMAH if the application is using NLog

I have to write a centralized logging framework. Basic requirements are: Log exceptions as well as other details if needed to SQL Server DB. If DB is down i.e. a failover option is to log to a file and email I had done some reading around and…
gbs
  • 7,196
  • 5
  • 43
  • 69
18
votes
1 answer

Elmah vs Elmah.MVC Nuget Package - Which to use & why?

I have Code First MVC 4 application. I tried installing the NuGet package for logging Elmah - and everything seemed to work fine - Errors were reported fine at http://myapp/elmah.axd I then noticed there was an Elmah.MVC package - so i removed the…
niico
  • 11,206
  • 23
  • 78
  • 161
18
votes
1 answer

Deploy PDBs on an Azure Web Role

I have a project that is deployed via a VS 2012 Azure Project (from right in VS, not manually). The web role project is set to build "pdb-only" Debug Info in release mode, but when deploying the PDBs are not packaged and copied to the web role VM…
pbristow
  • 1,997
  • 4
  • 26
  • 46
17
votes
1 answer

Programmatically Logging Errors With Elmah : Logging specific information

I am logging error with Elmah inside a try-catch block. here is the code; try { DateTime.Parse("poo"); } catch (Exception err) { Elmah.ErrorSignal.FromCurrentContext().Raise(err); } I would like to log some specific info like some…
tugberk
  • 57,477
  • 67
  • 243
  • 335
17
votes
4 answers

ASP.NET MVC - Elmah not working and returning 404 page for elmah.axd

I'm trying to use elmah for my MVC application and I've followed the steps on the wiki: http://code.google.com/p/elmah/wiki/MVC , but even so when trying to access myapp/elmah.axd the page: 404 - File or directory not found. Anyone could help me…
zanona
  • 12,345
  • 25
  • 86
  • 141
17
votes
1 answer

How can I mock Elmah's ErrorSignal routine?

We're using ELMAH for handling errors in our ASP.Net MVC c# application and in our caught exceptions, we're doing something like this: ErrorSignal.FromCurrentContext().Raise(exception); but when I try to unit test the caught exceptions, I get this…
Chris Conway
  • 16,269
  • 23
  • 96
  • 113
16
votes
3 answers

In ELMAH with MVC 3, How can I hide sensitive form data from the error log?

Here is the scenario... User types his username. Types an "incorrect" password. Both username and password values are being passed to the Elmah error log via the Exception.Context.Request.Form["Password"]. It's a read-only value and cannot be…
willis
  • 321
  • 3
  • 5
16
votes
2 answers

ELMAH log how to ignore error by type

Hello I have setup ELMAH in my project, but I am getting a lot errors like System.Web.HttpException: A potentially dangerous Request.Path value was detected from the client (:). Generated: Sun, 26 May 2013 21:46:30 GMT System.Web.HttpException…
Arbejdsglæde
  • 13,670
  • 26
  • 78
  • 144
16
votes
1 answer

ELMAH Logging in SQL Server

I am having an ELMAH problem. I think it is the connection string but can't figure out why. It is emailing me errors no problem, just not logging them into sql. If the problem is permissions, how would I catch an error to show me its a permission…
Ethan Schofer
  • 1,718
  • 5
  • 26
  • 55
16
votes
2 answers

How do I secure Elmah on ASP.Net MVC 4 with Windows Integrated Security : Elmah ignores my settings

I've added elmah to an asp.net mvc 4 application. Logging is working and now I am trying to configure security but elmah is not picking up the settings and the logs remain visible by all users. This is an intranet app and as such we are using…
Twisted
  • 2,939
  • 4
  • 32
  • 54
16
votes
1 answer

How to configure ELMAH with SignalR

I'm using SignalR hub in my MVC4 application. I added ELMAH to handle all errors. the problem is that errors which happen in the Hub are not being logged in ELMAH axd. Is there a way to configure it?
Haddar Macdasi
  • 3,477
  • 8
  • 37
  • 59
1 2
3
64 65