- 浏览: 978797 次
- 性别:
- 来自: 杭州
文章分类
最新评论
-
孤星119:
好熟悉的数据库字段啊, 上家公司做的项目每天都跟这些字段打招呼 ...
Oracle exp compress参数引起的空间浪费 -
itspace:
quxiaoyong 写道遇到个问题,网上一搜,全他妈这篇文章 ...
数据库连接错误ORA-28547 -
quxiaoyong:
遇到个问题,网上一搜,全他妈这篇文章。你转来转去的有意思吗?
数据库连接错误ORA-28547 -
hctech:
关于version count过高的问题,不知博主是否看过ey ...
某客户数据库性能诊断报告 -
itspace:
invalid 写道写的不错,我根据这个来安装,有点理解错误了 ...
AIX 配置vncserver
手头上有一数据库crs资源状态显示如下,可以看到节点1并没有显示vip和监听资源。
[oracle@rac1 admin]$ crs_stat -t
Name Type Target State Host
------------------------------------------------------------
ora.orcl.db application ONLINE ONLINE rac1
ora....l1.inst application ONLINE ONLINE rac1
ora....l2.inst application ONLINE ONLINE rac2
ora....SM1.asm application ONLINE ONLINE rac1
ora.rac1.gsd application ONLINE ONLINE rac1
ora.rac1.ons application ONLINE ONLINE rac1
ora....SM2.asm application ONLINE ONLINE rac2
ora....C2.lsnr application ONLINE ONLINE rac2
ora.rac2.gsd application ONLINE ONLINE rac2
ora.rac2.ons application ONLINE ONLINE rac2
ora.rac2.vip application ONLINE ONLINE rac2
在eth0的网卡上也没有绑定vip地址:
[root@rac1 ~]# ifconfig -a
eth0 Link encap:Ethernet HWaddr 00:0C:29:FD:71:8B
inet addr:192.168.72.50 Bcast:192.168.72.255 Mask:255.255.255.0
inet6 addr: fe80::20c:29ff:fefd:718b/64 Scope:Link
UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1
RX packets:498 errors:0 dropped:0 overruns:0 frame:0
TX packets:170 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:1000
RX bytes:45254 (44.1 KiB) TX bytes:22108 (21.5 KiB)
Interrupt:185 Base address:0x1480
eth1 Link encap:Ethernet HWaddr 00:0C:29:FD:71:95
inet addr:10.10.10.50 Bcast:10.255.255.255 Mask:255.0.0.0
inet6 addr: fe80::20c:29ff:fefd:7195/64 Scope:Link
UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1
RX packets:68919 errors:0 dropped:0 overruns:0 frame:0
TX packets:53252 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:1000
RX bytes:51438689 (49.0 MiB) TX bytes:29116844 (27.7 MiB)
Interrupt:193 Base address:0x1800
在操作系统上也没有监听进程存在:
[oracle@rac1 admin]$ ps -ef|grep tns
oracle 15282 14968 0 09:21 pts/3 00:00:00 grep tns
查看/etc/hosts可以知道目前vip的ip配置
192.168.72.50 rac1
192.168.72.60 rac2
192.168.72.51 rac1-vip
192.168.72.61 rac2-vip
10.10.10.50 rac1-priv
10.10.10.60 rac2-priv
那怎么样把vip资源和监听资源手动注册到ocr盘里呢?直接在通过命令crs_profile可以知道crs_profile的使用方法
[oracle@rac1 bin]$ ./crs_profile
Usage: crs_profile -create resource_name -t application
[-dir directory_path] [-a action_script] [-B binary_pathname]
[-d description] [-h hosting_members] [-r required_resources]
[-l optional_resources] [-p placement_policy]
[-o as=auto_start,ci=check_interval,ft=failure_threshold,
fi=failure_interval,ra=restart_attempts,fd=failover_delay,
st=script_timeout,ap=active_placement,
ut=uptime_threshold,rt=start_timeout,pt=stop_timeout] [-f] [-q]
crs_profile -create resource_name -I template_file [-dir directory_path] [-f] [-q]
crs_profile -delete resource_name [-dir directory_path] [-q]
crs_profile -print [resource_name [...]] [-dir directory_path] [-q]
crs_profile -template resource_name [-dir directory_path] [-O template_file]
crs_profile -template -t application [-O template_file]
crs_profile -update resource_name [-dir directory_path] [option ...] [-o option,...] [-q]
crs_profile -validate resource_name [-dir directory_path] [-q]
1、通过crs_profile创建vip资源
[oracle@rac1 bin]$ ./crs_profile -create ora.rac1.vip -t application -d "Test VIP" -a /oracle/product/crs_1/bin/usrvip -o oi=eth0,ov=192.168.72.51,on=255.255.255.0 -h abtripat -p favored
注意参数意思:
oi => physical NIC name (use ifconfig to identify it) of the Data Guard subnet. In this case it is eth4.
ov=> new VIP address for the NIC on the node
on => new VIP subnet
创建好vip资源后可以在/oracle/product/crs_1/crs/public目录下看到文件ora.rac1.vip.cap,其内容为
[oracle@rac1 public]$ more /oracle/product/crs_1/crs/public/ora.rac1.vip.cap
NAME=ora.rac1.vip
TYPE=application
ACTION_SCRIPT=/oracle/product/crs_1/bin/usrvip
ACTIVE_PLACEMENT=0
AUTO_START=restore
CHECK_INTERVAL=60
DESCRIPTION=Test VIP
FAILOVER_DELAY=0
FAILURE_INTERVAL=0
FAILURE_THRESHOLD=0
HOSTING_MEMBERS=abtripat
OPTIONAL_RESOURCES=
PLACEMENT=favored
REQUIRED_RESOURCES=
RESTART_ATTEMPTS=1
SCRIPT_TIMEOUT=60
START_TIMEOUT=0
STOP_TIMEOUT=0
UPTIME_THRESHOLD=7d
USR_ORA_ALERT_NAME=
USR_ORA_CHECK_TIMEOUT=0
USR_ORA_CONNECT_STR=/ as sysdba
USR_ORA_DEBUG=0
USR_ORA_DISCONNECT=false
USR_ORA_FLAGS=
USR_ORA_IF=eth0
USR_ORA_INST_NOT_SHUTDOWN=
USR_ORA_LANG=
USR_ORA_NETMASK=255.255.255.0
USR_ORA_OPEN_MODE=
USR_ORA_OPI=false
USR_ORA_PFILE=
USR_ORA_PRECONNECT=none
USR_ORA_SRV=
USR_ORA_START_TIMEOUT=0
USR_ORA_STOP_MODE=immediate
USR_ORA_STOP_TIMEOUT=0
USR_ORA_VIP=192.168.72.51
2、创建好内容之后通过crs_register可以注册ora.rac1.vip资源
[oracle@rac1 bin]$ crs_register ora.rac1.vip
注册完毕之后,可以看到ora.rac1.vip资源显示依然为offline状态
[oracle@rac1 bin]$ crs_stat -t
Name Type Target State Host
------------------------------------------------------------
ora.orcl.db application ONLINE ONLINE rac1
ora....l1.inst application ONLINE ONLINE rac1
ora....l2.inst application ONLINE ONLINE rac2
ora....SM1.asm application ONLINE ONLINE rac1
ora.rac1.gsd application ONLINE ONLINE rac1
ora.rac1.ons application ONLINE ONLINE rac1
ora.rac1.vip application OFFLINE OFFLINE
ora....SM2.asm application ONLINE ONLINE rac2
ora....C2.lsnr application ONLINE ONLINE rac2
ora.rac2.gsd application ONLINE ONLINE rac2
ora.rac2.ons application ONLINE ONLINE rac2
ora.rac2.vip application ONLINE ONLINE rac2
3、接下来就是对资源ora.rac1.vip进行赋权操作,需要注意的是赋权操作需要在root用户下执行
oracle@rac1 bin]$ su
Password:
[root@rac1 bin]# crs_setperm ora.rac1.vip -o root
[root@rac1 bin]# crs_setperm ora.rac1.vip -u user:oracle:r-x
4、最后通过oracle用户启动ora.rac1.vip资源
[root@rac1 bin]# su - oracle
[oracle@rac1 ~]$ crs_start ora.rac1.vip
Attempting to start `ora.rac1.vip` on member `rac1`
Start of `ora.rac1.vip` on member `rac1` succeeded.
在操作系统上也可以看到vip已经绑定到eth0上。
[root@rac1 ~]# ifconfig -a
eth0 Link encap:Ethernet HWaddr 00:0C:29:FD:71:8B
inet addr:192.168.72.50 Bcast:192.168.72.255 Mask:255.255.255.0
inet6 addr: fe80::20c:29ff:fefd:718b/64 Scope:Link
UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1
RX packets:567 errors:0 dropped:0 overruns:0 frame:0
TX packets:220 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:1000
RX bytes:52754 (51.5 KiB) TX bytes:28436 (27.7 KiB)
Interrupt:185 Base address:0x1480
eth0:1 Link encap:Ethernet HWaddr 00:0C:29:FD:71:8B
inet addr:192.168.72.51 Bcast:192.168.72.255 Mask:255.255.255.0
UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1
Interrupt:185 Base address:0x1480
[oracle@rac1 admin]$ crs_stat -t
Name Type Target State Host
------------------------------------------------------------
ora.orcl.db application ONLINE ONLINE rac1
ora....l1.inst application ONLINE ONLINE rac1
ora....l2.inst application ONLINE ONLINE rac2
ora....SM1.asm application ONLINE ONLINE rac1
ora.rac1.gsd application ONLINE ONLINE rac1
ora.rac1.ons application ONLINE ONLINE rac1
ora....SM2.asm application ONLINE ONLINE rac2
ora....C2.lsnr application ONLINE ONLINE rac2
ora.rac2.gsd application ONLINE ONLINE rac2
ora.rac2.ons application ONLINE ONLINE rac2
ora.rac2.vip application ONLINE ONLINE rac2
在eth0的网卡上也没有绑定vip地址:
[root@rac1 ~]# ifconfig -a
eth0 Link encap:Ethernet HWaddr 00:0C:29:FD:71:8B
inet addr:192.168.72.50 Bcast:192.168.72.255 Mask:255.255.255.0
inet6 addr: fe80::20c:29ff:fefd:718b/64 Scope:Link
UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1
RX packets:498 errors:0 dropped:0 overruns:0 frame:0
TX packets:170 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:1000
RX bytes:45254 (44.1 KiB) TX bytes:22108 (21.5 KiB)
Interrupt:185 Base address:0x1480
eth1 Link encap:Ethernet HWaddr 00:0C:29:FD:71:95
inet addr:10.10.10.50 Bcast:10.255.255.255 Mask:255.0.0.0
inet6 addr: fe80::20c:29ff:fefd:7195/64 Scope:Link
UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1
RX packets:68919 errors:0 dropped:0 overruns:0 frame:0
TX packets:53252 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:1000
RX bytes:51438689 (49.0 MiB) TX bytes:29116844 (27.7 MiB)
Interrupt:193 Base address:0x1800
在操作系统上也没有监听进程存在:
[oracle@rac1 admin]$ ps -ef|grep tns
oracle 15282 14968 0 09:21 pts/3 00:00:00 grep tns
查看/etc/hosts可以知道目前vip的ip配置
192.168.72.50 rac1
192.168.72.60 rac2
192.168.72.51 rac1-vip
192.168.72.61 rac2-vip
10.10.10.50 rac1-priv
10.10.10.60 rac2-priv
那怎么样把vip资源和监听资源手动注册到ocr盘里呢?直接在通过命令crs_profile可以知道crs_profile的使用方法
[oracle@rac1 bin]$ ./crs_profile
Usage: crs_profile -create resource_name -t application
[-dir directory_path] [-a action_script] [-B binary_pathname]
[-d description] [-h hosting_members] [-r required_resources]
[-l optional_resources] [-p placement_policy]
[-o as=auto_start,ci=check_interval,ft=failure_threshold,
fi=failure_interval,ra=restart_attempts,fd=failover_delay,
st=script_timeout,ap=active_placement,
ut=uptime_threshold,rt=start_timeout,pt=stop_timeout] [-f] [-q]
crs_profile -create resource_name -I template_file [-dir directory_path] [-f] [-q]
crs_profile -delete resource_name [-dir directory_path] [-q]
crs_profile -print [resource_name [...]] [-dir directory_path] [-q]
crs_profile -template resource_name [-dir directory_path] [-O template_file]
crs_profile -template -t application [-O template_file]
crs_profile -update resource_name [-dir directory_path] [option ...] [-o option,...] [-q]
crs_profile -validate resource_name [-dir directory_path] [-q]
1、通过crs_profile创建vip资源
[oracle@rac1 bin]$ ./crs_profile -create ora.rac1.vip -t application -d "Test VIP" -a /oracle/product/crs_1/bin/usrvip -o oi=eth0,ov=192.168.72.51,on=255.255.255.0 -h abtripat -p favored
注意参数意思:
oi => physical NIC name (use ifconfig to identify it) of the Data Guard subnet. In this case it is eth4.
ov=> new VIP address for the NIC on the node
on => new VIP subnet
创建好vip资源后可以在/oracle/product/crs_1/crs/public目录下看到文件ora.rac1.vip.cap,其内容为
[oracle@rac1 public]$ more /oracle/product/crs_1/crs/public/ora.rac1.vip.cap
NAME=ora.rac1.vip
TYPE=application
ACTION_SCRIPT=/oracle/product/crs_1/bin/usrvip
ACTIVE_PLACEMENT=0
AUTO_START=restore
CHECK_INTERVAL=60
DESCRIPTION=Test VIP
FAILOVER_DELAY=0
FAILURE_INTERVAL=0
FAILURE_THRESHOLD=0
HOSTING_MEMBERS=abtripat
OPTIONAL_RESOURCES=
PLACEMENT=favored
REQUIRED_RESOURCES=
RESTART_ATTEMPTS=1
SCRIPT_TIMEOUT=60
START_TIMEOUT=0
STOP_TIMEOUT=0
UPTIME_THRESHOLD=7d
USR_ORA_ALERT_NAME=
USR_ORA_CHECK_TIMEOUT=0
USR_ORA_CONNECT_STR=/ as sysdba
USR_ORA_DEBUG=0
USR_ORA_DISCONNECT=false
USR_ORA_FLAGS=
USR_ORA_IF=eth0
USR_ORA_INST_NOT_SHUTDOWN=
USR_ORA_LANG=
USR_ORA_NETMASK=255.255.255.0
USR_ORA_OPEN_MODE=
USR_ORA_OPI=false
USR_ORA_PFILE=
USR_ORA_PRECONNECT=none
USR_ORA_SRV=
USR_ORA_START_TIMEOUT=0
USR_ORA_STOP_MODE=immediate
USR_ORA_STOP_TIMEOUT=0
USR_ORA_VIP=192.168.72.51
2、创建好内容之后通过crs_register可以注册ora.rac1.vip资源
[oracle@rac1 bin]$ crs_register ora.rac1.vip
注册完毕之后,可以看到ora.rac1.vip资源显示依然为offline状态
[oracle@rac1 bin]$ crs_stat -t
Name Type Target State Host
------------------------------------------------------------
ora.orcl.db application ONLINE ONLINE rac1
ora....l1.inst application ONLINE ONLINE rac1
ora....l2.inst application ONLINE ONLINE rac2
ora....SM1.asm application ONLINE ONLINE rac1
ora.rac1.gsd application ONLINE ONLINE rac1
ora.rac1.ons application ONLINE ONLINE rac1
ora.rac1.vip application OFFLINE OFFLINE
ora....SM2.asm application ONLINE ONLINE rac2
ora....C2.lsnr application ONLINE ONLINE rac2
ora.rac2.gsd application ONLINE ONLINE rac2
ora.rac2.ons application ONLINE ONLINE rac2
ora.rac2.vip application ONLINE ONLINE rac2
3、接下来就是对资源ora.rac1.vip进行赋权操作,需要注意的是赋权操作需要在root用户下执行
oracle@rac1 bin]$ su
Password:
[root@rac1 bin]# crs_setperm ora.rac1.vip -o root
[root@rac1 bin]# crs_setperm ora.rac1.vip -u user:oracle:r-x
4、最后通过oracle用户启动ora.rac1.vip资源
[root@rac1 bin]# su - oracle
[oracle@rac1 ~]$ crs_start ora.rac1.vip
Attempting to start `ora.rac1.vip` on member `rac1`
Start of `ora.rac1.vip` on member `rac1` succeeded.
在操作系统上也可以看到vip已经绑定到eth0上。
[root@rac1 ~]# ifconfig -a
eth0 Link encap:Ethernet HWaddr 00:0C:29:FD:71:8B
inet addr:192.168.72.50 Bcast:192.168.72.255 Mask:255.255.255.0
inet6 addr: fe80::20c:29ff:fefd:718b/64 Scope:Link
UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1
RX packets:567 errors:0 dropped:0 overruns:0 frame:0
TX packets:220 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:1000
RX bytes:52754 (51.5 KiB) TX bytes:28436 (27.7 KiB)
Interrupt:185 Base address:0x1480
eth0:1 Link encap:Ethernet HWaddr 00:0C:29:FD:71:8B
inet addr:192.168.72.51 Bcast:192.168.72.255 Mask:255.255.255.0
UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1
Interrupt:185 Base address:0x1480
发表评论
-
buffer cache 的内部结构
2020-03-18 14:21 579BUFFER CACHE作为数据块的 ... -
Oracle OMC介绍
2020-03-18 13:19 487Oracle管理云服务(OMC)的大数据平台,自动收集的企业 ... -
参加Oracle勒索病毒防范专题培训会议
2019-09-27 17:15 5132019年7月22日,受邀参加Oracle勒索病毒防范专题培训 ... -
记一次内存换IO的Oracle优化
2019-09-27 16:50 827某客户数据库从P595物理 ... -
如何定位Oracle SQL执行计划变化的原因
2019-07-03 14:49 1460性能优化最难的是能够 ... -
如何定位Oracle SQL执行计划变化的原因
2018-10-30 09:24 1185性能优化最难的是能够 ... -
数据库性能优化目标
2018-10-08 10:59 518从数据库性能优化的场 ... -
数据库无法打开的原因及解决办法
2018-10-05 20:45 2120数据库的启动是一个相当复杂的过程。比如,Oracle在启动之前 ... -
怎么样彻底删除数据库?
2018-09-18 11:10 599Oracle提供了drop database命令用来删除数据库 ... -
Oracle减少日志量的方法
2018-09-10 10:17 867LGWR进程将LOG BUFFER中的 ... -
如何快速关闭数据库
2018-09-09 13:14 1233“一朝被蛇咬,十年怕井绳”。在没被“蛇”咬之前,很多DBA喜欢 ... -
关于《如何落地智能化运维》PPT
2018-05-17 10:19 1129在DTCC 2018发表《如何落地智能化运维》演讲,主要内容如 ... -
记录在redhat5.8平台安装oracle11.2容易忽视的几个问题
2018-05-11 19:58 578问题一:ping不通问题 在虚拟机上安装好linux系统后, ... -
《Oracle DBA实战攻略》第一章
2018-05-11 10:42 947即日起,不定期更新《OracleDBA实战攻略》一书电子版,请 ... -
Oracle 12c新特性
2018-05-11 10:33 900查询所有pdb [oracle@gj4 ~]$ sqlplu ... -
关于修改memory_target的值后数据库无法启动的问题
2017-02-28 12:24 3983操作系统:RHEL6.5 数据库版本:11.2.0.4 ... -
10g rac安装error while loading shared libraries libpthread.so.0 问题
2017-02-28 12:22 69511g rac安装在二节点跑脚本一般会报此错误: 解决这个问 ... -
记一次Oracle会话共享模式故障处理过程
2017-02-27 19:16 799故障简述 XXX第八人民医院HIS数据库7月13日11点左右从 ... -
RESMGR:cpu quantum等待事件处理过程
2017-02-27 18:23 2615由于数据库上线过程中出现大量的RESMGR:cpu quant ... -
谈谈log file sync
2014-03-19 14:18 1759数据库中的log file sync等待事件指的是,当user ...
相关推荐
Oracle RAC 故障节点删除步骤 Oracle RAC(Real Application Clusters)是一种高可用性数据库解决方案,旨在提供高可用性和可扩展性。然而,在实际操作中,RAC 节点可能会出现故障,导致整个集群的不稳定。因此,...
### ORACLE RAC重建CRS知识点详解 #### 一、背景与概述 Oracle Real Application Clusters (RAC) 是一种数据库集群技术,旨在提供高可用性和可扩展性。CRS (Cluster Ready Services) 是Oracle RAC的核心组件之一,...
### 知识点一:Oracle 19c RAC安装前的准备 在安装Oracle 19c RAC(Real Application Clusters)之前,系统环境的检查是至关重要的一步,这将确保安装顺利进行。OS环境检查包括检查操作系统的版本、可用内存大小,...
Oracle 数据库 Real Application Clusters (RAC) 是一种高可用性解决方案,它允许多个实例同时访问同一物理数据库,从而提供故障切换和负载均衡的能力。以下是对"11204 Oracle 数据库 RAC 安装_图文.docx"文档内容的...
- **EtherChannel技术**: 为了满足Oracle RAC中VIP的需求,需要将连接外网的两个网口使用EtherChannel技术虚拟成一个虚拟网口,VIP的地址需要和这个虚拟网口配置在同一网段。 - **交换机**: Oracle建议心跳使用单独...
在上述示例中,`crs_stop -all`命令尝试停止所有资源,包括`ora.rac01.gsd`(Global Shared Data)、`ora.rac01.ons`(Oracle Name Server)、`ora.rac01.vip`(Virtual IP)等。接着,使用`crs_unregister`命令逐个...
#### 手工配置rac1-vip和rac2-vip 手动配置虚拟IP地址,用于外部客户端访问RAC集群,增强应用的透明性和高可用性。 #### 安装database软件与配置监听 安装数据库软件并配置监听器,使数据库能够响应来自客户端的...
- **2.2 手工启动与关闭RAC**:通常不建议直接使用`crsctl`命令手工启动或关闭RAC,因为这样的操作可能会忽略资源间依赖关系的校验。 - **2.3 OCR的管理**:OCR(Oracle Cluster Registry)是集群关键信息的存储库...
手工启动与关闭RAC** - 启动RAC可以通过命令`init.crs start`来进行。 **3. OCR (Oracle Cluster Registry) 的管理** - OCR 是用于存储集群配置信息的关键文件。维护OCR的健康对于RAC集群的稳定至关重要。 - 例如...
- **手工启动与关闭RAC**:提供操作步骤来手动启动或关闭RAC集群,这对于故障排除非常有用。 - **OCR的管理** - **磁盘状态查看**:检查OCR磁盘的状态,以确保其可用性。 - **备份与恢复**:提供OCR的备份与恢复...