TNS-12535: TNS:operation timeout

oracleoracle-11g-r2

I have Windows Server 2008 R2 with Oracle Client 11.1.0.7.0 client installed. TNSPing to 100% available databases (accessible from other machines, i.e. I can do TNS ping to these databases from other machines) returns me following error: TNS-12535: TNS:operation timeout. At the same time I can telnet to database host/port and see that proper tnsnames file is being used. Environment variables are configured as appropriate (ORACLE_HOME, TNS_ADMIN, Path). Also I can connect via telnet using service/host name + port – so this is unlikely a firewall issue.

After enabling Oracle client logging I can see following error related details in tnsping.trc:

snlinGetAddrInfo: enrty
snlinGetAddrInfo: getaddrinfo() failed with
error 11001
snlinGetAddrInfo: exit

The only strange/suspicious thing about this machine is that it had multiple versions of oracle client installed (10, 11.1, 11.2) – removal of all versions apart from 11.1 & reinstall/repair of 11.1 haven't resolved this issue. Also it seems to me that v10 of client was not removed properly – it disappeared from Programs and Features, but files in installation folder had not been deleted.

Any advice on what to check / how to resolve this issue?

Best Answer

I know it is too late for the OP but here some advice to tackle such a problem:

The error message says that the clients sends but does not get a response. Most of the time it is a firewall problem.

  1. The windows getaddrinfo function is described here. Error number 11001 is WSAHOST_NOT_FOUND and is described here:

    Host not found.
    No such host is known. The name is not an official host name or alias, or it cannot be found in the database(s) being queried. This error may also be returned for protocol and service queries, and means that the specified name could not be found in the relevant database.

    Linux/Unix error numbers can found in the appropriate header files.

  2. I don't know if that windows error message is is the reason for your error. Even if you can access the listener port with telnet that does not mean that there is no firewall problem. I you used share servers or an oracle RAC with a scan listener the database will try to connect to a server by a different prot that can be blocked by a firewall.

  3. TNS ping does only contact the listner. So first you should check if the tnsping arrives at the server. Can you see it in the listner.log file? Check if you use the right tnsname.ora file by adding the connect string with a completely new tns-name and do a tnsping to this new tns-name. Do you get the same error message?

  4. If you want to remove all your Oracle installations on a windows server you can do that by hand. Remove all the directories and registry entries. Look for appropriate advice.