cancel
Showing results for 
Search instead for 
Did you mean: 

sqlnet.ora doubt

SOLVED
Go to solution
KapilRaj
Honored Contributor

sqlnet.ora doubt

Guys,

I am basically a Sysadmin .... But would like to know what this line says .....

In one of my boxes there is a file called /etc/sqlnet.ora which states as follows ..

NAMES.DIRECTORY_PATH = (TNSNAMES, ONAMES)
What is the effect of the path when it's mentioned as (TNSNAMES, HOSTNAME) and how does it work?

Thanks in advance...

Kaps
Nothing is impossible
5 REPLIES
T G Manikandan
Honored Contributor

Re: sqlnet.ora doubt

Kapil,

sqlnet.ora file is a file used for resolving network addresses and the order of resolution.

With
NAMES.DIRECTORY_PATH = (TNSNAMES, ONAMES)

deciding which configuration files to search for the order of resolution

First it checks the tnsnames.ora and then the name server onames configuration file for resolving the services.

Any further help please revert

Do you have a name server with name HOSTNAME

Alexander M. Ermes
Honored Contributor
Solution

Re: sqlnet.ora doubt

Hi there.
If you go for (TNSNAMES, HOSTNAME),
possible connections will be checked first in TNSNAMES.ORA, then in your hosts file
( mostly /etc/hosts).

Extract from Oracle SQLNet manual :

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

Configuring the Host Naming Method
In environments where simple connectivity is desired, host naming can eliminate the need for service name lookup in the tnsnames.ora files. However, for large or complex environments where advanced features such as connection pooling, external procedures, or Heterogeneous Services, which require additional connect information, are desired, host naming is not suitable. In these cases, another naming method is recommended.

The host naming method is available for TCP/IP network environments only. When instances register with the listener, the global database name of the server, a name comprised of the database name and domain name. The global database name is equal to a host name on an alias in an existing name resolution service. Clients use this name in their connect string to connect to the database.

Clients may connect to a server using the alias if:

You are connecting to an Oracle8i database service with Net8 Server/Net8 Client software installed

Your client and server are connecting over a TCP/IP protocol

All names are resolved through an IP address translation mechanism such as Domain Name System (DNS), or a centrally maintained TCP/IP hosts file

No advanced features like Oracle Connection Manager or security are requested or required

-------------------------------
Extract end

Rgds
Alexander M. ERmes
.. and all these memories are going to vanish like tears in the rain! final words from Rutger Hauer in "Blade Runner"
T G Manikandan
Honored Contributor

Re: sqlnet.ora doubt

TNSNAMES, HOSTNAME) would define the order as tnsnames.ora and then the /etc/hosts file on unix.

This configuration of

NAMES_DIRECTORY_PATH=(hostname)

This would make resolve without any client side configuration file.

HOSTNAME adapter is only for the TCP/IP based connection which is using NET8.

Also the listener.ora file on the server side should be configured such a way that the connection is established.

KapilRaj
Honored Contributor

Re: sqlnet.ora doubt

Thanks a million .....

Kaps
Nothing is impossible
Yogeeraj_1
Honored Contributor

Re: sqlnet.ora doubt

hi,

To add to above replies, please note that sqlnet.ora is an OPTIONAL file.

attached an interesting note from metalink (1006437.6)

Best wishes
Yogeeraj
No person was ever honoured for what he received. Honour has been the reward for what he gave (clavin coolidge)