Skip to content

Fatih Acar's blog

About of Database Systems and Information Technologies

Menu
  • Home
  • About Me
  • Contact Me
Menu

How to Add Standby Logfile in Oracle

Posted on 10/03/201327/11/2015 by Fatih Acar

If you want to use real-time apply Oracle Data Guard, you have to add standby logfile to standby database.

Show Logfiles Before Add

SQL> select * from gv$logfile;

INST_ID GROUP# STATUS TYPE MEMBER IS_RECOVERY_DEST_FILE
1 3 ONLINE +DATA/testdb/onlinelog/group_3.14134123 NO
1 1 ONLINE +DATA/testdb/onlinelog/group_1.35116731 NO
1 2 ONLINE +DATA/testdb/onlinelog/group_2.32513245 NO
1 4 ONLINE +DATA/testdb/onlinelog/group_4.12255335 NO
1 2 ONLINE +FRA/testdb/onlinelog/group_2.13423425 YES
1 1 ONLINE +FRA/testdb/onlinelog/group_1.53242411 YES
1 3 ONLINE +FRA/testdb/onlinelog/group_3.34634123 YES
1 4 ONLINE +FRA/testdb/onlinelog/group_4.32525244 YES

Add Standby Logfile ASM

SQL> alter database add standby logfile ‘+DATA’ size 52428800;

Add Standby Logfile FileSystem

SQL> alter database add standby logfile ‘/oracle/db/datafile/standby_redo01.rdo’ size 52428800;


Show Logfiles After Add

SQL> select * from gv$logfile;

INST_ID GROUP# STATUS TYPE MEMBER IS_RECOVERY_DEST_FILE
1 3 ONLINE +DATA/testdb/onlinelog/group_3.14134123 NO
1 1 ONLINE +DATA/testdb/onlinelog/group_1.35116731 NO
1 2 ONLINE +DATA/testdb/onlinelog/group_2.32513245 NO
1 4 ONLINE +DATA/testdb/onlinelog/group_4.12255335 NO
1 2 ONLINE +FRA/testdb/onlinelog/group_2.13423425 YES
1 1 ONLINE +FRA/testdb/onlinelog/group_1.53242411 YES
1 3 ONLINE +FRA/testdb/onlinelog/group_3.34634123 YES
1 4 ONLINE +FRA/testdb/onlinelog/group_4.32525244 YES
1 5 STANDBY +DATA/testdb/onlinelog/group_5.42344234 NO
1 6 STANDBY +DATA/testdb/onlinelog/group_6.90895675 NO
1 8 STANDBY +DATA/testdb/onlinelog/group_8.45674886 NO
1 7 STANDBY +DATA/testdb/onlinelog/group_7.87456844 NO

Alter Data Guard To Real-Time Apply

SQL> alter database recover managed standby database using current logfile disconnect;

You can drop log file with below operation. Logfile status has to be ‘INACTIVE’ when you drop logfile. You can look status at v$log dictionary view.

Drop Logfile

SQL> alter database drop logfile group 8;

Share this:

  • Click to share on LinkedIn (Opens in new window) LinkedIn
  • Click to share on X (Opens in new window) X
  • Click to share on Facebook (Opens in new window) Facebook

Leave a Reply Cancel reply

Your email address will not be published. Required fields are marked *

Time limit is exhausted. Please reload CAPTCHA.



View Fatih ACAR's profile on LinkedIn

Categories

  • Databases (329)
    • MsSQL Server (18)
      • Administration (16)
      • Errors and Solutions (4)
      • SQL (2)
    • MySQL (5)
      • Administration (4)
      • Backup And Recovery (1)
      • Errors and Solutions (1)
    • Oracle (290)
      • Administration (79)
      • Backup And Recovery (29)
      • Errors and Solutions (195)
      • Procedure (10)
      • SQL (32)
    • PostgreSQL (16)
      • Administration (15)
      • Errors and Solutions (3)
      • SQL (2)
    • Redis (1)
  • Microsotf Dynamics CRM (1)
  • Operating Systems (47)
    • Linux & Unix (34)
    • Windows (13)
  • Programing (5)
    • Python (5)
  • SAP (15)
    • Errors and Solutions (4)
    • SAP Basis (12)
  • Security (8)
    • Database Security (6)
    • Information Security (1)
    • System Security (4)
  • VMware (4)

Recent Posts

  • Redis 7 Sentinel Infrastructure Installation
  • Oracle Database 19c Multi Data Guard and DML Redirect, Switchover-Failover Operations on Oracle Linux 8
  • Oracle Database 23ai Free Installation Steps on Oracle Linux 9
  • Oracle Database 19c Active Data Guard Installation and DML Redirect, Switchover-Failover Operations on Oracle Linux 8
  • Oracle Database 19c Installation and 19.22 RU Patch Apply on Oracle Linux 8

Resources

  • Oracle
  • PostgreSQL

Blogroll

  • Gökhan Atıl
  • H. Koray Gündüz
  • Hakan Talip Öztürk
  • Zekeriya Beşiroğlu

Web Pages

  • BT Çözümleri

Tag Cloud

Administration Backup and Recovery Cluster Systems Database Administration Database Security Linux Linux Administration MsSQL Server MsSQL Server Error and Solutions MySQL MySQL Administration ORA-00018 ORA-00020 Oracle Oracle 12c Oracle 19c Oracle Administration Oracle Backup and Restore Oracle Data Guard Oracle Data Guard Failover Oracle Data Guard Switchover Oracle Error Solutions Oracle Linux Oracle Rman Backup Oracle Security Oracle SQL Query PostgreSQL PostgreSQL Administration PostgreSQL High Availability PostgreSQL Hot Standby Python SAP Basis Sap Errors and Solutions Sap System Administration SQL SQL Server Administration SQL Server Availability Group Stored Procedure System Administration System Security VMware VMware Administration Windows Windows Batch Script Windows Server

Social

  • View facar1987’s profile on Twitter
  • View facar’s profile on LinkedIn

Subscribe to Blog via Email

Enter your email address to subscribe to this blog and receive notifications of new posts by email.

Join 17 other subscribers
©2026 Fatih Acar's blog | Built using WordPress and Responsive Blogily theme by Superb