NBU重新配置导致恢复不成功--Oracle和NBU的link

[[email protected] rman]# su - oracle

[[email protected] ~]$ rman target /

Recovery Manager: Release 11.2.0.3.0 - Production on Fri Sep 19 09:47:47 2014

Copyright (c) 1982, 2011, Oracle and/or its affiliates.  All rights reserved.

connected to target database: sevendb (not mounted)

RMAN> restore controlfile from ‘/usr/openv/rman/control.sevendb‘;

Starting restore at 19-SEP-14

using target database control file instead of recovery catalog

allocated channel: ORA_DISK_1

channel ORA_DISK_1: SID=461 device type=DISK

channel ORA_DISK_1: copied control file copy

output file name=/oradata/sevendb/control01.ctl

output file name=/oradata/sevendb/control02.ctl

Finished restore at 19-SEP-14

RMAN> alter database mount;

database mounted

released channel: ORA_DISK_1

RMAN> list incarnation of database;

List of Database Incarnations

DB Key  Inc Key DB Name  DB ID            STATUS  Reset SCN  Reset Time

------- ------- -------- ---------------- --- ---------- ----------

1       1       sevendb    1917838411       PARENT  1          25-OCT-12

2       2       sevendb    1917838411       CURRENT 7906931    17-JAN-13

RMAN> run {

2> set until time "to_date (‘09/18/2014 18:30:00‘, ‘MM/DD/YYYY HH24:MI:SS‘ )";

3> allocate channel c1 type sbt;

4> send ‘NB_ORA_CLIENT=PsevendbS01‘ ;

5> restore database;

6> recover database;

7> release channel c1;

8> }

executing command: SET until clause

RMAN-00571: ===========================================================

RMAN-00569: =============== ERROR MESSAGE STACK FOLLOWS ===============

RMAN-00571: ===========================================================

RMAN-03009: failure of allocate command on c1 channel at 09/19/2014 09:48:27

ORA-19554: error allocating device, device type: SBT_TAPE, device name:

ORA-27211: Failed to load Media Management Library

Additional information: 2

RMAN>

[[email protected] trace]$ cat sevendb_ora_13171.trc

Trace file /oracle/app/oracle/diag/rdbms/sevendb/sevendb/trace/sevendb_ora_13171.trc

Oracle Database 11g Enterprise Edition Release 11.2.0.3.0 - 64bit Production

With the Partitioning, OLAP, Data Mining and Real Application Testing options

ORACLE_HOME = /oracle/app/oracle/product/11.2.0/dbhome_1

System name:    Linux

Node name:      SsevendbS01

Release:        2.6.18-194.el5

Version:        #1 SMP Tue Mar 16 21:52:39 EDT 2010

Machine:        x86_64

Instance name: sevendb

Redo thread mounted by this instance: 1

Oracle process number: 23

Unix process pid: 13171, image: [email protected] (TNS V1-V3)

*** 2014-09-19 10:04:04.632

*** SESSION ID:(461.19) 2014-09-19 10:04:04.632

*** CLIENT ID:() 2014-09-19 10:04:04.632

*** SERVICE NAME:() 2014-09-19 10:04:04.632

*** MODULE NAME:([email protected] (TNS V1-V3)) 2014-09-19 10:04:04.632

*** ACTION NAME:(0000001 STARTED1) 2014-09-19 10:04:04.632

SKGFQ OSD: Error in function sbtinit on line 2734

SKGFQ OSD: Look for SBT Trace messages in file /oracle/app/oracle/diag/rdbms/sevendb/sevendb/trace/sbtio.log

SBT Initialize failed for oracle.static

[[email protected] trace]$ which sbttest

/oracle/app/oracle/product/11.2.0/dbhome_1/bin/sbttest

[[email protected] lib]$ sbttest /etc/hosts

The sbt function pointers are loaded from oracle.static library.

libobk.so could not be loaded.  Check that it is installed

查了很多资料发现:

导致上述结果的原因是Oracle没有和NBU做链接,

cd $ORACLE_HOME/lib

ln /usr/openv/netbackup/bin/libobk.so

操作后重新测试SBTTEST:

