Re: SQLNet.ora per Listener?

From: <japplewhite_at_austinisd.org>
Date: Tue, 21 Apr 2009 15:32:12 -0500
Message-ID: <OF720B86B1.F7EC1D5D-ON8625759F.007084F5-8625759F.0070CDE1_at_austinisd.org>



Jeff,

I should have said that I tested that - having a real non-default directory and a real alternative listener.ora file there. Didn't matter what I did - even being in that non-default directory - lsnrctl went right to the default directory every time.

In a separate email I disclose how I finally solved the mystery.

Thanks for the response.

Jack C. Applewhite - Database Administrator Austin I.S.D. - MIS Department
512.414.9715 (wk) / 512.935.5929 (pager)

"~Jeff~" <jifjif_at_gmail.com>  

Sent by: oracle-l-bounce_at_freelists.org 04/21/2009 03:08 PM
Please respond to
jifjif_at_gmail.com

To
oracle-l_at_freelists.org
cc

Subject
Re: SQLNet.ora per Listener?

I'm pretty sure if there *was* a file there it'd work as expected - ie not finding a file in TNS_ADMIN causes it to look in the other usual places further down the hierarchy ($TNS_ADMIN, $OH/network/admin, pwd) An alternate way to test (from memory, not at work ATM) is to copy the file into your current directory, tweak it so it does something different, then do the lsnrctl start again. I did this previously for some OID testing.
HTH,
Jeff Wong

2009/4/22 <japplewhite_at_austinisd.org>

Sounds like a good plan, but it doesn't work for any of my Oracle environments - 9i on HP-UX, 9i and 10g on Linux. It's easy to test. Just set TNS_ADMIN to a non-existent directory and try to start a non-existent Listener. The output below for me on HP-UX is exactly what I get on Linux for both 9i and 10g. Looks to me like lsnrctl totally ignores the TNS_ADMIN variable.

Am I missing something?

oracle>>TNS_ADMIN=$ORACLE_HOME/network/lsnr2222 lsnrctl start lsnr2222

LSNRCTL for HPUX: Version 9.2.0.8.0 - Production on 21-APR-2009 10:02:08

Copyright (c) 1991, 2006, Oracle Corporation. All rights reserved.

Starting /oracle/product/9.2.0/bin/tnslsnr: please wait...

TNSLSNR for HPUX: Version 9.2.0.8.0 - Production System parameter file is /oracle/product/9.2.0/network/admin/listener.ora Log messages written to /oracle/product/9.2.0/network/log/lsnr2222.log TNS-01151: Missing listener name, lsnr2222, in LISTENER.ORA

Listener failed to start. See the error message(s) above...

oracle>>export TNS_ADMIN=$ORACLE_HOME/network/lsnr2222 oracle>>lsnrctl start lsnr2222

LSNRCTL for HPUX: Version 9.2.0.8.0 - Production on 21-APR-2009 10:02:59

Copyright (c) 1991, 2006, Oracle Corporation. All rights reserved.

Starting /oracle/product/9.2.0/bin/tnslsnr: please wait...

TNSLSNR for HPUX: Version 9.2.0.8.0 - Production System parameter file is /oracle/product/9.2.0/network/admin/listener.ora Log messages written to /oracle/product/9.2.0/network/log/lsnr2222.log TNS-01151: Missing listener name, lsnr2222, in LISTENER.ORA

Listener failed to start. See the error message(s) above...

Jack C. Applewhite - Database Administrator Austin I.S.D. - MIS Department
512.414.9715 (wk) / 512.935.5929 (pager)

Nigel Thomas <nigel.cl.thomas_at_googlemail.com>   

Sent by: oracle-l-bounce_at_freelists.org 04/20/2009 05:26 PM

Please respond to
nigel.cl.thomas_at_googlemail.com

To
japplewhite_at_austinisd.org, Oracle-L Freelists <oracle-l_at_freelists.org> cc

Subject
Re: SQLNet.ora per Listener?

Jack

The sqlnet.ora is found in $TNS_ADMIN (if that is set) so why not set it before starting one of the listeners (and change it or leave it default for the other)

eg

TNS_ADMIN=/my/nonstandard/net/admin lsnrctl start ...

NB:
env=value command parameters
causes the env to be set to value and included in the environment of the command

In the non-default directory pointed to by $TNS_ADMIN you can make tnsnames.ora (if needed) a symbolic link to the "real" tnsnames.ora.

Cheers Nigel

2009/4/20 <japplewhite_at_austinisd.org>

9i on HP-UX and 10g on Linux.

Basic question: Can you somehow tie a particular sqlnet.ora file to a specific listener for a database that has two Listeners? I've looked in the docs and everywhere else I can think of and I can't find that you can somehow specify that a sqlnet.ora file applies to only a specific Listener, it applies to all Listeners in that ORACLE_HOME. The only way that my little brain has come up with is to create another ORACLE_HOME and have a Listener there with its own sqlnet.ora.

What we have is a Student Information database that is accessed District-wide via our internal WAN / LAN. It has a Listener on port 1521.  We've had this setup for years. We also allow selected access to that database from the Internet. We opened up another port (not 1521 or any of the "usual" ones) in the firewall and we have a second Listener on that port. The sqlnet on the Client App server in the DMZ requires encryption, etc. via the parameters specific to those security settings. We'd like to require the matching encryption, etc. for any traffic coming to the non-standard Listener, but the single sqlnet.ora file on the server would apply to our internal Listener as well, killing our internal Users. For now, we only have the security settings Accepted, not Required, on the server.

Am I an idiot? I've done the standard setup of Listeners lots and lots over the years but am not well-versed in unusual setups or Advanced Security. Is there a relatively simple way to do what we want or is the separate ORACLE_HOME the ticket? Any guidance would be appreciated.

Thanks.

Jack C. Applewhite - Database Administrator Austin I.S.D. - MIS Department
512.414.9715 (wk) / 512.935.5929 (pager)

--
http://www.freelists.org/webpage/oracle-l
Received on Tue Apr 21 2009 - 15:32:12 CDT

Original text of this message