千家信息网

DM7如何使用裸设备搭建DMRAC

发表于:2024-11-23 作者:千家信息网编辑
千家信息网最后更新 2024年11月23日,这篇文章主要介绍DM7如何使用裸设备搭建DMRAC,文中介绍的非常详细,具有一定的参考价值,感兴趣的小伙伴们一定要看完!一、操作环境主机 IP地址(对外服务) IP地址(内部通信) 实例名 操作系统d
千家信息网最后更新 2024年11月23日DM7如何使用裸设备搭建DMRAC

这篇文章主要介绍DM7如何使用裸设备搭建DMRAC,文中介绍的非常详细,具有一定的参考价值,感兴趣的小伙伴们一定要看完!

一、操作环境
主机 IP地址(对外服务) IP地址(内部通信) 实例名 操作系统

dmrac1  10.18.13.165             10.10.10.165              rac0    Redhat 6.7dmrac2  10.18.13.166             10.10.10.166              rac1    Redhat 6.7

共享存储

/dev/sdb1  /dev/raw/raw1   dcr disk   2G/dev/sdb2       /dev/raw/raw2   voting disk        2G/dev/sdb3       /dev/raw/raw3   data disk1 2G/dev/sdb4       /dev/raw/raw4   data disk2 2G/dev/sdb1       /dev/raw/raw5   data disk3 2G/dev/sdb2       /dev/raw/raw6   data disk4 2G/dev/sdb3       /dev/raw/raw7   log disk1  2G/dev/sdb4       /dev/raw/raw8   log disk2  2G/dev/sdb1       /dev/raw/raw9   log disk3  2G/dev/sdb2       /dev/raw/raw10  log disk4  2G/dev/sdb3       /dev/raw/raw11  log disk5  2G/dev/sdb4       /dev/raw/raw12  log disk6  2G

二、操作系统配置
1、关闭防火墙和SELINUX

[root@cs ~]# service iptables stopiptables: Setting chains to policy ACCEPT: nat mangle filter [  OK  ]iptables: Flushing firewall rules: [  OK  ]iptables: Unloading modules: [  OK  ][root@cs ~]# chkconfig iptables off[root@cs ~]# setenforce 0[root@cs ~]# sed -i s:^SELINUX=.*$:SELINUX=disabled:g /etc/selinux/config[root@cs ~]# service iptables stopiptables: Setting chains to policy ACCEPT: nat mangle filter [  OK  ]iptables: Flushing firewall rules: [  OK  ]iptables: Unloading modules: [  OK  ][root@cs ~]# chkconfig iptables off[root@cs ~]# setenforce 0[root@cs ~]# sed -i s:^SELINUX=.*$:SELINUX=disabled:g /etc/selinux/config

2、修改主机名

[root@cs ~]# hostname dm1[root@cs ~]# sed -i s:^HOSTNAME=.*$:HOSTNAME=dm1:g /etc/sysconfig/network[root@cs ~]# hostname dm2[root@cs ~]# sed -i s:^HOSTNAME=.*$:HOSTNAME=dm2:g /etc/sysconfig/network3、修改hosts文件[root@cs ~]# echo "> 10.18.13.165   dm1> 10.18.13.166   dm2" >> /etc/hosts[root@cs ~]#[root@cs ~]# echo "> 10.18.13.165   dm1> 10.18.13.166   dm2" >> /etc/hosts[root@cs ~]#

三、 安装达梦软件
安装操作详见 Oracle Linux 7.1中安装达梦数据库DM7

四、绑定UDEV

