Azkaban-3.x configuration information described

1. Azkaban Web Server Configuration

(1) Basic Configuration

Configuration

Explanation

Defaults

azkaban.name

Examples of Azkaban name displayed on the web page

Local

azkaban.label

Description of an example of Azkaban

My Local Azkaban

azkaban.color

Web page theme colors

#FF3601

azkaban.default.servlet.path

WEB page access the default root path

/index

web.resource.dir

Position CSS and JS files are located

web/

default.timezone

Time zone should be set for the Asia / Shanghai

America/Los_Angeles

viewer.plugin.dir

Monitoring plug-in installation path

plugins/viewer

cache.directory

Cache directory

cache

job.max.Xms

Allocation of memory during initialization each Job

1GB

job.max.Xmx

Each Job can request the maximum memory

2GB

(2) Jetty relevant configuration

Configuration

Explanation

Defaults

jetty.port

jetty port

8081

jetty.use.ssl

Whether to use SSL

false

jetty.maxThreads

The maximum number of threads used to send the request

25

jetty.ssl.port

SSL port

8443

jetty.keystore

Keystore file location

jetty.password

jetty password

jetty.keypassword

jetty password

jetty.truststore

The position of truststore file

jetty.trustpassword

trust password

(3) Project management-related configuration

Configuration

Explanation

Defaults

project.temp.dir

Temporary files used when scheduling tasks folder upload

temp

project.version.retention

Retention schedule of the project has not been carried out before the clean-up version number

3

creator.default.proxy

The project creator will automatically be added to the project as a proxy user

true

lockdown.create.projects

To prevent any person other than the person with the Admin role in creating a new project

false

lockdown.upload.projects

To prevent any person other than the administrator user and the user has permission to upload uploads scheduled tasks

false

(4) MySQL configuration

Configuration

Explanation

Defaults

database.type

Database type, currently only supports MySQL

mysql

mysql.port

MySQL port number

3306

mysql.host

MySQL hostname

localhost

mysql.database

MySQL database

mysql.user

MySQL user name

mysql.password

MySQL password

mysql.numconnections

Web clients can open the maximum number of MySQL connections

100

(5) Multiple Executor mode related

azkaban.use.multiple.executors

  • Description: Multi-executor mode is turned on
  • Default: false

azkaban.executorselector.filters

  • Description: When a plurality of Executor simultaneously started, select an Executor need to perform the task, there is provided a group of filter types, do not satisfy the requirements of the Executor will not be assigned the task, optional values ​​are: StaticRemainingFlowSize, MinimumFreeMemory and CpuStatus, note that this has nothing to do with the configuration of the order
  • Default: None

azkaban.executorselector.comparator.{ComparatorName}

  • Description: Upon setting of the filter type Executor, also set the filter conditions, the type of comparator has NumberOfAssignedFlowComparator, Memory, LastDispatched and the four CpuUsage
  • 举例: (1) azkaban.executorselector.comparator.NumberOfAssignedFlowComparator=1 解释:如果已经某个Executor上已经提交的任务个数大于1个,就不往该Executor上分配任务 (2) azkaban.executorselector.comparator.Memory=1 解释:如果某个Executor所在节点的可用内存不足1G,就不往该节点分配任务 (3) azkaban.executorselector.comparator.CpuUsage=1 解释:如果某个Executor所在节点的可用CPU核数不足1个,就不往该节点分配任务 (4) azkaban.executorselector.comparator.LastDispatched=1 解释:如果上一次任务就是在这个Executor上分配的,那么本次的任务就不分配给这个Executor

azkaban.queueprocessing.enabled

  • 说明:是否启用队列来分配任务
  • 默认值:true

azkaban.webserver.queue.size

  • 说明:队列的大小
  • 默认值:100000

azkaban.activeexecutor.refresh.milisecinterval

  • 说明:统计可用executor个数的时间间隔(ms)
  • 默认值:50000

