1. 程式人生 > >log_archive_dest_1設置報錯

log_archive_dest_1設置報錯

dbd hive acl redo arch article edi bho log

DG搭建完之後,又報錯:
Tue Dec 22 16:24:33 2015
Errors in file /u01/app/oracle/admin/orcl/bdump/orcl_arc1_2994.trc:
ORA-16014: log 8 sequence# 20 not archived, no available destinations
ORA-00312: online log 8 thread 2: '/u01/app/orcl/onlinelog/stdby_redo8.log'

查看文件:

[[email protected] datafile]# cat /u01/app/oracle/admin/orcl/bdump/orcl_arc1_2994.trc
/u01/app/oracle/admin/orcl/bdump/orcl_arc1_2994.trc
Oracle Database 10g Enterprise Edition Release 10.2.0.4.0 - 64bit Production
With the Partitioning, OLAP, Data Mining and Real Application Testing options
ORACLE_HOME = /u01/app/oracle/product/10.2.0/dbhome_1
System name:    Linux
Node name:      dbdg
Release:        2.6.18-308.el5
Version:        #1 SMP Fri Jan 27 17:17:51 EST 2012
Machine:        x86_64
Instance name: orcl
Redo thread mounted by this instance: 1
Oracle process number: 17
Unix process pid: 2994, image: [email protected]
/* */ (ARC1) *** 2015-12-22 14:39:33.083 *** SERVICE NAME:() 2015-12-22 14:39:33.083 *** SESSION ID:(1640.1) 2015-12-22 14:39:33.083 *** 2015-12-22 14:39:33.083 21373 kcrr.c *** 2015-12-22 14:49:33.102 *** 2015-12-22 14:49:33.102 21373 kcrr.c *** 2015-12-22 14:59:33.123 *** 2015-12-22 14:59:33.123 21373 kcrr.c *** 2015-12-22 15:09:33.143 *** 2015-12-22 15:09:33.143 21373 kcrr.c *** 2015-12-22 15:19:33.163 *** 2015-12-22 15:19:33.163 21373 kcrr.c *** 2015-12-22 15:24:33.176 ARCH: Connecting to console port... ARCH: Connecting to console port... *** 2015-12-22 15:24:33.176 21373 kcrr.c ORA-16014: log 8 sequence# 20 not archived, no available destinations ORA-00312: online log 8 thread 2: '/u01/app/orcl/onlinelog/stdby_redo8.log' *** 2015-12-22 15:33:49.457 *** 2015-12-22 15:33:49.457 21420 kcrr.c *** 2015-12-22 15:34:33.197 ARCH: Connecting to console port... ARCH: Connecting to console port... *** 2015-12-22 15:34:33.197 21373 kcrr.c ORA-16014: log 8 sequence# 20 not archived, no available destinations ORA-00312: online log 8 thread 2: '/u01/app/orcl/onlinelog/stdby_redo8.log' *** 2015-12-22 15:44:33.215 *** 2015-12-22 15:44:33.215 21373 kcrr.c *** 2015-12-22 15:54:33.235 *** 2015-12-22 15:54:33.235 21373 kcrr.c *** 2015-12-22 16:04:33.254 *** 2015-12-22 16:04:33.254 21373 kcrr.c *** 2015-12-22 16:14:33.272 *** 2015-12-22 16:14:33.272 21373 kcrr.c *** 2015-12-22 16:19:33.281 ARCH: Connecting to console port... ARCH: Connecting to console port... *** 2015-12-22 16:19:33.281 21373 kcrr.c ORA-16014: log 8 sequence# 20 not archived, no available destinations ORA-00312: online log 8 thread 2: '/u01/app/orcl/onlinelog/stdby_redo8.log' *** 2015-12-22 16:24:33.291 ARCH: Connecting to console port... ARCH: Connecting to console port... *** 2015-12-22 16:24:33.291 21373 kcrr.c ORA-16014: log 8 sequence# 20 not archived, no available destinations ORA-00312: online log 8 thread 2: '/u01/app/orcl/onlinelog/stdby_redo8.log'

說的挺明顯,就是歸檔路徑有問題,

路徑下沒有歸檔:

[[email protected] orcl]# ll
total 0
查看參數:

log_archive_dest_1                   string      LOCATION=/u01/app/oracle/orcl
                                                 VALID_FOR=(ALL_LOGFILES,ALL_RO
                                                 LES) DB_UNIQUE_NAME=orcl

原來是DB_UNIQUE_NAME指定錯誤。

改動:

SQL>  alter system set log_archive_dest_1='LOCATION=/u01/app/oracle/orcl VALID_FOR=(ALL_LOGFILES,ALL_ROLES) DB_UNIQUE_NAME=orcldg' scope=both;

System altered.

歸檔路徑生成了歸檔

[[email protected] orcl]# ll
total 1436
-rw-r----- 1 oracle oinstall  174592 Dec 22 16:49 1_22_899013364.dbf
-rw-r----- 1 oracle oinstall    1024 Dec 22 16:49 1_28_899013364.dbf
-rw-r----- 1 oracle oinstall   98304 Dec 22 16:49 1_29_899013364.dbf

原來。log_archive_dest_1指定本機db_unique_name.

log_archive_dest_1設置報錯