DataGuard-Haupt- und Sicherungsarchive existieren als Lückenverarbeitungsmethode

 
  
Aus Netzwerk- und anderen Gründen können die Archivprotokolle zwischen der Standby-Datenbank und der aktiven Datenbank zwischen den aktiven und den Standby-Geräten von DataGuard inkonsistent sein, was zu Lücken führt.
Schritte zum Beheben der Lücke:
1. Erhalten Sie die detaillierten Informationen zur Lücke in der Standby-Datenbank.
2. Kopieren Sie die erforderlichen Archivprotokolle aus der Hauptdatenbank in die Standby-Datenbank.
3. Registrieren Sie die Archivprotokolle in der Standby-Datenbank und wenden Sie sie an.
 
- Das Alarmprotokoll fordert Lücken-Details im Sicherungsprotokoll auf.  
Medienwiederherstellung Warten auf Thread 1-Sequenz 7057
Abrufen der Lücken-Sequenz in Thread 1, Lücken-Sequenz 7057-7080
FAL [Client]: Fehler beim Abrufen der Lücken-Sequenz, kein FAL-Server angegeben
Mo Mar 24 11:39: 40 CST 2014
FAL [Client]:
 Lückensequenz konnte
 nicht angefordert werden  GAP-Thread 1-Sequenz 7057-7080 DBID 768411208 Zweig 784810891
FAL [Client]: Alle definierten FAL-Server wurden versucht. -

Sie können auch die Lückenauswahl
* aus der Standby-Datenbank abfragen v $ archive_gap; - Zusammenstellung von Kopieranweisungen

zur Vereinfachung
- Wenn sich das Archivprotokoll in ASM befindet, kopieren Sie zuerst das Archivprotokoll über rman in das Betriebssystem und scp dann in das Standby-Archivverzeichnis der Standby-Datenbank. --Wenn sich das
Archivprotokoll im Betriebssystem befindet, scp direkt in das Standby-Archivverzeichnis der Standby-Datenbank.
@Pirmary
Länge auswählen ('+ DG1 / primary / archivelog / 2014_03_21 /') von dual;
LENGTH ('+ DG1 / PRIMARY / ARCHIVELOG / 2014_03_21 /')
---------------- -----------------------------
                                           35
  
--get copy Befehl
select 'copy archivelog' '' || NAME || '' ' zu '' / tmp / '|| substr (name, 35) ||' ''; ' 
von v $ archived_log 
wobei SEQUENCE #> 7060 
und SEQUENCE # <= 7080 
und thread # = 1 
und NAME <>' Standby-Dienstname ';



