Serverside Configuration   «Prev  Next»

Lesson 3 The Oracle Listener
Objective Explain how the listener manages Incoming Connections

Listener manages Incoming Connections

Note:SQL*Net is a version of Oracle Network services that has been deprecated since Oracle 9i.
It is important to understand that there are many different configurations for listeners, and, as the figure below illustrates, many Oracle listeners can exist on the same Oracle server. These include
  1. SQL*Net version 1 listeners,
  2. SQL*Net version 2 listeners, and
  3. Oracle Net listeners.
In addition, a listener can be defined as a dedicated listener or a multi-threaded server listener. Finally, for SQL*Net version 2 and above, you can have separate listeners for different protocols.

More than on Oracle Listener existing at the same time
More than on Oracle Listener existing at the same time

Listener Characteristics

Each type of listener has its own characteristics:
  1. SQL*Net version 1 listener is started with the tcpctl start command. This listener only receives TCP/IP connections that are invoked with the TWO_TASK environment variable. TWO_TASK is set on the client specifying the protocol, the host name, and the database name. For example, setting TWO_TASK=t:dilbert:tom would connect to the tom database on the DILBERT server, using a TCP/IP protocol. The TWO_TASK environment variable is still supported in Oracle8.
  2. SQL*Net version 2 and Oracle Net dedicated listener, illustrated below, is the most common type of Oracle listener. It's called a dedicated listener because Oracle will bequeath dedicated server processes to manage the connections. These dedicated processes make it possible to start and stop a listener without interrupting current SQL*Net sessions.
Dedicated listener
Dedicated listener

  1. Multi-threaded server listeners use a pre-defined dispatcher processes to create the connections to Oracle, according to the way the Multi-Threaded Server (MTS) is defined. These dispatchers are defined in the init.ora file for each database, and the multi-threaded server routes the incoming connections to a dispatcher process, rather than creating a dedicated process. Each Oracle database will have a pre-defined number of dispatcher processes, and the connections will be multi-threaded through the dispatchers. The figure below illustrates the relationship between a multi-threaded listener and the dispatcher processes on two multi-threaded servers.
Dedicated listener
Multi-threaded listener
  1. The MTS is commonly used on servers where resources are scarce and there are very high volumes of incoming connections. We will discuss the MTS in detail in the second course in this series.
  2. Multi-protocol listeners are the separate SQL*Net version 2 or Oracle Net listeners that are defined to handle incoming SNMP, SPX, or other protocols.
Again, it is important to understand that the purpose of the listener process is to establish connections on behalf of the remote transaction. After establishing the connection, the listener disconnects from the process.
The next lesson discusses how to configure the Oracle listener.