某券商Oracle RAC数据库服务器更换(上)

2024-06-09 10:38

本文主要是介绍某券商Oracle RAC数据库服务器更换(上),希望对大家解决编程问题提供一定的参考价值,需要的开发者们随着小编来一起学习吧!

客户环境概览

2结点RAC(旧)

共享存储(旧)

2结点RAC(新)

共享存储(借用,中转数据使用,用完后需归还)

 

实施方案:

由于只更换服务器不更换共享存储,所以需要先在新服务器+新共享存储上搭建完RAC环境,导入原库中的数据,再将存储更换为老共享存储。

 

采取该方案的原因如下:

新机器操作系统最低只支持RHEL6.5,而原机器操作系统为RHEL5.5,数据库版本Oracle 10g。新机器6.5RHEL上无法安装Oracle 10g,最低只能安装Oracle11g,因此排除添加删除节点的方案。而且先将原rac升级到11g然后再增删结点的方案需要更长的回退时间,遂也未采用。

 

实施流程概览

1、为新服务器安装RHEL 6.5以及Oracle 11g GIDatabaseOCR使用借用的临时共享存储);

2、停止应用和旧数据库监听,expdp导出数据;

3impdp恢复数据到11g rac环境;

4、将应用连接到新数据库环境,进行简单连通性测试以及验证数据完整性;

5、关闭应用,卸载老存储并格式化分为300G一个的LUN,映射到新服务器上;

6、在老共享存储上创建asm磁盘组,迁移OCR以及voting disk至老存储

7、使用rmanbackup as copy)将数据库迁移到老存储;

8、启动数据库,并启动应用,进行测试;

 

 

201672109:34:00

安置新运达的服务器于办公室内,配置交换机、共享存储、以及一些前期准备工作。

 

201672112:34:41

上传安装介质

 

201672112:37:02

Fdisk 分区

for i in b c d e f g h i j k l m;
do
fdisk /dev/sd$i <<EOF
n
p
1w
EOF
done
 

udev绑定裸设备

for i in b c d e f g h i j k l m;
do
echo "KERNEL==\"sd*\", PROGRAM==\"/sbin/scsi_id --whitelisted --replace-whitespace --device=/dev/\$name\", RESULT==\"`/sbin/scsi_id --whitelisted --replace-whitespace --device=/dev/sd$i`\", NAME=\"asm-disk$i\", OWNER=\"grid\", GROUP=\"asmadmin\", MODE=\"0660\""      >> /etc/udev/rules.d/99-oracle-asmdevices.rules
done 
 

创建相关用户

/usr/sbin/groupadd -g 501 oinstall
/usr/sbin/groupadd -g 502 dba
/usr/sbin/groupadd -g 504 asmadmin
/usr/sbin/groupadd -g 506 asmdba
/usr/sbin/groupadd -g 507 asmoper/usr/sbin/useradd -u 501 -g oinstall -G asmadmin,asmdba,asmoper -d /home/grid -m grid
/usr/sbin/useradd -u 502 -g oinstall -G dba,asmdba -d /home/oracle -m oraclepasswd oracle
passwd grid
 

启动udev

start_udev

 

201672112:51:44

解压安装介质

ls *.zip | xargs -n1 unzip

 

 

等待网络配置。。。。。。。。。。。

 

 

201672114:04:21

二号结点fdisk -l 发现不到盘,重启后解决。

 

 

201672114:07:38

配置两台机器hosts文件

 

201672114:33:37

rpm -q --queryformat "%{NAME}-%{VERSION}-%{RELEASE} (%{ARCH})\n" binutils.x86_64 \
compat-libstdc++-33.x86_64 \
glibc.x86_64 \
ksh-*.x86_64 \
libaio.x86_64 \
libaio-devel.x86_64 \
libgcc.x86_64 \
libstdc++.x86_64 \
libstdc++-devel.x86_64 \
make.x86_64 \
compat-libcap1.x86_64 \
gcc.x86_64 \
gcc-c++.x86_64 \
glibc-devel.x86_64 \
sysstat.x86_64 | grep "not installed"

检查缺少的rpm包,用yum打上缺的包

