当前位置:网站首页>Migrate Oracle database from windows system to Linux Oracle RAC cluster environment (4) -- modify the scanip of Oracle11g RAC cluster
Migrate Oracle database from windows system to Linux Oracle RAC cluster environment (4) -- modify the scanip of Oracle11g RAC cluster
2022-06-25 02:24:00 【Rsda DBA_ WGX】
hold Oracle Database from Windows System migration to Linux Oracle Rac Cluster environment (4)—— modify oracle11g rac Clustered scanIP
Catalog
- hold Oracle Database from Windows System migration to Linux Oracle Rac Cluster environment (4)—— modify oracle11g rac Clustered scanIP
- One 、 see scan ip Status information
- Two 、 stop it scan_listener and scan
- 3、 ... and 、 modify /etc/hosts In the document scanIP( All nodes )
- Four 、 modify DNS Service configuration information
- 5、 ... and 、 modify SCAN name
- 6、 ... and 、 start-up scan and scan_listener
- 7、 ... and 、 test : Use the new scanIP Access database
- 8、 ... and 、 solve ORA-12514 error
When migrating data in a production environment , You need to create the target database cluster first , After the data migration is successful, the original IP Address access oracle database , In this way, the original client does not need to make any changes . here , You need to change the target database cluster scanIP For the source database IP Address .
When the client application uses scanIP When accessing the database ,scan listener Will forward the connection to local listener On . node rac1 The local monitoring content of is as follows :
LISTENER_RAC1=(DESCRIPTION=(ADDRESS_LIST=(ADDRESS=(PROTOCOL=TCP)(HOST=rac1-vip)(PORT=1521))(ADDRESS=(PROTOCOL=TCP)(HOST=192.168.1.101)(PORT=1521)
(IP=FIRST)))) # line added by Agent
One 、 see scan ip Status information
[[email protected] ~]$ srvctl config scan
SCAN name: rac-scan, Network: 1/192.168.1.0/255.255.255.0/ens34
SCAN VIP name: scan1, IP: /rac-scan/192.168.1.201
Two 、 stop it scan_listener and scan
# stop it scan_listener and scan
srvctl stop scan_listener
srvctl stop scan
# ---------------------------------------------------------------------
[[email protected] ~]$ srvctl stop scan_listener
[[email protected] ~]$ srvctl stop scan
# see scan_listener and scan The state of
[[email protected] ~]$ srvctl status scan_listener
SCAN Listener LISTENER_SCAN1 is enabled
SCAN listener LISTENER_SCAN1 is not running
[[email protected] ~]$ srvctl status scan
SCAN VIP scan1 is enabled
SCAN VIP scan1 is not running
[[email protected] ~]$ crs_stat -t | grep scan
ora.scan1.vip ora....ip.type OFFLINE OFFLINE
[[email protected] ~]$ crs_stat -t | grep lsnr
ora....ER.lsnr ora....er.type ONLINE ONLINE rac1
ora....N1.lsnr ora....er.type OFFLINE OFFLINE
ora....C1.lsnr application ONLINE ONLINE rac1
ora....C2.lsnr application ONLINE ONLINE rac2
3、 ... and 、 modify /etc/hosts In the document scanIP( All nodes )
# Switch to root user , node 1 and node 2 At the same time to modify scan IP
[[email protected] ~]# vi /etc/hosts
127.0.0.1 localhost localhost.localdomain localhost4 localhost4.localdomain4
::1 localhost localhost.localdomain localhost6 localhost6.localdomain6
#Public Network (bond1)—— public IP
192.168.1.101 rac1
192.168.1.102 rac2
#Private Interconnect (bond2)—— private IP
10.1.1.101 rac1-priv
10.1.1.102 rac2-priv
#Virtual IP—— fictitious IP, And bond1 Must be in the same network segment
192.168.1.111 rac1-vip
192.168.1.112 rac2-vip
#scan IP
192.168.1.221 my-racscan # Turned out to be :192.168.1.201
Four 、 modify DNS Service configuration information
[[email protected] ~]# vi /var/named/chroot/var/named/1.168.192.local
$TTL 86400
@ IN SOA dns.oracle.com. root.oracle.com. (
19997022700 ; serial
28800 ; refresh
14400 ; retry
3600000 ; expire
86400 ) ; minimum
@ IN NS dns.oracle.com.
101 IN PTR dns.oracle.com.
101 IN PTR rac1.oracle.com.
102 IN PTR rac2.oracle.com.
221 IN PTR scan.oracle.com. # Turned out to be :201
[[email protected] ~]# vi /var/named/chroot/var/named/oracle.com.zone
$TTL 86400
@ IN SOA dns.oracle.com. root.oracle.com. (
42 ; serial
3H ; refresh
15M ; retry
1W ; expire
1D ) ; minimum
@ IN NS dns.oracle.com.
dns IN A 192.168.1.101
rac1 IN A 192.168.1.101
rac2 IN A 192.168.1.102
scan IN A 192.168.1.221 # Turned out to be :192.168.1.201
# restart named service
[[email protected] ~]# systemctl restart named
# test
[[email protected] ~]# nslookup 192.168.1.221
Server: 192.168.1.101
Address: 192.168.1.101#53
221.1.168.192.in-addr.arpa name = scan.oracle.com.
[[email protected] ~]# nslookup scan.oracle.com
Server: 192.168.1.101
Address: 192.168.1.101#53
Name: scan.oracle.com
Address: 192.168.1.221
5、 ... and 、 modify SCAN name
# Switch to root user
[[email protected] ~]# cd /u01/app/11.2.0/grid/bin
[[email protected] bin]# pwd
/u01/app/11.2.0/grid/bin
[[email protected] bin]# ./srvctl modify scan -n my-racscan
# see scan ip Status information
[[email protected] bin]# ./srvctl config scan
SCAN name : my-racscan, The Internet : 1/192.168.1.0/255.255.255.0/ens34
SCAN VIP name : scan1, IP: /my-racscan/192.168.1.221
6、 ... and 、 start-up scan and scan_listener
# start-up scan and scan_listener
[[email protected] admin]$ srvctl start scan
[[email protected] admin]$ srvctl start scan_listener
# see scan and scan_listener The state of :
[[email protected] admin]$ srvctl status scan_listener
SCAN Listener LISTENER_SCAN1 is enabled
SCAN listener LISTENER_SCAN1 is running on node rac1
[[email protected] admin]$ srvctl status scan
SCAN VIP scan1 is enabled
SCAN VIP scan1 is running on node rac1
[[email protected] admin]$ crs_stat -t | grep scan
ora.scan1.vip ora....ip.type ONLINE ONLINE rac1
[[email protected] admin]$ crs_stat -t | grep lsnr
ora....ER.lsnr ora....er.type ONLINE ONLINE rac1
ora....N1.lsnr ora....er.type ONLINE ONLINE rac1
ora....C1.lsnr application ONLINE ONLINE rac1
ora....C2.lsnr application ONLINE ONLINE rac2
7、 ... and 、 test : Use the new scanIP Access database
1、 Test new scanIP Whether you can use
[[email protected] ~]$ ping 192.168.1.221
PING 192.168.1.221 (192.168.1.221) 56(84) bytes of data.
64 bytes from 192.168.1.221: icmp_seq=1 ttl=64 time=2.84 ms
64 bytes from 192.168.1.221: icmp_seq=2 ttl=64 time=0.267 ms
64 bytes from 192.168.1.221: icmp_seq=3 ttl=64 time=14.3 ms
^C
--- 192.168.1.221 ping statistics ---
3 packets transmitted, 3 received, 0% packet loss, time 2003ms
rtt min/avg/max/mdev = 0.267/5.827/14.374/6.134 ms
2、 Use the new scanIP Access database
[oracle@rac1 ~]$ sqlplus sys/oracle@192.168.1.221/hisdb as sysdba
SQL*Plus: Release 11.2.0.4.0 Production on Sun Jun 19 10:24:11 2022
Copyright (c) 1982, 2013, Oracle. All rights reserved.
ERROR:
ORA-12514: TNS:listener does not currently know of service requested in connect
descriptor
-- There is an error , Error code :ORA-12514
8、 ... and 、 solve ORA-12514 error
1、 At the node rac1 Do the following
-- View parameters :remote_listener
SQL> show parameter remote_listener
NAME TYPE VALUE
------------------------------------ ----------- ------------------------------
remote_listener string
-- Modify the parameters remote_listener The value of is empty
SQL> alter system set remote_listener='';
System altered.
-- register
SQL> alter system register;
System altered.
-- Modify the parameters remote_listener Value
SQL> alter system set remote_listener='my-racscan:1521';
System altered.
-- View parameters :remote_listener
SQL> show parameter remote_listener
NAME TYPE VALUE
------------------------------------ ----------- ------------------------------
remote_listener string my-racscan:1521
2、 test : Use the new scanIP Access database
[[email protected] ~]$ sqlplus sys/[email protected]/hisdb as sysdba
SQL*Plus: Release 11.2.0.4.0 Production on Wed Jun 22 13:57:47 2022
Copyright (c) 1982, 2013, Oracle. All rights reserved.
Connected to:
Oracle Database 11g Enterprise Edition Release 11.2.0.4.0 - 64bit Production
With the Partitioning, Real Application Clusters, Automatic Storage Management, OLAP,
Data Mining and Real Application Testing options
SQL>
边栏推荐
- Beescms website penetration test and repair comments "suggestions collection"
- 【移动端】手机界面的设计尺寸
- mysql命令备份
- Experience of epidemic prevention and control, home office and online teaching | community essay solicitation
- EasyCVR平台EHOME协议接入,视频播放出现断流是什么原因?
- 业务与技术双向结合构建银行数据安全管理体系
- 内网学习笔记(7)
- LINQ 查询(3)
- Computing service network: a systematic revolution of multi integration
- 2022年云计算应用关键威胁调查
猜你喜欢

