You are viewing a plain text version of this content. The canonical link for it is here.
Posted to common-user@hadoop.apache.org by Wa...@emc.com on 2011/09/25 16:00:39 UTC
problem: configuration files will be restored after call new
Configuration
Hi All,
Environment:
Hadoop 0.20.205 (0.20.204 also have this problem)
Mac OS 10.6
Java 1.6
I meet a very weird problem, when I make some changes of core-site.xml or other configuration files in HADOOP_CONF, if I run a program with (new Configuration), the changed config files will restored to xxx.xml.template:
How to reproduce:
Make a little change to core-site.xml:
<configuration>
<property>
<name>test.val</name>
<value>test.val</value>
</property>
</configuration>
Run a program with the following main method:
public class TestConf {
public static void main(String[] args) {
Configuration conf = new Configuration();
System.out.println(conf.get("test.val"));
}
}
This program will print "null", and core-site.xml will restore to:
<configuration>
</configuration>
Can anyone point me to this problem?
--
Regards,
Wangda