Skip to content
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

windows/perfmon metricset - handle win32 api errors in the events #18292

Closed
narph opened this issue May 6, 2020 · 1 comment · Fixed by #18361
Closed

windows/perfmon metricset - handle win32 api errors in the events #18292

narph opened this issue May 6, 2020 · 1 comment · Fixed by #18361
Assignees
Labels
Metricbeat Metricbeat Team:Integrations Label for the Integrations team

Comments

@narph
Copy link
Contributor

narph commented May 6, 2020

Users can encounter several error messages in the events:

    "error": {

      "message": "failed on query=\\\\Desktop232\\Process(psql#2)\\Page File Bytes: The data is not valid."
    },

The error message is returned by the win32 api https://docs.microsoft.com/en-us/windows/win32/api/pdh/nf-pdh-pdhgetformattedcountervalue.
Users can encounter this error if the process has stopped between retrieving/validating the path and retrieving the counter values, in some cases permissions are involved.

  },
  "error": {
    "message": "failed on query=\\\\Desktop232\\Process(RuntimeBroker#14)\\% Processor Time: A counter with a negative value was detected."
  },

The error message is returned by the win32 api https://docs.microsoft.com/en-us/windows/win32/api/pdh/nf-pdh-pdhgetformattedcountervalue which is not expecting a negative value.
Suspected there is an overflow of values in data storage, so the option could be to ignore this return value and retry later to get the new values.

In both cases, these are not a fatal errors and the application can continue running correctly so they should be kept only as debug log messages and not shown in the events.
Also, if there are any workarounds in this case.

@narph narph self-assigned this May 6, 2020
@narph narph added Metricbeat Metricbeat Team:Integrations Label for the Integrations team labels May 6, 2020
@elasticmachine
Copy link
Collaborator

Pinging @elastic/integrations (Team:Integrations)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Metricbeat Metricbeat Team:Integrations Label for the Integrations team
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants