[ https://issues.apache.org/jira/browse/YARN-160?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=14100621#comment-14100621 ]
Varun Vasudev commented on YARN-160: ------------------------------------ [~djp] {quote} The old way to configure resource of NM is still useful, especially when there are other agents running (like: HBase RegionServer). Thus, user need flexibility to calculate resource themselves in some cases, so we should provide another new option instead of removing old way completely. {quote} The patch supports the old way. If a user has set values for memory and vcores, they're used without looking at the underlying hardware. I've added test cases to verify that behaviour as well. Have I missed a use case? {quote} Given this is a new feature, we shouldn't change cluster's behavior with old configuration in upgrade prospective. We should keep previous configuration work as usual especially when user use some default settings. {quote} There are two scenarios here - 1. A configuration file with custom settings for memory and cpu - nothing will change for these users. 2. A configuration file with no settings for memory and cpu - in this case, the memory and cpu resources will be calculated based on the underlying hardware instead of them being set to 8192 and 8 respectively. Isn't calculating the values from the hardware a better option? If people feel strongly about sticking to 8192 and 8, I don't have any problems changing them but it seems a bit odd. > nodemanagers should obtain cpu/memory values from underlying OS > --------------------------------------------------------------- > > Key: YARN-160 > URL: https://issues.apache.org/jira/browse/YARN-160 > Project: Hadoop YARN > Issue Type: Improvement > Components: nodemanager > Affects Versions: 2.0.3-alpha > Reporter: Alejandro Abdelnur > Assignee: Varun Vasudev > Fix For: 2.6.0 > > Attachments: apache-yarn-160.0.patch > > > As mentioned in YARN-2 > *NM memory and CPU configs* > Currently these values are coming from the config of the NM, we should be > able to obtain those values from the OS (ie, in the case of Linux from > /proc/meminfo & /proc/cpuinfo). As this is highly OS dependent we should have > an interface that obtains this information. In addition implementations of > this interface should be able to specify a mem/cpu offset (amount of mem/cpu > not to be avail as YARN resource), this would allow to reserve mem/cpu for > the OS and other services outside of YARN containers. -- This message was sent by Atlassian JIRA (v6.2#6252)