[
https://issues.apache.org/jira/browse/YARN-8443?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]
Weiwei Yang updated YARN-8443:
------------------------------
Summary: Total #VCores in cluster metrics is wrong when CapacityScheduler
reserved some containers (was: Cluster metrics have wrong Total VCores when
there is reserved container for CapacityScheduler)
> Total #VCores in cluster metrics is wrong when CapacityScheduler reserved
> some containers
> -----------------------------------------------------------------------------------------
>
> Key: YARN-8443
> URL: https://issues.apache.org/jira/browse/YARN-8443
> Project: Hadoop YARN
> Issue Type: Bug
> Components: webapp
> Affects Versions: 2.9.0, 3.1.0, 3.2.0
> Reporter: Tao Yang
> Assignee: Tao Yang
> Priority: Major
> Attachments: YARN-8443.001.patch
>
>
> Cluster metrics on the web UI will give wrong Total Vcores when there is
> reserved container for CapacityScheduler.
> Reference code:
> {code:java|title=ClusterMetricsInfo.java}
> if (rs instanceof CapacityScheduler) {
> CapacityScheduler cs = (CapacityScheduler) rs;
> this.totalMB = availableMB + allocatedMB + reservedMB;
> this.totalVirtualCores =
> availableVirtualCores + allocatedVirtualCores + containersReserved;
> ...
> }
> {code}
> The key of this problem is the calculation of totalVirtualCores,
> {{containersReserved}} is the number of reserved containers, not reserved
> VCores. The correct calculation expression of totalVirtualCores should be
> (availableVirtualCores + allocatedVirtualCores + reservedVirtualCores)
--
This message was sent by Atlassian JIRA
(v7.6.3#76005)
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]