Support Questions

Find answers, ask questions, and share your expertise
Announcements
Celebrating as our community reaches 100,000 members! Thank you!

Changing Namenode & DataNode directories in HDP 2.4.2

avatar
Contributor

The Namenode & Datanode directories in HDFS default pointing to sda1(which has less space). I want to point the directories to sdb1 which has larger space. what is the procedure to change the Namenode & Datanode directories. As of now i do not have any data on HDFS so do not have problem of losing data while changing directories. Please let me know the steps. Below is the screen shot.

image.png

1 ACCEPTED SOLUTION

avatar
Master Guru
@Narasimhan Kazhiyur

Login to Ambari UI --> Click on HDFS service --> Click on configs --> Search for data.dir --> Change the location --> Restart required services via Ambari

Please refer below screenshot

7094-screen-shot-2016-08-30-at-114130-am.png

Please note - This procedure will not take care of data migration.

View solution in original post

3 REPLIES 3

avatar
Master Guru
@Narasimhan Kazhiyur

Login to Ambari UI --> Click on HDFS service --> Click on configs --> Search for data.dir --> Change the location --> Restart required services via Ambari

Please refer below screenshot

7094-screen-shot-2016-08-30-at-114130-am.png

Please note - This procedure will not take care of data migration.

avatar
Contributor

Hi @Kuldeep Kulkarni. In the datanode & namenode directories path i am giving "/mnt/resource/hadoop/hdfs/namenode & /mnt/resource/hadoop/hdfs/data" .Is this right ?

Please refer the attached screen shot of available partitions image.png.

Thank you.

avatar
Rising Star

Hi @Narasimhan Kazhiyur

Yes above change should work and also you should format the new name directory