./runInstaller安装grid

 

201672114:45:08

执行GI root.sh报错

[root@fxs38501 /]# /u01/app/11.2.0/grid/root.shPerforming root user operation for Oracle 11gThe following environment variables are set as:ORACLE_OWNER= gridORACLE_HOME=  /u01/app/11.2.0/gridEnter the full pathname of the local bin directory: [/usr/local/bin]:Copying dbhome to /usr/local/bin ...Copying oraenv to /usr/local/bin ...Copying coraenv to /usr/local/bin ...Creating /etc/oratab file...Entries will be added to the /etc/oratab file as needed byDatabase Configuration Assistant when a database is createdFinished running generic part of root script.Now product-specific root actions will be performed.Using configuration parameter file: /u01/app/11.2.0/grid/crs/install/crsconfig_paramsCreating trace directoryUser ignored Prerequisites during installationInstalling Trace File AnalyzerFailed to create keys in the OLR, rc = 127, Message:/u01/app/11.2.0/grid/bin/clscfg.bin: error while loading shared libraries: libcap.so.1: cannot open shared object file: No such file or directoryFailed to create keys in the OLR at /u01/app/11.2.0/grid/crs/install/crsconfig_lib.pm line 7660./u01/app/11.2.0/grid/perl/bin/perl -I/u01/app/11.2.0/grid/perl/lib -I/u01/app/11.2.0/grid/crs/install /u01/app/11.2.0/grid/crs/install/rootcrs.pl execution failed 

为两节点用yum打上缺的包

yum install -y compat-libcap1

 

然后删除crs配置

$GRID_HOME/crs/install/rootcrs.pl -verbose -deconfig -force

 

重新执行root.sh

执行成功。

至此GI安装完成。

 

201672115:04:28

搬运暂存在办公室的服务器以及共享存储至机房。

状况:

发现老RAC挂载新存储后导致磁盘盘符混乱(由最初安装rac时绑定裸盘方法不当导致),无法启动rac,遂采用挂载NFS文件系统的方式存储dump数据。

 

201672118:58:21

安装database软件(具体步骤略)

 

201672119:19:16

opatchGIDB软件打补丁:

export PATH=$PATH:$ORACLE_HOME/OPatch

执行$ORACLE_HOME/OPatch/ocm/bin/emocmrsp生成ocm.rsp文件

然后使用opatch auto /tmp/23274134 -ocmrf /tmp/ocm.rspGI打补丁

注意:如果已经建库opatch会自动为DB软件打补丁,如果未建库DB的补丁要自己手动打。

GI node1

