Hadoop集群(CHD4)实践之 (4) Oozie搭建

目录结构
Hadoop集群(CDH4)实践之 (0) 前言
Hadoop集群(CDH4)实践之 (1) Hadoop(HDFS)搭建
Hadoop集群(CDH4)实践之 (2) HBase&Zookeeper搭建
Hadoop集群(CDH4)实践之 (3) Hive搭建
Hadoop集群(CHD4)实践之 (4) Oozie搭建
Hadoop集群(CHD4)实践之 (5) Sqoop安装

本文内容
Hadoop集群(CHD4)实践之 (4) Oozie搭建

参考资料
http://www.cloudera.com/content/cloudera-content/cloudera-docs/CDH4/latest/CDH4-Installation-Guide/CDH4-Installation-Guide.html

环境准备
OS: CentOS 6.4 x86_64
Servers:
hadoop-master: 172.17.20.230 内存10G
- namenode
- hbase-master

hadoop-secondary: 172.17.20.234 内存10G
- secondarybackupnamenode,jobtracker
- hive-server,hive-metastore
- oozie

hadoop-node-1: 172.17.20.231 内存10G sudo yum install hbase-regionserver
- datanode,tasktracker
- hbase-regionserver,zookeeper-server

hadoop-node-2: 172.17.20.232 内存10G
- datanode,tasktracker
- hbase-regionserver,zookeeper-server

hadoop-node-3: 172.17.20.233 内存10G
- datanode,tasktracker
- hbase-regionserver,zookeeper-server

对以上角色做一些简单的介绍:
namenode - 整个HDFS的命名空间管理服务
secondarynamenode - 可以看做是namenode的冗余服务
jobtracker - 并行计算的job管理服务
datanode - HDFS的节点服务
tasktracker - 并行计算的job执行服务
hbase-master - Hbase的管理服务
hbase-regionServer - 对Client端插入,删除,查询数据等提供服务
zookeeper-server - Zookeeper协作与配置管理服务
hive-server - Hive的管理服务
hive-metastore - Hive的元存储,用于对元数据进行类型检查与语法分析
oozie - Oozie是一种Java Web应用程序,用于工作流的定义和管理

本文定义的规范,避免在配置多台服务器上产生理解上的混乱:
以下操作都只需要在 Oozie 所在主机,即 hadoop-secondary 上执行。

1. 安装前的准备
Hadoop集群(CDH4)实践之 (3) Hive搭建

2. 安装Oozie
$ sudo yum install oozie oozie-client

3. 创建Oozie数据库
$ mysql -uroot -phiveserver

1 mysql> create database oozie;
2 mysql> grant all privileges on oozie.* to 'oozie'@'localhost' identified by 'oozie';
3 mysql> grant all privileges on oozie.* to 'oozie'@'%' identified by 'oozie';
4 mysql> exit;

4.配置oozie-site.xml
$ sudo vim /etc/oozie/conf/oozie-site.xml

