TNSPING & TRCROUTE Utility to test Connectivity from the Client to Listener

TNSPING & TRCROUTE Utility to test Connectivity from the Client to Listener

TNSPING UTILITY
TNSPING utility used to check whether the listener for a service on an Oracle Net network can be reached successfully.

Checking a Listener connectivity with TNSPING

TNSPING XE


C:\Users\oracle>tnsping XE
TNS Ping Utility for 64-bit Windows: Version 11.2.0.2.0 - Production on 26-JUN-2018 14:58:22
Copyright (c) 1997, 2014, Oracle. All rights reserved.
Used parameter files:
D:\oraclexe\app\oracle\product\11.2.0\server\network\admin\sqlnet.ora
Used TNSNAMES adapter to resolve the alias
Attempting to contact (DESCRIPTION = (ADDRESS = (PROTOCOL = TCP)(HOST = IXC1-LP48ZJ622.FNFIS.com)(PO
RT = 1521)) (CONNECT_DATA = (SERVER = DEDICATED) (SERVICE_NAME = XE)))
OK (160 msec)

Check Listener with TNSPING 8 times

Tnsping XE 8


C:\Users\oracle>tnsping XE 8
TNS Ping Utility for 64-bit Windows: Version 11.2.0.2.0 - Production on 26-JUN-2018 14:59:48
Copyright (c) 1997, 2014, Oracle. All rights reserved.
Used parameter files:
D:\oraclexe\app\oracle\product\11.2.0\server\network\admin\sqlnet.ora
Used TNSNAMES adapter to resolve the alias
Attempting to contact (DESCRIPTION = (ADDRESS = (PROTOCOL = TCP)(HOST = IXC1-LP48ZJ622.FNFIS.com)(PO
RT = 1521)) (CONNECT_DATA = (SERVER = DEDICATED) (SERVICE_NAME = XE)))
OK (10 msec)
OK (0 msec)
OK (20 msec)
OK (0 msec)
OK (0 msec)
OK (0 msec)
OK (0 msec)
OK (0 msec)

Checking an Invalid Net Service Name with TNSPING

TNSPING badname

C:\Users\oracle>tnsping badname
TNS Ping Utility for 64-bit Windows: Version 11.2.0.2.0 - Production on 26-JUN-2018 15:00:48
Copyright (c) 1997, 2014, Oracle. All rights reserved.
Used parameter files:
D:\oraclexe\app\oracle\product\11.2.0\server\network\admin\sqlnet.ora
TNS-03505: Failed to resolve name

Solution
Check the tns entry in tnsnames.ora file and use it for fixed the solution of error TNS-03505: Failed to resolve name.

Checking Valid Net Service Name but No Listener with TNSPING
In this case listener is not working then we will get the following error:

TSNPING XE

C:\Users\oracle>tnsping XE
TNS Ping Utility for 64-bit Windows: Version 11.2.0.2.0 - Production on 26-JUN-2018 15:06:11
Copyright (c) 1997, 2014, Oracle. All rights reserved.
Used parameter files:
D:\oraclexe\app\oracle\product\11.2.0\server\network\admin\sqlnet.ora
Used TNSNAMES adapter to resolve the alias
Attempting to contact (DESCRIPTION = (ADDRESS = (PROTOCOL = TCP)(HOST = IXC1-LP48ZJ622.FNFIS.com)(PO
RT = 1521)) (CONNECT_DATA = (SERVER = DEDICATED) (SERVICE_NAME = XE)))
TNS-12541: TNS:no listener

Solution
Start the Listener of the Server and then tried.
Note: lsnrctl start command is used for start the listener

TRCROUTE UTILITY
Trace Route Utility (TRCROUTE) is used in Linux and UNIX environments, enables administrators to find the path of a connection between client to server.
Note: Used in Linux or Unix Platform.

Example of Successfull Execution

trcroute XE
Trace Route Utility for Linux: Version 18.0.0.0.0 - Production on 21-JAN-2018
Copyright (c) 1999, 2018 Oracle Corporation. All rights reserved.
Route of TrcRoute:
------------------
Node: Client Time and address of entry into node:
-------------------------------------------------------------
09-NOV-2012 21:48:48 ADDRESS= PROTOCOL=TCP HOST=10.50.2.130 PORT=14001
Node: Server Time and address of entry into node:
-------------------------------------------------------------
09-NOV-2012 21:48:05 ADDRESS= PROTOCOL=TCP HOST=10.50.2.130 PORT=14001

Example when listener not working

trcroute XE
Trace Route Utility for Linux: Version 18.0.0.0.0 - Production on 21-JAN-2018
Copyright (c) 1999, 2018 Oracle Corporation. All rights reserved.
Route of TrcRoute:
------------------
Node: Client Time and address of entry into node:
-------------------------------------------------------------
25-FEB-2012 14:43:05 ADDRESS= PROTOCOL=TCP HOST=10.50.2.130 PORT=1521
TNS-12543: TNS:unable to connect to destination
TNS-12541: TNS:no listener
TNS-12560: TNS:protocol adapter error
TNS-03601: Failed in route information collection

Advertisements

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Google+ photo

You are commenting using your Google+ account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s

This site uses Akismet to reduce spam. Learn how your comment data is processed.