Blogroll

Get a website with Godaddy


Logo designer Fiverr Frelancer

Wednesday, March 11, 2015

Oracle DB - RMAN command



RMAN is used to backup and restore Oracle database and also will be used in other backup tools like Symantec backup exec , and etc...

To connect from the operating system command line, enter the connection as in the following examples:
# example of operating system authentication
% rman TARGET / NOCATALOG

# example of Oracle Net authentication
% rman TARGET SYS/oracle@dbSID NOCATALOG



With catalog mode :
# example of operating system authentication
% rman TARGET /

# example of Oracle Net authentication
% rman TARGET SYS/oracle@dbSID

* to list out all backup set
LIST BACKUP;



% rman TARGET /
RMAN> BACKUP DATABASE;    # RMAN defaults to NOCATALOG mode
# operating system authentication
% rman TARGET / CATALOG rman/cat@catdb

# Oracle Net authentication
% rman TARGET SYS/oracle@trgt CATALOG rman/cat@catdb


note : Operating system authentication takes precedence over password file authentication.


you can refer to the below command for validating the the backup files before retoring them .
 RESTORE DATABASE VALIDATE;
 RESTORE ARCHIVELOG ALL VALIDATE;


How to delete expired archive log ? Archive log is an online redo log. Sometimes it could go wrong
and get expired and required to delete it before backup can take place..

RMAN>list expired archivelog all;
RMAN>crosscheck archivelog all;
RMAN>delete noprompt expired archivelog all;


NOTE : Loosing an archive redolog will compromises the recoverability of the RDBMS. So double check if this archive ever has been backed up via RMAN or normal filesystem backups.
If NO backup is found, than make a FULL database backup IMMEDIATELY !!!!!!



To be continued...






No comments:

Post a Comment

Amazon store

alidropship plugin

alidropship plugin
alidropship plugin

Total Pageviews

About