[root@dm1 rules.d]# vi 99-dm-devices.rulesACTION=="add", KERNEL=="sdb1", RUN+="/bin/raw /dev/raw/raw1 %N"ACTION=="add", KERNEL=="sdb2", RUN+="/bin/raw /dev/raw/raw2 %N"ACTION=="add", KERNEL=="sdb3", RUN+="/bin/raw /dev/raw/raw3 %N"ACTION=="add", KERNEL=="sdb4", RUN+="/bin/raw /dev/raw/raw4 %N"ACTION=="add", KERNEL=="sdc1", RUN+="/bin/raw /dev/raw/raw5 %N"ACTION=="add", KERNEL=="sdc2", RUN+="/bin/raw /dev/raw/raw6 %N"ACTION=="add", KERNEL=="sdc3", RUN+="/bin/raw /dev/raw/raw7 %N"ACTION=="add", KERNEL=="sdc4", RUN+="/bin/raw /dev/raw/raw8 %N"ACTION=="add", KERNEL=="sdd1", RUN+="/bin/raw /dev/raw/raw9 %N"ACTION=="add", KERNEL=="sdd2", RUN+="/bin/raw /dev/raw/raw10 %N"ACTION=="add", KERNEL=="sdd3", RUN+="/bin/raw /dev/raw/raw11 %N"ACTION=="add", KERNEL=="sdd4", RUN+="/bin/raw /dev/raw/raw12 %N"ACTION=="add", KERNEL=="raw[1-12]", OWNER="dmdba", GROUP="dinstall", MODE="660"[root@dm1 rules.d]# start_udevStarting udev: [  OK  ][root@dm1 rules.d]# ls -lrt /dev/raw/total 0crw-rw---- 1 root  disk     162,  0 May  7 16:28 rawctlcrw-rw---- 1 dmdba dinstall 162,  9 May  7 16:28 raw9crw-rw---- 1 dmdba dinstall 162, 12 May  7 16:28 raw12crw-rw---- 1 dmdba dinstall 162, 11 May  7 16:28 raw11crw-rw---- 1 dmdba dinstall 162, 10 May  7 16:28 raw10crw-rw---- 1 dmdba dinstall 162,  6 May  7 16:28 raw6crw-rw---- 1 dmdba dinstall 162,  1 May  7 16:28 raw1crw-rw---- 1 dmdba dinstall 162,  7 May  7 16:28 raw7crw-rw---- 1 dmdba dinstall 162,  8 May  7 16:28 raw8crw-rw---- 1 dmdba dinstall 162,  5 May  7 16:28 raw5crw-rw---- 1 dmdba dinstall 162,  2 May  7 16:28 raw2crw-rw---- 1 dmdba dinstall 162,  3 May  7 16:28 raw3crw-rw---- 1 dmdba dinstall 162,  4 May  7 16:28 raw4[root@dm2 /]# cd /etc/udev/rules.d/[root@dm2 rules.d]# vi 99-dm-devices.rulesACTION=="add", KERNEL=="sdb1", RUN+="/bin/raw /dev/raw/raw1 %N"ACTION=="add", KERNEL=="sdb2", RUN+="/bin/raw /dev/raw/raw2 %N"ACTION=="add", KERNEL=="sdb3", RUN+="/bin/raw /dev/raw/raw3 %N"ACTION=="add", KERNEL=="sdb4", RUN+="/bin/raw /dev/raw/raw4 %N"ACTION=="add", KERNEL=="sdc1", RUN+="/bin/raw /dev/raw/raw5 %N"ACTION=="add", KERNEL=="sdc2", RUN+="/bin/raw /dev/raw/raw6 %N"ACTION=="add", KERNEL=="sdc3", RUN+="/bin/raw /dev/raw/raw7 %N"ACTION=="add", KERNEL=="sdc4", RUN+="/bin/raw /dev/raw/raw8 %N"ACTION=="add", KERNEL=="sdd1", RUN+="/bin/raw /dev/raw/raw9 %N"ACTION=="add", KERNEL=="sdd2", RUN+="/bin/raw /dev/raw/raw10 %N"ACTION=="add", KERNEL=="sdd3", RUN+="/bin/raw /dev/raw/raw11 %N"ACTION=="add", KERNEL=="sdd4", RUN+="/bin/raw /dev/raw/raw12 %N"ACTION=="add", KERNEL=="raw[1-12]", OWNER="dmdba", GROUP="dinstall", MODE="660"[root@dm2 rules.d]# start_udevStarting udev: [  OK  ][root@dm2 rules.d]# ls -lrt /dev/raw/total 0crw-rw---- 1 root  disk     162,  0 May  7 16:28 rawctlcrw-rw---- 1 dmdba dinstall 162,  9 May  7 16:28 raw9crw-rw---- 1 dmdba dinstall 162, 12 May  7 16:28 raw12crw-rw---- 1 dmdba dinstall 162, 11 May  7 16:28 raw11crw-rw---- 1 dmdba dinstall 162, 10 May  7 16:28 raw10crw-rw---- 1 dmdba dinstall 162,  6 May  7 16:28 raw6crw-rw---- 1 dmdba dinstall 162,  1 May  7 16:28 raw1crw-rw---- 1 dmdba dinstall 162,  7 May  7 16:28 raw7crw-rw---- 1 dmdba dinstall 162,  8 May  7 16:28 raw8crw-rw---- 1 dmdba dinstall 162,  5 May  7 16:28 raw5crw-rw---- 1 dmdba dinstall 162,  2 May  7 16:28 raw2crw-rw---- 1 dmdba dinstall 162,  3 May  7 16:28 raw3crw-rw---- 1 dmdba dinstall 162,  4 May  7 16:28 raw4

