-
Notifications
You must be signed in to change notification settings - Fork 245
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[loki.process] stage.eventlogmessage - invalid line parsed from message #982
Comments
same here. Up |
Same setup, same problem. Any help/news on this? |
Again same setup, same problem! |
Hi there, Thanks for the help |
I found the Same issue and openwd a separate Ticket before i found this. |
Hello, thanks for reporting this bug. What's happening is that the eventlogmessage stage is expecting the windows message to contain a list of key-value pairs split by new lines. This is incorrect because windows messages sometimes contain empty lines or lines that don't have ":" (https://learn.microsoft.com/en-us/previous-versions/windows/desktop/bb226812(v=vs.85)#message-format). As a result, it logs a warning for every line that's not a key-value pair. The other lines are properly extracted and can be used by the other stages (for example the stage.labels if you want to have some of the values as labels). There is a trick here though: the non-alphabetical characters are transformed into "_" and that counts for "\t" as well. So if you have "\tSecurity ID", you can get it as "SecurityID" label with:
This is definitely not ideal + the info that's not formatted as key-value is lost (and the key-value pairs that have values on several lines are truncated). This stage definitely needs some improvements. I suggest that we should first change the log level from Warn to Debug. |
Hello @wildum, thanks for taking a look. |
What's wrong?
message
not parsed fromloki.source.windowsevent
Steps to reproduce
v1.1.1
.Application
. There will be plenty of these message:System information
Microsoft Windows Server 2022 Standard - 10.0.20348 N/A Build 20348
Software version
alloy, version v1.1.1 (branch: HEAD, revision: 2687a2d)
Configuration
No response
Logs
No response
The text was updated successfully, but these errors were encountered: