SlideShare a Scribd company logo
4
Most read
5
Most read
Basic Oracle Net
Server
Side Configuration
Objectives
 After completing this lesson, you should be able to do the following:
 Identify how the listener responds to incoming connections
 Describe Dynamic Service Registration
 Configure the listener by using Oracle Net Manager
 Control the listener by using the Listener Control Utility
 Configure the listener for HTTP connections
The Listener Process
listener.ora
Listener
Client Server
tnsnames.ora
sqlnet.ora
Connection Methods
 When a connection request is made by a client to a
server, the listener performs one of the following:
 Spawns a server process and bequeaths (passes) the
connection to it
 Hands off the connection to a dispatcher in an Oracle
Shared Server configuration
 Redirects the connection to a dispatcher or server process
Spawn and Bequeath
Connections
Listener
Server
Client
Dedicated
Server Process
1 2
3
Direct Hand-Off Connections
Listener
Dispatcher1 2
3
Shared
Server
Process
Shared
Server
Process
Redirected Session
port
Listener
Client Server
port
Server or
dispatcher
process
1
2
3
4
5
6
Service Configuration and
Registration
 The listener can be configured in two ways:
 Dynamic service registration
 Does not require configuration in listener.ora file
 The listener relies on the PMON process
 Static service configuration
 Used for Oracle8 and earlier releases
 Requires listener.ora configuration
 Required for Oracle Enterprise Manager and other services
Static Service Registration:
The listener.ora File
 Default settings for the listener.ora file with Oracle software
installation:
 Listener name LISTENER
 Port 1521
 Protocols TCP/IP and IPC
 SID name Default instance
 Host name Default host name
Static Service Registration:
The listener.ora File
1. LISTENER =
2. (ADDRESS_LIST =
3. (ADDRESS= (PROTOCOL= TCP)(Host= stc-
sun02)(Port= 1521)))
4. SID_LIST_LISTENER =
5. (SID_LIST =
6. (SID_DESC =
7. (ORACLE_HOME= /home/oracle)
8. (GLOBAL_DBNAME = ORCL.us.oracle.com)
9. (SID_NAME = ORCL)))
Static Service Registration:
Create a Listener
Configuring Services
Dynamic Service Registration:
Configure Registration
 To ensure that service registration is functional, the following
initialization parameters must be configured:
 SERVICE_NAMES
 INSTANCE_NAME
Dynamic Service Registration:
Registering Information with the
Listener
 By default, PMON registers with a local listener on the server on the
default local address of TCP/IP, port 1521
 PMON can register with a non default listener if:
 LOCAL_LISTENER initialization parameter is defined
 LISTENERS attribute of the DISPATCHERS initialization parameter is
defined for Oracle Shared Server
Configure the Listener for
Oracle9i JVM: HTTP
 The listener can be configured to accept connections from clients
using HTTP.
 Use Static Listener Registration if the database is Oracle8i or an
earlier version, even if Oracle9i listener is used.
 If both the listener and the database are Oracle9i, configuration
occurs dynamically during service registration.
Listener Control Utility
(LSNRCTL)
 Listener Control Utility commands can be issued from the
command-line or from the LSNRCTL prompt.
 UNIX command-line syntax:

 Prompt syntax:
 Control a non-default listener:
$ lsnrctl <command name>
LSNRCTL> <command name>
LSNRCTL> set current_listener listener02
LSNRCTL Commands
 Use the following commands to control the listener:
 Starting the listener:
 Stopping the listener:
$lsnrctl START listener_name
$lsnrctl STOP listener_name
LSNRCTL SET and SHOW
Modifiers
 Change listener parameters with SET:
 Display the values of parameters with SHOW:
LSNRCTL> SET trc_level ADMIN
LSNRCTL> SHOW trc_directory

More Related Content

PPTX
Tacacs+ with ise 2.4_ CCIE
PDF
Ftp server configuration on cisco packet tracer
TXT
Readme
PPTX
Setting up a web server in Linux (Ubuntu)
PPTX
Performance vision Version 3.0 - What's New
PDF
Dns server in packet tracer converted (labanna saha)
PDF
ACL Tutorial
PDF
Webserver Administration: Apache as a case study
Tacacs+ with ise 2.4_ CCIE
Ftp server configuration on cisco packet tracer
Readme
Setting up a web server in Linux (Ubuntu)
Performance vision Version 3.0 - What's New
Dns server in packet tracer converted (labanna saha)
ACL Tutorial
Webserver Administration: Apache as a case study

