Netgate Discussion Forum
    • Categories
    • Recent
    • Tags
    • Popular
    • Users
    • Search
    • Register
    • Login

    Dynamic behaviour of CPU usage in System Information widget of pfsense

    Scheduled Pinned Locked Moved webGUI
    1 Posts 1 Posters 822 Views
    Loading More Posts
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes
    Reply
    • Reply as topic
    Log in to reply
    This topic has been deleted. Only users with topic management privileges can see it.
    • P
      ppfsenseavan
      last edited by

      In System Information widget of pfsense 'CPU usage' gets updated automatically every 10 seconds. My question is where is the code that's modifying 'CPU usage' every 10 seconds.

      What I have done so far:

      Code that displays CPU usage is:

      CPU usage

      ![left bar](./themes/<?= $g['theme']; ?>/images/misc/bar_left.gif)![red bar](./themes/<?= $g['theme']; ?>/images/misc/bar_blue.gif)![gray bar](./themes/<?= $g['theme']; ?>/images/misc/bar_gray.gif)![right bar](./themes/<?= $g['theme']; ?>/images/misc/bar_right.gif)

      (Updating in 10 seconds)

      When 'id=cpumeter' is removed, '(Updating in 10 seconds)' is displayed forever. If 'id=cpumeter' is not removed then '(Updating in 10 seconds)' is displayed for 10 seconds and then replaced by 2% or 3% (depending upon the cpu usage). The precentage gets modified every 10 seconds.

      So I tried searching the code that is updating CPU usage every 10 seconds but couldn't find it. I think java script is updating CPU usage but not sure. How can I find the code that is updating the CPU usage every 10 seconds?

      1 Reply Last reply Reply Quote 0
      • First post
        Last post
      Copyright 2025 Rubicon Communications LLC (Netgate). All rights reserved.