Title: 544
Tags: lec18

Q: How do you format an HDFS NameNode?
A: hdfs namenode -format

Q: How do you start running an HDFS NameNode with hostname "main" and port 9000?
A: hdfs namenode --fs hdfs://main:9000

Q: How can you get an HDFS cluster report for hdfs://main:9000/?
A: hdfs dfsadmin -fs hdfs://main:9000/ -report

Q: How can you start a DataNode and connect it to a NameNode with hostname "main" on port 9000?
A: hdfs datanode -fs hdfs://main:9000

Q: If you want to use commands like mkdir, cp, ls, cat, and du on HDFS, how do you do it?
A: hdfs dfs -COMMAND ARGS
For example, to run "ls" on the "data" directory:
hdfs dfs -ls hdfs://main:9000/data/