Database Reference
In-Depth Information
The Linux cat command shows the contents of the cloudera-cdh4.repo file. The ls -l command shows that it is
owned by the root Linux user:
[root@hc1r1m1 yum.repos.d]# ls -l cloudera-cdh4.repo
-rw-r--r-- 1 root root 229 Sep 6 09:24 cloudera-cdh4.repo
This repository configuration file tells the yum command where to source Cloudera cdh4 software. The above file
is configured for a 64-bit machine (x86_64); a 32-bit machine would have the following lines:
baseurl= http://archive.cloudera.com/cdh4/redhat/6/i386/cdh/4/
gpgkey = http://archive.cloudera.com/cdh4/redhat/6/i386/cdh/RPM-GPG-KEY-cloudera
At this point, Cloudera advises you to install ZooKeeper so that you have a ZooKeeper cluster; you'll do so in the
next section. Tools like HBase (the distributed database that will be introduced in Chapter 3) rely on it.
ZooKeeper Installation
ZooKeeper is a centralized service for maintaining configuration information in distributed applications. Many of the
tools in the Hadoop ecosystem use it, so it will be helpful to install it now because you will need it later. You install the
ZooKeeper base package as follows:
yum install zookeeper
When you install ZooKeeper, remember that it needs to be installed on an odd number of servers—for example,
three machines. (When voting on an outcome, the odd number of servers makes it possible for ZooKeper to reach a
majority decision.) Next, you install the ZooKeeper server on each node:
yum install zookeeper-server
After installation, the ZooKeeper configuration needs to be altered for your environment. By default, the
configuration file is stored under /etc/zookeeper/conf/zoo.cfg. Its initial contents are the following:
maxClientCnxns=50
# The number of milliseconds of each tick
tickTime=2000
# The number of ticks that the initial
# synchronization phase can take
initLimit=10
# The number of ticks that can pass between
# sending a request and getting an acknowledgement
syncLimit=5
# the directory where the snapshot is stored.
dataDir=/var/lib/zookeeper
# the port at which the clients will connect
clientPort=2181
 
Search WWH ::




Custom Search