You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@dolphinscheduler.apache.org by gi...@apache.org on 2022/04/27 07:41:07 UTC

[dolphinscheduler-website] branch asf-site updated: Automated deployment: 47e16dbda97079768bb3b170eda3ac4b81560660

This is an automated email from the ASF dual-hosted git repository.

github-bot pushed a commit to branch asf-site
in repository https://gitbox.apache.org/repos/asf/dolphinscheduler-website.git


The following commit(s) were added to refs/heads/asf-site by this push:
     new f4d803eb2 Automated deployment: 47e16dbda97079768bb3b170eda3ac4b81560660
f4d803eb2 is described below

commit f4d803eb24e1e0c38d5e38b9cdc832caad9d431f
Author: github-actions[bot] <gi...@users.noreply.github.com>
AuthorDate: Wed Apr 27 07:41:02 2022 +0000

    Automated deployment: 47e16dbda97079768bb3b170eda3ac4b81560660
---
 .../guide/installation/pseudo-cluster.html         | 83 ++++++++++++----------
 .../guide/installation/pseudo-cluster.json         |  2 +-
 en-us/docs/dev/user_doc/guide/upgrade.html         | 10 +--
 en-us/docs/dev/user_doc/guide/upgrade.json         |  2 +-
 .../guide/installation/pseudo-cluster.html         | 63 +++++++++-------
 .../guide/installation/pseudo-cluster.json         |  2 +-
 zh-cn/docs/dev/user_doc/guide/upgrade.html         | 10 +--
 zh-cn/docs/dev/user_doc/guide/upgrade.json         |  2 +-
 8 files changed, 100 insertions(+), 74 deletions(-)

diff --git a/en-us/docs/dev/user_doc/guide/installation/pseudo-cluster.html b/en-us/docs/dev/user_doc/guide/installation/pseudo-cluster.html
index b5e03fc03..501f12070 100644
--- a/en-us/docs/dev/user_doc/guide/installation/pseudo-cluster.html
+++ b/en-us/docs/dev/user_doc/guide/installation/pseudo-cluster.html
@@ -69,23 +69,6 @@ chmod 600 ~/.ssh/authorized_keys
 <pre><code class="language-shell"><span class="hljs-meta">#</span><span class="bash"> Start ZooKeeper</span>
 ./bin/zkServer.sh start
 </code></pre>
-<!--
-Modify the database configuration and initialize
-
-```properties
-spring.datasource.driver-class-name=com.mysql.jdbc.Driver
-spring.datasource.url=jdbc:mysql://localhost:3306/dolphinscheduler?useUnicode=true&characterEncoding=UTF-8&allowMultiQueries=true
-# Modify it if you are not using dolphinscheduler/dolphinscheduler as your username and password
-spring.datasource.username=dolphinscheduler
-spring.datasource.password=dolphinscheduler
-```
-
-After modifying and saving, execute the following command to create database tables and init basic data.
-
-```shell
-sh script/create-dolphinscheduler.sh
-```
--->
 <h2>Modify Configuration</h2>
 <p>After completing the preparation of the basic environment, you need to modify the configuration file according to the
 environment you used. The configuration files are both in directory <code>bin/env</code> and named <code>install_env.sh</code> and <code>dolphinscheduler_env.sh</code>.</p>
@@ -109,24 +92,46 @@ installPath=&quot;~/dolphinscheduler&quot;
 deployUser=&quot;dolphinscheduler&quot;
 </code></pre>
 <h3>Modify <code>dolphinscheduler_env.sh</code></h3>
-<p>File <code>dolphinscheduler_env.sh</code> describes the database configuration of DolphinScheduler, which in the path <code>bin/env/dolphinscheduler_env.sh</code>
-and some tasks which need external dependencies or libraries such as <code>JAVA_HOME</code> and <code>SPARK_HOME</code>. You could ignore the
-task external dependencies if you do not use those tasks, but you have to change <code>JAVA_HOME</code>, registry center and database
+<p>File  <code>./bin/env/dolphinscheduler_env.sh</code> describes the following configurations:</p>
+<ul>
+<li>Database configuration of DolphinScheduler, see <a href="#initialize-the-database">Initialize the Database</a> for detailed instructions.</li>
+<li>Some tasks which need external dependencies or libraries such as <code>JAVA_HOME</code> and <code>SPARK_HOME</code>.</li>
+<li>Registry center <code>zookeeper</code>.</li>
+<li>Server related configuration, such as cache type, timezone, etc.</li>
+</ul>
+<p>You could ignore the task external dependencies if you do not use those tasks, but you have to change <code>JAVA_HOME</code>, registry center and database
 related configurations based on your environment.</p>
