Cold Backup Cloning of Database .
Cold Backup :
A cold backup is done when there is no user activity going on with the system. Also called as offline backup, is taken when the database is not running and no users are logged in. all files of the database are copied and no changes during the copy are made.
Cold backup can be preformed when Database is in archive mode as well as Non archive log mode .
Backup Strategy :
Gather all the details of physical files (CRD) files in database . redo log files are online redo log and archived redo log ones .
- Select file_name,tablespace_name from dba_data_files ;
- select * from v$controlfile
- select member from v$logfile ;
- select name from v$archived_Log ;
- create pfile from spfile
Backup the contol file manually .
alter database backup controlfile to trace as '/tmp/coldbackup_controlfile.sql' ;
Stop all the DB services (Database ,Listener)on source DB Server.
Copy all the files(Datafiles,redologfiles,pfile,contol file backup) from source to backup location to target server
On the target node
- Copy the Pfile to dbs location
- Edit the pfile and modify the Database name details , adump location ,contolfile details .
- Create all the Directories as per requirement
- Startup the database in no mount
- Edit the backup control file -- Delete everything before "CREATE CONTROLFILE" and after "CHARACTER SET " .
- Modify the location of data files and logfiles to point to new locations.
- Change the following words in sql file (REUSE to SET) and (NORESETLOGS to RESETLOGS)
- SAVE FILE WITH EXTENSION ".sql" ;
- execute the sql file from sqlplus
- Once the control file is successfully Created ,Open the database in reset log mode .
- "select open_Mode from v$database ;
Comments
Post a Comment