You are viewing a plain text version of this content. The canonical link for it is here.
Posted to yarn-issues@hadoop.apache.org by "Sunil G (JIRA)" <ji...@apache.org> on 2015/11/10 18:11:11 UTC

[jira] [Commented] (YARN-4308) ContainersAggregated CPU resource utilization reports negative usage in first few heartbeats

    [ https://issues.apache.org/jira/browse/YARN-4308?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=14998921#comment-14998921 ] 

Sunil G commented on YARN-4308:
-------------------------------

Hi [~djp]
Could you please help to see the above case. I can also handle this case from the user end. We could just reset res-usage for CPU as *n/a* or *0* before sending any resource usage to client/UI. But still for first time, I feel that we can return 0 rather that negative value. In other cases, sending a -ve value is fine (provided we need not do any more modification or calculation based on that negative value).
For eg: calculation of {{milliVcoresUsed}} in {{ContainerMonitorImpl}}

> ContainersAggregated CPU resource utilization reports negative usage in first few heartbeats
> --------------------------------------------------------------------------------------------
>
>                 Key: YARN-4308
>                 URL: https://issues.apache.org/jira/browse/YARN-4308
>             Project: Hadoop YARN
>          Issue Type: Bug
>          Components: nodemanager
>    Affects Versions: 2.7.1
>            Reporter: Sunil G
>            Assignee: Sunil G
>         Attachments: 0001-YARN-4308.patch
>
>
> NodeManager reports ContainerAggregated CPU resource utilization as -ve value in first few heartbeats cycles. I added a new debug print and received below values from heartbeats.
> {noformat}
> INFO org.apache.hadoop.yarn.server.nodemanager.containermanager.monitor.ContainersMonitorImpl: ContainersResource Utilization : CpuTrackerUsagePercent : -1.0 
> INFO org.apache.hadoop.yarn.server.nodemanager.containermanager.monitor.ContainersMonitorImpl:ContainersResource Utilization :  CpuTrackerUsagePercent : 198.94598
> {noformat}
> Its better we send 0 as CPU usage rather than sending a negative values in heartbeats eventhough its happening in only first few heartbeats.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)