Announcement

Collapse
No announcement yet.

High CPU usage on Linux

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

  • High CPU usage on Linux

    So on my system TankUtil is one of the higher CPU users on the system. Since I set it to poll for updates every 4 hours, I'm a little unclear on what the plugin is doing in the meantime. I don't see a heavy amount of HS calls, so just wondering if what your doing between updates isn't sleeping the thread as much as maybe you think it does? Overall it seems to sit between 5 and 20% CPU usage, which 10 being close to average. Hoping you could look (and happy to help if needed) to see if this could be cut down? Im on a SEL box and every CPU cycle helps!

  • #2
    Here is why its using so much CPU:

    Timing: HSPI_TankUtil.IAppCallbackAPI.RegisterConfigLink Total Calls: 1 Invoke: 38ms Deserialization: 0ms Total: 39ms Average: 39ms
    Timing: HSPI_TankUtil.IAppCallbackAPI.RegisterLink Total Calls: 1 Invoke: 26ms Deserialization: 0ms Total: 26ms Average: 26ms
    Timing: HSPI_TankUtil.IAppCallbackAPI.get_APIVersion Total Calls: 1 Invoke: 17ms Deserialization: 1ms Total: 18ms Average: 18ms
    Timing: HSPI_TankUtil.IHSApplication.Connect Total Calls: 1 Invoke: 69ms Deserialization: 0ms Total: 70ms Average: 70ms
    Timing: HSPI_TankUtil.IHSApplication.GetDeviceByRef Total Calls: 9970 Invoke: 1,222,390ms Deserialization: 94,157ms Total: 1,316,547ms Average: 132ms
    Timing: HSPI_TankUtil.IHSApplication.GetDeviceEnumerator Total Calls: 4 Invoke: 71,178ms Deserialization: 128,654ms Total: 199,833ms Average: 49,958ms
    Timing: HSPI_TankUtil.IHSApplication.GetINISetting Total Calls: 6 Invoke: 154ms Deserialization: 1ms Total: 156ms Average: 26ms
    Timing: HSPI_TankUtil.IHSApplication.GetURL Total Calls: 5 Invoke: 2,580ms Deserialization: 1ms Total: 2,582ms Average: 516ms
    Timing: HSPI_TankUtil.IHSApplication.RegisterPage Total Calls: 1 Invoke: 37ms Deserialization: 0ms Total: 37ms Average: 37ms
    Timing: HSPI_TankUtil.IHSApplication.SaveINISetting Total Calls: 5 Invoke: 175ms Deserialization: 1ms Total: 176ms Average: 35ms
    Timing: HSPI_TankUtil.IHSApplication.WriteLog Total Calls: 15 Invoke: 773ms Deserialization: 4ms Total: 777ms Average: 51ms
    Timing: HSPI_TankUtil.IHSApplication.get_APIVersion Total Calls: 1 Invoke: 67ms Deserialization: 27ms Total: 94ms Average: 94ms

    Ideally GetDeviceEnumerator should only be called once or even better store your deviceRefs in your ini file and only do a search if they are not set. Also could you please cache the results from GetDeviceByRef. Those 9970 calls occurred within 20 minutes of startup, so you must be doing this in a loop somewhere separate from the polling interval...

    Comment

    Working...
    X