What's hot (20)

PPTX
Presentation of Performance Vision Version 3.3
DOCX
PDF
Email server configuration on cisco packet tracer
PPTX
Information on Basic Web Host Manager Setup
PDF
TekSIP Route Server Manual
PDF
DNS server packet tracer
PPTX
PDF
Meeting 6 : ftp
PDF
DNS server configuration in packet tracer
PDF
Logger Forwarding Connector for OMi 7.3.0.7839.0 Configuration Guide
PDF
Logger Forwarding Connector for OM 7.3.0.7838.0 Configuration Guide
PDF
Dhcp & dhcp relay agent in cent os 5.3
PPTX
Exchange Server 2013 : upgrade migration et co-existence avec les anciennes v...
PDF
Microsoft Exchange 2013 deployment and coexistence
DOCX
Tugas 4 Kode SMTP & kelemahannya
PDF
Networking Puzzle
PPTX
Ivr subscription system v1
PPT
Enable Open D N S
ODT
How to configure IPA-Server & Client-Centos 7
DOCX
4.0 client server_change_log
Presentation of Performance Vision Version 3.3
Email server configuration on cisco packet tracer
Information on Basic Web Host Manager Setup
TekSIP Route Server Manual
DNS server packet tracer
Meeting 6 : ftp
DNS server configuration in packet tracer
Logger Forwarding Connector for OMi 7.3.0.7839.0 Configuration Guide
Logger Forwarding Connector for OM 7.3.0.7838.0 Configuration Guide
Dhcp & dhcp relay agent in cent os 5.3
Exchange Server 2013 : upgrade migration et co-existence avec les anciennes v...
Microsoft Exchange 2013 deployment and coexistence
Tugas 4 Kode SMTP & kelemahannya
Networking Puzzle
Ivr subscription system v1
Enable Open D N S
How to configure IPA-Server & Client-Centos 7
4.0 client server_change_log
Ad

Similar to Basic oracle net server side configuration (20)

DOCX
Ora static and-dynamic-listener
PPTX
Oracle DBA Configuring network environment
PPT
Configuración de la Red de DB Oracle 11g
PDF
Create Static Listener SI _ RAC Duplication.pdf
PPT
Less05 Network
PPT
Less06 networking
PDF
Oracle services on rac
PDF
Createlistener
PDF
Oracle networking listener
PDF
Configuremts
PPT
Rajnish singh(presentation on oracle )
PPTX
Oracle e-Business Suite & RAC 11GR2
PDF
2516186 oracle9i-dba-fundamentals-ii-volume-ii
PPTX
How oracle 12c flexes its muscles against oracle 11g r2 final
PPT
Les 01 core
PDF
real-application-clusters-installation-guide-linux-and-unix.pdf
DOCX
1- Check the major Oracle network files file location within Oracle Ho.docx
PDF
Presentation on Oracle Application Server
PDF
05 - Oracle Database 23c - Technical Architecture.pdf
PPT
les_01_core_database-oracle00000000.ppt.ppt
Ora static and-dynamic-listener
Oracle DBA Configuring network environment
Configuración de la Red de DB Oracle 11g
Create Static Listener SI _ RAC Duplication.pdf
Less05 Network
Less06 networking
Oracle services on rac
Createlistener
Oracle networking listener
Configuremts
Rajnish singh(presentation on oracle )
Oracle e-Business Suite & RAC 11GR2
2516186 oracle9i-dba-fundamentals-ii-volume-ii
How oracle 12c flexes its muscles against oracle 11g r2 final
Les 01 core
real-application-clusters-installation-guide-linux-and-unix.pdf
1- Check the major Oracle network files file location within Oracle Ho.docx
Presentation on Oracle Application Server
05 - Oracle Database 23c - Technical Architecture.pdf
les_01_core_database-oracle00000000.ppt.ppt
Ad

Recently uploaded (20)