-<pre><code class="language-sh"><span class="hljs-comment"># JAVA_HOME, will use it to start DolphinScheduler server</span>
-<span class="hljs-built_in">export</span> JAVA_HOME=<span class="hljs-variable">${JAVA_HOME:-/custom/path}</span>
-
-<span class="hljs-comment"># Database related configuration, set database type, username and password</span>
-<span class="hljs-built_in">export</span> DATABASE=<span class="hljs-variable">${DATABASE:-postgresql}</span>
-<span class="hljs-built_in">export</span> SPRING_PROFILES_ACTIVE=<span class="hljs-variable">${DATABASE}</span>
-<span class="hljs-built_in">export</span> SPRING_DATASOURCE_DRIVER_CLASS_NAME=org.postgresql.Driver
-<span class="hljs-built_in">export</span> SPRING_DATASOURCE_URL=<span class="hljs-string">&quot;jdbc:postgresql://127.0.0.1:5432/dolphinscheduler&quot;</span>
-<span class="hljs-built_in">export</span> SPRING_DATASOURCE_USERNAME=<span class="hljs-string">&quot;username&quot;</span>
-<span class="hljs-built_in">export</span> SPRING_DATASOURCE_PASSWORD=<span class="hljs-string">&quot;password&quot;</span>
+<pre><code class="language-shell"><span class="hljs-meta">#</span><span class="bash"> JAVA_HOME, will use it to start DolphinScheduler server</span>
+export JAVA_HOME=${JAVA_HOME:-/opt/soft/java}
+<span class="hljs-meta">
+#</span><span class="bash"> Database related configuration, <span class="hljs-built_in">set</span> database <span class="hljs-built_in">type</span>, username and password</span>
+export DATABASE=${DATABASE:-postgresql}
+export SPRING_PROFILES_ACTIVE=${DATABASE}
+export SPRING_DATASOURCE_DRIVER_CLASS_NAME=org.postgresql.Driver
+export SPRING_DATASOURCE_URL=jdbc:postgresql://127.0.0.1:5432/dolphinscheduler
+export SPRING_DATASOURCE_USERNAME={user}
+export SPRING_DATASOURCE_PASSWORD={password}
+<span class="hljs-meta">
+#</span><span class="bash"> DolphinScheduler server related configuration</span>
+export SPRING_CACHE_TYPE=${SPRING_CACHE_TYPE:-none}
+export SPRING_JACKSON_TIME_ZONE=${SPRING_JACKSON_TIME_ZONE:-UTC}
+export MASTER_FETCH_COMMAND_NUM=${MASTER_FETCH_COMMAND_NUM:-10}
+<span class="hljs-meta">
+#</span><span class="bash"> Registry center configuration, determines the <span class="hljs-built_in">type</span> and link of the registry center</span>
+export REGISTRY_TYPE=${REGISTRY_TYPE:-zookeeper}
+export REGISTRY_ZOOKEEPER_CONNECT_STRING=${REGISTRY_ZOOKEEPER_CONNECT_STRING:-localhost:2181}
+<span class="hljs-meta">
+#</span><span class="bash"> Tasks related configurations, need to change the configuration <span class="hljs-keyword">if</span> you use the related tasks.</span>
+export HADOOP_HOME=${HADOOP_HOME:-/opt/soft/hadoop}
+export HADOOP_CONF_DIR=${HADOOP_CONF_DIR:-/opt/soft/hadoop/etc/hadoop}
+export SPARK_HOME1=${SPARK_HOME1:-/opt/soft/spark1}
+export SPARK_HOME2=${SPARK_HOME2:-/opt/soft/spark2}
+export PYTHON_HOME=${PYTHON_HOME:-/opt/soft/python}
+export HIVE_HOME=${HIVE_HOME:-/opt/soft/hive}
+export FLINK_HOME=${FLINK_HOME:-/opt/soft/flink}
+export DATAX_HOME=${DATAX_HOME:-/opt/soft/datax}
 
