G. Xh. [http://community.zenoss.org/people/gx104] created the discussion
"Re: EventClassKey"
To view the discussion, visit: http://community.zenoss.org/message/66068#66068
--------------------------------------------------------------
So now I had again time to take a look in that System
Now I started and createt an Event with the comandline
eventcreate /L Application /T Error /SO TESTSOURCE /ID 999 /D "That's an random Event"
After that the Event went to the Zenoss Core Event System and it becomes the EventClassKey:
MSWinEventLog
In the log I can see this:
2012-04-26 15:37:13,449 DEBUG zen.Syslog: parseHEADER timestamp=Apr 26 15:37:17
2012-04-26 15:37:13,449 DEBUG zen.Syslog: parseHEADER hostname=pchs1136.sanacare.local
2012-04-26 15:37:13,449 DEBUG zen.Syslog: MSWinEventLog[1]:Application 1830 Thu Apr 26 15:37:17 2012 999 TESTSOURCE Unknown User N/A Error PCHS1136 None That's an random Event 7
2012-04-26 15:37:13,449 DEBUG zen.Syslog: tag regex: ^\S+\s+MSWinEventLog\s+\d\s+Application\s+\d+\s+\S\S\S\s\S\S\S\s\d\d\s\d\d:\d\d:\d\d\s\d\d\d\d\s+(?P<component>\d\d\d)\s+(?P<summary>.+)$
2012-04-26 15:37:13,449 DEBUG zen.Syslog: tag regex: ^(?P<summary>-- (?P<eventClassKey>MARK) --)
2012-04-26 15:37:13,449 DEBUG zen.Syslog: tag regex: ^: \d{4} \w{3}\s+\d{1,2}\s+\d{1,2}:\d\d:\d\d \w{3}: (?P<eventClassKey>[^:]+): (?P<summary>.*)
2012-04-26 15:37:13,449 DEBUG zen.Syslog: tag regex: ^(?P<component>.+)\[(?P<ntseverity>\D+)\] (?P<ntevid>\d+) (?P<summary>.*)
2012-04-26 15:37:13,450 DEBUG zen.Syslog: tag regex: %CARD-\S+:(SLOT\d+) %(?P<eventClassKey>\S+): (?P<summary>.*)
2012-04-26 15:37:13,450 DEBUG zen.Syslog: tag regex: %(?P<eventClassKey>(?P<component>\S+)-\d-\S+): (?P<summary>.*)
2012-04-26 15:37:13,450 DEBUG zen.Syslog: tag regex: ^(?P<ipAddress>\S+)\s+(?P<summary>(?P<eventClassKey>CisACS_\d\d_\S+)\s+(?P<eventKey>\S+)\s.*)
2012-04-26 15:37:13,450 DEBUG zen.Syslog: tag regex: device_id=\S+\s+\[\S+\](?P<eventClassKey>\S+\d+):\s+(?P<summary>.*)\s+\((?P<originalTime>\d\d\d\d-\d\d-\d\d \d\d:\d\d:\d\d)\)
2012-04-26 15:37:13,450 DEBUG zen.Syslog: tag regex: ^\[[^:]+: (?P<component>[^:]+)[^\]]+\]: (?P<summary>.*)
2012-04-26 15:37:13,450 DEBUG zen.Syslog: tag regex: (?P<component>\S+)\[(?P<pid>\d+)\]:\s*(?P<summary>.*)
2012-04-26 15:37:13,450 DEBUG zen.Syslog: tag match: {'component': 'MSWinEventLog', 'pid': '1', 'summary': "Application 1830 Thu Apr 26 15:37:17 2012 999 TESTSOURCE Unknown User N/A Error PCHS1136 None That's an random Event 7"}
2012-04-26 15:37:13,451 DEBUG zen.Syslog: eventClassKey=MSWinEventLog
2012-04-26 15:37:13,451 DEBUG zen.ZenSyslog: Queueing event {'firstTime': 1335447433.447741, 'severity': 2, 'facility': 'user', 'eventClassKey': u'MSWinEventLog', 'component': 'MSWinEventLog', 'pid': '1', 'agent': 'zensyslog', 'summary': "Application 1830 Thu Apr 26 15:37:17 2012 999 TESTSOURCE Unknown User N/A Error PCHS1136 None That's an random Event 7", 'priority': 5, 'manager': 'SRVHS1023.sanacare.local', 'eventGroup': 'syslog', 'originalTime': 'Apr 26 15:37:17', 'device': 'pchs1136.sanacare.local', 'lastTime': 1335447433.447741, 'monitor': 'localhost'}
2012-04-26 15:37:13,451 DEBUG zen.ZenSyslog: Total of 1 queued events
2012-04-26 15:37:19,936 DEBUG zen.Syslog: host=pchs1136.sanacare.local, ip=10.3.1.198
2012-04-26 15:37:19,937 DEBUG zen.Syslog: <13>Apr 26 15:37:23 pchs1136.sanacare.local MSWinEventLog[1]:Security     1831     Thu Apr 26 15:37:23 2012     861     Security     NETZWERKDIENST     Well Known Group     Failure Audit     PCHS1136     Detaillierte Ãberwachung          Der Windows-Firewall hat eine Anwendung ermittelt, die eingehenden Datenverkehr abhört.       Name: -   Pfad: C:\WINDOWS\system32\svchost.exe   Prozesskennung: 1508   Benutzerkonto: NETZWERKDIENST   BenutzerdomÀne: NT-AUTORITÃT   Dienst: Ja   RPC-Server: Nein   IP-Version: IPv4   IP-Protokoll: UDP   Portnummer: 53530   Zugelassen: Nein   Benutzer benachrichtigt: Nein      1813
There I can see that the parsing is not going well and so I tried so add a new regex-rule
Than I found this:
# SNARE windows msg
r"MSWinEventLog\s\d\s(?P<component>\D+?)\s\d+?\s\w\w\w\s\w\w\w\s\d\d\s\d\d:\d\d\s\d\d\d\d\s(?P<ntevid>\d+?)\s(?P<summary>.*)",
I wrote that to the SyslogProcessing.py but it doesnt help.
--------------------------------------------------------------
Reply to this message by replying to this email -or- go to the discussion on Zenoss Community
[http://community.zenoss.org/message/66068#66068]
Start a new discussion in zenoss-users by email
[discussions-community-forums-zenoss--***@community.zenoss.org] -or- at Zenoss Community
[http://community.zenoss.org/choose-container!input.jspa?contentType=1&containerType=14&container=2003]