IBM Support

A possible cause for slow connection to the database server

Troubleshooting


Problem

A problem with DNS lookup can cause slow connection to database server. This article explains one scenario and a possible solution for that problem.

Symptom

Connection request to database server from dbaccess is trying to access DNS server for hostname resolution, after it found the same in the local host file.

On certain Operating System (for example: Linux) you may noticed dbaccess (and other client applications) always doing DNS lookup while connecting to a database, even after found out the hostname or IP address in the local host file. This behavior sometimes caused slow connection, if you have problem related to DNS. Following is an excerpt of strace output shows the sequence of file accessed by a dbaccess request:




    $ strace dbaccess sysadmin -e | grep open
    ….
    open("/etc/services", O_RDONLY)         = 6
    open("/etc/resolv.conf", O_RDONLY)      = 6
    open("/etc/host.conf", O_RDONLY)        = 6
    open("/etc/hosts", O_RDONLY)            = 6
    open("/etc/ld.so.cache", O_RDONLY)      = 6
    open("/lib64/libnss_dns.so.2", O_RDONLY) = 6
    open("/lib64/libresolv.so.2", O_RDONLY) = 6
    open("/etc/hosts", O_RDONLY)            = 6
    ….


[{"Product":{"code":"SSGU8G","label":"Informix Servers"},"Business Unit":{"code":"BU059","label":"IBM Software w\/o TPS"},"Component":"Not Applicable","Platform":[{"code":"PF016","label":"Linux"}],"Version":"10.0;11.1;11.5;11.7;12.1","Edition":"","Line of Business":{"code":"LOB10","label":"Data and AI"}}]

Log InLog in to view more of this document

This document has the abstract of a technical article that is available to authorized users once you have logged on. Please use Log in button above to access the full document. After log in, if you do not have the right authorization for this document, there will be instructions on what to do next.

Document Information

Modified date:
16 June 2018

UID

swg21663287