天天看點

Apache DolphinScheduler叢集更新/安裝(1.2.1 & 1.3.0)目錄1 版本說明2 更新/安裝 1.2.1 版本 Apache DolphinScheduler3 更新/安裝 1.3.0 版本 Apache DolphinScheduler

目錄

  • 1 版本說明
    • 1.1 關于 1.1.0 版本
    • 1.2 關于 1.2.0 版本
      • 1.2.1 新特性
      • 1.2.2 增強功能
      • 1.2.3 修複的 Bug
    • 1.3 關于 1.2.1 版本
  • 2 更新/安裝 1.2.1 版本 Apache DolphinScheduler
    • 2.1 安裝/更新之前
    • 2.2 下載下傳并解壓
    • 2.3 中繼資料
      • 2.3.1 如果新環境
      • 2.3.2 如果更新
    • 2.4 配置安裝腳本
    • 2.5 配置 Nginx
    • 2.6 安裝并啟動服務
    • 2.7 通路前端頁面
  • 3 更新/安裝 1.3.0 版本 Apache DolphinScheduler
    • 3.1 配置與啟動
    • 3.2 資料連結

1 版本說明

每一個版本都會在上一版的基礎上修複一些問題、增加新的特性和對已有的功能進行增強。具體的可以檢視 Release。

1.1 關于 1.1.0 版本

具體可以檢視 Lidong Dai 的部落格 Easy Scheduler 1.1.0 Release釋出,分布式工作流任務排程系統。

這個版本的源碼的包命名統一為

cn.escheduler.*

,安裝部署需要需要單獨下載下傳後端和前端的二進制包進行安裝部署,關于這個版本的安裝部署可以參考我的另一篇 blog 工作流任務排程系統:Apache DolphinScheduler

1.2 關于 1.2.0 版本

從這個版本開始,項目的代碼整體上全部遷移為 Apache 項目,包命名規範統一

org.apache.dolphinscheduler.*

。在這個版本新增了對 PostgreSQL SQL 的支援。

1.2.1 新特性

  1. 支援 PostgreSQL SQL。
  2. 将所有中文名稱改為英文名。
  3. 添加 Flink 和 Http 任務的支援。
  4. 跨項目依賴。
  5. 将 mybatis 修改為 mybatisplus,支援多個資料庫。
  6. 添加導入和導出定義特征。
  7. Github Actions CI 編碼檢查。
  8. 添加方法和參數注釋。
  9. 為通用子產品添加Java文檔。

1.2.2 增強功能

  1. 添加 license 和 通知 檔案。
  2. 将 batchDelete 程式 的 Define/Instance 移到外部進行實物處理。
  3. 移除登陸使用者名前後的空格。
  4. Dockerfile 的優化。
  5. 更改

    mysql-connector-java

    的作用域為

    test

  6. 所有者和管理者可以删除 schedule。
  7. 資料庫頁面重命名和背景顔色的修改。
  8. 添加 postgre 性能監聽器。
  9. 解決樣式沖突,收件人無法進行 tab 和 value 的驗證。
  10. 更改複選框的背景顔色和環境為中文。
  11. 将中文 SQL 更改為英文。
  12. 更改

    sqlSessionTemplate

    單例并重新格式化代碼。
  13. loadaverage

    的值應該為小數點後 2 位。
  14. 删除報警組時需要删除使用者與報警組的關系。
  15. 删除租戶是删除檢查資源。
  16. 删除工作組之前檢查

    processInstance

    狀态。
  17. 删除租戶時添加檢查使用者和自定義功能。
  18. 在 Check 前删除,以避免

    KeeperException$NoNodeException