-<span class="hljs-comment"># Registry center configuration, determines the type and link of the registry center</span>
-<span class="hljs-built_in">export</span> REGISTRY_TYPE=<span class="hljs-variable">${REGISTRY_TYPE:-zookeeper}</span>
-<span class="hljs-built_in">export</span> REGISTRY_ZOOKEEPER_CONNECT_STRING=<span class="hljs-variable">${REGISTRY_ZOOKEEPER_CONNECT_STRING:-localhost:2181}</span>
+export PATH=$HADOOP_HOME/bin:$SPARK_HOME1/bin:$SPARK_HOME2/bin:$PYTHON_HOME/bin:$JAVA_HOME/bin:$HIVE_HOME/bin:$FLINK_HOME/bin:$DATAX_HOME/bin:$PATH
 </code></pre>
 <h2>Initialize the Database</h2>
 <p>DolphinScheduler metadata is stored in the relational database. Currently, supports PostgreSQL and MySQL. If you use MySQL, you need to manually download <a href="https://downloads.MySQL.com/archives/c-j/">mysql-connector-java driver</a> (8.0.16) and move it to the lib directory of DolphinScheduler, which is <code>tools/libs/</code>. Let's take MySQL as an example for how to initialize the database:</p>
@@ -153,9 +158,15 @@ mysql&gt;</span><span class="bash"> CREATE DATABASE dolphinscheduler DEFAULT CHA
 <span class="hljs-meta">mysql&gt;</span><span class="bash"> GRANT ALL PRIVILEGES ON dolphinscheduler.* TO <span class="hljs-string">&#x27;{user}&#x27;</span>@<span class="hljs-string">&#x27;localhost&#x27;</span>;</span>
 <span class="hljs-meta">mysql&gt;</span><span class="bash"> FLUSH PRIVILEGES;</span>
 </code></pre>
-<p>Change the username and password in <code>tools/conf/application.yaml</code> to {user} and {password} you set in the previous step.</p>
-<p>Then, modify <code>tools/bin/dolphinscheduler_env.sh</code>, set mysql as default database <code>export DATABASE=${DATABASE:-mysql}</code>.</p>
-<p>After the above steps done you would create a new database for DolphinScheduler, then run Shell scripts to init database:</p>
+<p>Then, modify <code>./bin/env/dolphinscheduler_env.sh</code> to use mysql, change {user} and {password} to what you set in the previous step.</p>
+<pre><code class="language-shell">export DATABASE=${DATABASE:-mysql}
+export SPRING_PROFILES_ACTIVE=${DATABASE}
+export SPRING_DATASOURCE_DRIVER_CLASS_NAME=com.mysql.cj.jdbc.Driver
+export SPRING_DATASOURCE_URL=jdbc:mysql://127.0.0.1:3306/dolphinscheduler?useUnicode=true&amp;characterEncoding=UTF-8
+export SPRING_DATASOURCE_USERNAME={user}
+export SPRING_DATASOURCE_PASSWORD={password}
+</code></pre>
+<p>After the above steps done you would create a new database for DolphinScheduler, then run the Shell script to init database:</p>
 <pre><code class="language-shell">sh tools/bin/create-schema.sh
 </code></pre>
 <h2>Start DolphinScheduler</h2>
diff --git a/en-us/docs/dev/user_doc/guide/installation/pseudo-cluster.json b/en-us/docs/dev/user_doc/guide/installation/pseudo-cluster.json
index 4880f3eb7..385e54d88 100644
--- a/en-us/docs/dev/user_doc/guide/installation/pseudo-cluster.json
+++ b/en-us/docs/dev/user_doc/guide/installation/pseudo-cluster.json
@@ -1,6 +1,6 @@
 {
   "filename": "pseudo-cluster.md",
-  "__html": "<h1>Pseudo-Cluster Deployment</h1>\n<p>The purpose of the pseudo-cluster deployment is to deploy the DolphinScheduler service on a single machine. In this mode, DolphinScheduler's master, worker, API server, are all on the same machine.</p>\n<p>If you are a new hand and want to experience DolphinScheduler functions, we recommend you install follow <a href=\"standalone.md\">Standalone deployment</a>. If you want to experience more complete functions and schedule massive tasks [...]
+  "__html": "<h1>Pseudo-Cluster Deployment</h1>\n<p>The purpose of the pseudo-cluster deployment is to deploy the DolphinScheduler service on a single machine. In this mode, DolphinScheduler's master, worker, API server, are all on the same machine.</p>\n<p>If you are a new hand and want to experience DolphinScheduler functions, we recommend you install follow <a href=\"standalone.md\">Standalone deployment</a>. If you want to experience more complete functions and schedule massive tasks [...]
   "link": "/dist/en-us/docs/dev/user_doc/guide/installation/pseudo-cluster.html",
   "meta": {}
 }