Kopieren Sie das Archivprotokoll '+ DG1 / primary / archivelog / 2014_03_21 / thread_1_seq_7061.393.842805877' nach '/tmp/thread_1_seq_7061.393.842805877';
Kopieren Sie das Archivprotokoll '+ DG1 / primary / archivelog / 2014_03_21 / thread_1_seq_7062.472.842816319' nach '/tmp/thread_1_seq_7062.472.842816319';
Archivprotokoll '+ DG1 / primary / archivelog / 2014_03_21 / thread_1_seq_7063.414.842825435' nach '/tmp/thread_1_seq_7063.414.842825435' kopieren;
Archivprotokoll '+ DG1 / primary / archivelog / 2014_03_22 / thread_1_seq_7064.308.842843087' nach '/tmp/thread_1_seq_7064.308.842843087' kopieren;
Archivprotokoll '+ DG1 / primary / archivelog / 2014_03_22 / thread_1_seq_7065.278.842847011' nach '/tmp/thread_1_seq_7065.278.842847011' kopieren;
Archivprotokoll '+ DG1 / primary / archivelog / 2014_03_22 / thread_1_seq_7066.415.842847023' nach '/tmp/thread_1_seq_7066.415.842847023' kopieren;
Kopieren Sie das Archivprotokoll '+ DG1 / primary / archivelog / 2014_03_22 / thread_1_seq_7067.469.842850077' nach '/tmp/thread_1_seq_7067.469.842850077';
Kopieren Sie das Archivprotokoll '+ DG1 / primary / archivelog / 2014_03_22 / thread_1_seq_7068.402.842864915' nach '/tmp/thread_1_seq_7068.402.842864915';
Kopieren Sie das Archivprotokoll '+ DG1 / primary / archivelog / 2014_03_22 / thread_1_seq_7069.475.842868603' nach '/tmp/thread_1_seq_7069.475.842868603';
Archivprotokoll '+ DG1 / primary / archivelog / 2014_03_22 / thread_1_seq_7070.413.842869761' nach '/tmp/thread_1_seq_7070.413.842869761' kopieren;
Archivprotokoll '+ DG1 / primary / archivelog / 2014_03_22 / thread_1_seq_7071.312.842871319' nach '/tmp/thread_1_seq_7071.312.842871319' kopieren;
Archivprotokoll '+ DG1 / primary / archivelog / 2014_03_22 / thread_1_seq_7072.407.842874331' nach '/tmp/thread_1_seq_7072.407.842874331' kopieren;
Kopieren Sie das Archivprotokoll '+ DG1 / primary / archivelog / 2014_03_22 / thread_1_seq_7073.405.842874917' nach '/tmp/thread_1_seq_7073.405.842874917';
Kopieren des Archivprotokolls '+ DG1 / primary / archivelog / 2014_03_22 / thread_1_seq_7074.328.842875663' nach '/tmp/thread_1_seq_7074.328.842875663';
Kopieren Sie das Archivprotokoll '+ DG1 / primary / archivelog / 2014_03_22 / thread_1_seq_7075.296.842876043' nach '/tmp/thread_1_seq_7075.296.842876043';
Kopieren Sie das Archivprotokoll '+ DG1 / primary / archivelog / 2014_03_22 / thread_1_seq_7076.452.842886921' nach '/tmp/thread_1_seq_7076.452.842886921';
Archivprotokoll '+ DG1 / primary / archivelog / 2014_03_22 / thread_1_seq_7077.446.842906131' nach '/tmp/thread_1_seq_7077.446.842906131' kopieren;
Archivprotokoll '+ DG1 / primary / archivelog / 2014_03_23 / thread_1_seq_7078.348.842928271' nach '/tmp/thread_1_seq_7078.348.842928271' kopieren;
Kopieren Sie das Archivprotokoll '+ DG1 / primary / archivelog / 2014_03_23 / thread_1_seq_7079.347.842928277' nach '/tmp/thread_1_seq_7079.347.842928277';
Kopieren Sie das Archivprotokoll '+ DG1 / primary / archivelog / 2014_03_23 / thread_1_seq_7080.367.842929387' nach '/tmp/thread_1_seq_7080.367.842929387';





--get Standby Register Archivelog Befehl
- 同样 在 主 库 执行 , 获得 注册 语句 Wählen
Sie 'ALTER DATABASE REGISTER PHYSICAL LOGFILE' '/ tmp /' || substr (name, 35) || '' ';' von v $ archived_log wobei SEQUENCE #> 7060 und SEQUENCE # <= 7080 und Thread # = 1 und NAME <> 'Standby-Dienstname';

ALTER DATABASE REGISTER PHYSICAL LOGFILE '/tmp/thread_1_seq_7061.393.842805877';
ALTER DATABASE REGISTER PHYSICAL LOGFILE '/tmp/thread_1_seq_7062.472.842816319';
ALTER DATABASE REGISTER PHYSICAL LOGFILE '/tmp/thread_1_seq_7063.414.842825435';
ALTER DATABASE REGISTER PHYSICAL LOGFILE '/tmp/thread_1_seq_7064.308.842843087';
ALTER DATABASE REGISTER PHYSICAL LOGFILE '/tmp/thread_1_seq_7065.278.842847011';
ALTER DATABASE REGISTER PHYSICAL LOGFILE '/tmp/thread_1_seq_7066.415.842847023';
ALTER DATABASE REGISTER PHYSICAL LOGFILE '/tmp/thread_1_seq_7067.469.842850077';
ALTER DATABASE REGISTER PHYSICAL LOGFILE '/tmp/thread_1_seq_7068.402.842864915';
ALTER DATABASE REGISTER PHYSICAL LOGFILE '/tmp/thread_1_seq_7069.475.842868603';
ALTER DATABASE REGISTER PHYSICAL LOGFILE '/tmp/thread_1_seq_7070.413.842869761';
ALTER DATABASE REGISTER PHYSICAL LOGFILE '/tmp/thread_1_seq_7071.312.842871319';
ALTER DATABASE REGISTER PHYSICAL LOGFILE '/tmp/thread_1_seq_7072.407.842874331';
ALTER DATABASE REGISTER PHYSICAL LOGFILE '/tmp/thread_1_seq_7073.405.842874917';
ALTER DATABASE REGISTER PHYSICAL LOGFILE '/tmp/thread_1_seq_7074.328.842875663';
ALTER DATABASE REGISTER PHYSICAL LOGFILE '/tmp/thread_1_seq_7075.296.842876043';
ALTER DATABASE REGISTER PHYSICAL LOGFILE '/tmp/thread_1_seq_7076.452.842886921';
ALTER DATABASE REGISTER PHYSICAL LOGFILE '/tmp/thread_1_seq_7077.446.842906131';
ALTER DATABASE REGISTER PHYSICAL LOGFILE '/tmp/thread_1_seq_7078.348.842928271';
ALTER DATABASE REGISTER PHYSICAL LOGFILE '/tmp/thread_1_seq_7079.347.842928277';
ALTER DATABASE REGISTER PHYSICAL LOGFILE '/tmp/thread_1_seq_7080.367.842929387';