可以通过blockdev --getsize64 /dev/raw/raw1命令查看裸设备大小

[root@dm1 rules.d]# blockdev --getsize64 /dev/raw/raw12154991104[root@dm2 ~]# blockdev --getsize64 /dev/raw/raw12154991104

六、配置dmdcr_cfg.ini文件
在2个节点的/dm7/data目录下创建配置文件dmdcr_cfg.ini,仅使用裸设备,不使用ASM文件系统,不需要配置ASM信息,仅配置CSS/DB信息。在文件中添加如下内容:

[dmdba@dm1 dm7]$ mkdir data[dmdba@dm1 dm7]$ cd data[dmdba@dm1 data]$ vi dmdcr_cfg.iniDCR_N_GRP = 2DCR_VTD_PATH = /dev/raw/raw2DCR_OGUID = 63635[GRP]DCR_GRP_TYPE = CSSDCR_GRP_NAME = GRP_CSSDCR_GRP_N_EP = 2DCR_GRP_DSKCHK_CNT = 60[GRP_CSS]DCR_EP_NAME = CSS0DCR_EP_HOST = 10.10.10.165DCR_EP_PORT = 9541[GRP_CSS]DCR_EP_NAME = CSS1DCR_EP_HOST = 10.10.10.166DCR_EP_PORT = 9542[GRP]DCR_GRP_TYPE = DBDCR_GRP_NAME = GRP_RACDCR_GRP_N_EP = 2DCR_GRP_DSKCHK_CNT = 60[GRP_RAC]DCR_EP_NAME = RAC0DCR_EP_SEQNO = 0DCR_EP_PORT = 5236DCR_CHECK_PORT = 9741[GRP_RAC]DCR_EP_NAME = RAC1DCR_EP_SEQNO = 1DCR_EP_PORT = 5236DCR_CHECK_PORT = 9742[dmdba@dm2 dm7]$ mkdir data[dmdba@dm2 dm7]$ cd data[dmdba@dm2 data]$ vi dmdcr_cfg.iniDCR_N_GRP = 2DCR_VTD_PATH = /dev/raw/raw2DCR_OGUID = 63635[GRP]DCR_GRP_TYPE = CSSDCR_GRP_NAME = GRP_CSSDCR_GRP_N_EP = 2DCR_GRP_DSKCHK_CNT = 60[GRP_CSS]DCR_EP_NAME = CSS0DCR_EP_HOST = 10.10.10.165DCR_EP_PORT = 9541[GRP_CSS]DCR_EP_NAME = CSS1DCR_EP_HOST = 10.10.10.166DCR_EP_PORT = 9542[GRP]DCR_GRP_TYPE = DBDCR_GRP_NAME = GRP_RACDCR_GRP_N_EP = 2DCR_GRP_DSKCHK_CNT = 60[GRP_RAC]DCR_EP_NAME = RAC0DCR_EP_SEQNO = 0DCR_EP_PORT = 5236DCR_CHECK_PORT = 9741[GRP_RAC]DCR_EP_NAME = RAC1DCR_EP_SEQNO = 1DCR_EP_PORT = 5236DCR_CHECK_PORT = 9742