\ No newline at end of file
diff --git a/en-us/docs/dev/user_doc/guide/upgrade.html b/en-us/docs/dev/user_doc/guide/upgrade.html
index a684c9ab1..5b8a5adff 100644
--- a/en-us/docs/dev/user_doc/guide/upgrade.html
+++ b/en-us/docs/dev/user_doc/guide/upgrade.html
@@ -22,11 +22,13 @@
 <h2>Database Upgrade</h2>
 <ul>
 <li>
-<p>Change <code>username</code> and <code>password</code> in <code>./tools/conf/application.yaml</code> to yours.</p>
-</li>
-<li>
-<p>If using MySQL as the database to run DolphinScheduler, please config it in <code>./tools/bin/dolphinscheduler_env.sh</code>, and add MYSQL connector jar into lib dir <code>./tools/lib</code>, here we download <code>mysql-connector-java-8.0.16.jar</code>, and then correctly configure database connection information. You can download MYSQL connector jar from <a href="https://downloads.MySQL.com/archives/c-j/">here</a>. Otherwise, PostgreSQL is the default database.</p>
+<p>If using MySQL as the database to run DolphinScheduler, please config it in <code>./bin/env/dolphinscheduler_env.sh</code>, change username and password to yours, and add MYSQL connector jar into lib dir <code>./tools/libs</code>, here we download <code>mysql-connector-java-8.0.16.jar</code>, and then correctly configure database connection information. You can download MYSQL connector jar from <a href="https://downloads.MySQL.com/archives/c-j/">here</a>. Otherwise, PostgreSQL is the  [...]
 <pre><code class="language-shell">export DATABASE=${DATABASE:-mysql}
+export SPRING_PROFILES_ACTIVE=${DATABASE}
+export SPRING_DATASOURCE_DRIVER_CLASS_NAME=com.mysql.cj.jdbc.Driver
+export SPRING_DATASOURCE_URL=jdbc:mysql://127.0.0.1:3306/dolphinscheduler?useUnicode=true&amp;characterEncoding=UTF-8
+export SPRING_DATASOURCE_USERNAME={user}
+export SPRING_DATASOURCE_PASSWORD={password}
 </code></pre>
 </li>
 <li>
diff --git a/en-us/docs/dev/user_doc/guide/upgrade.json b/en-us/docs/dev/user_doc/guide/upgrade.json
index 18b9ea666..5eefc4b69 100644
--- a/en-us/docs/dev/user_doc/guide/upgrade.json
+++ b/en-us/docs/dev/user_doc/guide/upgrade.json
@@ -1,6 +1,6 @@
 {
   "filename": "upgrade.md",
-  "__html": "<h1>DolphinScheduler Upgrade Documentation</h1>\n<h2>Back-Up Previous Version's Files and Database</h2>\n<h2>Stop All Services of DolphinScheduler</h2>\n<p><code>sh ./script/stop-all.sh</code></p>\n<h2>Download the Latest Version Installation Package</h2>\n<ul>\n<li><a href=\"/en-us/download/download.html\">download</a> the latest version of the installation packages.</li>\n<li>The following upgrade operations need to be performed in the new version's directory.</li>\n</ul>\ [...]
+  "__html": "<h1>DolphinScheduler Upgrade Documentation</h1>\n<h2>Back-Up Previous Version's Files and Database</h2>\n<h2>Stop All Services of DolphinScheduler</h2>\n<p><code>sh ./script/stop-all.sh</code></p>\n<h2>Download the Latest Version Installation Package</h2>\n<ul>\n<li><a href=\"/en-us/download/download.html\">download</a> the latest version of the installation packages.</li>\n<li>The following upgrade operations need to be performed in the new version's directory.</li>\n</ul>\ [...]
   "link": "/dist/en-us/docs/dev/user_doc/guide/upgrade.html",
   "meta": {}
 }
