openGauss6.0单中心一主两备部署

本文涉及的产品
RDS MySQL Serverless 基础系列,0.5-2RCU 50GB
云数据库 Tair(兼容Redis),内存型 2GB
Redis 开源版,标准版 2GB
推荐场景:
搭建游戏排行榜
简介: openGauss6.0单中心一主两备部署

单中心一主三备架构介绍

单AZ部署,可以配置一个同步备一个异步备

优势:

  1. 三个node完全等价,故障任意一个node都可以提供服务
  2. 成本低

劣势: 高可用能力较低,发生AZ级故障只能依赖节点恢复

适用性: 适用于对高可用性要求较低的业务系统

环境说明

角色

主机名

IPADDR

OS Version

DB version

opendb01

192.168.40.160

Centos7.9 x86_64

openGauss6.0.0

opendb02

192.168.40.161

Centos7.9 x86_64

openGauss6.0.0

opendb03

192.168.40.122

Centos7.9 x86_64

openGauss6.0.0

安装前准备(主备库均操作)

软硬件要求

仅作参考,自测环境低一些也可以,本文档是Centos7.9 x86_64 4G1C40G 的配置

硬件环境

表1 硬件环境要求列出了openGauss服务器应具备的最低硬件要求。在实际产品中,硬件配置的规划需考虑数据规模及所期望的数据库响应速度。请根据实际情况进行规划。

表 1 硬件环境要求

项目

配置描述

内存

功能调试建议32GB以上。

性能测试和商业部署时,单实例部署建议128GB以上。

复杂的查询对内存的需求量比较高,在高并发场景下,可能出现内存不足。此时建议使用大内存的机器,或使用负载管理限制系统的并发。

CPU

功能调试最小1×8 核 2.0GHz。

性能测试和商业部署时,建议1×16核 2.0GHz。

CPU超线程和非超线程两种模式都支持。

说明:

个人开发者最低配置2核4G, 推荐配置4核8G。

目前,openGauss仅支持ARM服务器和基于X86_64通用PC服务器的CPU。

硬盘

用于安装openGauss的硬盘需最少满足如下要求:

  • 至少1GB用于安装openGauss的应用程序。
  • 每个主机需大约300MB用于元数据存储。
  • 预留70%以上的磁盘剩余空间用于数据存储。

建议系统盘配置为Raid1,数据盘配置为Raid5,且规划4组Raid5数据盘用于安装openGauss。有关Raid的配置方法在本手册中不做介绍。请参考硬件厂家的手册或互联网上的方法进行配置,其中Disk Cache Policy一项需要设置为Disabled,否则机器异常掉电后有数据丢失的风险。

openGauss支持使用SSD盘作为数据库的主存储设备,支持SAS接口和NVME协议的SSD盘,以RAID的方式部署使用。

网络要求

300兆以上以太网。

建议网卡设置为双网卡冗余bond。有关网卡冗余bond的配置方法在本手册中不做介绍。请参考硬件厂商的手册或互联网上的方法进行配置。

该文档只采用了1块网卡。

软件环境

表 2 软件环境要求

软件类型

配置描述

Linux操作系统

  • ARM:
    • openEuler 20.03 LTS(推荐采用此操作系统)
    • openEuler 22.03 LTS
    • 麒麟V10
    • Asianux 7.5
    • 统信V20
  • x86:
    • openEuler 20.03 LTS
    • openEuler 22.03 LTS
    • CentOS 7.6
    • Asianux 7.6
    • 麒麟V10
  • 说明:1、当前安装包只能在英文操作系统上安装使用;2、OM工具已经支持对基于openEuler/Centos等商业操作系统的安装使用,具体配置信息可以查看OM中的osid.conf文件。

Linux文件系统

剩余inode个数 > 15亿(推荐)

工具

bzip2

Python

  • 支持Python3.6+

软件依赖要求

openGauss的软件依赖要求如表3 软件依赖要求所示。

建议使用上述操作系统安装光盘或者源中,下列依赖软件的默认安装包,若不存在下列软件,可参看软件对应的建议版本。

表 3 软件依赖要求

所需软件

建议版本

libaio-devel

建议版本:0.3.109-13

readline-devel

建议版本:7.0-13

expect

--

系统参数配置

操作系统主机命名(可选)

如果采用默认主机名,可忽略该步骤,默认的主机名localhost.localdomain,xml文件中的主机名也需要改成localhost.localdomain

--节点1
hostnamectl set-hostname opendb01
exec bash
--节点2
hostnamectl set-hostname opendb02
exec bash
--节点3
hostnamectl set-hostname opendb03
exec bash

/etc/hosts配置(可选)

如果采用默认主机名,可忽略该步骤,预安装会自动追加127.0.0.1  localhost  #Gauss OM IP Hosts Mapping

cp /etc/hosts /etc/hosts.bak
cat >>/etc/hosts<<EOF
192.168.40.160 opendb01  
192.168.40.161 opendb02  
192.168.40.122 opendb03 
EOF

/etc/security/limits.conf配置

不用配置该文件,会自动追加如下内容:

cp /etc/security/limits.conf /etc/security/limits.conf_bak_`date +%F`
cat >> /etc/security/limits.conf << "EOF"
#add by openGauss
*       soft    nofile  1000000
*       hard    nofile  1000000
EOF

关闭透明页

echo never > /sys/kernel/mm/transparent_hugepage/enabled
echo never > /sys/kernel/mm/transparent_hugepage/defrag
--加入开机启动
echo '
echo never > /sys/kernel/mm/transparent_hugepage/enabled
echo never > /sys/kernel/mm/transparent_hugepage/defrag' >>/etc/rc.local
chmod +x /etc/rc.local

防火墙配置

systemctl stop firewalld.service
systemctl disable firewalld.service

如果启用防火墙需进行如下配置:

如果数据库端口和ssh端口不是5432和22,需视情况更改

firewall-cmd --zone=public --add-port=5432/tcp --permanent
firewall-cmd --zone=public --add-port=22/tcp --permanent
firewall-cmd --reload

selinux配置

sed -i "s/SELINUX=enforcing/SELINUX=disabled/g" /etc/selinux/config
setenforce 0

关闭 numa和禁用透明大页

sed -i "s/quiet/quiet numa=off transparent_hugepage=never/g"  /etc/default/grub 
grub2-mkconfig -o /etc/grub2.cfg

设置字符集参数

echo "export LANG=en_US.UTF-8"  >> /etc/profile
source /etc/profile

设置时区和时间

如果服务器时间和当前时间相差8小时或者12小时,需要查看时区,分析是否决定更改。

非可视化更改步骤