1.2.3 修複的 Bug

  1. 修複了 #1245 号問題,使得

    scanCommand

    具有了事務性。
  2. 修複了

    ZKWorkerClient

    無法關閉

    PathChildrenCache

    的問題。
  3. 修複了資料類型存在的轉換錯誤 和 email 發送的錯誤。
  4. 修複捕獲異常事物的方法不生效,無法修改的錯誤。
  5. 修複 Spring 中事物不能工作的 bug。
  6. 修複Task 日志列印 Worker 日志的 bug。
  7. 修複 api server 調試模式的 bug。
  8. 修複了 task 異常和 task 運作的 bug。
  9. 修複bug:task 隊列長度的錯誤。
  10. 修複不合适的消息錯誤。
  11. 修複bug:電話可以為空。
  12. 修複 email 錯誤密碼。
  13. 修複 CheckUtils.checkUserParams 方法。
  14. 修複當處于 “送出成功” 狀态的任務時無法終止程序的問題。
  15. 修複 upgrade 或者 create 連接配接過多的問題。
  16. 修複 Worker 使用隊列執行任務時的錯誤,并删除檢查。
  17. 解決驗證 UDF 名字的錯誤和删除 UDF 錯誤。
  18. 修複bug:恢複故障轉移時 Task 不能送出。
  19. 修複bug:管理者将項目授權給普通使用者,但是普通使用者看不到管理者建立的 process 定義。
  20. 修複bug:建立 dolphinscheduler sql 失敗。

1.3 關于 1.2.1 版本

更詳細的釋出資訊可以檢視 dailidong 的部落格 Apache DolphinScheduler 1.2.1釋出,可視化工作流任務排程系統。在這個版本合并了前端和後端的源碼包,同時對配置檔案也進行了部分合并,減少了配置檔案。

2 更新/安裝 1.2.1 版本 Apache DolphinScheduler

2.1 安裝/更新之前

DolphinScheduler 的軟硬體環境建議配置要求可以檢視 官方部署文檔/軟硬體環境建議配置,同時需要有能夠通路的中繼資料庫 (PostgreSQL 8.2.15+ 或者 Mysql 5.6 or 5.7 ),JDK 1.8+, ZooKeeper 3.4.6+,其它比如(Apache Hadoop、Apache Hive 、Apache Spark、Apache Flink 等 可以選裝)。

安裝之前需要先在系統環境中建立一個普通使用者,作為我們部署 Apache DolphinScheduler 的使用者,同時如果是叢集化部署,多個節點需要配置好 SSH 。關于更詳細的安裝和配置可以參考 我一篇 blog 工作流任務排程系統:Apache DolphinScheduler,這篇 blog 以 1.1.0 為例詳細講解了安裝過程。下面這部分會介紹新環境下的安裝部署,和在 1.1.0 版本之上的更新安裝。

2.2 下載下傳并解壓

通路 Apache DolphinScheduler 鏡像 /apache/incubator/dolphinscheduler,部署可以直接下載下傳二進制分發包(Binary Distribution) apache-dolphinscheduler-incubating-1.2.1-dolphinscheduler-bin.tar.gz。

wget https://mirrors.tuna.tsinghua.edu.cn/apache/incubator/dolphinscheduler/1.2.1/apache-dolphinscheduler-incubating-1.2.1-dolphinscheduler-bin.tar.gz

# 解壓
tar -zxf apache-dolphinscheduler-incubating-1.2.1-dolphinscheduler-bin.tar.gz

# 修改檔案的所屬的使用者和租
sudo chown -R escheduler:escheduler apache-dolphinscheduler-incubating-1.2.1-dolphinscheduler-bin
           

解壓後進入解壓的檔案夾下,可以看到如下内容,我們在這裡可以看到一個二進制包下已經包含了前端和後端的所有檔案。

drwxr-xr-x 2 escheduler escheduler  4096 Mar  8 15:15 bin
drwxr-xr-x 7 escheduler escheduler  4096 Mar  8 15:15 conf
-rw-r--r-- 1 escheduler escheduler   563 Feb  7 16:55 DISCLAIMER
-rw-r--r-- 1 escheduler escheduler 18583 Feb  7 16:55 install.sh
drwxr-xr-x 2 escheduler escheduler 16384 Mar  8 15:15 lib
-rw-r--r-- 1 escheduler escheduler 41304 Feb  7 16:55 LICENSE
drwxr-xr-x 3 escheduler escheduler 16384 Feb  7 16:55 licenses
-rw-r--r-- 1 escheduler escheduler 83680 Feb  7 16:55 NOTICE
drwxr-xr-x 2 escheduler escheduler  4096 Mar  8 15:15 script
drwxr-xr-x 4 escheduler escheduler  4096 Mar  8 15:15 sql
drwxr-xr-x 8 escheduler escheduler  4096 Mar  8 15:15 ui
           

