until scn

classic Classic list List threaded Threaded
12 messages Options
Reply | Threaded
Open this post in threaded view
|

until scn

satish
Dear Erman,

Need your support

1)script used to take full backup

sql "alter system archive log current";

BACKUP AS COMPRESSED BACKUPSET INCREMENTAL LEVEL=0 spfile format '${BACKUPDIR}/spfile_%d_%s_%T.bak' DATABASE INCLUDE CURRENT CONTROLFILE PLUS ARCHIVELOG;

2)Below are the Backup files generated for full backup

-rw-r----- 1 oraprod asmadmin 1752142336 May 27 01:02 ora_df977187626_s74636_s1
-rw-r----- 1 oraprod asmadmin 2015733760 May 27 01:02 ora_df977187626_s74635_s1
-rw-r----- 1 oraprod asmadmin 2138429440 May 27 01:02 ora_df977187626_s74634_s1
-rw-r----- 1 oraprod asmadmin 2160716288 May 27 01:03 ora_df977187626_s74637_s1
-rw-r----- 1 oraprod asmadmin 83532288 May 27 01:03 ora_df977187784_s74641_s1
-rw-r----- 1 oraprod asmadmin 786694656 May 27 01:03 ora_df977187782_s74640_s1
-rw-r----- 1 oraprod asmadmin 917909504 May 27 01:04 ora_df977187775_s74639_s1
-rw-r----- 1 oraprod asmadmin 2229669376 May 27 01:05 ora_df977187772_s74638_s1
-rw-r----- 1 oraprod asmadmin 6239592448 May 27 01:14 ora_df977187930_s74642_s1
-rw-r----- 1 oraprod asmadmin 6096830464 May 27 01:14 ora_df977187930_s74644_s1
-rw-r----- 1 oraprod asmadmin 7627743232 May 27 01:16 ora_df977187930_s74645_s1
-rw-r----- 1 oraprod asmadmin 7775453184 May 27 01:17 ora_df977187930_s74643_s1
-rw-r----- 1 oraprod asmadmin 1303552 May 27 01:17 ora_df977188634_s74649_s1
-rw-r----- 1 oraprod asmadmin 1516032 May 27 01:17 ora_df977188634_s74648_s1
-rw-r--r-- 1 oraprod asmadmin 20656 May 27 01:17 ctrlfile_PRODDB2_010001_27052018

we are using backup based duplicate restore and recovery.we would like to use UNTIL TIME and use 27th full backup for duplicate.

please let us know what time we can take exactly to avoid any errors during recovery process.
Logfile attachedfullbackuplog.zip

Reply | Threaded
Open this post in threaded view
|

Re: until scn

satish
logfile.txt

Attached fullback log for your reference

Thank you
Reply | Threaded
Open this post in threaded view
|

Re: until scn

ErmanArslansOracleBlog
Administrator
If you have proper backup for using with the duplicate command (I mean db + archivelogs), then you should be able to duplicate  using until time till "last NEXT TIME" in your archived logs.
Reply | Threaded
Open this post in threaded view
|

Re: until scn

satish
Thanks for the update erman.

Dear Erman,

Thanks for the update.i have issues list backup command and taken the backup details that ran on 27th full backup

BS Key  Size       Device Type Elapsed Time Completion Time
------- ---------- ----------- ------------ ------------------
73266   1.24M      DISK        00:00:00     27-may-18 01:17:14
        BP Key: 73266   Status: AVAILABLE  Compressed: YES  Tag: TAG20180527T011714
        Piece Name: /u03/PRODRMAN/PRODDB2/rman/ora_df977188634_s74649_s1

  List of Archived Logs in backup set 73266
  Thrd Seq     Low SCN    Low Time           Next SCN   Next Time
  ---- ------- ---------- ------------------ ---------- ---------
  1    26405   5967693033115 27-may-18 01:00:17 5967693042468 27-may-18 01:17:14

BS Key  Size       Device Type Elapsed Time Completion Time
------- ---------- ----------- ------------ ------------------
73267   1.45M      DISK        00:00:00     27-may-18 01:17:14
        BP Key: 73267   Status: AVAILABLE  Compressed: YES  Tag: TAG20180527T011714
        Piece Name: /u03/PRODRMAN/PRODDB2/rman/ora_df977188634_s74648_s1

  List of Archived Logs in backup set 73267
  Thrd Seq     Low SCN    Low Time           Next SCN   Next Time
  ---- ------- ---------- ------------------ ---------- ---------
  2    25602   5967693033119 27-may-18 01:00:16 5967693042463 27-may-18 01:17:12


we are using RAC.From above next time is 27-may-18 01:17:12,if we issue this,then will it recover till 27-may-18 01:17:12?

one of my friend updated me to add 1 minute for the above time,need your expertise
Reply | Threaded
Open this post in threaded view
|

Re: until scn

satish
listbackup_27th.txt


Attached full log for your reference
Reply | Threaded
Open this post in threaded view
|

Re: until scn

ErmanArslansOracleBlog
Administrator
Use the last "next value". As I already send you the following info -> "you should be able to duplicate  using until time till "last NEXT TIME" in your archived logs"
 
Reply | Threaded
Open this post in threaded view
|

Re: until scn

Satish
Thanks for the update erman.

My colleague has argued with me to use LOW TIME. Could you plz give us some understanding

Thanks for all the support
Reply | Threaded
Open this post in threaded view
|

Re: until scn

ErmanArslansOracleBlog
Administrator
Low Time -> The time when the database switched into the redo log having this sequence number.
Next Time -> The low time of the next archived log sequence.

As you see from the definitions.. You decide :)
So, "Next Time-1 second" is more logical.
Reply | Threaded
Open this post in threaded view
|

Re: until scn

satish
Thanks for the update erman.Last six months,i am following this blog and got great support.Obviously i follow you.


1)Low Time -> The time when the database switched into the redo log having this sequence number.

is this redo log having this sequence number OR archived redo log having this sequence number?

2)I didnt get this "So, "Next Time-1 second" is more logical."

Thank you
Reply | Threaded
Open this post in threaded view
|

Re: until scn

ErmanArslansOracleBlog
Administrator
Thanks for the feedback..

It means the date that you see in next_time column minus -1 seconds.

If you see 27-may-18 01:17:12 for the last archive log in your backup , then use 27-may-18 01:17:11  
Reply | Threaded
Open this post in threaded view
|

Re: until scn

Satish
Thanks  a ton erman. Duplicate was successful with next time -1
Reply | Threaded
Open this post in threaded view
|

Re: until scn

ErmanArslansOracleBlog
Administrator
:) good.