azkaban.activeexecutor.refresh.flowinterval

  • 说明:用于统计当前阻塞的任务个数的时间间隔(ms)
  • 默认值:5

azkaban.executorinfo.refresh.maxThreads

  • 说明:用于统计以上信息的线程个数
  • 默认值:5

(6) Executor 管理相关配置

配置

说明

默认值

execution.logs.retention.ms

任务执行日志的保留时间(ms)

7257600000L(12 weeks)

(7) 通信邮件相关配置

配置

说明

默认值

mail.sender

azkaban发送通知消息的邮箱地址

mail.host

邮箱服务器的主机名

mail.user

邮箱服务器的用户名

mail.password

邮箱服务器的密码

job.failure.email

任务执行成功发送的邮箱

job.success.email

任务执行失败发送的邮箱

(8) 用户管理相关配置

配置

说明

默认值

user.manager.class

用户管理使用的类(可自定义)

azkaban.user.XmlUserManager

user.manager.xml.file

配置用户信息的xml文件的路径

conf/azkaban-users.xml

(9) 用户 Session 相关配置

配置

说明

默认值

session.time.to.live

用户session超时时间(ms)

86400000

max.num.sessions

最多可以同时开启的session个数

10000

(10) HA 相关配置

配置

说明

默认值

azkaban.webserver.external_hostname

另一个webserver的主机名

azkaban.webserver.external_ssl_port

另一个webserver的ssl端口

azkaban.webserver.external_port=8081

另一个webserver的端口

2. Azkaban Executor Server 配置

(1) 基本配置

配置

说明

默认值

azkaban.webserver.url

web server 的URL

azkaban.jobtype.plugin.dir

jobtype plugin 保存路径

plugins/jobtypes

azkaban.project.dir

项目保存路径

projects

default.timezone.id

Asia/Shanghai

America/Los_Angeles

(2) MySQL 相关配置

配置

说明

默认值

database.type

数据库类型,目前只支持MySQL

mysql

mysql.port

MySQL端口号

3306

mysql.host

MySQL主机名

localhost

mysql.database

MySQL数据库

mysql.user

MySQL用户名

mysql.password

MySQL密码

mysql.numconnections

Web客户端可以打开的MySQL连接的最大个数

100

(3) Executor 相关配置

配置

说明

默认值

executor.port

executor端口

12321

executor.maxThreads

每个executor使用的线程数

executor.flow.threads

每个任务可以使用的线程数

executor.global.propertie

Executor使用的全局配置文件的路径

conf/global.properties

3. 插件配置

Azkaban在安全功能上做了增强,除了可以使用Azkaban配置的用户执行任务以外,也可以使用系统用户来提交任务,这使的Azkaban充分利用了Linux系统的权限安全机制,并且使得资源的可见性提升,简化了监控资源的操作。配置过程如下:

编辑azkaban-exec-server/plugins/jobtypes/commonprivate.properties文件:

# 设置为true,才可以使用系统用户提交任务
execute.as.user=true # 后面的路径是你放置execute-as-user这个文件的路径 azkaban.native.lib=/path/to/execute-as-user # 使用系统用户提交的时候,azkaban默认把它们放入azkaban组 # 所以你需要提前创建好azkaban这个组或者修改为一个已存在的组 azkaban.group.name=azkaban

execute-as-user文件的构造过程:

# (1) 在源码包中找到execute-as-user.c文件的位置 # 例如在源码包的az-exec-util/src/main/c/目录下 find . -name execute-as-user.c # (2) 将execute-as-user.c文件移动到azkaban的安装目录下,例如: cp ./az-exec-util/src/main/c/execute-as-user.c /opt/azkaban/ # (3) 进去azkaban安装目录,执行以下命令 cd /opt/azkaban/ gcc execute-as-user.c -o execute-as-user sudo chown root execute-as-user sudo chmod 6050 execute-as-user

Guess you like

Origin www.cnblogs.com/ninglinglong/p/11595574.html