cancel
Showing results for 
Search instead for 
Did you mean: 

select max(sequence#) from v$archived_log where applied='YES' showd differn

pr_srinivas
Contributor
0 Kudos

Background :

We have Primary Server is in one town & We have Disaster Recovery Server in another town connected over 2MB MPLS.

Recently we have done "DB Reprganizations, during that time archive logs were created in huge as we aware, and due to archive directory space constraint, We backedup files and deleted immediately from primary.

Now Reorganizations completed - and manually we restoring archive files in DISASTER RECOVERY SITE and trying to recover Standby Database as below in DR Site:

-


1) lsnrctl start

2) sqlplus "/ as sysdba"

3) startup nomount;

4) alter database mount standby database;

5) recover standby database;

-


as soon as i issed command 5, Recovery started with Option "AUTO" as belo

-


ORA-00279: change 12324727338 generated at 11/21/2010 14:37:29 needed for

thread 1

ORA-00289: suggestion : /oracle/P10/oraarch/P10arch1_886187_638666197.dbf

ORA-00280: change 12324727338 for thread 1 is in sequence #886187

ORA-00278: log file '/oracle/P10/oraarch/P10arch1_886186_638666197.dbf' no

longer needed for this recovery

ORA-00279: change 12324728068 generated at 11/21/2010 14:37:38 needed for

thread 1

ORA-00289: suggestion : /oracle/P10/oraarch/P10arch1_886188_638666197.dbf

ORA-00280: change 12324728068 for thread 1 is in sequence #886188

ORA-00278: log file '/oracle/P10/oraarch/P10arch1_886187_638666197.dbf' no

longer needed for this recovery

ORA-00279: change 12324728652 generated at 11/21/2010 14:37:48 needed for

thread 1

ORA-00289: suggestion : /oracle/P10/oraarch/P10arch1_886189_638666197.dbf

ORA-00280: change 12324728652 for thread 1 is in sequence #886189

ORA-00278: log file '/oracle/P10/oraarch/P10arch1_886188_638666197.dbf' no

longer needed for this recovery

ORA-00279: change 12324728953 generated at 11/21/2010 14:37:57 needed for

thread 1

ORA-00289: suggestion : /oracle/P10/oraarch/P10arch1_886190_638666197.dbf

ORA-00280: change 12324728953 for thread 1 is in sequence #886190

ORA-00278: log file '/oracle/P10/oraarch/P10arch1_886189_638666197.dbf' no

longer needed for this recovery

ORA-00308: cannot open archived log

'/oracle/P10/oraarch/P10arch1_886190_638666197.dbf'

ORA-27037: unable to obtain file status

IBM AIX RISC System/6000 Error: 2: No such file or directory

Additional information: 3

SQL>

-


if you see above screen shot

the db is recovered still archive log sequense Number : 886189 (P10arch1_886189_638666197.dbf').

So understanding DB is recovered till 886189.

But when i issue command at SQL prmpt as below

SQL> select max(sequence#) from v$archived_log where applied='YES';

MAX(SEQUENCE#)

-


885116

SQL>

-


I am failing understand , even thought it is recoverd till 886189 , Why it is showing still 885116.

This observation we did for 1 day, when we try to recover with command it is recovering,

But applied shows the same.

-


We request to post their view / comments - Why this applied Sequence Number is differ than applied ?Rgds

PR

###########################################################################

GENERAL INFORMATION - BEGINING

###########################################################################

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

To bring standby database into managed recovery mode

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

1) Telnet to DRSERVER as root

2) lsnrctl start

3) sqlplus "/ as sysdba" as ora<sid>

4) startup nomount;

5) alter database mount standby database;

6) recover managed standby database disconnect;

7) exit

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

TO RECOVER MANUALLY

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

1) Telnet to DRSERVER as root

2) lsnrctl start

3) sqlplus "/ as sysdba" as "ora<sid>

4) startup nomount;

5) alter database mount standby database;

6) recover standby database;

7) recover managed standby database disconnect;

(after recovery completed & to put into MRM Mode)

😎 exit

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

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

TO CHECK APPLIED ARCHIVE LOGS

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

SQL> select max(sequence#) from v$archived_log where applied='YES';

###########################################################################

GENERAL INFORMATION - END

Accepted Solutions (1)

Accepted Solutions (1)

Former Member
0 Kudos

Hi PR,

For manual recovered history I think you have to look at v$log_history instead of v$archived_log.

And as far I know manual recovery never writes logs in v$archived_log, you have to check log_history or alertlog file.

What it says?

Regards,

Nick Loy

Answers (4)

Answers (4)

Former Member
0 Kudos

Hi,

There is always confusion on V$archived_log... but that wrong..

Use v$loghist OR v$log_history..

select max(SEQUENCE#) from v$log_history;

Thats all u need.

stefan_koehler
Active Contributor
0 Kudos

Hello Srinivas,

please check metalink note #263994.1 for your issue.

Regards

Stefan

Former Member
0 Kudos

Issue the below command in standbay database.

SELECT MAX(SEQUENCE#)-3 SEQUENCE# FROM V$ARCHIVED_LOG WHERE NAME <> 'SBY'

Substitute 'SBY' with your standby database name.

Regards

Sivakumar.R

Former Member
0 Kudos

can you please execute below command. and whats the DELAY to apply logs to your server?

SELECT ARCHIVED_THREAD#, ARCHIVED_SEQ#, APPLIED_THREAD#, APPLIED_SEQ# FROM V$ARCHIVE_DEST_STATUS;

pr_srinivas
Contributor
0 Kudos

Sunilll..Good Day

Thanks for your reply.

SQL> SELECT ARCHIVED_THREAD#, ARCHIVED_SEQ#, APPLIED_THREAD#, APPLIED_SEQ# FROM V$ARCHIVE_DEST_STATUS;

ARCHIVED_THREAD# ARCHIVED_SEQ# APPLIED_THREAD# APPLIED_SEQ#

-


1 907602 0 0

1 907602 1 886189

0 0 0 0

0 0 0 0

0 0 0 0

0 0 0 0

0 0 0 0

0 0 0 0

0 0 0 0

0 0 0 0

10 rows selected.

SQL>

-


It shows the cuurent sequence number as applied.

How to interpert this commands output ...Could U please explain

Rgds

PR