PDF
Building Integrated photovoltaic BIPV_UPV.pdf
PDF
Encapsulation theory and applications.pdf
PDF
7 ChatGPT Prompts to Help You Define Your Ideal Customer Profile.pdf
PPTX
Understanding_Digital_Forensics_Presentation.pptx
PDF
KodekX | Application Modernization Development
PDF
Network Security Unit 5.pdf for BCA BBA.
PPT
Teaching material agriculture food technology
PDF
cuic standard and advanced reporting.pdf
PDF
Dropbox Q2 2025 Financial Results & Investor Presentation
PDF
Diabetes mellitus diagnosis method based random forest with bat algorithm
PPTX
Big Data Technologies - Introduction.pptx
PDF
Peak of Data & AI Encore- AI for Metadata and Smarter Workflows
DOCX
The AUB Centre for AI in Media Proposal.docx
PDF
Mobile App Security Testing_ A Comprehensive Guide.pdf
PDF
Reach Out and Touch Someone: Haptics and Empathic Computing
PPTX
Digital-Transformation-Roadmap-for-Companies.pptx
PDF
Optimiser vos workloads AI/ML sur Amazon EC2 et AWS Graviton
PDF
Per capita expenditure prediction using model stacking based on satellite ima...
PPTX
Cloud computing and distributed systems.
PPTX
Programs and apps: productivity, graphics, security and other tools
Building Integrated photovoltaic BIPV_UPV.pdf
Encapsulation theory and applications.pdf
7 ChatGPT Prompts to Help You Define Your Ideal Customer Profile.pdf
Understanding_Digital_Forensics_Presentation.pptx
KodekX | Application Modernization Development
Network Security Unit 5.pdf for BCA BBA.
Teaching material agriculture food technology
cuic standard and advanced reporting.pdf
Dropbox Q2 2025 Financial Results & Investor Presentation
Diabetes mellitus diagnosis method based random forest with bat algorithm
Big Data Technologies - Introduction.pptx
Peak of Data & AI Encore- AI for Metadata and Smarter Workflows
The AUB Centre for AI in Media Proposal.docx
Mobile App Security Testing_ A Comprehensive Guide.pdf
Reach Out and Touch Someone: Haptics and Empathic Computing
Digital-Transformation-Roadmap-for-Companies.pptx
Optimiser vos workloads AI/ML sur Amazon EC2 et AWS Graviton
Per capita expenditure prediction using model stacking based on satellite ima...
Cloud computing and distributed systems.
Programs and apps: productivity, graphics, security and other tools

Basic oracle net server side configuration

  • 2. Objectives  After completing this lesson, you should be able to do the following:  Identify how the listener responds to incoming connections  Describe Dynamic Service Registration  Configure the listener by using Oracle Net Manager  Control the listener by using the Listener Control Utility  Configure the listener for HTTP connections
  • 3. The Listener Process listener.ora Listener Client Server tnsnames.ora sqlnet.ora
  • 4. Connection Methods  When a connection request is made by a client to a server, the listener performs one of the following:  Spawns a server process and bequeaths (passes) the connection to it  Hands off the connection to a dispatcher in an Oracle Shared Server configuration  Redirects the connection to a dispatcher or server process
  • 6. Direct Hand-Off Connections Listener Dispatcher1 2 3 Shared Server Process Shared Server Process
  • 8. Service Configuration and Registration  The listener can be configured in two ways:  Dynamic service registration  Does not require configuration in listener.ora file  The listener relies on the PMON process  Static service configuration  Used for Oracle8 and earlier releases  Requires listener.ora configuration  Required for Oracle Enterprise Manager and other services
  • 9. Static Service Registration: The listener.ora File  Default settings for the listener.ora file with Oracle software installation:  Listener name LISTENER  Port 1521  Protocols TCP/IP and IPC  SID name Default instance  Host name Default host name
  • 10. Static Service Registration: The listener.ora File 1. LISTENER = 2. (ADDRESS_LIST = 3. (ADDRESS= (PROTOCOL= TCP)(Host= stc- sun02)(Port= 1521))) 4. SID_LIST_LISTENER = 5. (SID_LIST = 6. (SID_DESC = 7. (ORACLE_HOME= /home/oracle) 8. (GLOBAL_DBNAME = ORCL.us.oracle.com) 9. (SID_NAME = ORCL)))
  • 13. Dynamic Service Registration: Configure Registration  To ensure that service registration is functional, the following initialization parameters must be configured:  SERVICE_NAMES  INSTANCE_NAME
  • 14. Dynamic Service Registration: Registering Information with the Listener  By default, PMON registers with a local listener on the server on the default local address of TCP/IP, port 1521  PMON can register with a non default listener if:  LOCAL_LISTENER initialization parameter is defined  LISTENERS attribute of the DISPATCHERS initialization parameter is defined for Oracle Shared Server
  • 15. Configure the Listener for Oracle9i JVM: HTTP  The listener can be configured to accept connections from clients using HTTP.  Use Static Listener Registration if the database is Oracle8i or an earlier version, even if Oracle9i listener is used.  If both the listener and the database are Oracle9i, configuration occurs dynamically during service registration.
  • 16. Listener Control Utility (LSNRCTL)  Listener Control Utility commands can be issued from the command-line or from the LSNRCTL prompt.  UNIX command-line syntax:   Prompt syntax:  Control a non-default listener: $ lsnrctl <command name> LSNRCTL> <command name> LSNRCTL> set current_listener listener02
  • 17. LSNRCTL Commands  Use the following commands to control the listener:  Starting the listener:  Stopping the listener: $lsnrctl START listener_name $lsnrctl STOP listener_name
  • 18. LSNRCTL SET and SHOW Modifiers  Change listener parameters with SET:  Display the values of parameters with SHOW: LSNRCTL> SET trc_level ADMIN LSNRCTL> SHOW trc_directory

