google code pretty

2020-11-05

CentOS 8 x hadoop 2.7.3 NameNode HA Configuration

core-site.xml
<property>
	<name>fs.defaultFS</name>
	<value>hdfs://my-cluster-name</value>
</property>

<property>
	<name>ha.zookeeper.quorum</name>
	<value>host1:2181,host2:2181,host3:2181</value>
</property>

<property>
	<name>ipc.client.connect.max.retries</name>
	<value>100</value>
	<description> Indicates the number of retries a client will make to establisha server connection. </description>
</property>

<property>
	<name>ipc.client.connect.retry.interval</name>
	<value>10000</value>
	<description> Indicates the number of milliseconds a client will wait for before retrying to establish a server connection. </description>
</property>
hdfs-site.xml
<property>  
	<name>dfs.nameservices</name>  
	<value>my-cluster-name</value>  
</property>  

<property>  
	<name>dfs.ha.namenodes.my-cluster-name</name>  
	<value>host1,host2</value>  
</property>  

<property>
	<name>dfs.namenode.rpc-address.my-cluster-name.eyequila08</name>
	<value>host1:9000</value>
</property>

<property>
	<name>dfs.namenode.rpc-address.my-cluster-name.eyequila09</name>
	<value>host2:9000</value>
</property>

<property>
	<name>dfs.namenode.http-address.my-cluster-name.eyequila08</name>
	<value>host1:50070</value>
</property>

<property>
	<name>dfs.namenode.http-address.my-cluster-name.eyequila09</name>
	<value>host2:50070</value>
</property>

<property>
	<name>dfs.namenode.shared.edits.dir</name>
	<value>qjournal://host1:8485;host2:8485/eyequila</value>
</property>

<property>
	<name>dfs.client.failover.proxy.provider.my-cluster-name</name>
	<value>org.apache.hadoop.hdfs.server.namenode.ha.ConfiguredFailoverProxyProvider</value>
</property>

<property>  
	<name>dfs.journalnode.edits.dir</name>  
	<value>/path/to/save/journal</value>  
</property>

<property>
	<name>dfs.qjournal.write-txns.timeout.ms</name>
	<value>600000000</value>
</property>

<property>  
	<name>dfs.ha.automatic-failover.enabled</name>  
	<value>true</value>  
</property>

<property>  
	<name>dfs.ha.fencing.methods</name>  
	<value>sshfence
	shell(/bin/true)
	</value>  
</property> 

<property>  
	<name>dfs.ha.fencing.ssh.private-key-files</name>  
	<value>/home/user_name/.ssh/id_rsa</value>  
</property>  

沒有留言:

張貼留言