Skip to content

Commit e644f9e

Browse files
sureshsundriyaltstack
authored andcommitted
[format/vmw_log] Add support for new vmw log format.
* Quotes around stuff like `opID` and `sub`. * No brackets around process/thread id. * Space between process name and process id.
1 parent 505eea3 commit e644f9e

File tree

1 file changed

+6
-0
lines changed

1 file changed

+6
-0
lines changed

src/formats/vmw_log.json

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,9 @@
55
"description": "One of the log formats used in VMware's ESXi and vCenter software.",
66
"url": "https://kb.vmware.com/kb/2004201",
77
"regex": {
8+
"9.0+": {
9+
"pattern": "^(?<timestamp>\\d{4}-\\d{2}-\\d{2}T\\d{2}:\\d{2}:\\d{2}\\.\\d{3}(?:Z|[-+]\\d{2}:\\d{2})) (?<level>\\w+)(?:\\(\\d+\\)+)? (?<prc>[\\w\\-]+)\\s?\\[?(?<tid>\\w+)\\]?:? (?:\\w+ -\\[\\d+\\] )?\\[(?<src>[a-zA-Z][\\w:]*(?:@\\d+)?)(?:\\s+sub=\\\"?(?<sub>.*?(?!\\w+=))\\\"?)?(?:\\s+item=\\\"?(?<item>[\\w\\.\\-@/:]+)\\\"?)?(?: req=\\\"?(?<req>[^ \\]]+)\\\"?)?(?: opI(?:D|d)=\\\"?(?<opid>(?:req=)?[\\w@ \\-\\.:]+?(?!\\w+=))\\\"?)?(?: sid=\\\"?(?<sid>[^ \\]]+)\\\"?)?(?: user=\\\"(?<user>[^ \\]<]+(?:<[^>]+>)?\\\"?))?(?: update=\\\"?(?<vpxa_update>\\d+)\\\"?)?(?:\\s+reason=\\\"?(?<reason>[^\\]]+)\\\"?)?\\]\\s+(?:\\[(?<file>[^ ]+)\\s+(?<line>\\d+)\\]\\s+)?(?<body>.*)$"
10+
},
811
"6.0+": {
912
"pattern": "^(?:\\[#\\d+\\] )?(?<timestamp>\\d{4}-\\d{2}-\\d{2}T\\d{2}:\\d{2}:\\d{2}\\.\\d{3}(?:Z|[-+]\\d{2}:\\d{2})) (?<level>\\w+)(?:\\(\\d+\\)+)? (?<prc>[\\w\\-]+)\\[(?<tid>\\w+)\\]:? (?:\\w+ -\\[\\d+\\] )?\\[(?<src>[a-zA-Z][\\w:]*(?:@\\d+)?)(?:\\s+sub=(?<sub>.*?(?!\\w+=)))?(?:\\s+item=(?<item>[\\w\\.\\-@/:]+))?(?: req=(?<req>[^ \\]]+))?(?: opI(?:D|d)=(?<opid>(?:req=)?[\\w@ \\-\\.:]+?(?!\\w+=)))?(?: sid=(?<sid>[^ \\]]+))?(?: user=(?<user>[^ \\]<]+(?:<[^>]+>)?))?(?: update=(?<vpxa_update>\\d+))?(?:\\s+reason=(?<reason>[^\\]]+))?\\]\\s+(?:\\[(?<file>[^ ]+)\\s+(?<line>\\d+)\\]\\s+)?(?<body>.*)$"
1013
},
@@ -355,6 +358,9 @@
355358
},
356359
{
357360
"line": "2023-10-28 02:56:46,013 INFO imageService[139745105131968] [imageService 1092] Image service is initialized"
361+
},
362+
{
363+
"line": "2025-06-04T17:06:21.349Z INFO vpxd 20973 [Originator@4413 sub=\"ServiceAccount\" opID=\"SvcAcctInit-5a91f2fc\"] Service account accessor initialized; user: vpxd-svc-acct-90beeaa8-b1b3-46f4-8200-641edac5cacf@VSPHERE.LOCAL, passwordStatus: Ok"
358364
}
359365
]
360366
}

0 commit comments

Comments
 (0)