Finally, I left data directories as follows:
- dfs.namenode.name.dir = /var/hadoop/hdfs/namenode
- dfs.datanode.data.dir = /var/hadoop/hdfs/data
I restarted all the services and they worked like a charm.
I did not execute hadoop namenode -format, but I’m not pretty sure if it’s needed, now that it is working.
Thank you very much, because you led me to the solution.