\ No newline at end of file
diff --git a/zh-cn/docs/dev/user_doc/guide/installation/pseudo-cluster.html b/zh-cn/docs/dev/user_doc/guide/installation/pseudo-cluster.html
index be47ef5b4..4434f3f54 100644
--- a/zh-cn/docs/dev/user_doc/guide/installation/pseudo-cluster.html
+++ b/zh-cn/docs/dev/user_doc/guide/installation/pseudo-cluster.html
@@ -69,23 +69,6 @@ chmod 600 ~/.ssh/authorized_keys
 <pre><code class="language-shell"><span class="hljs-meta">#</span><span class="bash"> 启动 zookeeper</span>
 ./bin/zkServer.sh start
 </code></pre>
-<!--
-修改数据库配置,并初始化
-
-```properties
-spring.datasource.driver-class-name=com.mysql.jdbc.Driver
-spring.datasource.url=jdbc:mysql://localhost:3306/dolphinscheduler?useUnicode=true&characterEncoding=UTF-8&allowMultiQueries=true
-# 如果你不是以 dolphinscheduler/dolphinscheduler 作为用户名和密码的,需要进行修改
-spring.datasource.username=dolphinscheduler
-spring.datasource.password=dolphinscheduler
-```
-
-修改并保存完后,执行 script 目录下的创建表及导入基础数据脚本
-
-```shell
-sh script/create-dolphinscheduler.sh
-```
--->
 <h2>修改相关配置</h2>
 <p>完成基础环境的准备后,需要根据你的机器环境修改配置文件。配置文件可以在目录 <code>bin/env</code> 中找到,他们分别是 并命名为 <code>install_env.sh</code> 和 <code>dolphinscheduler_env.sh</code>。</p>
 <h3>修改 <code>install_env.sh</code> 文件</h3>
@@ -107,23 +90,45 @@ installPath=&quot;~/dolphinscheduler&quot;
 deployUser=&quot;dolphinscheduler&quot;
 </code></pre>
 <h3>修改 <code>dolphinscheduler_env.sh</code> 文件</h3>
-<p>文件 <code>dolphinscheduler_env.sh</code> 描述了 DolphinScheduler 的数据库配置,一些任务类型外部依赖路径或库文件,注册中心,其中 <code>JAVA_HOME</code>
-和 <code>SPARK_HOME</code>都是在这里定义的,其路径是 <code>bin/env/dolphinscheduler_env.sh</code>。如果您不使用某些任务类型,您可以忽略任务外部依赖项,
-但您必须根据您的环境更改 <code>JAVA_HOME</code>、注册中心和数据库相关配置。</p>
+<p>文件 <code>./bin/env/dolphinscheduler_env.sh</code> 描述了下列配置:</p>
+<ul>
+<li>DolphinScheduler 的数据库配置,详细配置方法见<a href="#%E5%88%9D%E5%A7%8B%E5%8C%96%E6%95%B0%E6%8D%AE%E5%BA%93">初始化数据库</a></li>
+<li>一些任务类型外部依赖路径或库文件,如 <code>JAVA_HOME</code> 和 <code>SPARK_HOME</code>都是在这里定义的</li>
+<li>注册中心<code>zookeeper</code></li>
+<li>服务端相关配置,比如缓存,时区设置等</li>
+</ul>
+<p>如果您不使用某些任务类型,您可以忽略任务外部依赖项,但您必须根据您的环境更改 <code>JAVA_HOME</code>、注册中心和数据库相关配置。</p>
 <pre><code class="language-sh"><span class="hljs-comment"># JAVA_HOME, will use it to start DolphinScheduler server</span>
-<span class="hljs-built_in">export</span> JAVA_HOME=<span class="hljs-variable">${JAVA_HOME:-/custom/path}</span>
+<span class="hljs-built_in">export</span> JAVA_HOME=<span class="hljs-variable">${JAVA_HOME:-/opt/soft/java}</span>
 
 <span class="hljs-comment"># Database related configuration, set database type, username and password</span>
 <span class="hljs-built_in">export</span> DATABASE=<span class="hljs-variable">${DATABASE:-postgresql}</span>
 <span class="hljs-built_in">export</span> SPRING_PROFILES_ACTIVE=<span class="hljs-variable">${DATABASE}</span>
 <span class="hljs-built_in">export</span> SPRING_DATASOURCE_DRIVER_CLASS_NAME=org.postgresql.Driver