2.3 中繼資料

2.3.1 如果新環境

需要建立 一個中繼資料庫的使用者,并建立一個庫,例如元數存儲選擇使用 MySQL,并在 MySQL 中建立

escheduler

庫,然後執行

sql/dolphinscheduler_mysql.sql

下的 sql 腳本。例如環境中有 Beeline 工具,可以這樣執行:

beeline -n escheduler -p 123456 -d "com.mysql.jdbc.Driver" \
-u "jdbc:mysql://cdh1:3306/escheduler?useUnicode=true&characterEncoding=utf8&useSSL=false" \
--isolation=TRANSACTION_SERIALIZABLE -f sql/dolphinscheduler_mysql.sql
           

2.3.2 如果更新

執行更新之前,需要先配置好

conf/application.properties

中關于資料庫的配置資訊,如果是 MySQL 需要先注釋掉 postgre 配置。

# postgre
#spring.datasource.driver-class-name=org.postgresql.Driver
#spring.datasource.url=jdbc:postgresql://localhost:5432/dolphinscheduler
# mysql
spring.datasource.driver-class-name=com.mysql.jdbc.Driver
spring.datasource.url=jdbc:mysql://cdh1:3306/escheduler?characterEncoding=UTF-8
spring.datasource.username=escheduler
spring.datasource.password=123456
           

在接執行更新的腳本之前需要我們将對應資料庫的驅動包下載下傳到

lib

下。執行完畢會提示

upgrade DolphinScheduler success

,腳本會自動更新元數庫的資料。

# 下載下傳 mysql 驅動包到 lib/ 下
wget https://repo1.maven.org/maven2/mysql/mysql-connector-java/5.1.34/mysql-connector-java-5.1.34.jar -P lib/

# 執行更新腳本
sh script/upgrade-dolphinscheduler.sh
           

2.4 配置安裝腳本

在解壓的個目錄下編輯修改自動化部署的腳本檔案:

vim install.sh

,修改如下的配置項,其它配置可保持預設。

# for example postgresql or mysql ...
dbtype="mysql"

# db config
# db address and port
dbhost="cdh1:3306"

# db name
dbname="escheduler"

# db username
username="escheduler"

# db passwprd
# Note: if there are special characters, please use the \ transfer character to transfer
passowrd="123456"

# conf/config/install_config.conf config
# Note: the installation path is not the same as the current path (pwd)
installPath="/opt/DolphinScheduler/escheduler-backend"

# deployment user
# Note: the deployment user needs to have sudo privileges and permissions to operate hdfs. If hdfs is enabled, the root directory needs to be created by itself
deployUser="escheduler"

# zk cluster
zkQuorum="cdh1:2181,cdh2:2181,cdh3:2181"

# install hosts
# Note: install the scheduled hostname list. If it is pseudo-distributed, just write a pseudo-distributed hostname
ips="cdh2,cdh3"

# run master machine
# Note: list of hosts hostname for deploying master
masters="cdh2"

# run worker machine
# note: list of machine hostnames for deploying workers
workers="cdh2,cdh3"

# run alert machine
# note: list of machine hostnames for deploying alert server
alertServer="cdh2"

# run api machine
# note: list of machine hostnames for deploying api server
apiServers="cdh2"

######### 報警郵箱配置可選,這裡以網易雲郵箱為例
# alert config
# mail protocol
mailProtocol="SMTP"

# mail server host
mailServerHost="smtp.163.com"

# mail server port
mailServerPort="465"

# sender
mailSender="[email protected]"

# user
mailUser="[email protected]"

# sender password
mailPassword="123456"

# download excel path
xlsFilePath="/home/escheduler/xls"

# resource Center upload and select storage method:HDFS,S3,NONE
resUploadStartupType="HDFS"