七、使用 DMASMCMD 工具初始化(任意一节点执行)

[dmdba@dm1 ~]$ dmasmcmdDMASMCMD V7.1.6.46-Build(2018.02.08-89107)ENTASM>create dcrdisk '/dev/raw/raw1' 'dcr'the ASM initialize dcrdisk /dev/raw/raw1 to name DMASMdcrUsed time: 1.459(ms).ASM>create votedisk '/dev/raw/raw2' 'vote'the ASM initialize votedisk /dev/raw/raw2 to name DMASMvoteUsed time: 1.380(ms).ASM>init dcrdisk '/dev/raw/raw1' from '/dm7/data/dmdcr_cfg.ini'syntax errorasmcmd parse failed!ASM>init dcrdisk '/dev/raw/raw1' from '/dm7/data/dmdcr_cfg.ini' identified by 'dameng123'[Trace]DG 126 allocate 4 extents for file 0xfe000002.Check dcr disk failed, please check and try againUsed time: 271.543(ms).ASM>init dcrdisk '/dev/raw/raw1' from '/dm7/data/dmdcr_cfg.ini' identified by 'dameng123'[Trace]DG 126 allocate 4 extents for file 0xfe000002.Used time: 68.745(ms).ASM>init votedisk '/dev/raw/raw2' from '/dm7/data/dmdcr_cfg.ini'[Trace]DG 125 allocate 4 extents for file 0xfd000002.Used time: 33.488(ms).

八、操作系统配置准备配置dminit.ini文件,存放在/dm7/data目录中

system_path = /dm7/datadb_name=racmain = /dev/raw/raw3main_size = 128roll = /dev/raw/raw4roll_size = 128system = /dev/raw/raw5system_size = 128ctl_path = /dev/raw/raw6ctl_size = 8dcr_path=/dev/raw/raw1dcr_seqno=0[rac0]config_path=/dm7/data/rac0_configport_num = 5236mal_host = 10.10.10.165mal_port = 9340log_size = 256log_path = /dev/raw/raw7log_path = /dev/raw/raw8[rac1]config_path=/dm7/data/rac1_configport_num = 5236mal_host = 10.10.10.166mal_port = 9341log_size = 256log_path = /dev/raw/raw9log_path = /dev/raw/raw10

九、准备dmdcr.ini 配置文件
dmdcr.ini 是 dmcss、dmasmsvr、dmasmtool 工具的输入参数。记录了当前节点序列号以及 DCR 磁盘路径。在2个节点的/dm/dmdbms/data目录下创建dmdcr.ini 配置文件,dmdcr_path 相同,dmasvrmal.ini 文件内容也相同,dmdcr_seqo 分别为 0 和 1。
节点 1:

[dmdba@dmrac1 data]$ vi dmdcr.iniDMDCR_PATH = /dev/raw/raw1DMDCR_SEQNO = 0#ASMDMDCR_ASM_RESTART_INTERVAL = 0DMDCR_ASM_STARTUP_CMD = /dm7/bin/dmasmsvr dcr_ini=/dm7/data/dmdcr.ini#DBDMDCR_DB_RESTART_INTERVAL = 0DMDCR_DB_STARTUP_CMD = /dm7/bin/dmserver path=/dm7/data/rac0_config/dm.ini dcr_ini=/dm7/data/dmdcr.ini