--查看当前时间
[root@opendb01 ~]# date
Tue Oct 15 09:06:37 AM CST 2024
--查看当前时区
[root@opendb01 ~]# timedatectl
               Local time: Tue 2024-10-15 09:06:49 CST
           Universal time: Tue 2024-10-15 01:06:49 UTC
                 RTC time: Tue 2024-10-15 01:06:49
                Time zone: Asia/Shanghai (CST, +0800)
System clock synchronized: yes
              NTP service: active
          RTC in local TZ: no
--更改时区  执行tzselect命令
[root@opendb01 ~]# tzselect
Please identify a location so that time zone rules can be set correctly.
Please select a continent, ocean, "coord", or "TZ".
 1) Africa
 2) Americas
 3) Antarctica
 4) Asia
 5) Atlantic Ocean
 6) Australia
 7) Europe
 8) Indian Ocean
 9) Pacific Ocean
10) coord - I want to use geographical coordinates.
11) TZ - I want to specify the time zone using the Posix TZ format.
--找到Asia,输入4,回车
Please select a country whose clocks agree with yours.
 1) Afghanistan           18) Israel                35) Palestine
 2) Armenia               19) Japan                 36) Philippines
 3) Azerbaijan            20) Jordan                37) Qatar
 4) Bahrain               21) Kazakhstan            38) Russia
 5) Bangladesh            22) Korea (North)         39) Saudi Arabia
 6) Bhutan                23) Korea (South)         40) Singapore
 7) Brunei                24) Kuwait                41) Sri Lanka
 8) Cambodia              25) Kyrgyzstan            42) Syria
 9) China                 26) Laos                  43) Taiwan
10) Cyprus                27) Lebanon               44) Tajikistan
11) East Timor            28) Macau                 45) Thailand
12) Georgia               29) Malaysia              46) Turkmenistan
13) Hong Kong             30) Mongolia              47) United Arab Emirates
14) India                 31) Myanmar (Burma)       48) Uzbekistan
15) Indonesia             32) Nepal                 49) Vietnam
16) Iran                  33) Oman                  50) Yemen
17) Iraq                  34) Pakistan
--找到china,输入9,回车
Please select one of the following time zone regions.
1) Beijing Time
2) Xinjiang Time
--找到北京时间,输入1,回车
Please select one of the following time zone regions.
1) Beijing Time
2) Xinjiang Time
--选择yes,输入1,回车
The following information has been given:
        China
        Beijing Time
Therefore TZ='Asia/Shanghai' will be used.
Selected time is now:   Wed Jan 24 21:40:32 CST 2024.
Universal Time is now:  Wed Jan 24 13:40:32 UTC 2024.
Is the above information OK?
1) Yes
2) No
--更新设置
ln -sf /usr/share/zoneinfo/Asia/Shanghai /etc/localtime
--查看是否更改成功
root@HKSZF-ZW-172-19-146-176:/topsoft# date
Fri Apr 19 14:15:52 CST 2024
[root@localhost ~]# timedatectl
      Local time: Fri 2024-04-19 14:16:08 CST
  Universal time: Fri 2024-04-19 06:16:08 UTC
        RTC time: Fri 2024-04-19 06:16:07
       Time zone: Asia/Shanghai (CST, +0800)
     NTP enabled: n/a
NTP synchronized: no
 RTC in local TZ: no
      DST active: n/a

可视化更改步骤

--查看当前时间
[root@opendb01 ~]# date
Tue Oct 15 09:07:37 AM CST 2024
--查看当前时区
[root@opendb01 ~]# timedatectl
               Local time: Tue 2024-10-15 09:08:08 CST
           Universal time: Tue 2024-10-15 01:08:08 UTC
                 RTC time: Tue 2024-10-15 01:08:08
                Time zone: Asia/Shanghai (CST, +0800)
System clock synchronized: yes
              NTP service: active
          RTC in local TZ: no

在可视化界面中查看

选择进入 Applications -> System Tools -> Settings -> Details -> Date & Time

调整时间

点击“Date & Time”行中任意位置,弹出弹窗,调整时间为当前北京时间,再关闭弹窗,即保存。如下图所示:

再次使用命令查看,本地时间已显示为北京时间

[root@localhost ~]# timedatectl
      Local time: Fri 2024-04-19 14:43:31 CST
  Universal time: Fri 2024-04-19 06:43:31 UTC
        RTC time: Fri 2024-04-19 06:43:30
       Time zone: Asia/Shanghai (CST, +0800)
     NTP enabled: n/a
NTP synchronized: no
 RTC in local TZ: no
      DST active: n/a

关闭swap交换内存(可选)

关闭swap交换内存是为了保障数据库的访问性能,避免把数据库的缓冲区内存淘汰到磁盘上。 如果服务器内存比较小,内存过载时,可打开swap交换内存保障正常运行。

swapoff -a

关闭RemoveIPC

在各数据库节点上,关闭RemoveIPC。CentOS操作系统默认为关闭,可以跳过该步骤。

  1. 修改/etc/systemd/logind.conf文件中的“RemoveIPC”值为“no”。a. 使用VIM打开logind.conf文件。
--更改后的/etc/systemd/logind.conf
vi  /etc/systemd/logind.conf
RemoveIPC=no
--更改后的systemd-logind.service
vi /usr/lib/systemd/system/systemd-logind.service
RemoveIPC=no
--重新加载配置参数
systemctl daemon-reload
systemctl restart systemd-logind
--检查修改是否生效
loginctl show-session | grep RemoveIPC
systemctl show systemd-logind | grep RemoveIPC

关闭HISTORY记录(可选)

为避免指令历史记录安全隐患,需关闭各主机的history指令。

更改/etc/profile中HISTSIZE值
vi /etc/profile
HISTSIZE默认值为1000 更改为 HISTSIZE=0
--生效
source /etc/profile

配置yum源

将操作系统镜像上传至/opt目录下