[grid@fxs38501 OPatch]$ ./opatch lsinventory
Oracle 中间补丁程序安装程序版本 11.2.0.3.14
版权所有 (c) 2016, Oracle Corporation。保留所有权利。
Oracle Home       : /u01/app/11.2.0/grid
Central Inventory : /u01/app/oraInventory
from           : /u01/app/11.2.0/grid/oraInst.loc
OPatch version    : 11.2.0.3.14
OUI version       : 11.2.0.4.0
Log file location : /u01/app/11.2.0/grid/cfgtoollogs/opatch/opatch2016-07-21_20-03-52下午_1.log
Lsinventory Output file location : /u01/app/11.2.0/grid/cfgtoollogs/opatch/lsinv/lsinventory2016-07-21_20-03-52下午.txt
--------------------------------------------------------------------------------
Local Machine Information::
Hostname: fxs38501
ARU platform id: 226
ARU platform description:: Linux x86-64
已安装的顶级产品 (1):
Oracle Grid Infrastructure 11g                                       11.2.0.4.0
此 Oracle 主目录中已安装 1 个产品。
中间补丁程序 (3) :
Patch  22502505     : applied on Thu Jul 21 19:46:10 CST 2016
Unique Patch ID:  19880366
Patch description:  "ACFS Patch Set Update : 11.2.0.4.160419 (22502505)"
Created on 17 Feb 2016, 00:12:23 hrs PST8PDT
Bugs fixed:
21369858, 16318126, 19690653, 17503605, 17203009, 17359415, 20140148
17611362, 17164243, 19053182, 17696547, 17488768, 18168684, 21519796
18143006, 21208140, 17428148, 17070158, 20438706, 17510275, 17172303
18610307, 17376318, 17721778, 22198405, 17699423, 18915417, 18155334
18321597, 19919907, 18185024, 17636008, 17363999, 20681968, 17475946
Patch  23054319     : applied on Thu Jul 21 19:45:43 CST 2016
Unique Patch ID:  20209287
Patch description:  "OCW Patch Set Update : 11.2.0.4.160719 (23054319)"
Created on 15 Jul 2016, 14:38:17 hrs PST8PDT
Bugs fixed:
18328800, 19270660, 18691572, 18508710, 20038451, 21251192, 22162062
20365005, 21232394, 17387214, 17750548, 17617807, 14497275, 20219458
(此处略去若干bug号。)
21442094, 20235486, 19359787, 15869775, 17447588, 19642566, 21152052
16798862, 15920201
Patch  23054359     : applied on Thu Jul 21 19:44:57 CST 2016
Unique Patch ID:  20226193
Patch description:  "Database Patch Set Update : 11.2.0.4.160719 (23054359)"
Created on 15 Jun 2016, 16:08:35 hrs PST8PDT
Sub-patch  22502456; "Database Patch Set Update : 11.2.0.4.160419 (22502456)"
Sub-patch  21948347; "Database Patch Set Update : 11.2.0.4.160119 (21948347)"
Sub-patch  21352635; "Database Patch Set Update : 11.2.0.4.8 (21352635)"
Sub-patch  20760982; "Database Patch Set Update : 11.2.0.4.7 (20760982)"
Sub-patch  20299013; "Database Patch Set Update : 11.2.0.4.6 (20299013)"
Sub-patch  19769489; "Database Patch Set Update : 11.2.0.4.5 (19769489)"
Sub-patch  19121551; "Database Patch Set Update : 11.2.0.4.4 (19121551)"
Sub-patch  18522509; "Database Patch Set Update : 11.2.0.4.3 (18522509)"
Sub-patch  18031668; "Database Patch Set Update : 11.2.0.4.2 (18031668)"
Sub-patch  17478514; "Database Patch Set Update : 11.2.0.4.1 (17478514)"
Bugs fixed:
17184721, 21538558, 16091637, 18092127, 17381384, 15979965, 18441944
13837378, 16314254, 16731148, 17835048, 13558557, 17201159, 17853498
(此处略去若干bug号。)
19680952, 18704244, 18828868, 18273830, 17050888, 17360606, 16992075
17375354, 12905058, 18362222, 17571039, 17468141, 18436647, 17235750
21168487, 16220077, 16929165
包含多个节点的 RAC 系统
Local node = fxs38501
Remote node = fxs38502
--------------------------------------------------------------------------------
OPatch succeeded.

GI node2