-<span class="hljs-built_in">export</span> SPRING_DATASOURCE_URL=<span class="hljs-string">&quot;jdbc:postgresql://127.0.0.1:5432/dolphinscheduler&quot;</span>
-<span class="hljs-built_in">export</span> SPRING_DATASOURCE_USERNAME=<span class="hljs-string">&quot;username&quot;</span>
-<span class="hljs-built_in">export</span> SPRING_DATASOURCE_PASSWORD=<span class="hljs-string">&quot;password&quot;</span>
+<span class="hljs-built_in">export</span> SPRING_DATASOURCE_URL=jdbc:postgresql://127.0.0.1:5432/dolphinscheduler
+<span class="hljs-built_in">export</span> SPRING_DATASOURCE_USERNAME={user}
+<span class="hljs-built_in">export</span> SPRING_DATASOURCE_PASSWORD={password}
+
+<span class="hljs-comment"># DolphinScheduler server related configuration</span>
+<span class="hljs-built_in">export</span> SPRING_CACHE_TYPE=<span class="hljs-variable">${SPRING_CACHE_TYPE:-none}</span>
+<span class="hljs-built_in">export</span> SPRING_JACKSON_TIME_ZONE=<span class="hljs-variable">${SPRING_JACKSON_TIME_ZONE:-UTC}</span>
+<span class="hljs-built_in">export</span> MASTER_FETCH_COMMAND_NUM=<span class="hljs-variable">${MASTER_FETCH_COMMAND_NUM:-10}</span>
 
 <span class="hljs-comment"># Registry center configuration, determines the type and link of the registry center</span>
 <span class="hljs-built_in">export</span> REGISTRY_TYPE=<span class="hljs-variable">${REGISTRY_TYPE:-zookeeper}</span>
 <span class="hljs-built_in">export</span> REGISTRY_ZOOKEEPER_CONNECT_STRING=<span class="hljs-variable">${REGISTRY_ZOOKEEPER_CONNECT_STRING:-localhost:2181}</span>
+
+<span class="hljs-comment"># Tasks related configurations, need to change the configuration if you use the related tasks.</span>
+<span class="hljs-built_in">export</span> HADOOP_HOME=<span class="hljs-variable">${HADOOP_HOME:-/opt/soft/hadoop}</span>
+<span class="hljs-built_in">export</span> HADOOP_CONF_DIR=<span class="hljs-variable">${HADOOP_CONF_DIR:-/opt/soft/hadoop/etc/hadoop}</span>
+<span class="hljs-built_in">export</span> SPARK_HOME1=<span class="hljs-variable">${SPARK_HOME1:-/opt/soft/spark1}</span>
+<span class="hljs-built_in">export</span> SPARK_HOME2=<span class="hljs-variable">${SPARK_HOME2:-/opt/soft/spark2}</span>
+<span class="hljs-built_in">export</span> PYTHON_HOME=<span class="hljs-variable">${PYTHON_HOME:-/opt/soft/python}</span>
+<span class="hljs-built_in">export</span> HIVE_HOME=<span class="hljs-variable">${HIVE_HOME:-/opt/soft/hive}</span>
+<span class="hljs-built_in">export</span> FLINK_HOME=<span class="hljs-variable">${FLINK_HOME:-/opt/soft/flink}</span>
+<span class="hljs-built_in">export</span> DATAX_HOME=<span class="hljs-variable">${DATAX_HOME:-/opt/soft/datax}</span>
+
+<span class="hljs-built_in">export</span> PATH=<span class="hljs-variable">$HADOOP_HOME</span>/bin:<span class="hljs-variable">$SPARK_HOME1</span>/bin:<span class="hljs-variable">$SPARK_HOME2</span>/bin:<span class="hljs-variable">$PYTHON_HOME</span>/bin:<span class="hljs-variable">$JAVA_HOME</span>/bin:<span class="hljs-variable">$HIVE_HOME</span>/bin:<span class="hljs-variable">$FLINK_HOME</span>/bin:<span class="hljs-variable">$DATAX_HOME</span>/bin:<span class="hljs-variable">$PATH</span>
 </code></pre>
 <h2>初始化数据库</h2>
 <p>DolphinScheduler 元数据存储在关系型数据库中,目前支持 PostgreSQL 和 MySQL,如果使用 MySQL 则需要手动下载 <a href="https://downloads.MySQL.com/archives/c-j/">mysql-connector-java 驱动</a> (8.0.16) 并移动到 DolphinScheduler 的 lib目录下(<code>tools/libs/</code>)。下面以 MySQL 为例,说明如何初始化数据库</p>
