Anonymous Monk has asked for the wisdom of the Perl Monks concerning the following question:

I want to read my Windows EventLogs from my Unix box. It looks like Win32::EventLog should do it, but I can't install it. It looks like it needs Win32API::Registry, but that does not install either--it fails with
Writing Makefile for Win32API::Registry Makefile:850: *** missing separator. Stop. /usr/bin/make -- NOT OK
Does the module only work on Win32 systems?

Replies are listed 'Best First'.
Re: Windows Eventlog from unix
by blaze (Friar) on Sep 03, 2002 at 19:10 UTC
    Win32API::Registry is a module for accessing the windows registry, so yes, it is for win32 systems

    some of the monks here might be able to give you some suggestions, how are you accessing the windows box? who is the client and who is the server?
      I want to try to get all my logging in one place. I thought it might be possible to write a Perl script that runs on a Linux box, accesses the Windows EventLog, and then logs anything important (for example Warnings, or whatever they are called in Windows) to the Syslog running on the Linux box. Then all my *nix boxen would be logging to one box and my Windows machines would be logging on the same box.

        A fairly straightforward approach that's almost what you want, while leveraging the Win32 classes, is to have the Windows box do the event log parsing using the relevant modules and send the results onto the Linux box via a network socket or a text file on a network-accessible drive.

        If not P, what? Q maybe?
        "Sidney Morgenbesser"

Re: Windows Eventlog from unix
by MZSanford (Curate) on Sep 03, 2002 at 20:49 UTC
    There are some non-perl utilities for sending Event Log data to Syslog ... this could then be read as local data by any Perl code. Here is one i found on a quick Google search :
    EventReporter

    from the frivolous to the serious
Re: Windows Eventlog from unix
by richardX (Pilgrim) on Sep 03, 2002 at 22:25 UTC
    Roth Utilities is another place where you can find a set of functions that read event logs and sends network messages.

    Richard

    There are three types of people in this world, those that can count and those that cannot. Anon

Re: Windows Eventlog from unix
by kschwab (Vicar) on Sep 04, 2002 at 23:54 UTC
    There's a free ( as in beer ) utility that will allow you to forward Windows Event Logs to a syslog daemon. See BackLogNT