Azkaban安装与配置
1.将Azkaban压缩包上传
2.解压unzip azkaban.zip
3.在/root/apps/azkaban/azkaban-web-2.5.0目录下生成 keystore 的密码及相应信息
keytool -keystore keystore -alias jetty -genkey -keyalg RSA
4.生成时区文件
tzselect
覆盖本地时区配置
cp /usr/share/zoneinfo/Asia/Shanghai /etc/localtime
集群时间同步
sudo date -s ‘2017-06-14 09:23:45’ hwclock -w
5.修改配置文件
/root/apps/azkaban/azkaban-web-2.5.0/conf
azkaban.properties
#Azkaban Personalization Settings azkaban.name=Test azkaban.label=My Local Azkaban azkaban.color=#FF3601 azkaban.default.servlet.path=/index web.resource.dir=web/ default.timezone.id=Asia/Shanghai #Azkaban UserManager class user.manager.class=azkaban.user.XmlUserManager user.manager.xml.file=conf/azkaban-users.xml #Loader for projects executor.global.properties=conf/global.properties azkaban.project.dir=projects database.type=mysql mysql.port=3306 mysql.host=hdp-1 mysql.database=azkaban mysql.user=root mysql.password=root mysql.numconnections=100 # Velocity dev mode velocity.dev.mode=false # Azkaban Jetty server properties. jetty.maxThreads=25 jetty.ssl.port=8443 jetty.port=8081 jetty.keystore=keystore jetty.password=403411 jetty.keypassword=403411 jetty.truststore=keystore jetty.trustpassword=403411 # Azkaban Executor settings executor.port=12321 # mail settings mail.sender=xxxxxxxx@163.com mail.host=smtp.163.com job.failure.email=xxxxxxxx@163.com job.success.email=xxxxxxxx@163.com lockdown.create.projects=false cache.directory=cache
azkaban-users.xml:添加一个超级用户
<azkaban-users> <user username="azkaban" password="azkaban" roles="admin" groups="azkaban" /> <user username="metrics" password="metrics" roles="metrics"/> <user username="admin" password="admin" roles="admin,metrics" /> <role name="admin" permissions="ADMIN" /> <role name="metrics" permissions="METRICS"/> </azkaban-users>
/root/apps/azkaban/azkaban-executor-2.5.0/conf
azkaban.properties
#Azkaban default.timezone.id=Asia/Shanghai # Azkaban JobTypes Plugins azkaban.jobtype.plugin.dir=plugins/jobtypes #Loader for projects executor.global.properties=conf/global.properties azkaban.project.dir=projects database.type=mysql mysql.port=3306 mysql.host=hdp-1 mysql.database=azkaban mysql.user=root mysql.password=root mysql.numconnections=100 # Azkaban Executor settings executor.maxThreads=50 executor.port=12321 executor.flow.threads=30
6.在MySQL数据库中创建相应的数据库以及将azkaban需要的表创建好
创建一个azkaban库
create database azkaban;
将需要的表创建好
use azkaban; source /root/apps/azkaban/azkaban-2.5.0/create-all-sql-2.5.0.sql;
7.启动azkaban在/root/apps/azkaban/azkaban-web-2.5.0目录下
bin/azkaban-web-start.sh
访问https://hdp-1:8443,一定要加https安全协议