# if resUploadStartupType is HDFS,defaultFS write namenode address,HA you need to put core-site.xml and hdfs-site.xml in the conf directory.
# if S3,write S3 address,HA,for example :s3a://dolphinscheduler,
# Note,s3 be sure to create the root directory /dolphinscheduler
defaultFS="hdfs://cdh1:8020"

# resourcemanager HA configuration, if it is a single resourcemanager, here is yarnHaIps=""
yarnHaIps="cdh1"

# if it is a single resourcemanager, you only need to configure one host name. If it is resourcemanager HA, the default configuration is fine.
singleYarnIp="cdh1"

# hdfs root path, the owner of the root path must be the deployment user. 
# versions prior to 1.1.0 do not automatically create the hdfs root directory, you need to create it yourself.
hdfsPath="/escheduler"

# common config
# Program root path
programPath="opt/DolphinScheduler/escheduler-backend"

# download path
downloadPath="/tmp/escheduler/download"

# task execute path
execPath="/tmp/escheduler/exec"

# zk config
# zk root directory
zkRoot="/escheduler"
           

2.5 配置 Nginx

DolphinScheduler 前端服務需要 Nginx 服務。

# 1 下載下傳 Nginx 離線安裝包
# 例如下載下傳 Cento7 CPU指令為 x86版本的 
wget http://nginx.org/packages/mainline/centos/7/x86_64/RPMS/nginx-1.17.6-1.el7.ngx.x86_64.rpm

# 2 安裝
rpm -ivh nginx-1.17.6-1.el7.ngx.x86_64.rpm
           

修改或添加一個 Nginx 配置檔案作為 DolphinScheduler UI 前端的服務。例如有

/etc/nginx/conf.d/escheduler.conf

,修改如下,重點配置

server_name

root

proxy_pass

,其中 root 就是我們解壓的分發包中

ui/

的路徑。注意:在 1.2.1 版本中 ui 的連接配接由舊版本的 /escheduler 改為了 /dolphinscheduler。

server {
    listen       8888;# 通路端口
    server_name  cdh2;
    #charset koi8-r;
    #access_log  /var/log/nginx/host.access.log  main;
    location / {
        root   /opt/DolphinScheduler/apache-dolphinscheduler-incubating-1.2.1-dolphinscheduler-bin/ui; # 靜态檔案目錄
        index  index.html index.html;
    }
    #location /escheduler {
    location /dolphinscheduler{
        proxy_pass http://cdh2:12345; # 接口位址
        proxy_set_header Host $host;
        proxy_set_header X-Real-IP $remote_addr;
        proxy_set_header x_real_ipP $remote_addr;
        proxy_set_header remote_addr $remote_addr;
        proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
        proxy_http_version 1.1;
        proxy_connect_timeout 300s;
        proxy_read_timeout 300s;
        proxy_send_timeout 300s;
        proxy_set_header Upgrade $http_upgrade;
        proxy_set_header Connection upgrade;
    }
    #error_page  404              /404.html;
    # redirect server error pages to the static page /50x.html
    #
    error_page   500 502 503 504  /50x.html;
    location = /50x.html {
        root   /usr/share/nginx/html;
    }
}
           

注意:這裡再重點提下 ui 的路徑如何配置(即上面的配置檔案中 root 的值)

  • 如果是 1.2.0 版本就是你下載下傳的 前端的(Frontend Binary Distribution)二進制包解壓包下的 dist 的路徑。

    /xx/apache-dolphinscheduler-incubating-1.2.0-dolphinscheduler-front-bin/dist

  • 如果是 1.2.1 版本就是你下載下傳的二進制包(Binary Distribution,因為 這個版本前端和後端合并隻有一個包)二進制包解壓包下的 ui 的路徑。

    /xx/apache-dolphinscheduler-incubating-1.2.1-dolphinscheduler-bin/ui

2.6 安裝并啟動服務

# 執行安裝部署腳本,注意是 escheduler 使用者執行
sh ./install.sh

# 啟動 Nginx 服務
systemctl restart nginx

           

關于服務的其它啟停指令

