标签:ora 数据库版本 lease thread res 运行 解决方法 may ack
一、实验场景
主机A:
OS:SUSE Linux Enterprise Server 11 SP3 (x86_64)
IP:192.168.1.100
数据库:oracle11.2.0.1 ORACLE_SID=orcl
主机B:
OS:Red Hat Enterprise Linux Server release 6.5 (Santiago)
IP:192.168.1.124
数据库:oracle11.2.0.3
ORACLE_SID=fxcx
二、恢复过程
1.rman备份
备份参数文件
RMAN> BACKUP SPFILE FORMAT ‘/home/oracle/rman_backup/tc/orcl_spfile_%U.bak‘;
备份控制文件
RMAN> BACKUP CURRENT CONTROLFILE FORMAT ‘/home/oracle/rman_backup/tc/ctl_%d_%T_%s_%p.bak‘;
备份数据文件和归档日志文件
RMAN> backup database format ‘/backup/tc/dbfull_%d_%u_%s.bak‘ plus archivelog format ‘/backup/tc/archfull_%d_%u_%s.bak‘;
2.将备份文件cp到B机/hom2018-11-05e/oracle/rman_backup/tc/,如果没有新建并修改权限
3.rman恢复
将B机启动到nomount状态
RMAN> startup nomount;
恢复参数文件
RMAN> restore spfile from ‘/home/oracle/rman_backup/tc/orcl_spfile_1tt88a1g_1_1.bak‘;
注意:恢复时根据提示创建对应新的控制文件目录、归档日志文件目录等
恢复成功后切换至mount状态
RMAN> alter database mount
恢复控制文件
RMAN> restore controlfile from ‘/home/oracle/rman_backup/tc/ctl_ORCL_20180717_62_1.bak‘;
恢复数据文件
将数据备份集导入控制文件,此处适用于异机还原时备份集没有在默认位置的场景。
RMAN> catalog start with ‘/home/oracle/backup/‘;
还原数据文件
RMAN> restore database;
RMAN> recover database;
Starting recover at 28-MAY-15
using channel ORA_DISK_1
starting media recovery
RMAN-00571: ===========================================================
RMAN-00569: =============== ERROR MESSAGE STACK FOLLOWS ===============
RMAN-00571: ===========================================================
RMAN-03002: failure of recover command at 05/28/2015 17:07:45
RMAN-06053: unable to perform media recovery because of missing log
RMAN-06025: no backup of archived log for thread 1 with sequence 12 and starting SCN of 1083172 found to restore
//这里报日志缺少,实际上是备份的数据库文件后,没有备份归档日志,归档日志部分丢失
开始不完全恢复
SQL> recover database using backup controlfile until cancel;
SQL> alter database open resetlogs;
ORA-01092: ORACLE instance terminated. Disconnection forced
ORA-00704: bootstrap process failure
ORA-39700: database must be opened with UPGRADE option
由于此次异机恢复数据库版本不一致
因此需要通过upgrade的方式打开数据库
解决方法:通过upgrade的方式打开数据库
SQL> startup mount;
SQL> alter database open upgrade;
SQL> select status from v$Instance;
STATUS
------------------------------------
OPEN MIGRATE
SQL> @$ORACLE_HOME/rdbms/admin/catupgrd.sql;
原理:当数据库版本升级的时候,数据库内部的基表进行了变更,数据字典也需要进行相应的更
新,运行catupgrd.sql(30分钟)会进行相应对象更新;
执行完成后启动数据库即可
SQL>startup
标签:ora 数据库版本 lease thread res 运行 解决方法 may ack
原文地址:https://www.cnblogs.com/ylink-knowledge/p/9907697.html