The ecosystem of the yuan universe

常用的软件测试工具清单,请查收。

ProcessOn制作ER过程(自定义)

【直播回顾】战码先锋第七期:三方应用开发者如何为开源做贡献

3年测试经验,连简历上真正需要什么都没搞明白,张口就要20k?

Experience of epidemic prevention and control, home office and online teaching | community essay solicitation

It's 2022, and you still don't know what performance testing is?

文件系统 -- 磁盘基础知识和FAT32文件系统详细介绍

yarn : 无法加载文件 C:\Users\xxx\AppData\Roaming\npm\yarn.ps1,因为在此系统上禁止运行脚本
![[live review] battle code pioneer phase 7: how third-party application developers contribute to open source](/img/ad/26a302ca724177e37fe123f8b75e4e.png)
[live review] battle code pioneer phase 7: how third-party application developers contribute to open source
随机推荐
Intranet learning notes (6)
It's 2022, and you still don't know what performance testing is?
When they are in private, they have a sense of propriety
业务与技术双向结合构建银行数据安全管理体系
罗德与施瓦茨与中关村泛联院合作开展6G技术研究与早期验证
华为、阿里等大厂程序员真的好找对象吗?
Jetson Nano 从入门到实战(案例:Opencv配置、人脸检测、二维码检测)
Lizuofan, co-founder of nonconvex: Taking quantification as his lifelong career
Experience of epidemic prevention and control, home office and online teaching | community essay solicitation
Investigation on key threats of cloud computing applications in 2022
背了八股文,六月赢麻了……
Explanation of FTP protocol
June 24, 2022: golang multiple choice question, what does the following golang code output? A:1; B:3; C:4; D: Compilation failed. package main import ( “f
Redis
internship:svn的使用
入坑机器学习:一,绪论
How to get the picture outside the chain - Netease photo album [easy to understand]
Intranet learning notes (5)
F - Spices(线性基)
Cusdis - lightweight, privacy first open source comment system | chain of the city