# 1 啟停整個叢集
## 1.1 停止叢集所有服務
sh bin/stop-all.sh

## 1.2 開啟叢集所有服務
sh bin/start-all.sh


# 2 啟停 Master
## 2.1 啟動 master 服務
sh bin/dolphinscheduler-daemon.sh start master-server

## 2.2 關閉 master 服務
sh bin/dolphinscheduler-daemon.sh stop master-server


# 3 啟停 Worker
## 3.1 啟動 worker 服務
sh bin/dolphinscheduler-daemon.sh start worker-server

## 3.2 關閉 worker 服務
sh bin/dolphinscheduler-daemon.sh stop worker-server


# 4 啟停 Api
## 4.1 啟動 Api 服務
sh bin/dolphinscheduler-daemon.sh start api-server

## 4.2 關閉 Api 服務
sh bin/dolphinscheduler-daemon.sh stop api-server


# 5 啟停 Logger
## 5.1 啟動 Logger 服務
sh bin/dolphinscheduler-daemon.sh start logger-server

## 5.2 關閉 Logger 服務
sh bin/dolphinscheduler-daemon.sh stop logger-server


# 6 啟停 Alert
## 6.1 啟動 Alert 服務
sh bin/dolphinscheduler-daemon.sh start alert-server

## 6.2 關閉 Alert 服務
sh bin/dolphinscheduler-daemon.sh stop alert-server
           

2.7 通路前端頁面

在浏覽器通路 http://${master-ip}:8888,master-ip 是主節點服務的 ip。通路成功後需要輸入使用者名和密碼,如果是新安裝的預設的賬号為 admin/dolphinscheduler123, 如果是更新後的則沿用舊的賬号,例如在 1.1.0 預設的賬号為admin/escheduler123。

賬号驗證成功後可以進入頁面,如果是更新的,可以檢視到原先的項目的資訊,點選頁頭的 監控中心 下的 Worker,可以看到叢集中所有 Worker 的資訊,如下圖所示。

Apache DolphinScheduler叢集更新/安裝(1.2.1 & 1.3.0)目錄1 版本說明2 更新/安裝 1.2.1 版本 Apache DolphinScheduler3 更新/安裝 1.3.0 版本 Apache DolphinScheduler

3 更新/安裝 1.3.0 版本 Apache DolphinScheduler

總體更新或安裝類似于 1.2.1 版本。首先需要我們 1.3.0 的安裝包,安裝包官網還沒有連接配接進行下載下傳,我們可以通過源碼編譯擷取(環境中需要安裝 Node.js、 Maven),Maven 最好使用最新版(例如 3.1 版本安裝時會報錯)。

3.1 配置與啟動

# 1 擷取源碼
git clone https://github.com/apache/incubator-dolphinscheduler.git
cd incubator-dolphinscheduler
git tar
# 或者直接通過下載下傳 1.3.0 源碼方式編譯
# 但不建議,因為這個版本建立工作組的入口沒有了,具體可以檢視 [#2959](https://github.com/apache/incubator-dolphinscheduler/issues/2959)、 [Feature-2815](https://github.com/apache/incubator-dolphinscheduler/pull/2934)
# wget https://github.com/apache/incubator-dolphinscheduler/archive/1.3.0.tar.gz

# 2 編譯
# 這裡直接編譯的主分支的代碼,大家也可以檢出到 1.3.1 進行編譯: git checkout 1.3.1
## 2.1 生成 rpm 包
mvn -U clean install -Prpmbuild -Dmaven.test.skip=true -X
## 2.2 生成 tar/zip 包
mvn clean package install -Prelease -Dmaven.test.skip=true
# mvn package -Prelease -Dmaven.test.skip=true

           
Apache DolphinScheduler叢集更新/安裝(1.2.1 & 1.3.0)目錄1 版本說明2 更新/安裝 1.2.1 版本 Apache DolphinScheduler3 更新/安裝 1.3.0 版本 Apache DolphinScheduler
# 3 檢視編譯後的包。
# 編譯成功後的 tar/zip 包在如下目錄下
ls -l dolphinscheduler-dist/target/
# 編譯成功後 rpm 包在如下目錄下
ls -l dolphinscheduler-dist/target/rpm/apache-dolphinscheduler-incubating/RPMS/noarch
           
