An event log is a file used to record a timeline of events along with contextual metadata
Questions tagged [event-log]
1270 questions
211
votes
5 answers
Write to Windows Application Event Log without event source registration
Is there a way to write to this event log:
Or at least, some other Windows default log, where I don't have to register an event source?

Jerther
- 5,558
- 8
- 40
- 59
199
votes
23 answers
System.Security.SecurityException when writing to Event Log
I’m working on trying to port an ASP.NET app from Server 2003 (and IIS6) to Server 2008 (IIS7).
When I try and visit the page on the browser I get this:
Server Error in ‘/’ Application.
Security Exception
Description: The application attempted to…

encee
- 4,544
- 4
- 33
- 35
186
votes
9 answers
How to create Windows EventLog source from command line?
I'm creating an ASP.NET application that will log some stuff to Windows EventLog. To do this an event source has to be created first. This requires administrative priviledges so I cannot do it in the ASP.NET app.
Is there an existing command-line…

Vilx-
- 104,512
- 87
- 279
- 422
135
votes
11 answers
The source was not found, but some or all event logs could not be searched
I am getting the following exception. I have given full control to Asp.net account on Eventlogs in Registry edit.
[SecurityException: The source was not found, but some or all event
logs could not be searched. Inaccessible logs:…

Vaibhav Jain
- 33,887
- 46
- 110
- 163
98
votes
9 answers
The source was not found, but some or all event logs could not be searched. Inaccessible logs: Security
I am getting error:
The source was not found, but some or all event logs could not be
searched. Inaccessible logs: Security
When I run below code to capture errors on Win 2K12 R2 server IIS 8.5
EventLog elog = new…

user1480864
- 1,455
- 3
- 16
- 23
86
votes
8 answers
System.Security.SecurityException: The source was not found, but some or all event logs could not be searched. Inaccessible logs: Security
I am trying to create a Windows Service, but when I try and install it, it rolls back giving me this error:
System.Security.SecurityException: The
source was not found, but some or all
event logs could not be searched.
Inaccessible logs:…

michelle
- 2,759
- 4
- 31
- 46
78
votes
12 answers
Description for event id from source cannot be found
When I write a log into windows event log, I get the event below, what's the root cause of this message, and how can I fix it? Many Thanks
The description for Event ID 51001
from source RRWS cannot be found.
Either the component that raises…

Ji Yalin
- 1,180
- 2
- 9
- 14
64
votes
3 answers
How do you create an event log source using WiX
I'm creating an installer for a website that uses a custom event log source. I would like our WiX based installer to create that event log source during installation.
Does anyone know the best way to do this using the WiX framework.

Edward Wilde
- 25,967
- 8
- 55
- 64
56
votes
3 answers
c# writing to the event viewer
I'm trying to write to the event viewer in my c# code, but I'm getting the wonderful "Object reference not set to an instance of an object" message. I'd appreciate some help with this code, either what's wrong with it or even a better way to do it.…

PushCode
- 3,077
- 4
- 25
- 26
51
votes
5 answers
What event id to use for my custom event log entries?
Is there any ranges of valid event IDs which should be used by custom applications while logging to Windows EventLog? Or I can use any event ID of my choice (1,2,3,4....).
P.S, I am developing in C#.NET.

Niran
- 1,106
- 1
- 8
- 10
48
votes
4 answers
Deleting Custom Event Log Source Without Using Code
I have an application that has created a number of custom event log sources to help filter its output. How can I delete the custom sources from the machine WITHOUT writing any code as running a quick program using System.Diagnostics.EventLog.Delete…

Wolfwyrd
- 15,716
- 5
- 47
- 67
42
votes
10 answers
How to determine if an EventLog already exists
I'm using the following line to create a new event log
new-eventlog -LogName "Visual Studio Builds" -Source "Visual Studio"
I want to run this every time, because if I run a build from a new computer, I'd still like to see the event logs.
The…

Chase Florell
- 46,378
- 57
- 186
- 376
38
votes
5 answers
Writing Exceptions to the Windows Log File
I'd like to catch my exceptions and log them in the Windows log file. How do I go about opening and writing to the Windows log?

Gold
- 60,526
- 100
- 215
- 315
36
votes
3 answers
What do I need to change to allow my IIS7 ASP.Net 3.5 application to create an event source and log events to Windows EventLog?
ASP.Net 3.5 running under IIS 7 doesn't seem to allow this out of the box.
if (!EventLog.SourceExists("MyAppLog"))
EventLog.CreateEventSource("MyAppLog", "Application");
EventLog myLog = new EventLog();
…

JTew
- 3,149
- 3
- 31
- 39
34
votes
6 answers
How does node process concurrent requests?
I have been reading up on nodejs lately, trying to understand how it handles multiple concurrent requests. I know NodeJs is a single threaded event loop based architecture, and at a given point in time only one statement is going to be executing,…

Saroj
- 1,551
- 2
- 14
- 30