HDFS basic operation of the command line

1 .hdfs command line 
    ( 1 ) View Help 
        HDFS the DFS - Help 
        
    ( 2 ) view the current directory information 
        HDFS the DFS -ls / 
        
    ( 3 ) upload files 
        HDFS the DFS -put / local path / HDFS path 
        
    ( 4 ) Cut file 
        HDFS the DFS - a.txt moveFromLocal / aa.txt 
        
    ( 5 ) download the file to a local 
        HDFS the DFS -get / HDFS path / local path 
        
    ( 6 ) merge download 
        HDFS the DFS -getmerge / HDFS path to the folder / file after the merger 
        
    ( 7 ) create folder
        DFS hdfs file-mkdir / Hello 
        
    ( . 8 ) to create multi-level folder 
        hdfs DFS -mkdir -p / Hello / World 
        
    ( . 9 ) move files hdfs 
        hdfs DFS -MV / hdfs path / hdfs path 
        
    ( 10 ) to copy the file hdfs 
        hdfs DFS -cp / hdfs path / hdfs path 
        
    ( 11 ) to delete the file hdfs 
        hdfs the DFS -rm / aa.txt 
        
    ( 12 ) to delete the folder hdfs 
        hdfs the DFS -rm -r / the Hello 
        
    ( 13 ) to view files in hdfs 
        hdfs the DFS -cat / 
        hdfs the DFS -tail -f /File 
        
    ( 14 ) View folder how many files 
        hdfs the DFS -count / folder 
        
    ( 15 ) View the total space of hdfs 
        hdfs the DFS -df / 
        hdfs the DFS -df -h / 
        
    ( 16 ) to modify the number of copies     
        hdfs the DFS -setrep 1 /a.txt

 

Guess you like

Origin www.cnblogs.com/java-h/p/11199177.html