[grid@fxs38502 OPatch]$ ./opatch lsinventory
Oracle 中间补丁程序安装程序版本 11.2.0.3.14
版权所有 (c) 2016, Oracle Corporation。保留所有权利。
Oracle Home       : /u01/app/11.2.0/grid
Central Inventory : /u01/app/oraInventory
from           : /u01/app/11.2.0/grid/oraInst.loc
OPatch version    : 11.2.0.3.14
OUI version       : 11.2.0.4.0
Log file location : /u01/app/11.2.0/grid/cfgtoollogs/opatch/opatch2016-07-21_20-06-28下午_1.log
Lsinventory Output file location : /u01/app/11.2.0/grid/cfgtoollogs/opatch/lsinv/lsinventory2016-07-21_20-06-28下午.txt
--------------------------------------------------------------------------------
Local Machine Information::
Hostname: fxs38502
ARU platform id: 226
ARU platform description:: Linux x86-64
已安装的顶级产品 (1):
Oracle Grid Infrastructure 11g                                       11.2.0.4.0
此 Oracle 主目录中已安装 1 个产品。
中间补丁程序 (3) :
Patch  22502505     : applied on Thu Jul 21 20:02:06 CST 2016
Unique Patch ID:  19880366
Patch description:  "ACFS Patch Set Update : 11.2.0.4.160419 (22502505)"
Created on 17 Feb 2016, 00:12:23 hrs PST8PDT
Bugs fixed:
21369858, 16318126, 19690653, 17503605, 17203009, 17359415, 20140148
17611362, 17164243, 19053182, 17696547, 17488768, 18168684, 21519796
18143006, 21208140, 17428148, 17070158, 20438706, 17510275, 17172303
18610307, 17376318, 17721778, 22198405, 17699423, 18915417, 18155334
18321597, 19919907, 18185024, 17636008, 17363999, 20681968, 17475946
Patch  23054319     : applied on Thu Jul 21 20:01:40 CST 2016
Unique Patch ID:  20209287
Patch description:  "OCW Patch Set Update : 11.2.0.4.160719 (23054319)"
Created on 15 Jul 2016, 14:38:17 hrs PST8PDT
Bugs fixed:
18328800, 19270660, 18691572, 18508710, 20038451, 21251192, 22162062
20365005, 21232394, 17387214, 17750548, 17617807, 14497275, 20219458
(此处略去若干bug号。)
19319357, 20094984, 17046460, 17059927, 18053631, 16867761, 18774591
21442094, 20235486, 19359787, 15869775, 17447588, 19642566, 21152052
16798862, 15920201
Patch  23054359     : applied on Thu Jul 21 20:00:50 CST 2016
Unique Patch ID:  20226193
Patch description:  "Database Patch Set Update : 11.2.0.4.160719 (23054359)"
Created on 15 Jun 2016, 16:08:35 hrs PST8PDT
Sub-patch  22502456; "Database Patch Set Update : 11.2.0.4.160419 (22502456)"
Sub-patch  21948347; "Database Patch Set Update : 11.2.0.4.160119 (21948347)"
Sub-patch  21352635; "Database Patch Set Update : 11.2.0.4.8 (21352635)"
Sub-patch  20760982; "Database Patch Set Update : 11.2.0.4.7 (20760982)"
Sub-patch  20299013; "Database Patch Set Update : 11.2.0.4.6 (20299013)"
Sub-patch  19769489; "Database Patch Set Update : 11.2.0.4.5 (19769489)"
Sub-patch  19121551; "Database Patch Set Update : 11.2.0.4.4 (19121551)"
Sub-patch  18522509; "Database Patch Set Update : 11.2.0.4.3 (18522509)"
Sub-patch  18031668; "Database Patch Set Update : 11.2.0.4.2 (18031668)"
Sub-patch  17478514; "Database Patch Set Update : 11.2.0.4.1 (17478514)"
Bugs fixed:
17184721, 21538558, 16091637, 18092127, 17381384, 15979965, 18441944
13837378, 16314254, 16731148, 17835048, 13558557, 17201159, 17853498
(此处略去若干bug号。)
19680952, 18704244, 18828868, 18273830, 17050888, 17360606, 16992075
17375354, 12905058, 18362222, 17571039, 17468141, 18436647, 17235750
21168487, 16220077, 16929165
包含多个节点的 RAC 系统
Local node = fxs38502
Remote node = fxs38501
--------------------------------------------------------------------------------
OPatch succeeded.

opatch auto /tmp/23274134 -oh /u01/app/oracle/product/11.2.0/dbhome_1 -ocmrf /tmp/ocm.rsp

DB node1