Apache DolphinScheduler叢集更新/安裝(1.2.1 & 1.3.0)目錄1 版本說明2 更新/安裝 1.2.1 版本 Apache DolphinScheduler3 更新/安裝 1.3.0 版本 Apache DolphinScheduler

通過上面的編譯我們成功得到了 DS 的安裝包,但是是一個 RPM 包,可以直接執行

rpm -ivh apache-dolphinscheduler-incubating-1.3.0-1.noarch.rpm

手動安裝,預設會安裝到

/opt/soft/apache-dolphinscheduler-incubating-1.3.0/

。這裡我們在原先 DS 的基礎上(路徑下)更新安裝,是以我們直接解壓RPM 包,進行手動配置更新安裝,RPM包括是使用cpio格式打包的,是以可以先轉成cpio然後解壓

# 解壓 RPM 包,會在目前目錄解壓生成  opt/soft/apache-dolphinscheduler-incubating-1.3.0
rpm2cpio apache-dolphinscheduler-incubating-1.3.0-1.noarch.rpm | cpio -div
# 将 apache-dolphinscheduler-incubating-1.3.0 拷貝指定目錄下,例如 /u01/DolphinScheduler 下

           

修改元數庫資訊,例如這裡使用 MySQL,與 1.2.1 版本不同的是這裡需要修改

conf/datasource.properties

配置檔案,注釋掉 postgre 配置

添加如下 MySQL 配置。

# postgresql。這是官方推薦 postgresql 配置,使用 MySQL 的将中繼資料遷移到 postgresql 中
# spring.datasource.driver-class-name=org.postgresql.Driver
# spring.datasource.url=jdbc:postgresql://localhost:5432/dolphinscheduler
# spring.datasource.username=test
# spring.datasource.password=test

# mysql
spring.datasource.driver-class-name=com.mysql.jdbc.Driver
spring.datasource.url=jdbc:mysql://cdh1:3306/escheduler?characterEncoding=UTF-8
spring.datasource.username=escheduler
spring.datasource.password=123456
           

添加 MySQL 驅動包,執行更新腳本,更新中繼資料庫中的資料

# 下載下傳 mysql 驅動包到 lib/ 下
wget https://repo1.maven.org/maven2/mysql/mysql-connector-java/5.1.34/mysql-connector-java-5.1.34.jar -P lib/

# 執行更新腳本。更新中繼資料時一定保持中繼資料表 t_ds_version 的 version 值低于更新的版本,
sh script/upgrade-dolphinscheduler.sh
           

更新前可以對 MySQL 庫和 安裝目錄進行提前備份,然後清空舊版本安裝目錄下的檔案,這裡将新本的安裝目錄改為

/u01/dolphinscheduler

,是以建立這個目錄并屬組改為 DS 的使用者

mkdir /u01/dolphinscheduler
 chown escheduler:escheduler /u01/dolphinscheduler
           

修改

conf/config/install_config.conf

,修改内容和 2.4 配置安裝腳本 類似,主要參考修改如下,其他可使用預設值。

# NOTICE :  If the following config has special characters in the variable `.*[]^${}\+?|()@#&`, Please escape, for example, `[` escape to `\[`
# postgresql or mysql
dbtype="mysql"

# db config
# db address and port
dbhost="cdh1:3306"

# db username
username="escheduler"

# database name
dbname="escheduler"

# db passwprd
# NOTICE: if there are special characters, please use the \ to escape, for example, `[` escape to `\[`
password="123456"

# zk cluster
zkQuorum="cdh1:2181,cdh2:2181,cdh3:2181"

# Note: the target installation path for dolphinscheduler, please not config as the same as the current path (pwd)
installPath="/u01/dolphinscheduler"

# deployment user
# Note: the deployment user needs to have sudo privileges and permissions to operate hdfs. If hdfs is enabled, the root directory needs to be created by itself
deployUser="escheduler"

