The configuration you are trying to set up is not currently supported. You can go ahead and attempt it, but the only configuration pointer I can give is that you will probably need to set up a VIP to switch between them. Also running the namenodes and datanodes on the same server is not reccomended. A similar configuration to this will be supported when hadoop 2.0 is fully adopted, but under hadoop 1.0 it is not. Hadoop 2.0 is currently still in beta.