[Contents] [Index] [Info] [Previous] [Next]

CHAPTER 4. TNS Listener

This chapter gives information about the TNS Listener on OpenVMS. It covers the following topics:

Introduction

The function of the TNS Listener is to receive connection requests from local or remote clients and to provide the client with a Server process to which to connect. The Listener can service multiple instances. For each instance, the Listener keeps a list of services that provide access to that instance. If multithreaded servers are being used, the Listener may direct a client connection to a dispatcher. Otherwise, for dedicated servers, the Listener will direct the client connection to an existing prespawned server or will create a new server process to service the connection.

Additional Information: General information about the Listener and its configuration can be found in the generic SQL*Net documentation. This chapter provides only information about the Listener that is specific to OpenVMS.

LSNRCTL

The LSNRCTL utility is used to start and stop the Listener and to query its status or services. The LSNRCTL command executes the command procedure ORA_NETCONFIG:LSNRCTL.COM, which provides a shell to the executable program ORA_NETCONFIG:LSNRCTL.EXE.

The main function of the command procedure is to check that the privileges required to start the Listener are present (see the section "Listener Privileges"). If a LSNRCTL START command is entered and the required privileges are not present, an error is displayed and LSNRCTL exits.

Note: Start the listener using the Oracle account.

Warning: If you enter the LSNRCTL interactive mode by giving the LSNRCTL command without a subcommand and you have received a warning about inadequate privileges, DO NOT attempt to start the Listener. The Listener process may still start, depending on the privileges you do have, but it may not function properly.

Warning: Also, DO NOT start the Listener from a process that has a UIC in the system group, for example a group less than or equal to MAXSYSGROUP. If you enter a LSNRCTL START command from such a process, an error is displayed and LSNRCTL exits. If you enter a LSNRCTL command with no arguments, you are warned not to start the Listener from within the LSNRCTL utility. If the Listener did run in a system group, any Server processes it creates would be in the system group and the Server would abort, because it does not allow itself to run in privileged groups.

Listener Privileges

The process in which the Listener runs must have the OpenVMS privileges in Table 4.1 to be able to perform the associated function.

Privilege Function
CMKRNL Pass this privilege to server processes that the Listener creates.
DETACH Create detached processes.
LOG_IO Perform certain I/O functions.
NETMBX Use DECnet.
PRMMBX Create a permanent mailbox on which to listen. (The mailbox is permanent so that the logical name associated with it goes into the SYSTEM logical name table.)
SYSLCK Lock system wide resources.
SYSNAM Create SYSTEM logical names and shared logical name tables.
TMPMBX Create temporary mailboxes.
WORLD Allow the Listener to get information about and to control processes that it may not have created, such as dispatchers and shared server processes.
Note: Before attempting to start the Listener, the process that starts the Listener must have the privileges in this table or be able to have them set. As noted above, the LSNRCTL command file will attempt to set these privileges and warn the user if it was unable to do so.
Table 4-1 Privileges and Their Functions

Process Quotas

Process quotas for the Listener and for the Server processes which the Listener creates can be controlled by logical names. The logical names are:

ORA_LSNR_<quotaname>

where:

<quotaname> is ASTLM, BIIOLM, BYTLM, CPULM, DIOLM, FILLM, PGFLQUOTA, PRCLM, TQELM, WSQUOTA, WSDEFAULT, ENQLM, WSEXTENT, or JTQUOTA.

Several of the logical names are defined in LSNRCTL.COM and control the quotas of the Listener process. They are defined in user mode so that they are not present after exiting LSNRCTL. If your Listener supports an especially large number of services, some of these quotas may need to be increased. For the quotas you determine to be deficient or under direction of Oracle Support, you can edit the quota values in LSNRCTL.COM.

To control the quotas of the processes that the Listener creates, specify the logical names in the file ORA_NETWORK:TNSLSNR.COM, the command file that runs in the Listener process. Statements to define these logical names are in TNSLSNR.COM, but are commented out.

If, for example, a very large file backed SGA requires that Server processes have larger quotas, you can uncomment the appropriate logical name definition in TNSLSNR.COM and specify the quota value. Starting with Version 7.3.2.3.2 and the VLM feature, a file backed SGA is created when the INIT.ORA parameter VLM_BACKING_STORAGE_FILE is set to TRUE.

Quotas can also be specified for the Server processes in the LISTENER.ORA file on a SID-by-SID basis. This is done in the SID_DESC section for a Listener. For example:

SID_LIST_LISTENER =  
    (SID_DESC = 
      (SID_NAME = <name>)        
      (PROGRAM = <disk:>[<directory>]ORASRV_NETV2.COM)
      (OSDS=
        (PRIORITY=<number>)
        (QUOTA=
          (ASTLM=<number>)
          (BYTLM=<number>)
          (PGFLQUOTA=<number>)
        )
      ) 
    )

There are no restrictions on the number of quotas that you can specify in the QUOTA list. However, if any quota is specified in the QUOTA list, then none of the quotas specified by logical name will be used and quotas that are not specified in the list will assume the system default.

Warning: The process priority of the Server process can also be specified, as in the example above, but this is not recommended.

ORASRV_NETV2 Command File

In the LISTENER.ORA file, you provide a SID_LIST for each defined Listener, and for each SID you provide a program name. The program name is the full directory path, without Oracle logical names, to a command file, based on the file TNS_ADMIN:ORASRV_NETV2_COM.SAMPLE.

When you edit the file TNS_ADMIN:ORASRV_NETV2_COM.SAMPLE for a particular SID, it may have any name. The recommendation is to name it: TNS_ADMIN:ORASRV_NETV2_<sid>.COM

For example:

(SID_LIST_LISTENER =  
 (SID_DESC =
    (SID_NAME = PROD)
    (PROGRAM = DK:[O732.NETWORK.ADMIN]ORASRV_NETV2_PROD.COM)
))

When the Listener starts a prespawned or dedicated server process, the process runs this command file. To create this file for a particular SID, change the following three lines in the sample command file:

$ ora_db = "database administration directory"
$ sid    = "sid name"
$ dbname = "database name"

where: "database administration directory" is the directory that contains the startup, shutdown, and orauser command files for the database. Specify a full directory path, without using Oracle logical names. "sid name" and "database name" are the names provided for the database when it was created.

Note: You can find a sample command file in Appendix B of this document.

General Connections

Make sure that your SQL*Net task file defines any logical names used by the INIT.ORA parameters USER_DUMP_DEST and BACKGROUND_DUMP_DEST (if defined).

Note: If you define these logical names by calling ORA_DB:ORAUSER_<database_name>.COM, make sure that ORA_UTIL:ORAUSER.COM runs RDBMSUSER.COM AFTER PROGINTUSER.COM.

PROGINTUSER.COM also defines ORA_SLAX, making it into a search list with ORA_PROGINT_MESG and ORA_RDBMS.


[Contents] [Index] [Info] [Previous] [Next]