<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	>

<channel>
	<title>惜分飞 &#187; sqlplus 登录慢</title>
	<atom:link href="https://www.xifenfei.com/tag/sqlplus-%e7%99%bb%e5%bd%95%e6%85%a2/feed" rel="self" type="application/rss+xml" />
	<link>https://www.xifenfei.com</link>
	<description>提供7*24专业数据库(Oracle,SQL Server,MySQL,PostgreSQL等)恢复和技术支持@Tel:17813235971</description>
	<lastBuildDate>Sat, 07 Nov 2026 15:45:44 +0000</lastBuildDate>
	<language>zh-CN</language>
		<sy:updatePeriod>hourly</sy:updatePeriod>
		<sy:updateFrequency>1</sy:updateFrequency>
	
	<item>
		<title>19c sqlplus / as sysdba 登录慢分析</title>
		<link>https://www.xifenfei.com/2021/10/19c-sqlplus-as-sysdba-login-slow.html</link>
		<comments>https://www.xifenfei.com/2021/10/19c-sqlplus-as-sysdba-login-slow.html#comments</comments>
		<pubDate>Thu, 28 Oct 2021 16:22:37 +0000</pubDate>
		<dc:creator><![CDATA[惜分飞]]></dc:creator>
				<category><![CDATA[ORACLE 19C]]></category>
		<category><![CDATA[sqlplus dns]]></category>
		<category><![CDATA[sqlplus 登录慢]]></category>

		<guid isPermaLink="false">https://www.xifenfei.com/?p=9465</guid>
		<description><![CDATA[联系：手机/微信(+86 17813235971) QQ(107644445)  &#8230; <a href="https://www.xifenfei.com/2021/10/19c-sqlplus-as-sysdba-login-slow.html">继续阅读 <span class="meta-nav">&#8594;</span></a>]]></description>
				<content:encoded><![CDATA[<div id="xifenfeicopyright">
<p>联系：<a href="https://www.xifenfei.com/about_xifenfei" target="_blank">手机/微信(+86 17813235971)   QQ(107644445)</a><a target="_blank" href="http://wpa.qq.com/msgrd?v=3&#038;uin=107644445&#038;site=qq&#038;menu=yes"><img src="https://www.xifenfei.com/wp-content/themes/img/site_qq.jpg" alt="QQ咨询惜分飞" title="QQ咨询惜分飞"/></a></p>
<p>标题：<a href="https://www.xifenfei.com/2021/10/19c-sqlplus-as-sysdba-login-slow.html" target="_blank">19c sqlplus / as sysdba 登录慢分析</a></p>
<p>作者：<a href="https://www.xifenfei.com" target="_blank">惜分飞</a>©版权所有[未经本人同意,不得以任何形式转载,否则有进一步追究法律责任的权利.]</p>
</div>
<p>sqlplus / as sysdba登录非常慢</p>
<pre class="brush: bash; title: ; notranslate">
[oracle@xifenfei trace]$ date
Fri Oct 29 00:04:27 CST 2021
[oracle@xifenfei trace]$ sqlplus / as sysdba&lt;&lt; EOF
&gt; exit;
&gt; EOF

SQL*Plus: Release 19.0.0.0.0 - Production on Fri Oct 29 00:04:28 2021
Version 19.3.0.0.0

Copyright (c) 1982, 2019, Oracle.  All rights reserved.



Connected to:
Oracle Database 19c Enterprise Edition Release 19.0.0.0.0 - Production
Version 19.3.0.0.0

SQL&gt; Disconnected from Oracle Database 19c Enterprise Edition Release 19.0.0.0.0 - Production
Version 19.3.0.0.0
[oracle@xifenfei trace]$ date
Fri Oct 29 00:04:49 CST 2021
</pre>
<p>sqlpus 一个简单的登录+退出使用了22秒,严重的慢,通过strace分析发现访问以下两个ip，但是10.11.0.41非常慢,10.13.0.41很快，并且通过一些信息53端口,判断可能是dns服务器的ip</p>
<pre class="brush: bash; title: ; notranslate">
connect(9, {sa_family=AF_INET, sin_port=htons(53), sin_addr=inet_addr(&quot;10.13.0.41&quot;)}, 16) = 0

connect(12, {sa_family=AF_INET, sin_port=htons(53), sin_addr=inet_addr(&quot;10.11.0.41&quot;)}, 16) = 0
</pre>
<p>进一步确认,确认是该服务器配置的dns服务器</p>
<pre class="brush: bash; title: ; notranslate">
[root@xifenfei ~]# cat /etc/resolv.conf
# Generated by NetworkManager
nameserver 10.13.0.41
nameserver 10.11.0.41
</pre>
<p>对这两个ip的连通性进行测试</p>
<pre class="brush: bash; title: ; notranslate">
[root@xifenfei ~]# ping 10.13.0.41
PING 10.13.0.41 (10.13.0.41) 56(84) bytes of data.
64 bytes from 10.13.0.41: icmp_seq=1 ttl=126 time=0.616 ms
^C
--- 10.13.0.41 ping statistics ---
1 packets transmitted, 1 received, 0% packet loss, time 0ms
rtt min/avg/max/mdev = 0.616/0.616/0.616/0.000 ms
[root@xifenfei ~]# ping  10.11.0.41
PING 10.11.0.41 (10.11.0.41) 56(84) bytes of data.
^C
--- 10.11.0.41 ping statistics ---
3 packets transmitted, 0 received, 100% packet loss, time 2063ms

[root@xifenfei ~]# 
</pre>
<p>确认10.11.0.41 ip不通,对于此类问题最快的解决方案就是除掉不可使用的dns服务器,然后测试登录和退出时间</p>
<pre class="brush: bash; title: ; notranslate">
[oracle@xifenfei trace]$ date
Fri Oct 29 00:21:12 CST 2021
[oracle@xifenfei trace]$ sqlplus / as sysdba&lt;&lt; EOF
&gt; exit;
&gt; EOF

SQL*Plus: Release 19.0.0.0.0 - Production on Fri Oct 29 00:21:12 2021
Version 19.3.0.0.0

Copyright (c) 1982, 2019, Oracle.  All rights reserved.

date

Connected to:
Oracle Database 19c Enterprise Edition Release 19.0.0.0.0 - Production
Version 19.3.0.0.0

SQL&gt; Disconnected from Oracle Database 19c Enterprise Edition Release 19.0.0.0.0 - Production
Version 19.3.0.0.0
[oracle@xifenfei trace]$ date
Fri Oct 29 00:21:13 CST 2021
</pre>
<p>通过除掉不可用的dns服务器ip之后,测试时间为1s,恢复正常</p>
<div id="crp_related"><ul><li style="list-style-type:decimal;font-size:11px;" ><a href="https://www.xifenfei.com/2020/10/ora-01034-ora-27101.html" rel="bookmark" class="crp_title">ORA-01034 ORA-27101故障分析</a></li><li style="list-style-type:decimal;font-size:11px;" ><a href="https://www.xifenfei.com/2016/03/%e4%bf%ae%e6%94%b911-2-rac-%e7%9a%84-scan-ip.html" rel="bookmark" class="crp_title">修改11.2 RAC 的 SCAN IP</a></li><li style="list-style-type:decimal;font-size:11px;" ><a href="https://www.xifenfei.com/2023/10/no-tns-login-pdb.html" rel="bookmark" class="crp_title">非tns方式登录pdb方法</a></li><li style="list-style-type:decimal;font-size:11px;" ><a href="https://www.xifenfei.com/2012/02/%e8%bf%9c%e7%a8%8b%e8%ae%bf%e9%97%aeasm.html" rel="bookmark" class="crp_title">远程访问ASM</a></li><li style="list-style-type:decimal;font-size:11px;" ><a href="https://www.xifenfei.com/2025/02/connect-pdb-sid-use_sid_as_service_listener.html" rel="bookmark" class="crp_title">使用sid方式直接访问pdb(USE_SID_AS_SERVICE_LISTENER)</a></li><li style="list-style-type:decimal;font-size:11px;" ><a href="https://www.xifenfei.com/2011/10/sys%e7%94%a8%e6%88%b7%e5%af%86%e7%a0%81%e5%90%ab-sqlplus%e7%99%bb%e5%bd%95%e6%95%b0%e6%8d%ae%e5%ba%93%e8%af%a1%e5%bc%82%e4%ba%8b%e4%bb%b6%e5%88%86%e6%9e%90.html" rel="bookmark" class="crp_title">sys用户密码含$ sqlplus登录数据库诡异事件分析</a></li><li style="list-style-type:decimal;font-size:11px;" ><a href="https://www.xifenfei.com/2013/02/%e6%93%8d%e4%bd%9c%e7%b3%bb%e7%bb%9f%e7%ba%a7%e5%88%ab%e5%81%9asystemstate.html" rel="bookmark" class="crp_title">操作系统级别做systemstate</a></li><li style="list-style-type:decimal;font-size:11px;" ><a href="https://www.xifenfei.com/2015/06/ora-21561-oid-generation-failed%e6%95%85%e9%9a%9c%e8%a7%a3%e5%86%b3.html" rel="bookmark" class="crp_title">ORA-21561: OID generation failed故障解决</a></li><li style="list-style-type:decimal;font-size:11px;" ><a href="https://www.xifenfei.com/2012/02/sqlplus%e7%89%88%e6%9c%ac%e4%b8%8d%e6%ad%a3%e7%a1%ae%ef%bc%8c%e5%af%bc%e8%87%b4ora-12560.html" rel="bookmark" class="crp_title">sqlplus版本不正确，导致ORA-12560</a></li><li style="list-style-type:decimal;font-size:11px;" ><a href="https://www.xifenfei.com/2011/11/data-pump-%e4%b8%adnetwork_link%e5%8f%82%e6%95%b0%e7%9a%84%e4%bd%bf%e7%94%a8%e7%bb%ad%e7%99%bb%e5%bd%95%e7%94%a8%e6%88%b7%e5%92%8c%e6%ba%90%e7%ab%af%e7%94%a8%e6%88%b7%e4%b8%8d%e4%b8%80%e8%87%b4.html" rel="bookmark" class="crp_title">Data pump 中network_link参数的使用续(登录用户和源端用户不一致处理)</a></li><li style="list-style-type:decimal;font-size:11px;" ><a href="https://www.xifenfei.com/2016/07/ora-28040-no-matching-authentication-protocol.html" rel="bookmark" class="crp_title">ORA-28040: No matching authentication protocol</a></li><li style="list-style-type:decimal;font-size:11px;" ><a href="https://www.xifenfei.com/2021/12/impdp-transform.html" rel="bookmark" class="crp_title">impdp TRANSFORM参数</a></li></ul></div>]]></content:encoded>
			<wfw:commentRss>https://www.xifenfei.com/2021/10/19c-sqlplus-as-sysdba-login-slow.html/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
	</channel>
</rss>
