12c archive_lag_targe强制日志切换

12c R1测试环境

ARCHIVE_LAG_TARGET forces a log switch after the specified amount of time elapses.

A 0 value disables the time-based thread advance feature; otherwise, the value represents the number of seconds. Values larger than 7200 seconds are not of much use in maintaining a reasonable lag in the standby database. The typical, or recommended value is 1800 (30 minutes). Extremely low values can result in frequent log switches, which could degrade performance; such values can also make the archiver process too busy to archive the continuously generated logs.
建议半个小时到1个小时切换一次,以下为了做实验测试,设置了60秒。

SQL> show parameter lag

NAME                                 TYPE        VALUE
------------------------------------ ----------- ------------------------------
archive_lag_target                   integer     0
client_result_cache_lag              big integer 3000
plsql_ccflags                        string
SQL> alter system set archive_lag_target=60;  --单位秒

System altered.

SQL> show parameter archive_lag_target;

NAME                                 TYPE        VALUE
------------------------------------ ----------- ------------------------------
archive_lag_target                   integer     60
SQL> select name,COMPLETION_TIME from v$archived_log where name is not null order by COMPLETION_TIME desc ;

NAME                                                         COMPLETION_TIME
------------------------------------------------------------ -------------------
+DATADG/arch/log_1_406_961866198_585bafa7.arc                2018-01-25 12-04-59
+DATADG/arch/log_1_405_961866198_585bafa7.arc                2018-01-25 12-03-59
...................省略

原文地址:http://blog.51cto.com/roidba/2064983

时间: 2024-11-09 05:56:08

12c archive_lag_targe强制日志切换的相关文章

12c Oracle ADG日志切换hang

一.环境12c ADG环境 二.现象描述 主库日志切换卡住(hang) SQL> alter system switch logfile; 三.处理过程1.查看日志 <roidb02:orcldg:/u01/app/oracle/diag/rdbms/orcldg/orcldg/trace>$tail -f al*.log Mon Jan 08 21:04:20 2018 ARC0: LGWR is scheduled to archive destination LOG_ARCHIVE

【翻译自mos文章】Oracle db 12c中,每次日志切换时,会改变alert_sid.log的权限

12c中,每次日志切换时,会改变alert_sid.log的权限 来源于: Alert log file's permissions Change with every log switch in 12c (Doc ID 1637367.1) 适用于: Oracle Database - Enterprise Edition - Version 12.1.0.1 and later Information in this document applies to any platform. 症状:

HA模式强制手动切换:IPC&#39;s epoch [X] is less than the last promised epoch [X+1]

016-11-30 21:13:14,637 WARN org.apache.hadoop.hdfs.qjournal.client.QuorumJournalManager: Remote journal 192.168.58.183:8485 failed to write txns 54560-54560. Will try to write to this JN again after the next log roll. at org.apache.hadoop.hdfs.qjourn

Oracle redo 日志切换时间频率

DB: 11.2.0.3.0 查看Oracle的redo日志切换频率 两条SQL,原理是一样的,第二个用到了统计函数 时间单位:分钟 方法一. select * from v$log a where a.THREAD# = 1 ; set line 200select b.SEQUENCE#, b.FIRST_TIME,a.SEQUENCE#,a.FIRST_TIME,round(((a.FIRST_TIME-b.FIRST_TIME)*24)*60,2) from v$log_history

日志切换

http://blog.chinaunix.net/uid-16362696-id-3472265.html [[email protected] logrotate.d]# cat message /var/log/messages { daily dateext copytruncate nocompress rotate 15 } [[email protected] logrotate.d]# pwd /etc/logrotate.d 日志切换:[[email protected] lo

SqlServer 错误日志切换和查看

Sql Server 日志 和 代理错误日一般在实例重新启动后自己主动切换,假设实例久未重新启动,将可能积累太多的日志,不方便查看. 查看错误日志大小: --查看日志大小 EXEC xp_enumerrorlogs --sqlserver错误日志 EXEC xp_enumerrorlogs 1 --sqlserver错误日志 EXEC xp_enumerrorlogs 2 --代理日志 日志切换:(须要权限: sysadmin 固定server角色的成员) -- "Sql Server 日志&q

关于mongodb读写分离 及 日志切换

mongodb的读写分离使用Replica Sets来实现 对于replica set 中的secondary 节点默认是不可读的.在写多读少的应用中,使用Replica Sets来实现读写分离.通过在连接时指定或者在主库指定slaveOk,由Secondary来分担读的压力,Primary只承担写操作. 如果通过shell访问mongo,要在secondary进行查询.会出现如下错误:imageSet:SECONDARY> db.fs.files.find()error: { "$err

MongoDB 日志切换(Rotate Log Files)实战

1. 在mongo shell下,执行logRotate命令: use admin     db.runCommand({logRotate:1}) 需要在mongos,mongod,config server运行. 该方式的变种: a) 在unix shell下运行: mongo localhost/admin –eval "dbo.runCommand({logRotate:1})" b) 在unix shell下运行: mongo localhost/admin –eval &q

Oracle查看每小时日志切换量脚本

---- Show the Number of Redo Log Switches Per Hour-- SET PAUSE ONSET PAUSE 'Press Return to Continue'SET PAGESIZE 60SET LINESIZE 300 SELECT to_char(first_time, 'yyyy - mm - dd') aday,           to_char(first_time, 'hh24') hour,           count(*) tot