001 xml version="1.0"?>
002 <configuration>
003     <property>
004         <name>oozie.service.ActionService.executor.ext.classesname>
005         <value>
006             org.apache.oozie.action.email.EmailActionExecutor,
007             org.apache.oozie.action.hadoop.HiveActionExecutor,
008             org.apache.oozie.action.hadoop.ShellActionExecutor,
009             org.apache.oozie.action.hadoop.SqoopActionExecutor,
010             org.apache.oozie.action.hadoop.DistcpActionExecutor
011         value>
012     property>
013     <property>
014         <name>oozie.service.SchemaService.wf.ext.schemasname>
015         <value>shell-action-0.1.xsd,shell-action-0.2.xsd,email-action-0.1.xsd,hive-action-0.2.xsd,hive-action-0.3.xsd,hive-action-0.4.xsd,hive-action-0.5.xsd,sqoop-action-0.2.xsd,sqoop-action-0.3.xsd,ssh-action-0.1.xsd,ssh-action-0.2.xsd,distcp-action-0.1.xsdvalue>
016     property>
017     <property>
018         <name>oozie.system.idname>
019         <value>oozie-${user.name}value>
020     property>
021     <property>
022         <name>oozie.systemmodename>
023         <value>NORMALvalue>
024     property>
025     <property>
026         <name>oozie.service.AuthorizationService.security.enabledname>
027         <value>falsevalue>
028     property>
029     <property>
030         <name>oozie.service.PurgeService.older.thanname>
031         <value>30value>
032     property>
033     <property>
034         <name>oozie.service.PurgeService.purge.intervalname>
035         <value>3600value>
036     property>
037     <property>
038         <name>oozie.service.CallableQueueService.queue.sizename>
039         <value>10000value>
040     property>
041     <property>
042         <name>oozie.service.CallableQueueService.threadsname>
043         <value>10value>
044     property>
045     <property>
046         <name>oozie.service.CallableQueueService.callable.concurrencyname>
047         <value>3value>
048     property>
049     <property>
050         <name>oozie.service.coord.normal.default.timeout
051     name>
052     <value>120value>
053     property>
054  
055     <property>
056         <name>oozie.db.schema.namename>
057         <value>oozievalue>
058     property>
059     <property>
060         <name>oozie.service.JPAService.create.db.schemaname>
061         <value>truevalue>
062     property>
063  
064     <property>
065         <name>oozie.service.JPAService.jdbc.drivername>
066         <value>com.mysql.jdbc.Drivervalue>
067     property>
068     <property>
069         <name>oozie.service.JPAService.jdbc.urlname>
070         <value>jdbc:mysql://localhost:3306/oozievalue>
071     property>
072     <property>
073         <name>oozie.service.JPAService.jdbc.usernamename>
074         <value>oozievalue>
075     property>
076     <property>
077         <name>oozie.service.JPAService.jdbc.passwordname>
078         <value>oozievalue>
079     property>
080  
081     <property>
082         <name>oozie.service.JPAService.pool.max.active.connname>
083         <value>10value>
084     property>
085  
086     <property>
087         <name>oozie.service.HadoopAccessorService.kerberos.enabledname>
088         <value>falsevalue>
089     property>
090     <property>
091         <name>local.realmname>
092         <value>LOCALHOSTvalue>
093     property>
094     <property>
095         <name>oozie.service.HadoopAccessorService.keytab.filename>
096         <value>${user.home}/oozie.keytabvalue>
097     property>
098     <property>
099         <name>oozie.service.HadoopAccessorService.kerberos.principalname>
100         <value>${user.name}/localhost@${local.realm}value>
101     property>
102     <property>
103         <name>oozie.service.HadoopAccessorService.jobTracker.whitelistname>
104         <value> value>
105     property>
106     <property>
107         <name>oozie.service.HadoopAccessorService.nameNode.whitelistname>
108         <value> value>
109     property>
110  
111     <property>
112         <name>oozie.service.HadoopAccessorService.hadoop.configurationsname>
113         <value>*=/etc/hadoop/confvalue>
114     property>
115     <property>
116         <name>oozie.service.WorkflowAppService.system.libpathname>
117         <value>/user/${user.name}/share/libvalue>
118     property>
119  
120     <property>
121         <name>use.system.libpath.for.mapreduce.and.pig.jobsname>
122         <value>falsevalue>
123     property>
124  
125     <property>
126         <name>oozie.authentication.typename>
127         <value>simplevalue>
128     property>
129     <property>
130         <name>oozie.authentication.token.validityname>
131         <value>36000value>
132     property>
133     <property>
134         <name>oozie.authentication.signature.secretname>
135         <value>oozievalue>
136     property>
137  
138     <property>
139       <name>oozie.authentication.cookie.domainname>
140       <value>value

你可能感兴趣的:(文章)