0

Deploying new Windows Server 2022 VM. Our application - classic ISAPI with no managed code - writes events to the Application Event Log to track progress of certain processes, for debugging and troubleshooting purposes.

Application Event log is showing appropriate entries for a given time, but the event log text is always "The system cannot find the file specified". Although the application writes detailed messages, including call stack, etc, none of that information is showing in the event log, just "The system cannot find the file specified".

How can I fix this - important we see the message content that we post to the event log.

(Not really new member - old profile was lost)

ComeAndGo
  • 3
  • 2

1 Answers1

1

The event log uses resources from the application that generates the events, in order to show the messages. If the Event Viewer can't find your application, that's what it shows instead of messages. For the moment, check the system path to ensure that your application, and all its bits, are on the system path - which may require a reboot, as the system path does not get reloaded when it changes, many processes load it at boot / startup only. (This is, in my experience, true even if you don't actually use resources; if it can't load the executable, that's more critical to Event Viewer than any failure you may be reporting.)

tsc_chazz
  • 905
  • 3
  • 14
  • There is definitely an event message DLL, but it may not be registered/defined in the registry. Remember this is a "new deployment". The application is so old (could be 20 years) the procedure to register the DLL probably disappeared many years ago. https://www.eventsentry.com/blog/2010/11/creating-your-very-own-event-m.html https://www.eventsentry.com/blog/2008/04/event-log-message-files-the-de.html – Greg Askew Jul 22 '23 at 20:08
  • `regsvr32 eventmsg.dll` perhaps? The `regsvr32` mechanism has existed since NT 3.1 and is still used today... but if there is a statically linked DLL, and that DLL is visible when the app runs but not when it's loaded by EventViewer, error 126 will pop at executable load and you'll get the "cannot find the file" error message. – tsc_chazz Jul 22 '23 at 20:12