For learning and local development purposes, there is no easier way than to download the Hortonworks Data Platform (HDP) sandbox and run in inside your favourite hypervisor.
Once you get your image started in whatever hypervisor you use, you will see a login screen with connection information.
Use your SSH client to connect to the presented IP address and login with user root and password hadoop
Once we are in, it’s time to perform first hdfs command. Switch user to hdfs and issue hdfs dfsadmin with report as a parameter. What we get is a general information about our Hadoop sandbox.
su hdfs hdfs dfsadmin -report
And that’s it!
Bottom line
If we hadn’t switched to hdfs user, we wouldn’t have seen all the information from the above screenshot. Apparently, Hortonworks made a change in the sandbox configuration for 2.2 version that root user doesn’t have a superuser privilege for hdfs anymore.

For the sake of sandbox testing purposes, one may issue a usermod command to assign root to the superuser group.
usermod -a -G hdfs root
Leave a Reply