April 1999
Intermediate to advanced
552 pages
15h 39m
English
---------------------------------------------------------------------------
-- Filename: busydisp.sql
-- Purpose: Provides stats indicating whether the dispatcher processes
-- are overly taxed.
-- Author: Chas. Dye (cdye@excitecorp.com)
-- Date: 6-Aug-1998
---------------------------------------------------------------------------
column network heading "Protocol" format a40
column rate heading "Total Busy Rate|>50%=>Add Dispatchers" format 99.99
SELECT network,
100*(sum(busy)/(sum(busy)+sum(idle))) rate
FROM v$dispatcher
GROUP BY network
/
column protocol heading "Protocol" format a40
column Wait heading "Average Wait|(hundredths of seconds)" format a30
SELECT network Protocol,
decode( sum(totalq), 0, 'No Responses',
to_char(sum(wait)/sum(totalq), 'FM9999.90')) Wait
FROM v$queue q, v$dispatcher d
WHERE q.type = 'DISPATCHER'
AND q.paddr = d.paddr
GROUP BY network
/