[[email protected] lib]$ sbttest /etc/hosts

The sbt function pointers are loaded from libobk.so library.

-- sbtinit succeeded

-- sbtinit (2nd time) succeeded

sbtinit: Media manager supports SBT API version 2.0

sbtinit: Media manager is version 5.0.0.0

sbtinit: vendor description string=Veritas NetBackup for Oracle - Release 7.5 (2013061020)

sbtinit: allocated sbt context area of 8 bytes

sbtinit: proxy copy is supported

-- sbtinit2 succeeded

-- regular_backup_restore starts ................................

OK,配置成功。

[[email protected] lib]$ ls -lrt /oracle/app/oracle/product/11.2.0/dbhome_1/lib/libobk.so64

ls: /oracle/app/oracle/product/11.2.0/dbhome_1/lib/libobk.so64: No such file or directory

[[email protected] lib]$

[[email protected] lib]$

[[email protected] lib]$ pwd

/oracle/app/oracle/product/11.2.0/dbhome_1/lib

[[email protected] lib]$ cp /usr/openv/netbackup/bin/libobk.so64 libobk.so64

[[email protected] lib]$ pwd

/oracle/app/oracle/product/11.2.0/dbhome_1/lib

[[email protected] lib]$ ls -lrt /oracle/app/oracle/product/11.2.0/dbhome_1/lib/libobk.so64

-r-xr-xr-x 1 oracle oinstall 1511982 Sep 19 10:03 /oracle/app/oracle/product/11.2.0/dbhome_1/lib/libobk.so64

[[email protected] lib]$

[[email protected] lib]$

[[email protected] lib]$ rman target /

Recovery Manager: Release 11.2.0.3.0 - Production on Fri Sep 19 10:04:01 2014

Copyright (c) 1982, 2011, Oracle and/or its affiliates.  All rights reserved.

connected to target database: sevendb (DBID=1917838411, not open)

RMAN> run {

2> set until time "to_date (‘09/18/2014 18:30:00‘, ‘MM/DD/YYYY HH24:MI:SS‘ )";

3> allocate channel c1 type sbt;

4> send ‘NB_ORA_CLIENT=PsevendbS01‘;

5> restore database;

6> recover database;

7> release channel c1;

8> }

executing command: SET until clause

using target database control file instead of recovery catalog

RMAN-00571: ===========================================================

RMAN-00569: =============== ERROR MESSAGE STACK FOLLOWS ===============

RMAN-00571: ===========================================================

RMAN-03009: failure of allocate command on c1 channel at 09/19/2014 10:04:04

ORA-19554: error allocating device, device type: SBT_TAPE, device name:

ORA-27211: Failed to load Media Management Library

Additional information: 2

RMAN> exit

Recovery Manager complete.

[[email protected] lib]$ mv libobk.so64 libobk.so

需要将libobk.so64改为libobk.so。

[[email protected] lib]$ rman target /

Recovery Manager: Release 11.2.0.3.0 - Production on Fri Sep 19 10:04:26 2014

Copyright (c) 1982, 2011, Oracle and/or its affiliates.  All rights reserved.

connected to target database: sevendb (DBID=1917838411, not open)

RMAN> run {

2> set until time "to_date (‘09/18/2014 18:30:00‘, ‘MM/DD/YYYY HH24:MI:SS‘ )";

3> allocate channel c1 type sbt;

4> send ‘NB_ORA_CLIENT=PsevendbS01‘;

5> restore database;

6> recover database;

7> release channel c1;

8> }

executing command: SET until clause

using target database control file instead of recovery catalog

allocated channel: c1

channel c1: SID=461 device type=SBT_TAPE

channel c1: Veritas NetBackup for Oracle - Release 7.5 (2013061020)

sent command to channel: c1

Starting restore at 19-SEP-14

channel c1: starting datafile backup set restore

channel c1: specifying datafile(s) to restore from backup set

channel c1: restoring datafile 00002 to /oradata/sevendb/sysaux01.dbf

channel c1: restoring datafile 00004 to /oradata/sevendb/users01.dbf

channel c1: restoring datafile 00005 to /oradata/sevendb/tivoliorts01.dbf

