Visit Counter

Wednesday, January 22, 2014

ORA-12543: TNS:destination host unreachable



[oracle@rac2 bin]$tnsping orapri
TNS Ping Utility for Linux: Version 11.2.0.1.0 - Production on 30-Nov-2012 01:52:34
Copyright (c) 1997, 2009, Oracle.  All rights reserved.
Used parameter files:
/ora/oracle/ora11g/network/admin/sqlnet.ora

Used TNSNAMES adapter to resolve the alias
Attempting to contact (DESCRIPTION = (ADDRESS_LIST = (ADDRESS = (PROTOCOL = TCP)(HOST = 192.0.0.24)(PORT = 1521))) (CONNECT_DATA = (SERVICE_NAME = orapri)))

TNS-12543: TNS:destination host unreachable

Diagnosis process:

-------------------

If you are unfamiliar with the error use the oerr utility to get the more information on this error.

oracle@rac2 $ oerr ora 12543

12543, 00000, "TNS:destination host unreachable"

*Cause: Contact can not be made with remote party.

*Action: Make sur the network driver is functioning and the network is up.


Solution:
---------
Reason : Firewall was enabled on Primary and Standby servers.
-----------------------------------------------------------------

I disabled the Fire wall from primary and standby servers.You can disable firewall by GUI and command line as well.

root@rac1 # service iptables status
                     service iptables stop
                     chkconfig iptables off


Linux Error 111: Connection refused



[oracle@rac2 bin]$ lsnrctl

LSNRCTL for Linux: Version 11.2.0.1.0 - Production on 23-JAN-2012 01:51:56

Copyright (c) 1991, 2009, Oracle.  All rights reserved.

Welcome to LSNRCTL, type "help" for information.

LSNRCTL> start
Connecting to (DESCRIPTION=(ADDRESS=(PROTOCOL=IPC)(KEY=EXTPROC1521)))
TNS-12541: TNS:no listener
 TNS-12560: TNS:protocol adapter error
  TNS-00511: No listener
   Linux Error: 111: Connection refused
Connecting to (DESCRIPTION=(ADDRESS=(PROTOCOL=TCP)(HOST=rac2)(PORT=1521)))
TNS-12541: TNS:no listener
 TNS-12560: TNS:protocol adapter error
  TNS-00511: No listener
   Linux Error: 111: Connection refused


Solution:
-------------

The hosts file does not contain the correct address or name for the server. This can also occur if the loopback address is not present. Edit /etc/hosts and verify that the host name and address are correct. Also verify that 127.0.0.1 localhost.localdoman localhost are present.


# /etc/hosts

LSNRCTL> start
Starting /ora/oracle/ora11g/bin/tnslsnr: please wait...

TNSLSNR for Linux: Version 11.2.0.1.0 - Production
System parameter file is /ora/oracle/ora11g/network/admin/listener.ora
Log messages written to /ora/oracle/ora11g/base/diag/tnslsnr/rac2/listener/alert/log.xml
Listening on: (DESCRIPTION=(ADDRESS=(PROTOCOL=ipc)(KEY=EXTPROC1521)))
Listening on: (DESCRIPTION=(ADDRESS=(PROTOCOL=tcp)(HOST=rac2)(PORT=1521)))

Connecting to (DESCRIPTION=(ADDRESS=(PROTOCOL=IPC)(KEY=EXTPROC1521)))
STATUS of the LISTENER
------------------------
Alias                     LISTENER
Version                   TNSLSNR for Linux: Version 11.2.0.1.0 - Production
Start Date                23-JAN-2012 01:52:04
Uptime                    0 days 0 hr. 0 min. 0 sec
Trace Level               off
Security                  ON: Local OS Authentication
SNMP                      OFF
Listener Parameter File   /ora/oracle/ora11g/network/admin/listener.ora
Listener Log File         /ora/oracle/ora11g/base/diag/tnslsnr/rac2/listener/alert/log.xml
Listening Endpoints Summary...
  (DESCRIPTION=(ADDRESS=(PROTOCOL=ipc)(KEY=EXTPROC1521)))
  (DESCRIPTION=(ADDRESS=(PROTOCOL=tcp)(HOST=rac2)(PORT=1521)))
The listener supports no services
The command completed successfully