[oracle@fxs38501 OPatch]$ ./opatch lsinventory
Oracle 中间补丁程序安装程序版本 11.2.0.3.14
版权所有 (c) 2016, Oracle Corporation。保留所有权利。
Oracle Home       : /u01/app/oracle/product/11.2.0/dbhome_1
Central Inventory : /u01/app/oraInventory
from           : /u01/app/oracle/product/11.2.0/dbhome_1/oraInst.loc
OPatch version    : 11.2.0.3.14
OUI version       : 11.2.0.4.0
Log file location : /u01/app/oracle/product/11.2.0/dbhome_1/cfgtoollogs/opatch/opatch2016-07-21_20-13-24下午_1.log
Lsinventory Output file location : /u01/app/oracle/product/11.2.0/dbhome_1/cfgtoollogs/opatch/lsinv/lsinventory2016-07-21_20-13-24下午.txt
--------------------------------------------------------------------------------
Local Machine Information::
Hostname: fxs38501
ARU platform id: 226
ARU platform description:: Linux x86-64
已安装的顶级产品 (1):
Oracle Database 11g                                                  11.2.0.4.0
此 Oracle 主目录中已安装 1 个产品。
中间补丁程序 (2) :
Patch  23054319     : applied on Thu Jul 21 20:11:50 CST 2016
Unique Patch ID:  20209287
Patch description:  "OCW Patch Set Update : 11.2.0.4.160719 (23054319)"
Created on 15 Jul 2016, 14:38:02 hrs PST8PDT
Bugs fixed:
18328800, 19270660, 18691572, 18508710, 20038451, 21251192, 22162062
20365005, 21232394, 17387214, 17750548, 17617807, 14497275, 20219458
(此处略去若干bug号。)
21442094, 20235486, 19359787, 15869775, 17447588, 19642566, 21152052
16798862, 15920201
Patch  23054359     : applied on Thu Jul 21 20:11:07 CST 2016
Unique Patch ID:  20226193
Patch description:  "Database Patch Set Update : 11.2.0.4.160719 (23054359)"
Created on 15 Jun 2016, 16:08:35 hrs PST8PDT
Sub-patch  22502456; "Database Patch Set Update : 11.2.0.4.160419 (22502456)"
Sub-patch  21948347; "Database Patch Set Update : 11.2.0.4.160119 (21948347)"
Sub-patch  21352635; "Database Patch Set Update : 11.2.0.4.8 (21352635)"
Sub-patch  20760982; "Database Patch Set Update : 11.2.0.4.7 (20760982)"
Sub-patch  20299013; "Database Patch Set Update : 11.2.0.4.6 (20299013)"
Sub-patch  19769489; "Database Patch Set Update : 11.2.0.4.5 (19769489)"
Sub-patch  19121551; "Database Patch Set Update : 11.2.0.4.4 (19121551)"
Sub-patch  18522509; "Database Patch Set Update : 11.2.0.4.3 (18522509)"
Sub-patch  18031668; "Database Patch Set Update : 11.2.0.4.2 (18031668)"
Sub-patch  17478514; "Database Patch Set Update : 11.2.0.4.1 (17478514)"
Bugs fixed:
17184721, 21538558, 16091637, 18092127, 17381384, 15979965, 18441944
13837378, 16314254, 16731148, 17835048, 13558557, 17201159, 17853498
(此处略去若干bug号。)
19680952, 18704244, 18828868, 18273830, 17050888, 17360606, 16992075
17375354, 12905058, 18362222, 17571039, 17468141, 18436647, 17235750
21168487, 16220077, 16929165
包含多个节点的 RAC 系统
Local node = fxs38501
Remote node = fxs38502
--------------------------------------------------------------------------------
OPatch succeeded.

DB node2:

[oracle@fxs38502 OPatch]$ ./opatch lsinventory
Oracle 中间补丁程序安装程序版本 11.2.0.3.14
版权所有 (c) 2016, Oracle Corporation。保留所有权利。
Oracle Home       : /u01/app/oracle/product/11.2.0/dbhome_1
Central Inventory : /u01/app/oraInventory
from           : /u01/app/oracle/product/11.2.0/dbhome_1/oraInst.loc
OPatch version    : 11.2.0.3.14
OUI version       : 11.2.0.4.0
Log file location : /u01/app/oracle/product/11.2.0/dbhome_1/cfgtoollogs/opatch/opatch2016-07-21_20-17-42下午_1.log
Lsinventory Output file location : /u01/app/oracle/product/11.2.0/dbhome_1/cfgtoollogs/opatch/lsinv/lsinventory2016-07-21_20-17-42下午.txt
--------------------------------------------------------------------------------
Local Machine Information::
Hostname: fxs38502
ARU platform id: 226
ARU platform description:: Linux x86-64
已安装的顶级产品 (1):
Oracle Database 11g                                                  11.2.0.4.0
此 Oracle 主目录中已安装 1 个产品。
中间补丁程序 (2) :
Patch  23054319     : applied on Thu Jul 21 20:17:01 CST 2016
Unique Patch ID:  20209287
Patch description:  "OCW Patch Set Update : 11.2.0.4.160719 (23054319)"
Created on 15 Jul 2016, 14:38:02 hrs PST8PDT
Bugs fixed:
18328800, 19270660, 18691572, 18508710, 20038451, 21251192, 22162062
20365005, 21232394, 17387214, 17750548, 17617807, 14497275, 20219458
(此处略去若干bug号。)
17769597, 19955755, 16429265, 18336452, 17273003, 17209968, 16988311
19319357, 20094984, 17046460, 17059927, 18053631, 16867761, 18774591
21442094, 20235486, 19359787, 15869775, 17447588, 19642566, 21152052
16798862, 15920201
Patch  23054359     : applied on Thu Jul 21 20:16:19 CST 2016
Unique Patch ID:  20226193
Patch description:  "Database Patch Set Update : 11.2.0.4.160719 (23054359)"
Created on 15 Jun 2016, 16:08:35 hrs PST8PDT
Sub-patch  22502456; "Database Patch Set Update : 11.2.0.4.160419 (22502456)"
Sub-patch  21948347; "Database Patch Set Update : 11.2.0.4.160119 (21948347)"
Sub-patch  21352635; "Database Patch Set Update : 11.2.0.4.8 (21352635)"
Sub-patch  20760982; "Database Patch Set Update : 11.2.0.4.7 (20760982)"
Sub-patch  20299013; "Database Patch Set Update : 11.2.0.4.6 (20299013)"
Sub-patch  19769489; "Database Patch Set Update : 11.2.0.4.5 (19769489)"
Sub-patch  19121551; "Database Patch Set Update : 11.2.0.4.4 (19121551)"
Sub-patch  18522509; "Database Patch Set Update : 11.2.0.4.3 (18522509)"
Sub-patch  18031668; "Database Patch Set Update : 11.2.0.4.2 (18031668)"
Sub-patch  17478514; "Database Patch Set Update : 11.2.0.4.1 (17478514)"
Bugs fixed:
17184721, 21538558, 16091637, 18092127, 17381384, 15979965, 18441944
13837378, 16314254, 16731148, 17835048, 13558557, 17201159, 17853498
17246576, 18356166, 18440047, 18681862, 16875449, 19788842, 17296856
21330264, 14010183, 17648596, 17551063, 17025461, 17267114, 22507210
17912217, 17889583, 18202441, 17040764, 16524926, 17478145, 19358317
(此处略去若干bug号。)
19680952, 18704244, 18828868, 18273830, 17050888, 17360606, 16992075
17375354, 12905058, 18362222, 17571039, 17468141, 18436647, 17235750
21168487, 16220077, 16929165
包含多个节点的 RAC 系统
Local node = fxs38502
Remote node = fxs38501
--------------------------------------------------------------------------------
OPatch succeeded.

201672120:18:38

dbca建库

 

建库过程中警告日志出现如下警告

Thread 1 cannot allocate new log, sequence 21

Checkpoint not complete

  Current log# 2 seq# 20 mem# 0: +DATA/centerdb/onlinelog/group_2.264.917814411

  Current log# 2 seq# 20 mem# 1: +DATA/centerdb/onlinelog/group_2.265.917814413

Thread 1 advanced to log sequence 21 (LGWR switch)

  Current log# 1 seq# 21 mem# 0: +DATA/centerdb/onlinelog/group_1.262.917814411

  Current log# 1 seq# 21 mem# 1: +DA...................

 

后期要添加在线日志组,日志组成员大小为500MB

 

 

201672121:10:00

expdp DIRECTORY=DMPDIR DUMPFILE=all.dmp LOGFILE=all.log SCHEMAS=TSMSYS,CENTER_MAIL,OUTLN,BENTER_ADMIN,WMSYS,CENTER_ETL,GYAM,DDS

 

数据泵开始从源库导出数据

 

201672121:53:16

准备添加日志组的脚本:

