SAP中oracle数据库的备份恢复.docx

上传人:b****4 文档编号:24349788 上传时间:2023-05-26 格式:DOCX 页数:18 大小:1MB
下载 相关 举报
SAP中oracle数据库的备份恢复.docx_第1页
第1页 / 共18页
SAP中oracle数据库的备份恢复.docx_第2页
第2页 / 共18页
SAP中oracle数据库的备份恢复.docx_第3页
第3页 / 共18页
SAP中oracle数据库的备份恢复.docx_第4页
第4页 / 共18页
SAP中oracle数据库的备份恢复.docx_第5页
第5页 / 共18页
点击查看更多>>
下载资源
资源描述

SAP中oracle数据库的备份恢复.docx

《SAP中oracle数据库的备份恢复.docx》由会员分享,可在线阅读,更多相关《SAP中oracle数据库的备份恢复.docx(18页珍藏版)》请在冰豆网上搜索。

SAP中oracle数据库的备份恢复.docx

SAP中oracle数据库的备份恢复

1.备份数据库

进入T-codeDB13

备份在线数据库

去DB12可以看进度

查看日志

 

这是成功了

 

2.备份数据库归档文件

执行DB13的TCODE,创建计划,设定计划时间,选择redologbackup.

利用命令备份:

brarchive-u/-cforce-pinitPRD.sap-sd

Zzxc

报错,说Function中写的BRARCHIVE出错了,所以这里要用-sd

这样就可以了,去DB14中查看日志备份状态

 

成功了

备份更改路径

3.SAP数据恢复

在运行中输入sqlplus/nolog打开cmd界面,登陆oracle

Windows切换为devadm用户登录

关闭数据库服务

Linux下备份数据库

使用rdvadm用户登录

用chmod–R777/oracle给权限

修改/oracle/RDV/102_64/dbs/initRDV.sap

备份日志文件路径

备份数据库时报错

解决方法:

[root@vm~]#su-oracle

[oracle@vm~]$cd$ORACLE_HOME/bin

[oracle@vmbin]$chmod+soracle

[oracle@vmbin]$lloracle

-rwsrwsr-x1oracleoinstall152028761Aug3019:

06oracle

[oracle@vmbin]$

关于s权限的说明:

s表示setUID和setGID。

位于user和group权限组的第三位置。

如果在user权限组中设置了s权限。

那么当该文件被执行时,是以文件所有者的GID,而不是用户的GID执行文件,因此可执行的文件搭配这个权限,便能得到特权,任意存取该文件的所有者能使用全部系统资源

NOTE:

776505

Symptom

1.BRARCHIVE,BRBACKUP,andBRCONNECT-startedwiththeuseradmwhenusingtheOPS$connection(option"-u/")-terminateonLinuxorSolaris11withthefollowingerrormessages:

BR0301ESQLerror-1017atlocationBrDbConnect-2

ORA-01017:

invalidusername/password;logondenied

BR0310EConnecttodatabaseinstanceQO1failed

2.BRBACKUPorBRARCHIVEbackupwithRMAN-startedwiththeuseradm-failsonLinuxorSolaris11withthefollowingerrormessages:

BR0278ECommandoutputof'SHELL=/bin/sh/oracle/I20/920_32/bin/rman

nocatalog':

RecoveryManager:

Release9.2.0.4.0-Production

Copyright(c)1995,2002,OracleCorporation.  Allrightsreserved.

RMAN>

RMAN>connecttarget/;

RMAN-00571:

===========================================================

RMAN-00569:

===============ERRORMESSAGESTACKFOLLOWS===============

RMAN-00571:

===========================================================

ORA-01031:

insufficientprivileges

RMAN>**end-of-file**

3.BRBACKUPorBRARCHIVEfailwithORA-01031duringanattempttoconnecttothedatabaseusingtheSYSOPERauthorization,forexample:

BR0301ESQLerror-1031atlocationBrInitOraCreate-2,SQLstatement:

'CONNECT/ATPROF_CONNINSYSOPERMODE'

ORA-01031:

insufficientprivileges

BR0303EDeterminationofOracleversionfailed

