Read a hadoop config Files from Unix Path in Java Program
<p>I am developing an Java Application and this application is saving a result data to HDFS. The java Application should run in my windows machine. </p>

<p>As of now, I copied the Hadoop config files such as core-site, hdfs-site.xml in to my windows machine and testing it. Below is my configuration Code Snippet.</p>

<pre><code>config.addResource(new Path("C:\\Hadoop\\core-site.xml"));
config.addResource(new Path("C:\\Hadoop\\hdfs-site.xml"));
config.addResource(new Path("C:\\Hadoop\\mapred-site.xml"));
config.addResource(new Path("C:\\Hadoop\\yarn-site.xml"));
</code></pre>

<p>Is there any way I can load config files directly from unix server  from my Windows Machine like below.</p>

<pre><code>config.addResource(new Path("/opt/hdp/2.3.4.7-4/hadoop/conf/core-site.xml"));
config.addResource(new Path("/opt/hdp/2.3.4.7-4/hadoop/conf/hdfs-site.xml"));
config.addResource(new Path("/opt/hdp/2.3.4.7-4/hadoop/conf/mapred-site.xml"));
config.addResource(new Path("/opt/hdp/2.3.4.7-4/hadoop/conf/yarn-site.xml"));
</code></pre>

<p>Kindly help me.</p>