节点2:

[dmdba@dmrac2 data]$ vi dmdcr.iniDMDCR_PATH = /dev/raw/raw1DMDCR_SEQNO = 1#ASMDMDCR_ASM_RESTART_INTERVAL = 0DMDCR_ASM_STARTUP_CMD = /dm7/bin/dmasmsvr dcr_ini=/dm7/data/dmdcr.ini#DBDMDCR_DB_RESTART_INTERVAL = 0DMDCR_DB_STARTUP_CMD = /dm7/bin/dmserver path=/dm7/data/rac1_config/dm.ini dcr_ini=/dm7/data/dmdcr.ini

十、启动DMCSS 服务程序
1、注册 DMCSS服务
节点一:

[root@dm1 ~]# /dm7/script/root/dm_service_installer.sh -t dmcss -i /dm7/data/dmdcr.ini -p rac1Move the service script file(/dm7/bin/DmCSSServicerac1 to /etc/rc.d/init.d/DmCSSServicerac1)Finished to create the service (DmCSSServicerac1)

节点二:

[root@dm2 ~]# /dm7/script/root/dm_service_installer.sh -t dmcss -i /dm7/data/dmdcr.ini -p rac2Move the service script file(/dm7/bin/DmCSSServicerac2 to /etc/rc.d/init.d/DmCSSServicerac2)Finished to create the service (DmCSSServicerac2)

2、启动DMCSS 服务
节点一:

[root@dm1 ~]# service DmCSSServicerac1 startStarting DmCSSServicerac1: [ OK ]

节点二:

[root@dm2 ~]# service DmCSSServicerac2 startStarting DmCSSServicerac2: [ OK ]

十一、操作系统配置使用dminit初始化DB环境
在任意节点启动 dminit 工具初始化数据库。dminit 执行完成后,会在 config_path 目录(/dm7/data/rac0_config 和/dm7/data/rac1_config)下生成配置文件 dm.ini 和 dmmal.ini。

[dmdba@dm1 data]$ dminit control=/dm7/data/dminit.iniinitdb V7.1.6.46-Build(2018.02.08-89107)ENTdb version: 0x7000afile dm.key not found, use default license!License will expire in 14 day(s) on 2020-05-21 log file path: /dev/raw/raw7 log file path: /dev/raw/raw8 log file path: /dev/raw/raw9 log file path: /dev/raw/raw10FILE "/dev/raw/raw5" has already existedFILE "/dev/raw/raw4" has already existedFILE "/dev/raw/raw3" has already existedFILE "/dev/raw/raw6" has already existedFILE "/dev/raw/raw7" has already existedFILE "/dev/raw/raw8" has already existedFILE "/dev/raw/raw9" has already existedFILE "/dev/raw/raw10" has already existedFile "/dev/raw/raw5" has already existed,whether overwrite(y/n, 1/0): yFile "/dev/raw/raw4" has already existed,whether overwrite(y/n, 1/0): yFile "/dev/raw/raw3" has already existed,whether overwrite(y/n, 1/0): yFile "/dev/raw/raw6" has already existed,whether overwrite(y/n, 1/0): yFile "/dev/raw/raw7" has already existed,whether overwrite(y/n, 1/0): yFile "/dev/raw/raw8" has already existed,whether overwrite(y/n, 1/0): yFile "/dev/raw/raw9" has already existed,whether overwrite(y/n, 1/0): yFile "/dev/raw/raw10" has already existed,whether overwrite(y/n, 1/0): ywrite to dir [/dm7/data/rac].create dm database success. 2020-05-07 16:41:52

将节点一的配置文件复制到节点二:

[dmdba@dm1 data]$ scp -r rac1_config 10.18.13.166:`pwd`The authenticity of host '10.18.13.166 (10.18.13.166)' can't be established.RSA key fingerprint is 89:fc:3e:e3:2d:27:94:07:0e:6b:fc:c5:e8:89:44:1f.Are you sure you want to continue connecting (yes/no)? yesWarning: Permanently added '10.18.13.166' (RSA) to the list of known hosts.dmdba@10.18.13.166's password:sqllog.ini                                                                                                                                                                                                100%  479     0.5KB/s   00:00dm.ini                                                                                                                                                                                                    100%   40KB  39.8KB/s   00:00dmmal.ini                                                                                                                                                                                                 100%  204     0.2KB/s   00:00[dmdba@dm1 data]$

一定要将节点一/dm7/data/目录中生成的rac目录复制到节点二的/dm7/data目录中,否则在节点二中启动数据库时会出现以下错误,原因就是因为使用裸设备时生成的rac目录及其文件不是存储在共享存储中可以让集群节点都能访问。

Starting DmServicerac2: [ FAILED ]file dm.key not found, use default license!Read ini warning, default dm.ctl backup path [/dm7/data/rac/ctl_bak] does not exist.Read ini error, name:SYSTEM_PATH, value:/dm7/data/racdmserver startup failed, code = -803 [Invalid ini config value]

将节点一/dm7/data/目录中生成的rac目录复制到节点二的/dm7/data目录

[dmdba@dm1 data]$ scp -r rac 10.18.13.166:`pwd`dmdba@10.18.13.166's password:dm_20200507164149_942994.ctl                                                                                                                                                                              100% 6144     6.0KB/s   00:00TEMP0.DBF                                                                                                                                                                                                 100%   10MB  10.0MB/s   00:00dm_service.prikey                                                                                                                                                                                         100%  633     0.6KB/s   00:00

十二、启动数据库服务器
1、在2个节点分别注册DM 数据库服务:
节点一:

[root@dm1 ~]# /dm7/script/root/dm_service_installer.sh -t dmserver -i /dm7/data/rac0_config/dm.ini -d /dm7/data/dmdcr.ini -p rac1Move the service script file(/dm7/bin/DmServicerac1 to /etc/rc.d/init.d/DmServicerac1)Finished to create the service (DmServicerac1)

节点二:

[root@dm2 ~]# /dm7/script/root/dm_service_installer.sh -t dmserver -i /dm7/data/rac1_config/dm.ini -d /dm7/data/dmdcr.ini -p rac2Move the service script file(/dm7/bin/DmServicerac2 to /etc/rc.d/init.d/DmServicerac2)Finished to create the service (DmServicerac2)

2、启动数据库

[root@dm1 ~]# service DmServicerac1 startStarting DmServicerac1: [ OK ][root@dm2 ~]# service DmServicerac2 startStarting DmServicerac2: [ OK ]

手工启动命令如下,手工启动后窗口不能关闭,所以

./dmserver /dm7/data/rac0_config/dm.ini dcr_ini=/dm7/data/dmdcr.ini./dmserver /dm7/data/rac1_config/dm.ini dcr_ini=/dm7/data/dmdcr.ini

十三、操作系统配置连接数据库验证
13.1配置服务名文件

[dmdba@dm1 data]$ vi /etc/dm_svc.confrac=(10.18.13.165:5236,10.18.13.166:5236)SWITCH_TIME=(10000)SWITCH_INTERVAL=(10)TIME_ZONE=(480)LANGUAGE=(en)[dmdba@dm2 rac]$ vi /etc/dm_svc.confTIME_ZONE=(480)rac=(10.18.13.165:5236,10.18.13.166:5236)SWITCH_TIME=(10000)SWITCH_INTERVAL=(10)TIME_ZONE=(480)LANGUAGE=(en)

13.2 连接RAC集群
节点一:

[dmdba@dm1 data]$ disql SYSDBA/SYSDBA@racServer[10.18.13.166:5236]:mode is normal, state is openlogin used time: 9.596(ms)disql V7.1.6.46-Build(2018.02.08-89107)ENTConnected to: DM 7.1.6.46SQL> select instance_name from v$instance;LINEID     INSTANCE_NAME---------- -------------1          RAC1used time: 5.020(ms). Execute id is 2.SQL> select * from v$rac_ep_info;LINEID     EP_NAME EP_SEQNO    EP_GUID              EP_TIMESTAMP         EP_MODE EP_STATUS---------- ------- ----------- -------------------- -------------------- ------- ---------1          RAC0    0           2982624975           2982625916           MASTER  OK2          RAC1    1           2983098335           2983098713           SLAVE   OKused time: 7.731(ms). Execute id is 3.

节点二:

SQL> select instance_name from v$instance;LINEID     INSTANCE_NAME---------- -------------1          RAC1used time: 117.515(ms). Execute id is 1.SQL> select * from v$rac_ep_info;LINEID     EP_NAME EP_SEQNO    EP_GUID              EP_TIMESTAMP         EP_MODE EP_STATUS---------- ------- ----------- -------------------- -------------------- ------- ---------1          RAC0    0           2982624975           2982632228           MASTER  OK2          RAC1    1           2983098335           2983105025           SLAVE   OKused time: 4.439(ms). Execute id is 4.

13.3测试故障重连

[dmdba@dm2 rac]$ disql SYSDBA/SYSDBA@racServer[10.18.13.166:5236]:mode is normal, state is openlogin used time: 6.728(ms)disql V7.1.6.46-Build(2018.02.08-89107)ENTConnected to: DM 7.1.6.46SQL> select instance_name from v$instance;LINEID     INSTANCE_NAME---------- -------------1          RAC1used time: 117.515(ms). Execute id is 1.SQL> select * from v$rac_ep_info;LINEID     EP_NAME EP_SEQNO    EP_GUID              EP_TIMESTAMP         EP_MODE EP_STATUS---------- ------- ----------- -------------------- -------------------- ------- ---------1          RAC0    0           2982624975           2982632228           MASTER  OK2          RAC1    1           2983098335           2983105025           SLAVE   OKused time: 4.439(ms). Execute id is 4.

#此时连接的rac1,我们kill 进程:

[root@dm2 ~]# ps -ef | grep dm.inidmdba     6231     1  0 17:25 pts/2    00:00:44 /dm7/bin/dmserver /dm7/data/rac1_config/dm.ini DCR_INI=/dm7/data/dmdcr.ini -noconsoleroot     10844  5237  0 19:20 pts/2    00:00:00 grep dm.ini[root@dm2 ~]# kill -9 6231

#在查询,故障重连成功:

SQL> select instance_name from v$instance;[-70065]:Connection exception, switch the current connection sucessful.[-70065]:Connection exception, switch the current connection sucessful.Server[10.18.13.165:5236]:mode is normal, state is openSQL> select instance_name from v$instance;LINEID     INSTANCE_NAME---------- -------------1          RAC0used time: 9.443(ms). Execute id is 807.SQL> select * from v$rac_ep_info;LINEID     EP_NAME EP_SEQNO    EP_GUID              EP_TIMESTAMP         EP_MODE EP_STATUS---------- ------- ----------- -------------------- -------------------- ------- ---------1          RAC0    0           2982624975           2982632568           MASTER  OK2          RAC1    1           2983098335           2983105240           SLAVE   ERRORused time: 3.184(ms). Execute id is 808.

可以看到连接的实例从rac1变为了rac0

以上是"DM7如何使用裸设备搭建DMRAC"这篇文章的所有内容,感谢各位的阅读!希望分享的内容对大家有帮助,更多相关知识,欢迎关注行业资讯频道!

0