@@ -150,8 +155,14 @@ mysql&gt;</span><span class="bash"> CREATE DATABASE dolphinscheduler DEFAULT CHA
 <span class="hljs-meta">mysql&gt;</span><span class="bash"> GRANT ALL PRIVILEGES ON dolphinscheduler.* TO <span class="hljs-string">&#x27;{user}&#x27;</span>@<span class="hljs-string">&#x27;localhost&#x27;</span>;</span>
 <span class="hljs-meta">mysql&gt;</span><span class="bash"> FLUSH PRIVILEGES;</span>
 </code></pre>
-<p>将<code>tools/conf/application.yaml</code>中的username和password改成你在上一步中设置的用户名{user}和密码{password}</p>
-<p>然后修改<code>tools/bin/dolphinscheduler_env.sh</code>,将mysql设置为默认数据类型<code>export DATABASE=${DATABASE:-mysql}</code>.</p>
+<p>然后修改<code>./bin/env/dolphinscheduler_env.sh</code>,将username和password改成你在上一步中设置的用户名{user}和密码{password}</p>
+<pre><code class="language-shell">export DATABASE=${DATABASE:-mysql}
+export SPRING_PROFILES_ACTIVE=${DATABASE}
+export SPRING_DATASOURCE_DRIVER_CLASS_NAME=com.mysql.cj.jdbc.Driver
+export SPRING_DATASOURCE_URL=jdbc:mysql://127.0.0.1:3306/dolphinscheduler?useUnicode=true&amp;characterEncoding=UTF-8
+export SPRING_DATASOURCE_USERNAME={user}
+export SPRING_DATASOURCE_PASSWORD={password}
+</code></pre>
 <p>完成上述步骤后,您已经为 DolphinScheduler 创建一个新数据库,现在你可以通过快速的 Shell 脚本来初始化数据库</p>
 <pre><code class="language-shell">sh tools/bin/create-schema.sh
 </code></pre>
diff --git a/zh-cn/docs/dev/user_doc/guide/installation/pseudo-cluster.json b/zh-cn/docs/dev/user_doc/guide/installation/pseudo-cluster.json
index 63fc378eb..85c40dea5 100644
--- a/zh-cn/docs/dev/user_doc/guide/installation/pseudo-cluster.json
+++ b/zh-cn/docs/dev/user_doc/guide/installation/pseudo-cluster.json
@@ -1,6 +1,6 @@
 {
   "filename": "pseudo-cluster.md",
-  "__html": "<h1>伪集群部署</h1>\n<p>伪集群部署目的是在单台机器部署 DolphinScheduler 服务,该模式下master、worker、api server 都在同一台机器上</p>\n<p>如果你是新手,想要体验 DolphinScheduler 的功能,推荐使用<a href=\"standalone.md\">Standalone</a>方式体检。如果你想体验更完整的功能,或者更大的任务量,推荐使用<a href=\"pseudo-cluster.md\">伪集群部署</a>。如果你是在生产中使用,推荐使用<a href=\"cluster.md\">集群部署</a>或者<a href=\"kubernetes.md\">kubernetes</a></p>\n<h2>前置准备工作</h2>\n<p>伪分布式部署 DolphinScheduler 需要有外部软件的支持</p>\n<ul>\n<li>JDK:下载<a href=\"https://www.oracle.com/technetwork/java/javase/dow [...]
+  "__html": "<h1>伪集群部署</h1>\n<p>伪集群部署目的是在单台机器部署 DolphinScheduler 服务,该模式下master、worker、api server 都在同一台机器上</p>\n<p>如果你是新手,想要体验 DolphinScheduler 的功能,推荐使用<a href=\"standalone.md\">Standalone</a>方式体检。如果你想体验更完整的功能,或者更大的任务量,推荐使用<a href=\"pseudo-cluster.md\">伪集群部署</a>。如果你是在生产中使用,推荐使用<a href=\"cluster.md\">集群部署</a>或者<a href=\"kubernetes.md\">kubernetes</a></p>\n<h2>前置准备工作</h2>\n<p>伪分布式部署 DolphinScheduler 需要有外部软件的支持</p>\n<ul>\n<li>JDK:下载<a href=\"https://www.oracle.com/technetwork/java/javase/dow [...]
   "link": "/dist/zh-cn/docs/dev/user_doc/guide/installation/pseudo-cluster.html",
   "meta": {}
 }
