Sudo addgroup hadoop # Add a hadoop Group
Sudo usermod-a-g hadoop Larry # Add the current user to the hadoop Group
Sudo gedit ETC/sudoers # Add the hadoop group to sudoer
Hadoop all = (all) All after root all = (all) All
Modify hadoop Directory Permissions
Sudo chown-r Larry: hadoop/home/Larry/hadoop <owner: group File>
Sudo chmod-r 755/home/Larry/hadoop
Modify HDFS Permissions
Sudo bin/hadoop DFS-chmod-r 755/
Sudo bin/hadoop DFS-ls/
Modify the HDFS file owner
Sudo bin/hadoop FS-chown-r Larry/
Sudo bin/hadoop dfsadmin-safemode leave # Remove hadoop Security Mode
Hadoop FS-copyfromlocal <localsrc> URI # copy a local file to HDFS
Hadoop FS-cat file: // file3/user/hadoop/file4 # output the content of the specified file in the path to stdout
Hadoop
FS-chgrp [-R] group URI # change the group to which the object belongs
Hadoop
FS-chmod [-R] 755 URI # Change User Access Permissions
Hadoop
FS-chown [-R] [owner] [: [group] URI [URI] # modify the object owner
Hadoop
FS-copytolocal URI localdst # copy the HDFS file to the local device
Hadoop
FS-cp uri [URI…] <DEST> # copy HDFS files to other directories
Hadoop
FS-du URI [URI…] # Display the size of all files in the directory
Hadoop
FS-getmerge <SRC> <localdst> [addnl] # Merge files to the local directory