# 郵箱配置這裡省略 ……

# resource storage type:HDFS,S3,NONE
resourceStorageType="HDFS"

# if resourceStorageType is HDFS,defaultFS write namenode address,HA you need to put core-site.xml and hdfs-site.xml in the conf directory.
# if S3,write S3 address,HA,for example :s3a://dolphinscheduler,
# Note,s3 be sure to create the root directory /dolphinscheduler
defaultFS="hdfs://cdh1:8020"

# if resourcemanager HA enable or not use resourcemanager, please skip this value setting; If resourcemanager is single, you only need to replace yarnIp1 to actual resourcemanager hostname.
singleYarnIp="cdh1"

# resource store on HDFS/S3 path, resource file will store to this hadoop hdfs path, self configuration, please make sure the directory exists on hdfs and have read write permissions。/dolphinscheduler is recommended
resourceUploadPath="/escheduler"

# who have permissions to create directory under HDFS/S3 root path
# Note: if kerberos is enabled, please config hdfsRootUser=
hdfsRootUser="hdfs"

# api server port
apiServerPort="12345"

# install hosts
# Note: install the scheduled hostname list. If it is pseudo-distributed, just write a pseudo-distributed hostname
ips="cdh2,cdh3"

# run master machine
# Note: list of hosts hostname for deploying master
masters="cdh2"

# run worker machine
# note: need to write the worker group name of each worker, the default value is "default"
workers="cdh2:cdh2,cdh3:cdh3"

# run alert machine
# note: list of machine hostnames for deploying alert server
alertServer="cdh2"

# run api machine
# note: list of machine hostnames for deploying api server
apiServers="cdh2"
           

新版本中添加了DataX 、Sqoop、Conditions 類型的工作流定義,如下圖所示。當使用 DataX 時,需要我們修改

conf/env/dolphinscheduler_env.sh

腳本中

export DATAX_HOME=/opt/soft/datax/bin/datax.py

,預設使用

/opt/soft/datax/bin/datax.py

執行任務,路徑配為自己環境中的 DataX 的路徑,如果沒有需要自己下載下傳(DataX下載下傳位址)解壓到環境中。目前 DataX 工作流支援的資料庫有 MySQL、PostgreSQL、Oracle、SQLServer。

Apache DolphinScheduler叢集更新/安裝(1.2.1 & 1.3.0)目錄1 版本說明2 更新/安裝 1.2.1 版本 Apache DolphinScheduler3 更新/安裝 1.3.0 版本 Apache DolphinScheduler

Nginx 中修改 8888 資源路徑

location / {
        root   /u01/dolphinscheduler/ui;
        index  index.html index.html;
    }
           

開始安裝

# 執行安裝部署腳本,注意是 escheduler 使用者執行,
sh ./install.sh

# 啟動 Nginx 服務
systemctl restart nginx

# 檢視背景 java 程序
## master 節點有如下程序 
[email protected] apache-dolphinscheduler-incubating-1.3.0]$ jps
26480 Jps
23890 LoggerServer
23781 MasterServer
23943 AlertServer
23997 ApiApplicationServer
23837 WorkerServer
# Worker 節點有如下程序
[[email protected] escheduler-backend]$ jps
15427 LoggerServer
15367 WorkerServer
19417 Jps
           

安裝完畢後 DS 服務已經啟動,如果想重新開機 DS 服務,可以參考 2.6 安裝并啟動服務 節中的指令。

3.2 資料連結

官方 DolphinScheduler 1.3.1 版本(1.3.1 Release Notes)在 2020-07-13 釋出,可以直接下載下傳 官網提供的二進制包(apache-dolphinscheduler-incubating-1.3.1-dolphinscheduler-bin.tar.gz)進行安裝。

  • 檢視目前部署的 DS 的文檔:http://

    ${MasterServer-IP}

    :8888/dolphinscheduler/doc.html、http://

    ${MasterServer-IP}

    :8888/dolphinscheduler/swagger-ui.html
  • 1.3.1/user_doc
  • 一份資料 :DolphinScheduler_Feature_Roadmap.pdf

繼續閱讀