OtherTerms

BR*Tools

ReasonandPrerequisites

TheBRexecutablesareassignedans-bit.Theproblemisrelatedtothespecialprocessingofthes-bitbyLinuxandSolaris11operatingsystems.

1.TheproblemdoesnotoccuriftheBR*ToolsarecalledwiththeSYSTEMdatabaseuser,forexample:

brbackup-uSYSTEM/-q

2+3.TheproblemoccursforeverydatabaseuserifthebackupwasstartedwiththeOSuseradm.

Solution

1.AlthoughtheBR*ToolsarecalledwiththeOSadm,therelevantdatabaseuserfortheOPS$connectionmustbecalledOPS$ORA.Ifitdoesnotexistyet,createitasfollows:

sqlplus/nolog

SQL>connect/assysdba

SQL>createuserops$oraidentifiedexternallytemporarytablespacepsaptemp;

SQL>grantsapdbatoops$ora;

2+3.Tosolvetheproblem,settheSGIDbitforthebrarchive,brbackup,andbrconnectexecutables(theymustbelongtoora):

su-root

cd/usr/sap//SYS/exe/run

改变文件所有者为ora

chownorabrarchivebrbackupbrconnect

改变所属用户组为dba

chgrpdbabrarchivebrbackupbrconnect

改变文件权限为6754

chmod6754brarchivebrbackupbrconnect

Thesecommandsshouldresultinthefollowingfileauthorizations:

-rwsr-sr--1ora  dba    93253742012-12-1904:

52brarchive

-rwsr-sr--1ora  dba    94432232012-12-1904:

52brbackupLS

-rwsr-sr--1ora  dba    113337562012-12-1904:

55brconnect

-rwxr-xr-x1admsapsys  98937022012-12-1904:

56brrecover

-rwxr-xr-x1admsapsys  62030962012-12-1904:

56brrestore

-rwxr-xr-x1admsapsys117668272012-12-1904:

58brspace

-rwxr-xr-x1admsapsys  67975242012-12-1904:

58brtools

Theauthorization***4shouldpreventjustanybodyfrombeingabletoperformanofflinebackup,whichcoulddisrupttheavailabilityoftheSAPsystem.

HeaderData

ReleasedOn

27.07.201514:

33:

10

ReleaseStatus

ReleasedforCustomer

Component

BC-DB-ORA-DBADatabaseAdministrationwithOracle

Priority

Correctionwithmediumpriority

Category

Helpforerroranalysis

Validity

Thisdocumentisnotrestrictedtoasoftwarecomponentorsoftwarecomponentversion 

References

Thisdocumentrefersto:

SAPNotes

1882181

 

CorrectionsinBR*Tools7.20Patch33/7.40Patch3

361641

 

CreatingOPS$usersonUNIX

113747

 

OwnersandauthorizationsforBR*Tools

Thisdocumentisreferencedby:

SAPNotes(3)

113747

 

OwnersandauthorizationsforBR*Tools

361641

 

CreatingOPS$usersonUNIX

1882181

 

CorrectionsinBR*Tools7.20Patch33/7.40Patch3

 

Linux下恢复数据库

 

恢复数据文件

>su–oraprd

>cd/oracle/PRD/sapbackup

>brrestore–bbeqktnhh.and–mfull–cforce-ddisk

注意:

在上面命令中,beqktnhh.and为对应备份集的备份日志文件,请根据实际情况进行相关替换。

在生产数据库中产生控制文件的trace.

>su–oraprd

>sqlplus“/assysdba”

SQL>alterdatabasebackupcontrolfiletotraceas'/tmp/prd.trc';

将产生的控制文件拷贝到本地,加工获得相关目录和控制文件重建SQL脚本。

 

由于是压缩备份,所以在恢复时必须解压日志文件

解压命令

cd/oracle/RDV/oraarch/

gunzip–c文件名>解压到的文件名

展开阅读全文
相关资源
猜你喜欢
相关搜索

当前位置:首页 > 解决方案 > 学习计划

copyright@ 2008-2022 冰豆网网站版权所有

经营许可证编号:鄂ICP备2022015515号-1