Editor's Notes

  • #4: Characteristics of the Listener Process The database server receives an initial connection from a client application through the listener. The listener is a process running on a node that listens for incoming connections on behalf of a database or a number of databases. The following are the characteristics of a listener: A listener process can listen for more than one database Multiple listeners can listen on behalf of a single database to perform load balancing The listener can listen for multiple protocols The default name of the listener in Oracle Net is LISTENER The name of the listener must be unique per listener.ora file Note: Oracle9i databases require an Oracle9i listener. Earlier versions of the listener are not supported. However, it is possible to use an Oracle9i listener with databases created with an earlier version of Oracle. Using Oracle Enterprise Manager The Listeners page under the Nodes folder in the Navigator displays listener properties for a node selected in the Navigator. Information displayed includes a list of all databases monitored by the listener as well as the TNS address of the listener. You can determine the operational status of the listener by clicking Listener Status.
  • #5: Connection Methods Spawn and Bequeath The listener passes or bequeaths the connection to a spawned process. This method is used in a dedicated server configuration only. Direct Hand-Off The listener will hand off a connection to a dispatcher when an Oracle Shared Server is used. This method is not possible with dedicated server processes. Redirected (Message) A connection may be redirected by the listener to a dispatcher if a Shared Server is used. Note: Each of the connection types is covered in more detail later in the lesson. Transparency of Direct Hand Off and Redirect Whether a connection session is bequeathed, handed off, or redirected to an existing process, the session is transparent to the user. It can be detected only by turning on tracing and analyzing the resulting trace file.
  • #6: Spawn and Bequeath Connections The listener may spawn dedicated server processes as connection requests are received and bequeath (or pass) the connections to the server processes. The use of this method is dependant on the ability of the underlying operating system to support inheritance of network endpoints. When the listener forks a dedicated server process and bequeaths the connection to the server process, it is called a bequeath session. The following sequence of events occurs: 1.The listener receives a client connection request. 2.The listener starts a dedicated server process, and the dedicated server inherits the connection request from the listener. 3.The client is now connected directly to the dedicated server. If, because of the operating system or protocol, a connection cannot be passed between two different processes on the same machine, a redirect must take place instead. Note: When a client disconnects, the clients’ dedicated server process closes.
  • #7: Direct Hand-Off Connections The listener uses the dispatcher as a type of service handler to which it can direct client requests. When a client request arrives, the listener performs one of the following actions: Hands the connection request directly to a dispatcher. Issues a redirect message to the client, containing the protocol address of a dispatcher. The client then terminates the network session to the listener and establishes a network session to the dispatcher, by using the network address provided in the redirect message. The listener uses direct hand off whenever possible. Redirect messages are used, for example, when dispatchers are remote to the listener. The sequence of events is as follows: 1.The listener receives a client connection request. 2.The listener hands the connect request directly to the dispatcher. 3.The client is now connected to the dispatcher.
  • #8: The Redirected Session When conditions do not support the establishment of a bequeath or direct hand-off connection, a redirect session will be established. The following steps outline the mechanics of this type of connection: 1.The client establishes a connection to the listener by using the configured protocol and sends the listener a connect packet. 2.The listener checks that the SID is defined. If it is, the listener will spawn a new thread or process to service the new connection. An IPC connection is then established between the listener and the new process or thread. 3.The new process or thread selects a new TCP/IP port from the list of free user-defined ports and passes this information back to the listener. 4. The listener inserts this new port into a redirect packet and sends it back to the client and the original TCP socket between the client and the listener is then reset. 5. A new TCP connection is established to the redirect address specified in the redirect packet and a connect packet is then forwarded to the dedicated server process.
  • #9: Configuring the Listener Dynamic Service Registration An Oracle9i instance uses service registration to inform the listener about its database services. Service registration relies on the PMON process to register instance information with the listener. PMON also informs the listener about the current state and load of the instance and Shared Server dispatchers. If Oracle9i JVM is installed, HTTP listening endpoints can be registered dynamically with the listener. When an instance is started, initialization parameters about the listener are read from the initialization parameter file by which PMON registers information with the listener. If a listener is not up when the instance starts, PMON will not register information with the listener. PMON will continue attempting to contact the listener. The listener will reject any connections made to an unregistered service. Static Service Registration You must configure the listener.ora file for Oracle8 instances. Note: The static configuration is also required for Oracle Enterprise Manager (OEM) and other services such as external procedures and Heterogeneous Services.
  • #10: The listener.ora File You must use the listener.ora file to configure the listener for static service registration. The listener.ora file must reside on the machine or node on which the listener is to reside. The listener.ora file contains configuration information as follows: The listener name The listener address Databases that use the listener Listener parameters
  • #11: listener.ora File Contents The default listener.ora file contains the following parameters: 1.The name of the listener. The default name is LISTENER. 2.The ADDRESS_LIST parameter contains a block of addresses at which the listener listens for incoming connections. Each of the addresses defined in this block represents a different way by which a listener receives a connection. 3.The TCP address identifies incoming TCP connections from clients on the network attempting to connect to port 1521. The clients use the port defined in their tnsnames.ora file to connect to this listener. Based on the SID_LIST defined for this listener, the listener specifies the database to which to connect. Please note that is possible to configure multiple listeners here as long as they have unique names and unique ports on the node where they are configured. Each listener configured will have its own SID_LIST but a single database can be serviced by multiple listeners. 4.A listener can listen for more than one database on a machine. The SID_LIST_listener_name block or parameter is where these SIDs are defined. 5.The SID_LIST parameter is defined if more than one SID is defined.
  • #12: Creating an Additional Listener During the installation of an Enterprise Edition or Standard Edition on the server, Oracle Net Configuration Assistant automatically configures a listener with a name of LISTENER that has a TCP/IP protocol address for the Oracle database. If you need to create an additional listener, follow the steps outlined below to configure additional listeners in the listener.ora file using Oracle Net Manager: 1.In the navigator pane, expand Oracle Net Configuration &amp;gt; Local &amp;gt; Listeners. 2.Select Create from the Edit menu. 3.Enter a listener name in the Listener Name field in the dialog box that appears. 4.Select Listening Locations from the drop-down list for your listener. 5.Click Add Address. 6.Change or enter information in the Protocol, the Host, and Port fields as necessary. 7.Select Save Network Configuration from the File menu of Oracle Met Manager. Note: In the Local folder you can configure network elements in configuration files located in ORACLE_HOME/network/admin on Windows. Other directories can be specified by selecting Open Network Configuration from the File menu.
  • #13: Configuring Database Services 1.Select Database Services from the drop-down list for your listener. 2.Click Add Database. 3.Enter the global database name, the Oracle home directory, and the SID in the appropriate fields. 4.Select Save Network Configuration from the File menu of Oracle Net Manager.
  • #14: Configuring Listener Logging and Tracing 1.Select General Parameters from the pull-down menu within Net Manager for your listener. 2.Click the Logging &amp; Tracing tab. 3.To enable logging, select the Logging Enabled option button. 4.Enter the path and filename for a log file. 5.Select Save Network Configuration from the File menu. 6.Repeat the preceding steps for tracing. Note: Be aware that logging and especially tracing can use large amounts of disk space and should be monitored. Tracing should only be used if needed.
  • #15: Configuring Service Registration Dynamic service registration is used by Oracle9i or Oracle8i instances. The registration is performed by the PMON process of each database instance that has the required configuration in the database initialization parameter file. Dynamic service registration does not require any configuration in the listener.ora file. Dynamic service registration is configured in the database initialization file. Listener configuration must be synchronized with the information in the database initialization file. The following initialization parameters must be configured for service registration to work: SERVICE_NAMES: Specifies one or more names for the database service to which this instance connects. You can specify multiple service names in order to distinguish among different uses of the same database. INSTANCE_NAME: Specifies the instance name. In a single-instance database system, the instance name is usually the same as the database name. Examples SERVICE_NAMES=sales.us.oracle.com INSTANCE_NAME=salesdb
  • #16: Service Registration By default, the PMON process registers service information with its local listener on the default local address of TCP/IP, port 1521. Using a Nondefault Listener You can force PMON to register with a local listener on the server that does not use TCP/IP or use port 1521 by configuring the LOCAL_LISTENER parameter in the initialization parameter file as follows: LOCAL_LISTENER=listener_alias listener_alias must be resolved to the listener protocol address through a naming method such as tnsnames.ora. An example entry in the tnsnames.ora follows: listener_name= (DESCRIPTION= (ADDRESS=(PROTOCOL=tcp)(HOST=sales-server)(PORT=1421)))
  • #17: Statically Configuring the Listener for HTTP Connections to Oracle9i JVM require TCP/IP or TCP/IP with SSL listening protocol addresses. If both the listener and database are Oracle9i, configuration occurs dynamically during service registration. If the database is Oracle8i or earlier, configure listening addresses statically using the following procedure, even if an Oracle9i listener is used. 1.Start Oracle Net Manager. 2.In the navigator pane, expand Local &amp;gt; Listeners. 3.Select an existing listener. 4.From the list in the right pane, select Listening Locations. 5.Select Add Address. A new address tab appears. 6.Select the TCP/IP or TCP/IP with SSL protocol from the Protocol list. 7.Enter the host name of the database in the Host field. 8.Enter port 2481 in the Port field if the chosen protocol is TCP/IP, or enter port 2482 in the Port field if the chosen protocol is TCP/IP with SSL. 9.Select Statically dedicate this address for JServer connections.
  • #18: Listener Control Utility When the lsnrctl command is issued, the command will work against the default listener LISTENER unless the SET LISTENER command is executed. Another way to control different listeners is to use the listener name as a command modifier: $ lsnrctl start listener02 Windows Command Line Syntax On Windows, use the following command to start the Listener Control utility: C:\&amp;gt; lsnrctl &amp;lt;command name&amp;gt;
  • #19: LSNRCTL Commands Starting the Listener You can use the START command to start the listener from the Listener Control utility. Any manual changes to the listener.ora file must be made when the listener is shut down. The argument for the START command is the name of the listener, and if no argument is specified, the current listener is started. If a current listener is not defined, LISTENER is started. LSNRCTL&amp;gt; START listener_name or $lsnrctl start listener_name On Windows NT, the listener can also be started through the Control Panel: 1.Double-click the Services icon in the Control Panel window. 2.Select the Oraclehome_nameTNSListener service (the service name if you are using the default listener name LISTENER) or Oraclehome_nameTNSListenerlsnr, where lsnr is the nondefault listener name. 3.Click Start to start the service. 4.In the Services window, click Close.
  • #20: SET and SHOW Modifiers The SET modifier is used to change listener parameters in the Listener Control utility environment. The SHOW modifier is used to display the values of the parameters set for the listener.