DATABASE FUNDAMENTALS
BASICS OF BIG DATA
Question
[CLICK ON ANY CHOICE TO KNOW THE RIGHT ANSWER]
|
|
Copy files from local file system to HDFS.
|
|
Copy files or directories from local file system to HDFS
|
|
Copy files from from HDFS to local filesystem.
|
|
Copy files or directories from HDFS to local filesystem.
|
Detailed explanation-1: -copyFromLocal: Copy files from the local file system to HDFS, similar to-put command. This command will not work if the file already exists. To overwrite the destination if the file already exists, add-f flag to command.
Detailed explanation-2: -copyFromLocal (or) put: To copy files/folders from local file system to hdfs store. This is the most important command.
Detailed explanation-3: -You can use the cp command in Hadoop. This command is similar to the Linux cp command, and it is used for copying files from one directory to another directory within the HDFS file system.
Detailed explanation-4: –copyFromLocal is restricted to copy from local while-put can take file from any (other HDFS/local filesystem/..)
Detailed explanation-5: -The Hadoop fs shell command ls displays a list of the contents of a directory specified in the path provided by the user. It shows the name, permissions, owner, size, and modification date for each file or directories in the specified directory.