<?xml version="1.0"?>
<!--
  Licensed under the Apache License, Version 2.0 (the "License");
  you may not use this file except in compliance with the License.
  You may obtain a copy of the License at

    http://www.apache.org/licenses/LICENSE-2.0

  Unless required by applicable law or agreed to in writing, software
  distributed under the License is distributed on an "AS IS" BASIS,
  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
  See the License for the specific language governing permissions and
  limitations under the License. See accompanying LICENSE file.
-->
<configuration>

<!-- Site specific YARN configuration properties -->
    <property>
        <name>yarn.resourcemanager.webapp.address</name>
        <value>${yarn.resourcemanager.hostname}:8088</value>
    </property>
    <property>
        <name>yarn.nodemanager.aux-services</name>
        <value>mapreduce_shuffle</value>
    </property>
    <property>
        <name>yarn.nodemanager.env-whitelist</name>
        <value>JAVA_HOME,HADOOP_COMMON_HOME,HADOOP_HDFS_HOME,HADOOP_CONF_DIR,CLASSPATH_PREPEND_DISTCACHE,HADOOP_YARN_HOME,HADOOP_HOME,PATH,LANG,TZ,HADOOP_MAPRED_HOME</value>
    </property>
	<property>
			<name>yarn.scheduler.maximum-allocation-mb</name>
			<value>2048</value>
	</property>
	<property>
			<name>yarn.scheduler.minimum-allocation-mb</name>
			<value>2048</value>
	</property>
	<property>
			<name>yarn.nodemanager.vmem-pmem-ratio</name>
			<value>2.1</value>
	</property>
	<property>
			<name>mapred.child.java.opts</name>
			<value>-Xmx1024m</value>
	</property>

	<property>
		 <name>yarn.nodemanager.pmem-check-enabled</name>
		 <value>false</value>
	</property>
	<!--是否启动一个线程检查每个任务正使用的虚拟内存量，如果任务超出分配值，则直接将其杀掉，默认是true -->
	<property>
		 <name>yarn.nodemanager.vmem-check-enabled</name>
		 <value>false</value>
	</property>
</configuration>