channel c1: restoring datafile 00006 to /oradata/sevendb/TS_CIM_DATA_01.dbf

channel c1: restoring datafile 00009 to /oradata/sevendb/TS_ETL_IND_01.dbf

channel c1: reading from backup piece bk_4975_1_858258002

channel c1: ORA-19870: error while restoring backup piece bk_4975_1_858258002

ORA-19507: failed to retrieve sequential file, handle="bk_4975_1_858258002", parms=""

ORA-27029: skgfrtrv: sbtrestore returned error

ORA-19511: Error received from media manager layer, error text:

Backup file <bk_4975_1_858258002> not found in NetBackup catalog

channel c1: starting datafile backup set restore

channel c1: specifying datafile(s) to restore from backup set

channel c1: restoring datafile 00001 to /oradata/sevendb/system01.dbf

channel c1: restoring datafile 00003 to /oradata/sevendb/undotbs01.dbf

channel c1: restoring datafile 00007 to /oradata/sevendb/TS_CIM_IND_01.dbf

channel c1: restoring datafile 00008 to /oradata/sevendb/TS_ETL_DATA_01.dbf

channel c1: reading from backup piece bk_4976_1_858258148

channel c1: ORA-19870: error while restoring backup piece bk_4976_1_858258148

ORA-19507: failed to retrieve sequential file, handle="bk_4976_1_858258148", parms=""

ORA-27029: skgfrtrv: sbtrestore returned error

ORA-19511: Error received from media manager layer, error text:

Backup file <bk_4976_1_858258148> not found in NetBackup catalog

failover to previous backup

channel c1: starting datafile backup set restore

channel c1: specifying datafile(s) to restore from backup set

channel c1: restoring datafile 00002 to /oradata/sevendb/sysaux01.dbf

channel c1: restoring datafile 00004 to /oradata/sevendb/users01.dbf

channel c1: restoring datafile 00005 to /oradata/sevendb/tivoliorts01.dbf

channel c1: restoring datafile 00006 to /oradata/sevendb/TS_CIM_DATA_01.dbf

channel c1: restoring datafile 00009 to /oradata/sevendb/TS_ETL_IND_01.dbf

channel c1: reading from backup piece bk_4894_1_857653202

channel c1: ORA-19870: error while restoring backup piece bk_4894_1_857653202

ORA-19507: failed to retrieve sequential file, handle="bk_4894_1_857653202", parms=""

ORA-27029: skgfrtrv: sbtrestore returned error

ORA-19511: Error received from media manager layer, error text:

Backup file <bk_4894_1_857653202> not found in NetBackup catalog

channel c1: starting datafile backup set restore

channel c1: specifying datafile(s) to restore from backup set

channel c1: restoring datafile 00001 to /oradata/sevendb/system01.dbf

channel c1: restoring datafile 00003 to /oradata/sevendb/undotbs01.dbf

channel c1: restoring datafile 00007 to /oradata/sevendb/TS_CIM_IND_01.dbf

channel c1: restoring datafile 00008 to /oradata/sevendb/TS_ETL_DATA_01.dbf

channel c1: reading from backup piece bk_4895_1_857653337

以上报错提示找不到备份片,通常此等报错均是跟NBU的media server有关,通过查看/etc/hosts 和 bp.conf 发现没有问题,最终将问题定位到NB_ORA_CLIENT=PsevendbS01上,查看NBU备份脚本,其中client为PsevendbS而不是PsevendbS01,更改恢复脚本后,恢复成功。

时间: 2024-08-07 05:13:11

NBU重新配置导致恢复不成功--Oracle和NBU的link的相关文章

配置PL/SQL DEVELOPER远程访问oracle数据库

