ORA-12537: Network Session: End of file
最近开发组同事使用Azure的Function App访问公司内部的Oracle数据库时,偶尔会遇到“ORA-12537: Network Session: End of file”这个错误。关于ORA-12537的详细信息如下:
[oracle@DB-Server ~]$ oerr ora 12537
12537, 00000, "TNS:connection closed"
// *Cause: "End of file" condition has been reached; partner has disconnected.
// *Action: None needed; this is an information message.
按照官方文档,引起ORA-12537的错误原因很多,如下所示:
ORA-12537 is an informational message and means that the connection has been closed. This error message can happen due to any of the following reasons:
- There are too many connections being open by the application.
- There are configuration issues in the sqlnet.ora, protocol.ora and listener.ora files.
- Database is shut down (maybe for nightly backup), but connection to database was kept by client.
- A timeout occurred on the client connection.
- A firewall closed idle connections.
- There is a path name that is too long for the Oracle TNS client on Windows. See Note:263489.1
一一分析、排除后,怀疑我设定的一个定期清理超过90分钟空闲会话的作业导致了这个问题,具体参考“ORACLE定期清理INACTIVE会话”,测试了一下,我们通过V$SESSION找到对应的会话,然后使用下面SQL终止会话。
SQL> ALTER SYSTEM DISCONNECT SESSION 'xxx,xxx' IMMEDIATE;
Azure的Function App测试验证发现报“ORA-12537: Network Session: End of file” 。注意:ALTER SYSTEM KILL SESSION 'xxx,xxx' IMMEDIATE;也是同样的错误。
但是如果你使用SQL*Plus等工具(使用SQL*Net连接数据库),测试发现报ORA-03113:通信通道的文件结尾“,而不是ORA-12537这个错误,如下所示:

查了一下官方文档关于Azure的Function(Function App)连接数据库的相关知识,因为连接池缘故,应用程序关闭会话后,连接池对应的数据库会话一直处于INACTIVE状态,而当达到条件时(空闲时间超过90分钟),就被作业清理掉,而此时如果Azure的Function应用再次访问数据库时,由于连接池的相关会话被清理掉了,从而报错。
ORA-12537: Network Session: End of file的更多相关文章
- 阿里云centos安装oracle
目录 阿里云centos安装oracle 阿里云默认没有swap分区,oracle安装需要 安装Oracle所需的依赖包 创建用户和组 关闭SELINUX(阿里云缺省关闭) 开始安装 使用" ...
- ORA-19566: exceeded limit of 0 corrupt blocks for file E:\xxxx\<datafilename>.ORA.
How to Format Corrupted Block Not Part of Any Segment (Doc ID 336133.1) To BottomTo Bottom In this D ...
- 【Azure 存储服务】如何把开启NFS 3.0协议的Azure Blob挂载在Linux VM中呢?(NFS: Network File System 网络文件系统)
问题描述 如何把开启NFS协议的Azure Blob挂载到Linux虚拟机中呢? [答案]:可以使用 NFS 3.0 协议从基于 Linux 的 Azure 虚拟机 (VM) 或在本地运行的 Linu ...
- How to Modify Public Network Information including VIP in Oracle Clusterware (文档 ID 276434.1)
APPLIES TO: Oracle Database - Enterprise Edition - Version 11.2.0.3 to 12.1.0.2 [Release 11.2 to 12. ...
- ORACLE RAC 下非缺省端口监听配置(listener.ora tnsnames.ora)
不论是单实例还是RAC,对于非缺省端口下(1521)的监听器,pmon进程不会将service/instance注册到监听器,即不会实现动态注册.与单实例相同,RAC非缺省端口的监听器也是通过设置参数 ...
- MatterTrack Route Of Network Traffic :: Matter
Python 1.1 基础 while语句 字符串边缘填充 列出文件夹中的指定文件类型 All Combinations For A List Of Objects Apply Operations ...
- ORA-01336: specified dictionary file cannot be opened
这篇介绍使用Logminer时遇到ORA-01336: specified dictionary file cannot be opened错误的各种场景 1:dictionary_location参 ...
- 【Debian】非法关机后无法联网 connect: network is unreachable
某一天,突然发现无法ssh登录虚拟机内的debian系统,一直认为是ssh的问题,然后无意间ping了ping百度,发现原来是debian系统没有联网....囧 首先,是虚拟机的网络设置检查. 打开V ...
- Linux Found a swap file by the name filename
在Linux中使用vi命令编辑mysql_backup.sh时遇到下面提示信息 E325: ATTENTION Found a swap file by the name ".mysql_b ...
随机推荐
- [Swift]LeetCode446. 等差数列划分 II - 子序列 | Arithmetic Slices II - Subsequence
A sequence of numbers is called arithmetic if it consists of at least three elements and if the diff ...
- [Swift]LeetCode794. 有效的井字游戏 | Valid Tic-Tac-Toe State
A Tic-Tac-Toe board is given as a string array board. Return True if and only if it is possible to r ...
- [Swift]LeetCode827. 最大人工岛 | Making A Large Island
In a 2D grid of 0s and 1s, we change at most one 0 to a 1. After, what is the size of the largest is ...
- python高级-装饰器(19)
一.什么是闭包 先看一个例子: #定义一个函数 def test(number): #在函数内部在定义一个函数,并且这个函数用到外围函数的变量 #那么将这个函数及用到的一些变量称之为闭包 def te ...
- scala调用Linux命令行
在 scala 里面存在 调用 Linux 命令行的函数: import scala.sys.process._ 执行的方法也不难: import scala.sys.process._ /** * ...
- Python爬虫入门教程 5-100 27270图片爬取
27270图片----获取待爬取页面 今天继续爬取一个网站,http://www.27270.com/ent/meinvtupian/ 这个网站具备反爬,so我们下载的代码有些地方处理的也不是很到位, ...
- 如何合理封装你的轮子、飞机、大炮(以封装OkHttp为例)
前言 对于程序员来说,很多时候,我们都在造房子,从学会框架或者是学会构建整个项目之后,慢慢的我们就会觉得自己在做的事情是一种重复劳动,很多时候只不过是换个面孔而已.而更快的造房子,造好看的房子可能是进 ...
- Kafka监控系统Kafka Eagle剖析
1.概述 最近有同学留言反馈了使用Kafka监控工具Kafka Eagle的一些问题,这里笔者特意整理了这些问题.并且希望通过这篇博客来解答这些同学的在使用Kafka Eagle的时候遇到的一些困惑, ...
- .NET Core中实现AOP编程
AOP全称Aspect Oriented Progarmming(面向切面编程),其实AOP对ASP.NET程序员来说一点都不神秘,你也许早就通过Filter来完成一些通用的功能,例如你使用Autho ...
- 免费报名 | 腾讯云自研数据库CynosDB交流会
本文由云+社区发表 作者:技术沙龙 All in 云+时代,数据库的高可用性.按需付费.按需扩展等属性解放了大批开发者.腾讯发布的自研数据库CynosDB作为国内首款同时兼容MySQL和PG的云原生数 ...