ALTER DATABASE ADD LOGFILE THREAD 1 GROUP 5 SIZE 500M;ALTER DATABASE ADD LOGFILE THREAD 1 GROUP 6 SIZE 500M;ALTER DATABASE ADD LOGFILE THREAD 2 GROUP 7 SIZE 500M;ALTER DATABASE ADD LOGFILE THREAD 2 GROUP 8 SIZE 500M;ALTER DATABASE ADD LOGFILE THREAD 1 GROUP 9 SIZE 500M;ALTER DATABASE ADD LOGFILE THREAD 1 GROUP 10 SIZE 500M;ALTER DATABASE ADD LOGFILE THREAD 2 GROUP 11 SIZE 500M;ALTER DATABASE ADD LOGFILE THREAD 2 GROUP 12 SIZE 500M;

删除旧的日志组(删除前要switch logfile以确保删掉的日志组不是current状态)

ALTER DATABASE DROP LOGFILE GROUP 1;ALTER DATABASE DROP LOGFILE GROUP 2;ALTER DATABASE DROP LOGFILE GROUP 3;ALTER DATABASE DROP LOGFILE GROUP 4; 
 

创建表空间并添加相应数据文件:

CREATE TABLESPACE CENTERDBT DATAFILE SIZE 1G AUTOEXTEND ON next 100m;ALTER TABLESPACE CENTERDBT ADD DATAFILE SIZE 1G AUTOEXTEND ON next 100m;ALTER TABLESPACE CENTERDBT ADD DATAFILE SIZE 1G AUTOEXTEND ON next 100m;ALTER TABLESPACE CENTERDBT ADD DATAFILE SIZE 1G AUTOEXTEND ON next 100m;ALTER TABLESPACE CENTERDBT ADD DATAFILE SIZE 1G AUTOEXTEND ON next 100m;ALTER TABLESPACE CENTERDBT ADD DATAFILE SIZE 1G AUTOEXTEND ON next 100m;ALTER TABLESPACE CENTERDBT ADD DATAFILE SIZE 1G AUTOEXTEND ON next 100m;ALTER TABLESPACE CENTERDBT ADD DATAFILE SIZE 1G AUTOEXTEND ON next 100m;ALTER TABLESPACE CENTERDBT ADD DATAFILE SIZE 1G AUTOEXTEND ON next 100m;ALTER TABLESPACE CENTERDBT ADD DATAFILE SIZE 1G AUTOEXTEND ON next 100m;ALTER TABLESPACE CENTERDBT ADD DATAFILE SIZE 1G AUTOEXTEND ON next 100m;ALTER TABLESPACE CENTERDBT ADD DATAFILE SIZE 1G AUTOEXTEND ON next 100m;ALTER TABLESPACE CENTERDBT ADD DATAFILE SIZE 1G AUTOEXTEND ON next 100m;CREATE TABLESPACE GYDB DATAFILE SIZE 1G AUTOEXTEND ON next 100m;ALTER TABLESPACE GYDB ADD DATAFILE SIZE 1G AUTOEXTEND ON next 100m;CREATE TABLESPACE CENTERMAIL DATAFILE SIZE 1G AUTOEXTEND on next 100m;CREATE TABLESPACE SPACE_INXITEDB DATAFILE SIZE 1G AUTOEXTEND ON next 100m;

运行hugepages_settings.sh得出大内存参数

vm.nr_hugepages = 2052

vm.vfs_cache_pressure=200

vm.swappiness=10

vm.min_free_kbytes=524288

 

 

201672200:14:12

expdp导出完成

 

201672200:14:26

添加日志组

创建相应表空间并添加数据文件

 

201672201:15:37

导入开始

impdp system/oracle DIRECTORY=dmpdir DUMPFILE=all.dmp LOGFILE=in.log CLUSTER=N &

 

状况:发现字符集不对,原库用的GBK,新库用的UTF8,遂DBCA删除重建。(耗时大约15分钟)

 

201672202:56:57

再次进行impdp操作

 

201672207:23:58

最终由于导入速度过慢,无法再8点之前完成导入操作(3小时导入100G),客户要求终止新rac的导入,并重新启用旧rac。暂定于周五继续进行迁移操作。

 

 

