Database Reference
In-Depth Information
Here, I used a query to discover the process ID (PID) associated with my dedicated server (the SPID from
V$PROCESS is the operating system PID of the process that was being used during the execution of that query).
The output of /bin/ps -fp includes the parent process id (PPID) and shows the dedicated server process, 18571,
is the child of my SQL*Plus process: process id 18570.
Shared Server Connections
Let's now take a look at the shared server process in more detail. This type of connection mandates the use of Oracle
Net even if the client and server are on the same machine—you cannot use a shared server without using the Oracle
TNS listener. As described earlier, the client application will connect to the Oracle TNS listener and will be redirected
or handed off to a dispatcher. The dispatcher acts as the conduit between the client application and the shared server
process. Figure 5-2 is a diagram of the architecture of a shared server connection to the database.
Network Access
Memory Access
Client
Application
SGA
S
S
S
Shared
Servers
Dispatcher
Request
Queue
Response
Queue
Figure 5-2. Typical shared server connection
Here, we can see that the client applications, with the Oracle libraries linked in, will be physically connected to a
dispatcher process. We may have many dispatchers configured for any given instance, but it is not uncommon to have
just one dispatcher for many hundreds—even thousands—of users. The dispatcher is simply responsible for receiving
inbound requests from the client applications and putting them into a request queue in the SGA. The first available
shared server process from the pool of pre-created shared server processes will pick up the request from the queue
and attach the UGA of the associated session (the boxes labeled “S” in Figure 5-2 ). The shared server will process that
request and place any output from it into the response queue. The dispatcher constantly monitors the response queue
for results and transmits them back to the client application. As far as the client is concerned, it can't really tell if it is
connected via a dedicated server or a shared connection—they appear to be the same. Only at the database level is
the difference apparent.
 
 
Search WWH ::




Custom Search