Database Reference
In-Depth Information
"'But--still--monsieur----' 1
"'Catherine, 1
"'Comb 1
Again, V2 provides a sorted list of words with their counts. The successful test proves that the installed system,
both HDFS and Map Reduce, works. For now, you're finished with the configuration, although in later chapters of this
book I'll be introducing more Hadoop components.
Like Hadoop V1, Hadoop V2 offers a web interface for monitoring your cluster's nodes. Direct your web browser
to http://hc1nn:8088/cluster/nodes , and you can see all of your active data nodes along with information relating
to status and storage. The nodes themselves are actually http links, so you can click on then to drill down further.
Figure 2-6. Hadoop V2 UI cluster nodes
Hadoop Commands
Hadoop offers many additional command-line options. In addition to the shell commands you've already used in this
chapter's examples, I'll cover some other essential commands here, but only give a brief introduction to get you going.
The following sections will introduce Hadoop shell, user and administration commands. Where possible, I've given a
working example for each command. For a complete guide, see the Hadoop site, https://hadoop.apache.org .
Hadoop Shell Commands
The Hadoop shell commands are really user commands; specifically, they are a subset related to the file system.
Each command is invoked using the hadoop keyword, followed by the fs option, which stands for “file system.” Each
subcommand is passed as an argument to the fs option. File paths are specified as uniform resource identifiers, or URIs.
A file on the HDFS can be specified as hdfs:///dir1/dir2/file1, whereas the same file on the Linux file system can
be specified as file:///dir1/dir2/file1. If you neglect to offer a scheme (hdfs or file), then Hadoop assumes you mean
the HDFS.
If you are familiar with Linux or Unix shell commands, then you will find these Hadoop file system commands
similar. You can list files on HDFS using the ls command:
[hadoop@hc1nn ~]$ hadoop fs -ls /user/hadoop/edgar/
Found 1 items
drwxr-xr-x - hadoop hadoop 0 2014-03-23 16:32 /user/hadoop/edgar/edgar
 
Search WWH ::




Custom Search