这篇关于某券商Oracle RAC数据库服务器更换(上)的文章就介绍到这儿,希望我们推荐的文章对编程师们有所帮助!



http://www.chinasem.cn/article/1044948

相关文章

NFS实现多服务器文件的共享的方法步骤

《NFS实现多服务器文件的共享的方法步骤》NFS允许网络中的计算机之间共享资源,客户端可以透明地读写远端NFS服务器上的文件,本文就来介绍一下NFS实现多服务器文件的共享的方法步骤,感兴趣的可以了解一... 目录一、简介二、部署1、准备1、服务端和客户端:安装nfs-utils2、服务端:创建共享目录3、服

IDEA如何切换数据库版本mysql5或mysql8

《IDEA如何切换数据库版本mysql5或mysql8》本文介绍了如何将IntelliJIDEA从MySQL5切换到MySQL8的详细步骤,包括下载MySQL8、安装、配置、停止旧服务、启动新服务以及... 目录问题描述解决方案第一步第二步第三步第四步第五步总结问题描述最近想开发一个新应用,想使用mysq

Oracle数据库使用 listagg去重删除重复数据的方法汇总

《Oracle数据库使用listagg去重删除重复数据的方法汇总》文章介绍了在Oracle数据库中使用LISTAGG和XMLAGG函数进行字符串聚合并去重的方法,包括去重聚合、使用XML解析和CLO... 目录案例表第一种:使用wm_concat() + distinct去重聚合第二种:使用listagg,

macOS怎么轻松更换App图标? Mac电脑图标更换指南

《macOS怎么轻松更换App图标?Mac电脑图标更换指南》想要给你的Mac电脑按照自己的喜好来更换App图标?其实非常简单,只需要两步就能搞定,下面我来详细讲解一下... 虽然 MACOS 的个性化定制选项已经「缩水」,不如早期版本那么丰富,www.chinasem.cn但我们仍然可以按照自己的喜好来更换

Python项目打包部署到服务器的实现

《Python项目打包部署到服务器的实现》本文主要介绍了PyCharm和Ubuntu服务器部署Python项目,包括打包、上传、安装和设置自启动服务的步骤,具有一定的参考价值,感兴趣的可以了解一下... 目录一、准备工作二、项目打包三、部署到服务器四、设置服务自启动一、准备工作开发环境:本文以PyChar

oracle中exists和not exists用法举例详解

《oracle中exists和notexists用法举例详解》:本文主要介绍oracle中exists和notexists用法的相关资料,EXISTS用于检测子查询是否返回任何行,而NOTE... 目录基本概念:举例语法pub_name总结 exists (sql 返回结果集为真)not exists (s

Java读取InfluxDB数据库的方法详解

《Java读取InfluxDB数据库的方法详解》本文介绍基于Java语言,读取InfluxDB数据库的方法,包括读取InfluxDB的所有数据库,以及指定数据库中的measurement、field、... 首先,创建一个Java项目,用于撰写代码。接下来,配置所需要的依赖;这里我们就选择可用于与Infl

Oracle的to_date()函数详解

《Oracle的to_date()函数详解》Oracle的to_date()函数用于日期格式转换,需要注意Oracle中不区分大小写的MM和mm格式代码,应使用mi代替分钟,此外,Oracle还支持毫... 目录oracle的to_date()函数一.在使用Oracle的to_date函数来做日期转换二.日

详谈redis跟数据库的数据同步问题

《详谈redis跟数据库的数据同步问题》文章讨论了在Redis和数据库数据一致性问题上的解决方案,主要比较了先更新Redis缓存再更新数据库和先更新数据库再更新Redis缓存两种方案,文章指出,删除R... 目录一、Redis 数据库数据一致性的解决方案1.1、更新Redis缓存、删除Redis缓存的区别二

oracle数据库索引失效的问题及解决

《oracle数据库索引失效的问题及解决》本文总结了在Oracle数据库中索引失效的一些常见场景,包括使用isnull、isnotnull、!=、、、函数处理、like前置%查询以及范围索引和等值索引... 目录oracle数据库索引失效问题场景环境索引失效情况及验证结论一结论二结论三结论四结论五总结ora