@Standby -
Registrieren Sie das Lückenarchivprotokoll im Standby-Modus.
ALTER DATABASE REGISTER PHYSICAL LOGFILE '/ tmp / thread_1_seq_7061.
ALTER DATABASE REGISTER PHYSICAL LOGFILE '/tmp/thread_1_seq_7062.472.842816319';
ALTER DATABASE REGISTER PHYSICAL LOGFILE '/tmp/thread_1_seq_7063.414.842825435';
ALTER DATABASE REGISTER PHYSICAL LOGFILE '/tmp/thread_1_seq_7064.308.842843087';
ALTER DATABASE REGISTER PHYSICAL LOGFILE '/tmp/thread_1_seq_7065.278.842847011';
ALTER DATABASE REGISTER PHYSICAL LOGFILE '/tmp/thread_1_seq_7066.415.842847023';
ALTER DATABASE REGISTER PHYSICAL LOGFILE '/tmp/thread_1_seq_7067.469.842850077';
ALTER DATABASE REGISTER PHYSICAL LOGFILE '/tmp/thread_1_seq_7068.402.842864915';
ALTER DATABASE REGISTER PHYSICAL LOGFILE '/tmp/thread_1_seq_7069.475.842868603';
ALTER DATABASE REGISTER PHYSICAL LOGFILE '/tmp/thread_1_seq_7070.413.842869761';
ALTER DATABASE REGISTER PHYSICAL LOGFILE '/tmp/thread_1_seq_7071.312.842871319';
ALTER DATABASE REGISTER PHYSICAL LOGFILE '/tmp/thread_1_seq_7072.407.842874331';
ALTER DATABASE REGISTER PHYSICAL LOGFILE '/tmp/thread_1_seq_7073.405.842874917';
ALTER DATABASE REGISTER PHYSICAL LOGFILE '/tmp/thread_1_seq_7074.328.842875663';
ALTER DATABASE REGISTER PHYSICAL LOGFILE '/tmp/thread_1_seq_7075.296.842876043';
ALTER DATABASE REGISTER PHYSICAL LOGFILE '/tmp/thread_1_seq_7076.452.842886921';
ALTER DATABASE REGISTER PHYSICAL LOGFILE '/tmp/thread_1_seq_7077.446.842906131';
ALTER DATABASE REGISTER PHYSICAL LOGFILE '/tmp/thread_1_seq_7078.348.842928271';
ALTER DATABASE REGISTER PHYSICAL LOGFILE '/tmp/thread_1_seq_7079.347.842928277';
ALTER DATABASE REGISTER PHYSICAL LOGFILE '/tmp/thread_1_seq_7080.367.842929387';

--wenn der Standby-Modus echt ist, wird der Standby-Modus AUTO Apply archivelog anwenden. - Wenn
dies nicht der Fall ist, öffnen Sie bitte den Real- 
Apply.

--get real apply info
set lineize 200
col name für a70
alter session set nls_date_format = 'jjjj-mm-tt hh24: mi: ss';
Wählen Sie NAME, THREAD #, FIRST_TIME, Sequenznummer, die aus der Reihenfolge v $ archived_log von FIRST_TIME, THREAD #, Sequenznummer, DEST_ID angewendet wird.

- Sie können das Warnprotokoll sehen, es zeigt auch das Archivprotokoll an. Informationen anwenden
tail -f alert.log -

Stellen Sie sicher, dass keine Lücke zwischen primärem und Standby-
SQL besteht.> Wählen Sie * aus v $ archive_gap aus.

--Clean
@Priamry
cd / tmp
rm thread_ *

RMAN> crosscheck archivelog all;
RMAN> Archivprotokoll auflisten alle;
RMAN> abgelaufenes Archivprotokoll alle löschen;
 

Ich denke du magst

Origin www.cnblogs.com/xiaoL/p/12682861.html
Empfohlen
Rangfolge