1.要想使用PL/SQL需要先安装oracle客户端(这个是必须的,要不然plsql就用不了,这个客户端可以去oracle官网上下载,名字叫instance client,尽量用较新的版本就可以了,windows版的大的也就50多M,还有精简版的20多M,地址:http://www.oracle.com/technology/global/cn/software/tech/oci/instantclient/index.html,挑个适合你的系统的版本的.) oracle客户端的安装很简单,直接

重装系统后,oracle11g数据库恢复(原oracle安装目录还在)

安装与之前同版本的数据库,安装目录选择与之前一样. 关闭oracle的所有服务. 拷贝原oracle_home目录下的database文件夹到现在的目录(最好先将现在的database文件夹进行备份). 拷贝原oracle_base下的oradata.admin.fgtoollogs.flash_recovery_area文件夹,覆盖现在的目录(请先进行备份). 打开服务. 运行命令sqlplus / as sysdba; 运行命令shutdown 运行命令startup 恢复成功.

Qlikview配置ODBC连接SQL SERVER/ORACLE

一, Qlikview配置ODBC连接SQL SERVER 1,打开ODBC数据源管理器:运行--〉ODBC 2,添加用户DSN 3,选择SQL Server Native Client 11.0, 然后点击[完成] 4,输入连接数据库的用户名和密码 5,选择默认的连接的数据库(可以不设置此步骤) 6,配置完成 7, 测试连接数据库 从上面的图片可看出连接时成功的,就SQL SERVER 2012的ODBC 是配置成功了. 8, Qlikview里创建用上面建立好的ODBC数据源来连接数据库 从

GitLab CE服务器安装配置备份恢复升级注意项总结

GitLab CE安装 安装比较简单,rpm直接在不同平台安装 https://about.gitlab.com/installation/ 直接下载源包地址 https://about.gitlab.com/downloads/archives/ 安装 #yum install curl openssh-server openssh-clients postfix cronie #service postfix start #chkconfig postfix on #lokkit -s ht

自己配置的WAMP环境,扩展oracle函数库(oci)

同事昨天接到一个任务,要用php处理oracle数据库的内容,但是php打开oracle扩展不是像mysql那样直接用就行,需要下一点东西才能打开 第一步 需要到oracle官方下载一个install client 包,在win下找到你对应系统版本的zip(注意这里是系统版本) 截止到2015-06-25,下载地址如下http://www.oracle.com/technetwork/database/features/instant-client/index-097480.html 例如选择

配置PL/SQL Developer连接Oracle数据库

准备: PL/SQL Developer:我用的是plsqldev1005(32位) win32_11gR2_client:记住一定是32位的,因为PL/SQL Developer只认32位的 安装成功后,需要配置环境变量: TNS_ADMIN环境变量,类似于:C:\app\Lzj\product\11.2.0\client_1\network\admin.这个变量实际上是PL/SQL Developer寻找tnsnames.ora的依据.有了这个环境变量,PL/SQL Developer启动是

JDK配置环境变量不成功的原因

根据自己配置环境变量遇到的问题进行总结: 1.二次安装需要注意的问题 由于已经安装了一次的原因,此时的注册表已经有了安装记录. 建议删除jdk的记录 首先打开注册表 开始菜单→运行.或者直接键盘按下WIN+R键,打开运行窗口.输入regedit,确定. 打开了注册表编辑器. 找到JDK 在注册表的顶部输入框输入以下路径: 计算机\HKEY_LOCAL_MACHINE\SOFTWARE\JavaSoft\Java Development Kit 此时可以看到你的jdk的版本,删除即可 2.配置环境

Mysql bin-log日志配置与恢复数据

1:在使用日志之前先确认日志是否已经开启了,登录mysql客户端,mysql -uroot -p123456(如果是源码安装且没有把mysql bin的路径加入到环境变量中,可以输入 /usr/local/mysql/bin/mysql -uroot -p123456 或 在家目录配置.bash_profile文件把/usr/local/mysql/bin一次性加到环境变量中),输入:shou variables like "%bin%",查看log_bin 的值是不是ON. 2:配置

因为diagwait未配置导致RAC脑裂日志记录不完整的分析案例

1.故障现象 一个RAC,CRS版本为10.2.0.4,在第二节点DOWN机后,第一节点也相继DOWN机. 2.CRS日志分析 2.1 二节点日志情况 CRS_LOG [cssd(8796)]CRS-1611:node XXdb1 (1) at 75% heartbeat fatal, eviction in 14.118 seconds 2014-07-04 22:49:38.556 [cssd(8796)]CRS-1611:node XXdb1 (1) at 75% heartbeat fa