\ No newline at end of file
diff --git a/zh-cn/docs/dev/user_doc/guide/upgrade.html b/zh-cn/docs/dev/user_doc/guide/upgrade.html
index 037fe7b55..7838c846b 100644
--- a/zh-cn/docs/dev/user_doc/guide/upgrade.html
+++ b/zh-cn/docs/dev/user_doc/guide/upgrade.html
@@ -22,11 +22,13 @@
 <h2>4. 数据库升级</h2>
 <ul>
 <li>
-<p>将<code>./tools/conf/application.yaml</code>中的username和password改成你设定数据库用户名和密码</p>
-</li>
-<li>
-<p>如果选择 MySQL,请修改<code>./tools/bin/dolphinscheduler_env.sh</code>中的如下配置, 还需要手动添加 <a href="https://downloads.MySQL.com/archives/c-j/"> mysql-connector-java 驱动 jar </a> 包到 lib 目录(<code>./tools/lib</code>)下,这里下载的是mysql-connector-java-8.0.16.jar</p>
+<p>如果选择 MySQL,请修改<code>./bin/env/dolphinscheduler_env.sh</code>中的如下配置({user}和{password}改成你数据库的用户名和密码), 还需要手动添加 <a href="https://downloads.MySQL.com/archives/c-j/"> mysql-connector-java 驱动 jar </a> 包到 lib 目录(<code>./tools/lib</code>)下,这里下载的是mysql-connector-java-8.0.16.jar</p>
 <pre><code class="language-shell">export DATABASE=${DATABASE:-mysql}
+export SPRING_PROFILES_ACTIVE=${DATABASE}
+export SPRING_DATASOURCE_DRIVER_CLASS_NAME=com.mysql.cj.jdbc.Driver
+export SPRING_DATASOURCE_URL=jdbc:mysql://127.0.0.1:3306/dolphinscheduler?useUnicode=true&amp;characterEncoding=UTF-8
+export SPRING_DATASOURCE_USERNAME={user}
+export SPRING_DATASOURCE_PASSWORD={password}
 </code></pre>
 </li>
 <li>
diff --git a/zh-cn/docs/dev/user_doc/guide/upgrade.json b/zh-cn/docs/dev/user_doc/guide/upgrade.json
index 5ef025065..bdc4c2211 100644
--- a/zh-cn/docs/dev/user_doc/guide/upgrade.json
+++ b/zh-cn/docs/dev/user_doc/guide/upgrade.json
@@ -1,6 +1,6 @@
 {
   "filename": "upgrade.md",
-  "__html": "<h1>DolphinScheduler升级文档</h1>\n<h2>1. 备份上一版本文件和数据库</h2>\n<h2>2. 停止dolphinscheduler所有服务</h2>\n<p><code>sh ./script/stop-all.sh</code></p>\n<h2>3. 下载新版本的安装包</h2>\n<ul>\n<li><a href=\"/zh-cn/download/download.html\">下载</a>, 下载最新版本的二进制安装包</li>\n<li>以下升级操作都需要在新版本的目录进行</li>\n</ul>\n<h2>4. 数据库升级</h2>\n<ul>\n<li>\n<p>将<code>./tools/conf/application.yaml</code>中的username和password改成你设定数据库用户名和密码</p>\n</li>\n<li>\n<p>如果选择 MySQL,请修改<code>./tools/bin/dolphinscheduler_env.sh</code>中的如下配置,  [...]
+  "__html": "<h1>DolphinScheduler升级文档</h1>\n<h2>1. 备份上一版本文件和数据库</h2>\n<h2>2. 停止dolphinscheduler所有服务</h2>\n<p><code>sh ./script/stop-all.sh</code></p>\n<h2>3. 下载新版本的安装包</h2>\n<ul>\n<li><a href=\"/zh-cn/download/download.html\">下载</a>, 下载最新版本的二进制安装包</li>\n<li>以下升级操作都需要在新版本的目录进行</li>\n</ul>\n<h2>4. 数据库升级</h2>\n<ul>\n<li>\n<p>如果选择 MySQL,请修改<code>./bin/env/dolphinscheduler_env.sh</code>中的如下配置({user}和{password}改成你数据库的用户名和密码), 还需要手动添加 <a href=\"https://downloads.MySQL.com/archives/c-j/\"> mysql [...]
   "link": "/dist/zh-cn/docs/dev/user_doc/guide/upgrade.html",
   "meta": {}
 }
\ No newline at end of file