Sqlplus logon slow due to/etc/resolv.conf configuration in Oracle

Source: Internet
Author: User
Tags mongodb postgresql redis reserved nameserver sqlplus firewall linux


Symptom Description:



Under Linux use Sqlplus Sys/oracle@prod as SYSDBA login is very slow, it takes about more than 10 seconds to log in successfully, use Sqlplus/as SYSDBA login database fast, second log.



Using the Sqlplus Sys/oracle@prod as SYSDBA login will be stuck in the following position for more than 10 seconds:



[Oracle@jp admin]$ Sqlplus Sys/oracle@prod



Sql*plus:release 10.2.0.1.0-production on Wed Mar 26 23:32:29 2014



Copyright (c) 1982, +, Oracle. All rights reserved.



Initial thought may be listening to this side of the problem, and then tnsping tried:



[Oracle@jp admin]$ tnsping PROD



TNS Ping Utility for linux:version 10.2.0.1.0-production on 27-mar-2014 09:11:30



Copyright (c) 1997, +, Oracle. All rights reserved.



Stuck for more than 10 seconds.



Used parameter files:



/u01/app/oracle/product/10.2.0/db_1/network/admin/sqlnet.ora



Used TNSNAMES Adapter to resolve the alias



Attempting to Contacts (description = (address= (protocol=tcp) (HOST=JP) (port=1521)) (connect_data= (server = dedicated) ( service_name = PROD))



OK (0 msec)



During the tnsping process, the location of the card was found to be



Used TNSNAMES Adapter to resolve the alias



Before, then the problem should be out before using tnsnames parsing,



After continuous viewing, the problem is found in the/etc/resolv.conf file:



The contents of the/etc/resolv.conf file are as follows:



NameServer 192.168.50.2



Search Localdomain



~



Found that nameserver is configured here, if the nameserver is configured, then Oracle will first verify the nameserver, the failure to timeout before the other way to connect. The timeout period is more than 10 seconds to 30 seconds.



Decisively comment out nameserver, and then try again, Sqlplus Sys/oracle@prod as SYSDBA login speed back to normal.



This column more highlights: http://www.bianceng.cnhttp://www.bianceng.cn/database/Oracle/


Alibaba Cloud Hot Products

Elastic Compute Service (ECS) Dedicated Host (DDH) ApsaraDB RDS for MySQL (RDS) ApsaraDB for PolarDB(PolarDB) AnalyticDB for PostgreSQL (ADB for PG)
AnalyticDB for MySQL(ADB for MySQL) Data Transmission Service (DTS) Server Load Balancer (SLB) Global Accelerator (GA) Cloud Enterprise Network (CEN)
Object Storage Service (OSS) Content Delivery Network (CDN) Short Message Service (SMS) Container Service for Kubernetes (ACK) Data Lake Analytics (DLA)

ApsaraDB for Redis (Redis)

ApsaraDB for MongoDB (MongoDB) NAT Gateway VPN Gateway Cloud Firewall
Anti-DDoS Web Application Firewall (WAF) Log Service DataWorks MaxCompute
Elastic MapReduce (EMR) Elasticsearch

Alibaba Cloud Free Trail

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.