java -version # 如果无法找到 # The operation couldn’t be completed. Unable to locate a Java Runtime. # Please visit http://www.java.com for information on installing Java.
docker-compose up -d # 复制文件 docker cp <local> namenode:/<path>
在namenode中
# HDFS list commands to show all the directories in root "/" hdfs dfs -ls / # Create a new directory inside HDFS using mkdir tag. hdfs dfs -mkdir -p /user/root # Copy the files to the input path in HDFS. -f means force hdfs dfs -put -f <file_name> <path> # Have a look at the content of your input file. hdfs dfs -cat <input_file>