[zt] Log actively being archived by another process

本文探讨了Oracle数据库中归档进程ARC1归档失败的问题,详细分析了当多个归档进程同时尝试归档同一日志文件时所遇到的kcrrlt锁竞争问题,并提供了相关参数设置建议。

Alert中内容:

Mon Sep 03 10:12:44 2007
ARC0: Evaluating archive log 3 thread 1 sequence 31
ARC0: Beginning to archive log 3 thread 1 sequence 31
Creating archive destination LOG_ARCHIVE_DEST_1: 'D:ORACLEORADATAECOARCHIVE1_31.DBF'
Mon Sep 03 10:12:47 2007
Thread 1 advanced to log sequence 33
Current log# 1 seq# 33 mem# 0: D:ORACLEORADATAECOREDO01.LOG
Current log# 1 seq# 33 mem# 1: E:ECO_DATAREDO01B.LOG
Mon Sep 03 10:12:47 2007
ARC1: Evaluating archive log 3 thread 1 sequence 31
ARC1: Unable to archive log 3 thread 1 sequence 31
Log actively being archived by another process


回想那个时间刚好执行alter system switch logfile执行了手工日志切换.另外itpub上有人也反映在使用rman执行backup加选项plus archivelog 时候会出现.

原因在于启动了多于1个的归档进程,而每个归档进程都尝试对日志文件进行归档,由于没有获得kcrrlt锁而失败,这个锁是用来保护多个归档进程归档同一日志文件,失败的归档进程将写报警信息到警告日志。

system@ECO> show parameter log_archive_max_processes

NAME TYPE VALUE
------------------------------------ ---------------------- ------------------------------
log_archive_max_processes integer 2

一些深入研究参考链接:

http://www.eygle.com/archives/2007/06/log_archive_process.html
http://www.eygle.com/archives/2007/06/log_archive_process_more.html
http://www.itpub.net/276117.html
http://www.dbcool.net/oracle/070729/9513/

 

 

 

---------------------------------------------------------------------- 

 

 

 

Tom的解释

AlertSID.log中出现ARC1: Failed to archive log# 2 seq# 295
在alertSID.log中,出现:
Tue Jun 26 11:38:37 2001
ARC1: Beginning to archive log# 2 seq# 295
Tue Jun 26 11:38:37 2001
ARC1: Failed to archive log# 2 seq# 295
ARC1: Beginning to archive log# 1 seq# 296
ARC1: Failed to archive log# 1 seq# 296
Tue Jun 26 11:38:37 2001
ARC2: Beginning to archive log# 2 seq# 295
ARC2: Failed to archive log# 2 seq# 295


and we said...
It is just a side effect of having more then one archiver.

If automatic archiving is turned on then all of the archiver process will try to archive this logfile, however they will not be able to aquire the lock 'kcrrlt',the lock to protect multiple arch processes from archiving the same logfile.

The failing process process will write to the trace/alert message that it was
unable to archive the logfile.

The file is successfully archived by some other process.

In 9i, this message is a little more informative:

ARC1: Beginning to archive log# 2 thrd# 1 seq# 24
ARC1: Unable to archive log# 2 thrd# 1 seq# 24
Log actively being archived by another process

相关参数
LOG_ARCHIVE_TRACE controls output generated by the archivelog process.

This process can be initiated by any of the following:

An ARCn background process (designated as ARCn in the output logs)
An explicit session-invoked foreground process (designated as ARCH in the output logs)
The valid values have the following meanings:

0: Disable archivelog tracing (this is the default)
1: Track archival of redo log file
2: Track archival status of each archivelog destination
4: Track archival operational phase
8: Track archivelog destination activity
16: Track detailed archivelog destination activity
32: Track archivelog destination parameter modifications
64: Track ARCn process state activity
128: Track FAL (fetch archived log) server related activities
You can combine tracing levels by adding together the values of the desired tracing levels.
For example, a setting of 3 will generate level 1 and level 2 trace output.
You can set different values for the primary and standby database.

When this parameter is set to the default value of 0, Oracle will still generate appropriate alert and trace
entries in response to error conditions.
If you change the value of this parameter dynamically in an ALTER SYSTEM statement,
the changes will take effect at the start of the next archivelog operation.


LOG_ARCHIVE_MAX_PROCESSES specifies the number of archiver background processes (ARC0 through ARC9)
Oracle initially invokes.

If the LOG_ARCHIVE_START initialization parameter has the value true, then this value is evaluated at instance startup.
Otherwise, this parameter is evaluated when the archiver process is first invoked by SQL*Plus or SQL syntax.
The actual number of archiver processes in use may vary subsequently based on archive workload.

 

 

来自 “ ITPUB博客 ” ,链接:http://blog.itpub.net/35489/viewspace-561458/,如需转载,请注明出处,否则将追究法律责任。

转载于:http://blog.itpub.net/35489/viewspace-561458/

### ESP32 连接被目标机主动拒绝的原因分析 当遇到 `connection refused` 错误时,通常表示目标机器上的服务未运行、端口未开放或者防火墙阻止了连接请求。以下是可能原因及其解决方案: #### 1. **目标服务器的服务状态** 如果目标服务器上对应的服务未启动,则会返回 `connection refused` 的错误消息。可以通过以下方法验证并解决问题: - 使用命令行工具检查目标主机的服务是否正在监听指定端口[^1]。 ```bash netstat -tuln | grep <port> ``` - 如果发现该端口未被监听,需确认服务已正确配置并启动。 #### 2. **网络地址转换 (NAT) 和防火墙设置** ESP32 设备通过 NAT 或 Masquerading 访问外部网络时,需要启用 `CONFIG_IP_NF_CONNTRACK` 模块来支持连接跟踪功能。此模块对于实现防火墙规则以及管理内部局域网设备访问至关重要。因此,在固件编译阶段应确保启用了相关选项。 #### 3. **DNS 配置问题** 有时 DNS 解析失败也会导致无法建立连接。可以尝试手动解析域名 IP 地址,并测试直连情况。利用 `dig` 命令执行区域传输查询可以帮助排查是否存在 DNS 权威记录缺失的情况[^2]: ```bash dig @<domain_of_name_server> <target_domain> axfr ``` #### 4. **代码逻辑中的超时处理** 在编写 ESP32 应用程序时,应当加入合理的重试机制和异常捕获流程以应对瞬态错误。下面是一个简单的 TCP 客户端示例代码片段展示如何优雅地处理此类场景: ```c #include <WiFi.h> void setup() { WiFi.begin("SSID", "PASSWORD"); while (WiFi.status() != WL_CONNECTED) delay(500); } bool connectToServer(const char* host, uint16_t port){ WiFiClient client; int retries = 5; while(retries--){ if(client.connect(host,port)){ Serial.println("Connected!"); return true; } Serial.print("."); delay(1000); } Serial.println("\nConnection failed."); return false; } ``` 以上内容涵盖了从基础到高级层面可能导致 `connection refused` 的因素及对应的修复措施。
评论
成就一亿技术人!
拼手气红包6.0元
还能输入1000个字符  | 博主筛选后可见
 
红包 添加红包
表情包 插入表情
 条评论被折叠 查看
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值