mount /opt/*.iso /mnt/
cat << EOF >> /etc/fstab
/dev/sr0    /mnt        iso9660 loop            0 0
EOF
mkdir -p /etc/yum.repos.d/bak
mv /etc/yum.repos.d/*.repo /etc/yum.repos.d/bak
cat >> /etc/yum.repos.d/os.repo <<"EOF"
[OS1]
name=OS
baseurl=file:///mnt
enabled=1
gpgcheck=0
EOF

安装依赖包

必须安装bzip2不然后面预安装初始化安装环境报错

--安装openGauss数据库的依赖包
yum install -y libaio-devel readline-devel expect 
yum -y install bzip2
--安装辅助工具
yum install -y tar 
yum install -y vim

升级python

--采用yum方式安装操作系统自带的包管理器中的python3
yum install python3

若不进行升级后面预安装会提示如下报错:

--问题描述
[root@opendb01 script]# ./gs_preinstall -U omm -G dbgrp -X /topsoft/soft/openGauss/cluster_config.xml
/usr/bin/env: python3: No such file or directory
--解决办法
采用下面办法进行python版本升级
--查看python版本
[root@opendb01 ~]# python --version
Python 2.7.5
[root@opendb01 ~]# python3 --version
python3命令找不到
--采用yum方式安装操作系统自带的包管理器中的python3
yum install python3
--再次查看python版本
[root@opendb01 ~]# python --version
Python 2.7.5
[root@opendb01 ~]# python3 --version
Python 3.6.8

编译安装rlwrap

上传rlwrap-0.46.1.tar.gz至/opt目录下

yum install gcc-c++  readline* libtermcap-devel*
cd /opt
tar -xvf rlwrap-0.46.1.tar.gz
cd rlwrap-0.46.1
./configure
make
make install

创建用户及用户组(可选)

可以创建也可以不创建,自行操作

--创建用户组dbgrp
groupadd dbgrp
--创建用户组dbgroup下的普通用户omm,并设置密码为Gauss_234 
useradd -g dbgrp -m omm
passwd omm

为了实现安装过程中安装帐户权限最小化,及安装后openGauss的系统运行安全性,安装脚本在安装过程中会自动按照用户指定内容创建安装用户并将此用户作为后续运行和维护openGauss的管理员帐户

用户/组名

所属类型

规划建议

dbgrp

操作系统

建议规划单独的用户组,例如dbgrp

初始化安装环境时,由-G参数所指定的安装用户所属的用户组。该用户组如果不存在,则会自动创建,也可提前创建好用户组。在执行gs_preinstall脚本时会检查权限。gs_preinstall脚本会自动赋予此组中的用户对安装目录、数据目录的访问和执行权限。

创建dbgrp用户组命令:

groupadd dbgrp

omm

操作系统

建议规划用户用于运行和维护openGauss,例如omm。

初始化安装环境时,由-U参数所指定和自动创建的操作系统用户,如果已经存在该用户,请清理该用户或更换初始化用户。从安全性考虑,对此用户的所属组规划如下:

所属组:dbgrp

在安装openGauss过程中root用户运行 openGauss-All-6.0.0-openEuler22.03-x86_64.tar.gz中scripts目录中的“gs_preinstall”时,会创建与安装用户同名的数据库用户即数据库用户omm。此用户具备数据库的最高操作权限,此用户初始密码由用户指定。

目录规划

--创建存放安装包的目录
mkdir -p /topsoft/soft/openGauss
chmod 777 -R /topsoft/soft

不建议把安装包的存放目录规划到openGauss用户的根目录或其子目录下,可能导致权限问题。。安装目录和数据目录在统一目录下也会导致权限问题,建议安装目录和数据目录分开。

openGauss用户须具有/topsoft/soft/openGauss目录的读写权限。

规划以下目录但是不要创建,后面执行gs_preinstall时会自动创建,如果提前创建,执行gs_preinstall过程中会报错

/opt/huawei/install/app  #数据库安装目录
/opt/huawei/log/omm  #日志目录
/opt/huawei/tmp  #临时文件目录
/opt/huawei/install/om  #数据库工具目录
/opt/huawei/corefile  #数据库core文件目录

下载并上传安装包

登录openGauss开源社区https://opengauss.org/zh/download/,选择对应平台的企业版安装包。

安装包“openGauss-All-6.0.0-CentOS7-x86_64.tar.gz”上传至/topsoft/soft/openGauss目录。

配置一主两备XML文件

安装openGauss前需要创建XML文件。XML文件包含部署openGauss的服务器信息、安装路径、IP地址以及端口号等。用于告知openGauss如何部署。用户需根据不同场景配置对应的XML文件。

关于如何配置XML文件,详细请参见创建XML配置文件

将cluster_config.xml上传至/topsoft/soft/openGauss目录,安装包“openGauss-All-6.0.0-CentOS7-x86_64.tar.gz”和配置文件“cluster_config.xml”都上传至上一步所创建的目录中。

为确保成功安装,检查hostname与/etc/hostname是否一致。预安装过程中,会对hostname进行检查。

默认端口5432,若待用自定义端口,更改xml文件中的端口号。

说明:在script/gspylib/etc/conf/cluster_config_template.xml获取XML文件模板。

官方一主两备XML文件模板

<?xml version="1.0" encoding="UTF-8"?> 
<ROOT> 
    <!-- openGauss整体信息 --> 
    <CLUSTER> 
        <PARAM name="clusterName" value="Cluster_template" /> 
        <PARAM name="nodeNames" value="node1_hostname,node2_hostname,node3_hostname" /> 
    
        <PARAM name="gaussdbAppPath" value="/opt/huawei/install/app" /> 
        <PARAM name="gaussdbLogPath" value="/var/log/omm" /> 
        <PARAM name="tmpMppdbPath" value="/opt/huawei/tmp"/> 
        <PARAM name="gaussdbToolPath" value="/opt/huawei/install/om" /> 
        <PARAM name="corePath" value="/opt/huawei/corefile"/> 
        <PARAM name="backIp1s" value="192.168.0.1,192.168.0.2,192.168.0.3"/> 
     
    </CLUSTER> 
    <!-- 每台服务器上的节点部署信息 --> 
    <DEVICELIST> 
        <!-- node1上的节点部署信息 --> 
        <DEVICE sn="node1_hostname"> 
            <PARAM name="name" value="node1_hostname"/> 
            <PARAM name="azName" value="AZ1"/> 
            <PARAM name="azPriority" value="1"/> 
            <!-- 如果服务器只有一个网卡可用,将backIP1和sshIP1配置成同一个IP --> 
            <PARAM name="backIp1" value="192.168.0.1"/> 
            <PARAM name="sshIp1" value="192.168.0.1"/> 
            <!--CM节点部署信息--> 
            <PARAM name="cmsNum" value="1"/> 
            <PARAM name="cmServerPortBase" value="15000"/> 
            <PARAM name="cmServerListenIp1" value="192.168.0.1,192.168.0.2,192.168.0.3"/> 
            <PARAM name="cmServerHaIp1" value="192.168.0.1,192.168.0.2,192.168.0.3"/> 
            <PARAM name="cmServerLevel" value="1"/> 
            <PARAM name="cmServerRelation" value="node1_hostname,node2_hostname,node3_hostname"/> 
            <PARAM name="cmDir" value="/opt/huawei/data/cmserver"/> 
      <!--dn--> 
            <PARAM name="dataNum" value="1"/> 
      <PARAM name="dataPortBase" value="15400"/> 
      <PARAM name="dataNode1" value="/opt/huawei/install/data/dn,node2_hostname,/opt/huawei/install/data/dn,node3_hostname,/opt/huawei/install/data/dn"/> 
            <PARAM name="dataNode1_syncNum" value="0"/> 
        </DEVICE> 
 
        <!-- node2上的节点部署信息,其中“name”的值配置为主机名称 --> 
        <DEVICE sn="node2_hostname"> 
            <PARAM name="name" value="node2_hostname"/> 
            <PARAM name="azName" value="AZ1"/> 
            <PARAM name="azPriority" value="1"/> 
            <!-- 如果服务器只有一个网卡可用,将backIP1和sshIP1配置成同一个IP --> 
            <PARAM name="backIp1" value="192.168.0.2"/> 
            <PARAM name="sshIp1" value="192.168.0.2"/> 
            <!-- cm --> 
            <PARAM name="cmServerPortStandby" value="15000"/> 
            <PARAM name="cmDir" value="/opt/huawei/data/cmserver"/> 
  </DEVICE> 
 
        <!-- node3上的节点部署信息,其中“name”的值配置为主机名称 --> 
        <DEVICE sn="node3_hostname"> 
            <PARAM name="name" value="node3_hostname"/> 
            <PARAM name="azName" value="AZ1"/> 
            <PARAM name="azPriority" value="1"/> 
            <!-- 如果服务器只有一个网卡可用,将backIP1和sshIP1配置成同一个IP --> 
            <PARAM name="backIp1" value="192.168.0.3"/> 
            <PARAM name="sshIp1" value="192.168.0.3"/> 
            <!-- cm --> 
            <PARAM name="cmServerPortStandby" value="15000"/> 
            <PARAM name="cmDir" value="/opt/huawei/data/cmserver"/> 
  </DEVICE> 
    </DEVICELIST> 
</ROOT>

根据官方模板更改后的一主两备xml文件

cat cluster_config.xml
<?xml version="1.0" encoding="UTF-8"?> 
<ROOT> 
    <!-- openGauss整体信息 --> 
    <CLUSTER> 
        <PARAM name="clusterName" value="cluster_dxj" /> 
        <PARAM name="nodeNames" value="opendb01,opendb02,opendb03" /> 
    
        <PARAM name="gaussdbAppPath" value="/opt/huawei/install/app" /> 
        <PARAM name="gaussdbLogPath" value="/var/log/omm" /> 
        <PARAM name="tmpMppdbPath" value="/opt/huawei/tmp"/> 
        <PARAM name="gaussdbToolPath" value="/opt/huawei/install/om" /> 
        <PARAM name="corePath" value="/opt/huawei/corefile"/> 
        <PARAM name="backIp1s" value="192.168.40.160,192.168.40.161,192.168.40.122"/> 
     
    </CLUSTER> 
    <!-- 每台服务器上的节点部署信息 --> 
    <DEVICELIST> 
        <!-- node1上的节点部署信息 --> 
        <DEVICE sn="opendb01"> 
            <PARAM name="name" value="opendb01"/> 
            <PARAM name="azName" value="AZ1"/> 
            <PARAM name="azPriority" value="1"/> 
            <!-- 如果服务器只有一个网卡可用,将backIP1和sshIP1配置成同一个IP --> 
            <PARAM name="backIp1" value="192.168.40.160"/> 
            <PARAM name="sshIp1" value="192.168.40.160"/> 
            <!--CM节点部署信息--> 
            <PARAM name="cmsNum" value="1"/> 
            <PARAM name="cmServerPortBase" value="15000"/> 
            <PARAM name="cmServerListenIp1" value="192.168.40.160,192.168.40.161,192.168.40.122"/> 
            <PARAM name="cmServerHaIp1" value="192.168.40.160,192.168.40.161,192.168.40.122"/> 
            <PARAM name="cmServerLevel" value="1"/> 
            <PARAM name="cmServerRelation" value="opendb01,opendb02,opendb03"/> 
            <PARAM name="cmDir" value="/opt/huawei/data/cmserver"/> 
      <!--dn--> 
            <PARAM name="dataNum" value="1"/> 
      <PARAM name="dataPortBase" value="5432"/> 
      <PARAM name="dataNode1" value="/opt/huawei/install/data/dn,opendb02,/opt/huawei/install/data/dn,opendb03,/opt/huawei/install/data/dn"/> 
            <PARAM name="dataNode1_syncNum" value="0"/> 
        </DEVICE> 
 
        <!-- node2上的节点部署信息,其中“name”的值配置为主机名称 --> 
        <DEVICE sn="opendb02"> 
            <PARAM name="name" value="opendb02"/> 
            <PARAM name="azName" value="AZ1"/> 
            <PARAM name="azPriority" value="1"/> 
            <!-- 如果服务器只有一个网卡可用,将backIP1和sshIP1配置成同一个IP --> 
            <PARAM name="backIp1" value="192.168.40.161"/> 
            <PARAM name="sshIp1" value="192.168.40.161"/> 
            <!-- cm --> 
            <PARAM name="cmServerPortStandby" value="15000"/> 
            <PARAM name="cmDir" value="/opt/huawei/data/cmserver"/> 
  </DEVICE> 
 
        <!-- node3上的节点部署信息,其中“name”的值配置为主机名称 --> 
        <DEVICE sn="opendb03"> 
            <PARAM name="name" value="opendb03"/> 
            <PARAM name="azName" value="AZ1"/> 
            <PARAM name="azPriority" value="1"/> 
            <!-- 如果服务器只有一个网卡可用,将backIP1和sshIP1配置成同一个IP --> 
            <PARAM name="backIp1" value="192.168.40.122"/> 
            <PARAM name="sshIp1" value="192.168.40.122"/> 
            <!-- cm --> 
            <PARAM name="cmServerPortStandby" value="15000"/> 
            <PARAM name="cmDir" value="/opt/huawei/data/cmserver"/> 
  </DEVICE> 
    </DEVICELIST> 
</ROOT>

注意事项

  • “/opt/huawei/install/om”存放互信等工具,为了避免权限问题,不要把实例数据目录放在此目录下。
  • 安装目录和数据目录需为空或者不存在,否则可能导致安装失败。
  • 在对数据库节点的实例进行具体配置时,需确保配置的目录之间不相互耦合。即各个配置目录不关联,删除其中任意一个目录,不会级联删除其它目录。如gaussdbAppPath为"/opt/huawei/install/app",gaussdbLogPath为"/opt/huawei/install/app/omm"。当gaussdbAppPath目录被删除时,会级联删除gaussdbLogPath目录,从而引起其它问题。
  • 若需要安装脚本自动创建安装用户时,各配置的目录需保证不与系统创建的默认用户目录耦合关联。
  • 配置openGauss路径和实例路径时,路径中不能包含"|",";","&","$","<",">","`","\\","'","\"","{","}","(",")","[","]","~","*","?“特殊字符。
  • 配置数据库节点名称时,请通过hostname命令获取数据库节点的主机名称,替换示例中的opendb01,opendb02。
  • 配置dcf_config时,角色的配置有leader,follower,passive,logger,其中可投票的角色有leader,follower,logger,配置角色组网时,可投票的角色不能少于3个,因此dcf模式下至少需要三个节点。
  • 资源池化中请谨慎配置所有包含磁盘信息的参数,安装时工具会低格所有参数中配置的磁盘,所有参数中的磁盘不能重复。
  • 资源池化中的ip和dn的数据ip保持一致,dss的端口是db端口+10,dms的端口是db端口+20。
  • om支持ipv6地址安装管理,所有节点的ip类型需一致(ipv4或者ipv6)。

解压安装包

对于个人开发者或非企业级环境,下载极简安装包(不安装OM等组件)即可。本文档采用的是企业版安装,因此安装OM等组件。一个节点操作即可

注意:安装包“openGauss-All-6.0.0-CentOS7-x86_64.tar.gz”和配置文件“cluster_config.xml”需在同一目录中,本文档是/topsoft/soft/openGauss目录

--进入安装包所在目录
[root@opendb01 openGauss]# ls -l
total 149768
-rw-r--r--. 1 root root 3.4K Oct 25 10:09 cluster_config.xml
-rw-r--r--. 1 root root 147M Oct 25 10:11 openGauss-All-6.0.0-CentOS7-x86_64.tar.gz
--解压openGauss-All-6.0.0-CentOS7-x86_64.tar.gz安装包
tar -xvf openGauss-All-6.0.0-CentOS7-x86_64.tar.gz
tar -xvf  openGauss-OM-6.0.0-CentOS7-x86_64.tar.gz
  • 在执行前置脚本gs_preinstall时,需要规划好openGauss配置文件路径、安装包存放路径、程序安装目录、实例数据目录,后续普通用户使用过程中不能再更改这些路径。
  • 运行前置脚本gs_preinstall准备安装环境时,脚本内部会自动将openGauss配置文件、解压后的安装包同步拷贝到其余服务器的相同目录下。
  • 在执行前置脚本或者互信前,请检查/etc/profile文件中是否包含错误输出信息,如果存在错误输出,需手动处理。

使用gs_preinstall初始化安装环境(主节点操作)

安装环境的初始化包含上传安装包和XML文件(二者需在同一目录)、解压安装包、使用gs_preinstall准备好安装环境。

创建完openGauss配置文件后,在执行安装前,为了后续能以最小权限进行安装及openGauss管理操作,保证系统安全性,需要运行安装前置脚本gs_preinstall准备好安装用户及环境在执行前置脚本gs_preinstall时,需要规划好openGauss配置文件路径、安装包存放路径、程序安装目录、实例数据目录,后续普通用户使用过程中不能再更改这些路径。

安装前置脚本gs_preinstall可以协助用户自动完成如下的安装环境准备工作:

  • 自动设置Linux内核参数以达到提高服务器负载能力的目的。这些参数直接影响数据库系统的运行状态,请仅在确认必要时调整。openGauss所设置的Linux内核参数取值请参见配置操作系统参数
  • 脚本内部会自动将openGauss配置文件、安装包拷贝到openGauss主机的相同目录下。
  • openGauss安装用户、用户组不存在时,自动创建安装用户以及用户组。
  • 读取openGauss配置文件中的目录信息并创建,将目录权限授予安装用户。
  • 只能使用root用户执行gs_preinstall命令
  • 在执行前置脚本或者互信前,请检查/etc/profile文件中是否包含错误输出信息,如果存在错误输出,需手动处理。
  • 会根据XML文件配置的备库信息,将文件传输到备库并创建用户、用户组、目录以及初始化安装
[root@opendb01 /]# cd /topsoft/soft/openGauss/script/
./gs_preinstall -U omm -G dbgrp -X /topsoft/soft/openGauss/cluster_config.xml

这里设置:omm用户密码omm

预安装脚本执行的详细过程如下:

[root@opendb01 script]# ./gs_preinstall -U omm -G dbgrp -X /topsoft/soft/openGauss/cluster_config.xml
Parsing the configuration file.
Successfully parsed the configuration file.
Installing the tools on the local node.
Successfully installed the tools on the local node.
Are you sure you want to create trust for root (yes/no)?yes
Please enter password for root
Please enter password for current user[root].
Password:
Checking network information.
All nodes in the network are Normal.
Successfully checked network information.
Creating SSH trust.
Creating the local key file.
Successfully created the local key files.
Appending local ID to authorized_keys.
Successfully appended local ID to authorized_keys.
Updating the known_hosts file.
Successfully updated the known_hosts file.
Appending authorized_key on the remote node.
Successfully appended authorized_key on all remote node.
Checking common authentication file content.
Successfully checked common authentication content.
Distributing SSH trust file to all node.
Distributing trust keys file to all node successfully.
Successfully distributed SSH trust file to all node.
Verifying SSH trust on all hosts.
Verifying SSH trust on all hosts by ip.
Successfully verified SSH trust on all hosts by ip.
Verifying SSH trust on all hosts by hostname.
Successfully verified SSH trust on all hosts by hostname.
Successfully verified SSH trust on all hosts.
Start set cron for root
Successfully to set cron for root
Successfully created SSH trust.
Successfully created SSH trust for the root permission user.
Setting host ip env
Successfully set host ip env.
Distributing package.
Begin to distribute package to tool path.
Successfully distribute package to tool path.
Begin to distribute package to package path.
Successfully distribute package to package path.
Successfully distributed package.
Are you sure you want to create the user[omm] and create trust for it (yes/no)? yes
Preparing SSH service.
Successfully prepared SSH service.
Installing the tools in the cluster.
Successfully installed the tools in the cluster.
Checking hostname mapping.
Successfully checked hostname mapping.
Creating SSH trust for [omm] user.
Please enter password for current user[omm].
Password:
Checking network information.
All nodes in the network are Normal.
Successfully checked network information.
Creating SSH trust.
Creating the local key file.
Successfully created the local key files.
Appending local ID to authorized_keys.
Successfully appended local ID to authorized_keys.
Updating the known_hosts file.
Successfully updated the known_hosts file.
Appending authorized_key on the remote node.
Successfully appended authorized_key on all remote node.
Checking common authentication file content.
Successfully checked common authentication content.
Distributing SSH trust file to all node.
Distributing trust keys file to all node successfully.
Successfully distributed SSH trust file to all node.
Verifying SSH trust on all hosts.
Verifying SSH trust on all hosts by ip.
Successfully verified SSH trust on all hosts by ip.
Successfully verified SSH trust on all hosts.
Start set cron for omm
Successfully to set cron for omm
Successfully created SSH trust.
Successfully created SSH trust for [omm] user.
Checking OS software.
Successfully check OS software.
Checking OS version.
Successfully checked OS version.
Checking cpu instructions.
Successfully checked cpu instructions.
Creating cluster's path.
Successfully created cluster's path.
Set and check OS parameter.
Setting OS parameters.
Successfully set OS parameters.
Warning: Installation environment contains some warning messages.
Please get more details by "/topsoft/soft/openGauss/script/gs_checkos -i A -h opendb01,opendb02,opendb03 -X /topsoft/soft/openGauss/cluster_config.xml --detail".
Set and check OS parameter completed.
Preparing CRON service.
Successfully prepared CRON service.
Setting user environmental variables.
Successfully set user environmental variables.
Setting the dynamic link library.
Successfully set the dynamic link library.
Setting Core file
Successfully set core path.
Setting pssh path
Successfully set pssh path.
Setting Cgroup.
Successfully set Cgroup.
Set ARM Optimization.
No need to set ARM Optimization.
Fixing server package owner.
Setting finish flag.
Successfully set finish flag.
Preinstallation succeeded.

警告可忽略

问题处理

问题1:python3: No such file or directory

--问题描述
[root@opendb01 script]# ./gs_preinstall -U omm -G dbgrp -X /topsoft/soft/openGauss/cluster_config.xml
/usr/bin/env: python3: No such file or directory
--解决办法
采用下面办法进行python版本升级
--查看python版本
[root@opendb01 ~]# python --version
Python 2.7.5
[root@opendb01 ~]# python3 --version
python3命令找不到
--采用yum方式安装操作系统自带的包管理器中的python3
yum install python3
--再次查看python版本
[root@opendb01 ~]# python --version
Python 2.7.5
[root@opendb01 ~]# python3 --version
Python 3.6.8

问题2:The XML file format is incorrect

--问题描述
[root@opendb01 script]# ./gs_preinstall -U omm -G dbgrp -X /topsoft/soft/openGauss/cluster_config.xml
Parsing the configuration file.
Successfully parsed the configuration file.
[GAUSS-50217] : Failed to decompress version.cfg.The cmd is cd /topsoft/soft/openGauss/script/.. && tar -xpf `ls openGauss-Server*.tar.bz2 | tail -1` ./version.cfg. The output is tar (child): lbzip2: Cannot exec: No such file or directory
tar (child): Error is not recoverable: exiting now
tar: Child returned status 2
tar: Error is not recoverable: exiting now.
--解决办法
yum -y install bzip2

问题3:python3: command not found

--问题描述
[root@opendb01 script]# ./gs_preinstall -U omm -G dbgrp -X /topsoft/soft/openGauss/cluster_config.xml
...
Successfully distribute package to package path.
[GAUSS-51400] : Failed to execute the command: python3 '/topsoft/soft/openGauss/script/local/PreInstallUtility.py' -t check_config -u omm -X /topsoft/soft/openGauss/cluster_config.xml. Result:{'opendb02': 'Failure'}.
Error:
[FAILURE] opendb02:
bash: python3: command not found
--解决办法
备库升级python
yum install python3

问题4:[GAUSS-50202] : The /opt/huawei/install must be empty

--问题描述
[root@opendb01 script]# ./gs_preinstall -U omm -G dbgrp -X /topsoft/soft/openGauss/cluster_config.xml
......
Creating cluster's path.
[SUCCESS] opendb01:
[FAILURE] opendb02:
[GAUSS-50202] : The /opt/huawei/install must be empty. Or user [omm] has write permission to directory /opt/huawei/install. Because it will create symbolic link [/opt/huawei/install/app] to install path [/opt/huawei/install/app_aee4abd5] in gs_install process with this user.
--解决办法
第一次初始化安装环境失败后,手动删除备库上的目录后再进行初始化安装
节点2上操作
cd /opt
rm -rf huawei

执行安装(主节点操作)

使用gs_install安装openGauss。安装脚本gs_install必须以前置脚本中指定的omm执行,否则,脚本执行会报错。

/topsoft/soft/openGauss/cluster_config.xml为openGauss配置文件的路径。在执行过程中,用户需根据提示输入数据库的密码,密码具有一定的复杂度,为保证用户正常使用该数据库,请记住输入的数据库密码。这里设置为Topnet@123

设置的密码要符合复杂度要求:

  • 最少包含8个字符,最多包含16个字符。
  • 不能和用户名、当前密码(ALTER)、或当前密码反序相同。
  • 至少包含大写字母(A-Z)、小写字母(a-z)、数字、非字母数字字符(限定为~!@#$%^&*()-_=+\|[{}];:,<.>/?)四类字符中的三类字符。

注意事项:

  • openGauss支持字符集的多种写法:gbk/GBK、UTF-8/UTF8/utf8/utf-8和Latine1/latine1。
  • openGauss5.0.0安装时若不指定字符集,默认字符集为SQL_ASCII,为简化和统一区域loacle默认设置为C,若想指定其他字符集和区域,请在安装时使用参数–gsinit-parameter="–locale=LOCALE"来指定,LOCALE为新数据库设置缺省的区域;而openGauss6.0.0默认字符集已经更改为UTF8。
  • 默认端口5432
--赋予配置文件777的权限,因为安装脚本gs_install必须以前置脚本中指定的omm执行
chmod 777 /topsoft/soft/openGauss/cluster_config.xml
chmod 777 /topsoft/soft
--切换用户  omm为前置脚本gs_preinstall中-U参数指定的用户
su - omm
--查看配置文件/etc/profile中的语言参数
[root@opendb01 script]# su - omm
Last login: Fri Oct 25 12:51:53 CST 2024
[omm@opendb01 ~]$ cat /etc/profile | grep LANG
export LANG=en_US.UTF-8
--查看系统支持UTF-8编码的区域
 locale -a|grep utf8
--执行安装脚本
gs_install -X /topsoft/soft/openGauss/cluster_config.xml --gsinit-parameter="--locale=en_US.utf8"

安装过程中会生成ssl证书,证书存放路径为{gaussdbAppPath}/share/sslcert/om,其中{gaussdbAppPath}为openGauss配置文件中指定的程序安装目录。

[omm@opendb01 ~]$ cd /opt/huawei/install/app/share/sslcert/om
[omm@opendb01 om]$ ls -lh
total 64K
-rw-------. 1 omm dbgrp  4399 Oct 26 18:15 cacert.pem
-rw-------. 1 omm dbgrp  1766 Oct 26 18:15 server.key
-rw-------. 1 omm dbgrp 10921 Oct 26 18:15 openssl.cnf
-rw-------. 1 omm dbgrp  4402 Oct 26 18:15 server.crt
-rw-------. 1 omm dbgrp    24 Oct 26 18:15 server.key.rand
-rw-------. 1 omm dbgrp    56 Oct 26 18:15 server.key.cipher
-rw-------. 1 omm dbgrp  1766 Oct 26 18:15 client.key
-rw-------. 1 omm dbgrp  4402 Oct 26 18:15 client.crt
-rw-------. 1 omm dbgrp    24 Oct 26 18:15 client.key.rand
-rw-------. 1 omm dbgrp    56 Oct 26 18:15 client.key.cipher
-rw-------. 1 omm dbgrp  1219 Oct 26 18:15 client.key.pk8

日志文件路径下会生成1个日志文件:“gs_local-YYYY-MM-DD_HHMMSS.log”。

/var/log/omm/omm/om/gs_local-2024-10-26_174100.log

详细过程如下:

[omm@opendb01 ~]$ gs_install -X /topsoft/soft/openGauss/cluster_config.xml --gsinit-parameter="--locale=en_US.utf8"
Parsing the configuration file.
Successfully checked gs_uninstall on every node.
Check preinstall on every node.
Successfully checked preinstall on every node.
Creating the backup directory.
Successfully created the backup directory.
begin deploy..
Installing the cluster.
begin prepare Install Cluster..
Checking the installation environment on all nodes.
begin install Cluster..
Installing applications on all nodes.
Successfully installed APP.
begin init Instance..
encrypt cipher and rand files for database.
Please enter password for database:
Please repeat for database:
begin to create CA cert files
The sslcert will be generated in /opt/huawei/install/app/share/sslcert/om
Create CA files for cm beginning.
Create CA files on directory [/opt/huawei/install/app_aee4abd5/share/sslcert/cm]. file list: ['cacert.pem', 'server.key', 'server.crt', 'client.key', 'client.crt', 'server.key.cipher', 'server.key.rand', 'client.key.cipher', 'client.key.rand']
Non-dss_ssl_enable, no need to create CA for DSS
Cluster installation is completed.
Configuring.
Deleting instances from all nodes.
Successfully deleted instances from all nodes.
Checking node configuration on all nodes.
Initializing instances on all nodes.
Updating instance configuration on all nodes.
Check consistence of memCheck and coresCheck on database nodes.
Successfully check consistence of memCheck and coresCheck on all nodes.
Configuring pg_hba on all nodes.
Configuration is completed.
Starting cluster.
======================================================================
Successfully started primary instance. Wait for standby instance.
======================================================================
.
Successfully started cluster.
======================================================================
cluster_state      : Normal
redistributing     : No
node_count         : 3
Datanode State
    primary           : 1
    standby           : 2
    secondary         : 0
    cascade_standby   : 0
    building          : 0
    abnormal          : 0
    down              : 0
Successfully installed application.
end deploy..
[omm@opendb01 ~]$

至此一主一备部署完成,主备服务器上的服务也都随之启动。

测试主备数据同步

主库登录数据库

[omm@opendb01 om]$ gsql -d postgres -p 5432
gsql ((openGauss 6.0.0 build aee4abd5) compiled at 2024-09-29 18:38:08 commit 0 last mr  )
Non-SSL connection (SSL connection is recommended when requiring high-security)
Type "help" for help.
openGauss=# \l+
                                                              List of databases
   Name    | Owner | Encoding |  Collate   |   Ctype    | Access privileges | Size  | Tablespace |                Description
-----------+-------+----------+------------+------------+-------------------+-------+------------+--------------------------------------------
 postgres  | omm   | UTF8     | en_US.utf8 | en_US.utf8 |                   | 13 MB | pg_default | default administrative connection database
 template0 | omm   | UTF8     | en_US.utf8 | en_US.utf8 | =c/omm           +| 13 MB | pg_default | default template for new databases
           |       |          |            |            | omm=CTc/omm       |       |            |
 template1 | omm   | UTF8     | en_US.utf8 | en_US.utf8 | =c/omm           +| 13 MB | pg_default | unmodifiable empty database
           |       |          |            |            | omm=CTc/omm       |       |            |
(3 rows)

主库创建业务用户

openGauss不支持通过初始用户进行远程连接的原因如下:

  • openGauss包含两个模板数据库template0、template1,以及一个默认的用户数据库postgres。postgres默认的兼容数据库类型为O(即DBCOMPATIBILITY = A ),该兼容类型下将空字符串作为NULL处理。
  • CREATE DATABASE实际上通过拷贝模板数据库来创建新数据库。默认情况下,拷贝template0。请避免使用客户端或其他手段连接及操作两个模板数据库。
  • 模板数据库中没有用户表,可通过系统表PG_DATABASE查看模板数据库属性。
  • 模板template0不允许用户连接;模板template1只允许数据库初始用户和系统管理员连接,普通用户无法连接。

由于openGauss不支持通过初始用户进行远程连接,使用客户端工具通过omm用户访问数据库提示FATAL: Forbid remote connection with initial user,因此需创建1个业务用户用于访问数据库:

--登录数据库
su - omm
gsql -d postgres -p 5432
--创建业务用户
create user dxjnew password "Topnet@123";
grant usage on  schema public to dxjnew;
grant all privileges to dxjnew;
--创建业务用户(超管角色)
CREATE USER dxjnew WITH SYSADMIN password "Topnet@123";

主库创建数据库

CREATE DATABASE dxj owner dxjnew;

主库构建测试数据

openGauss=# \c dxj dxjnew
Password for user dxjnew:
Non-SSL connection (SSL connection is recommended when requiring high-security)
You are now connected to database "dxj" as user "dxjnew".
dxj=> create table t01(id int);
CREATE TABLE
dxj=> insert into t01 values (10);
INSERT 0 1
dxj=> select * from t01;
 id
----
 10
(1 row)

备库查询

--备库1查询
[omm@opendb02 ~]$ gsql -d dxj -p 5432
gsql ((openGauss 6.0.0 build aee4abd5) compiled at 2024-09-29 18:38:08 commit 0 last mr  )
Non-SSL connection (SSL connection is recommended when requiring high-security)
Type "help" for help.
dxj=# select * from t01;
 id
----
 10
(1 row)
--备库2查询
[omm@opendb03 ~]$ gsql -d dxj -p 5432
gsql ((openGauss 6.0.0 build aee4abd5) compiled at 2024-09-29 18:38:08 commit 0 last mr  )
Non-SSL connection (SSL connection is recommended when requiring high-security)
Type "help" for help.
dxj=# select * from t01;
 id
----
 10
(1 row)

至此openGauss企业版单中心一主一备部署完成,备库默认是只读。

dxj=# insert into t01 values(10);
ERROR:  cannot execute INSERT in a read-only transaction

数据库配置

配置omm用户环境变量

su - omm
vi .bash_profile
alias gsql='rlwrap gsql'
--生效
source .bash_profile

查数据库版本

--法一
安装目录下查看
cat /topsoft/huawei/install/app/version.cfg
--法二
openGauss=# select version();
                                                                        version
-------------------------------------------------------------------------------------------------------------------------------------------------------
 (openGauss 6.0.0 build aee4abd5) compiled at 2024-09-29 18:38:08 commit 0 last mr   on x86_64-unknown-linux-gnu, compiled by g++ (GCC) 10.3.0, 64-bit
(1 row)

配置远程访问数据库

--更改配置文件
vi /topsoft/huawei/install/data/dn/postgresql.conf
更改前
listen_addresses = 'localhost'
wal_level = hot_standby  # minimal, archive, hot_standby or logical
更改后
listen_addresses = '*,192.168.40.106'
wal_level = logical             # minimal, archive, hot_standby or logical
vi /topsoft/huawei/install/data/dn/pg_hba.conf
添加
host    all    all    0.0.0.0/0   md5
--重启库
gs_om -t stop
gs_om -t start

密码参数

password_encryption_type

参数说明:该参数决定采用何种加密方式对用户密码进行加密存储。修改此参数的配置不会自动触发已有用户密码加密方式的修改,只会对新创建用户的密码或已有用户修改的密码采用新的加密方式进行加密。

参数类型:枚举型

参数单位:无

取值范围:0、1、2、3

0:表示采用md5方式对密码加密。

1:表示采用sha256和md5两种方式分别对密码加密。

2:表示采用sha256方式对密码加密。

3:表示采用sm3方式对密码加密。

NOTICE:MD5加密算法安全性低,存在安全风险,不建议使用。

默认值:2

设置方式:该参数属于SIGHUP类型参数,请参见表1中对应设置方法进行设置。数据库全局参数,可在数据库启动时设置或者在数据库启动后,发送指令重新加载。

设置建议:设置为默认值。不需要重启库,需要加载下库reload

--密码策略
show password_encryption_type
--更改pg_hba.conf
[root@topnet31 ~]# cd /opt/huawei/openGauss/install/data/dn
[root@topnet31 dn]# vi postgresql.conf
更改前
#password_encryption_type = 2            #Password storage type, 0 is md5 for PG, 1 is sha256 + md5, 2 is sha256 only
更改后
password_encryption_type = 1            #Password storage type, 0 is md5 for PG, 1 is sha256 + md5, 2 is sha256 only

重启数据库服务

如果主备节点都是停止状态,那么启动主节点备节点会自动重启,这点比PG智能。

--停止
cd /opt/huawei/openGauss/install/om/script/
gs_om -t stop
--启动
cd /opt/huawei/openGauss/install/om/script/
gs_om -t start

查询openGauss状态

gs_om -t status --detail 
--查询某主机上的实例状态,请在命令中增加“-h”项  主机名
gs_om -t status -h plat2

查看默认字符集

openGauss=# show server_encoding;
 server_encoding
-----------------
 UTF8
(1 row)

参考链接:openGauss 5.0.0企业版一主一备安装部署_openeuler pssh-CSDN博客

参考链接:Open Gauss常见主备部署方案简介 (osinfra.cn)

创建 Xml配置文件 (osinfra.cn)

参考链接:openGauss 5.0.0企业版一主一备安装部署_openeuler pssh-CSDN博客

参考链接:Open Gauss常见主备部署方案简介 (osinfra.cn)

相关文章
|
12天前
|
消息中间件 分布式计算 NoSQL
大数据-134 - ClickHouse 集群三节点 安装配置启动
大数据-134 - ClickHouse 集群三节点 安装配置启动
32 0
|
2月前
|
运维 监控 数据库
在OceanBase数据库中,obd集群版本需在线升级4.3.1.0升级至4.3.2
【8月更文挑战第14天】在OceanBase数据库中,obd集群版本需在线升级4.3.1.0升级至4.3.2
63 0
|
存储 Kubernetes 关系型数据库
Kubernetes(k8s)上搭建一主两从的mysql8集群
Kubernetes(k8s)上搭建一主两从读写分离的MySQL集群,采用了MySQL8。视频教程地址:https://www.bilibili.com/video/BV1iw411e7ZE/
826 2
|
存储 分布式计算 资源调度
搭建Flink集群、集群HA高可用以及配置历史服务器
本文介绍了如何搭建一个Flink集群、Flink集群HA高可用,并配置历史服务器以记录Job任务执行的详细信息和状态。
355 1
|
存储 运维 Kubernetes
PostgreSQL-HA 高可用集群在 Rainbond 上的部署方案
本文将介绍在 Rainbond 上使用 Postgresql-repmgr + Pgpool 实现 Postgresql 高可用集群的部署和管理。
|
网络安全
OushuDB 管理指南 集群高可用(2)
OushuDB 管理指南 集群高可用(2)
78 0
OushuDB 管理指南 集群高可用(3)
OushuDB 管理指南 集群高可用(3)
73 0
|
存储 Java 关系型数据库
OushuDB 管理指南 集群高可用(1)
OushuDB 管理指南 集群高可用(1)
103 0
|
存储 监控 Cloud Native
从0到1部署一套TiDB本地集群
从0到1部署一套TiDB本地集群
882 0
从0到1部署一套TiDB本地集群
|
分布式计算 Hadoop 大数据
hadoop集群离线化搭建(利用HDP快速搭建大数据集群)(二)
000hadoop集群离线化搭建(利用HDP快速搭建大数据集群)
154 0
hadoop集群离线化搭建(利用HDP快速搭建大数据集群)(二)