Ad Widget

Collapse

pagefile perf_counters only partially working

Collapse
This topic has been answered.
X
X
 
  • Time
  • Show
Clear All
new posts
  • tomstocker
    Junior Member
    • Jan 2024
    • 16

    #1

    pagefile perf_counters only partially working

    Hi all

    Only the _Total perf counter are working. Agent2 v7.0, windows server 2022.

    # zabbix_get -s hostname -k 'perf_counter["\Paging File(\??\c:\pagefile.sys\)\% Usage"]' -p 10050
    zabbix_get [1916354]: Check access restrictions in Zabbix agent configuration
    # zabbix_get -s hostname -k 'perf_counter["\Paging File(\??\c:\pagefile.sys\)\% Usage Peak"]' -p 10050
    zabbix_get [1916719]: Check access restrictions in Zabbix agent configuration
    # zabbix_get -s hostname -k 'perf_counter["\Paging File(_Total)\% Usage"]' -p 10050
    14.957886
    # zabbix_get -s hostname -k 'perf_counter["\Paging File(_Total)\% Usage Peak"]' -p 10050
    15.463867

    any idea why?
  • Answer selected by Markku at 03-07-2024, 16:57.
    Markku
    Senior Member
    Zabbix Certified SpecialistZabbix Certified ProfessionalZabbix Certified Expert
    • Sep 2018
    • 1781

    You have an extra backslash in the pagefile name. Without it works here:

    PS C:\Program Files\Zabbix Agent> .\zabbix_agentd.exe -t 'perf_counter["\Paging File(\??\C:\pagefile.sys)\% Usage Peak"]'
    perf_counter[\Paging File(\??\C:\pagefile.sys)\% Usage Peak] [d|25.936247173108551]

    PS C:\Program Files\Zabbix Agent> .\zabbix_agentd.exe -t 'perf_counter["\Paging File(\??\C:\pagefile.sys\)\% Usage Peak"]'
    perf_counter[\Paging File(\??\C:\pagefile.sys\)\% Usage Peak] [m|ZBX_NOTSUPPORTED] [Cannot obtain performance information from collector.]


    Markku

    Comment

    • Markku
      Senior Member
      Zabbix Certified SpecialistZabbix Certified ProfessionalZabbix Certified Expert
      • Sep 2018
      • 1781

      #2
      You have an extra backslash in the pagefile name. Without it works here:

      PS C:\Program Files\Zabbix Agent> .\zabbix_agentd.exe -t 'perf_counter["\Paging File(\??\C:\pagefile.sys)\% Usage Peak"]'
      perf_counter[\Paging File(\??\C:\pagefile.sys)\% Usage Peak] [d|25.936247173108551]

      PS C:\Program Files\Zabbix Agent> .\zabbix_agentd.exe -t 'perf_counter["\Paging File(\??\C:\pagefile.sys\)\% Usage Peak"]'
      perf_counter[\Paging File(\??\C:\pagefile.sys\)\% Usage Peak] [m|ZBX_NOTSUPPORTED] [Cannot obtain performance information from collector.]


      Markku

      Comment

      • tomstocker
        Junior Member
        • Jan 2024
        • 16

        #3
        Your're absolutely right, thanks for spotting. PEBCAK error :-)

        (Get-Counter -ListSet * | select -expand PathsWithInstances | Select-String -Pattern "Paging")

        \Paging File(\??\C:\pagefile.sys)\% Usage
        \Paging File(_Total)\% Usage
        \Paging File(\??\C:\pagefile.sys)\% Usage Peak
        \Paging File(_Total)\% Usage Peak

        Comment

        Working...