create table t (id number, sometext varchar2(50),my_date date) tablespace data;
create or replace procedure manysessions as
v_jobno number:=0;
begin
FOR i in 1..10 LOOP
dbms_job.submit(v_jobno,’manyinserts;’, sysdate);
END LOOP;
commit;
end;
/
exec manysessions;
create table t (id number, sometext varchar2(50),my_date date) tablespace data;
create or replace procedure manysessions as
v_jobno number:=0;
begin
FOR i in 1..10 LOOP
dbms_job.submit(v_jobno,’manyinserts;’, sysdate);
END LOOP;
commit;
end;
/
exec manysessions;
./oratop -f -d -i 10 / as sysdba
For A.

For B

Section 1 - database Global Database information Version : Oracle major version role : database_role db name : db_unique_name time [s]: time as of the most recent stats (hh24:mi:ss) up [T]: database uptime ins [N]: total number of instance(s) sn [c,N]: total user sessions (active/inactive) us [c,N]: number of distinct users mt [s,N]: global database memory total (sga+pga) fra [N]: flashback recovery area %used, (red > 90%) er [N]: diag active problem count (faults) % db [s,N]: database time as %(dbtime/cpu) (red if > 99%)Section 2 - instance Top 5 Instance(s) Activity o Ordered by Database time desc ID [c,N]: inst_id (instance id) %CPU [m,N]: host cpu busy %(busy/busy+idle). (red if > 90%) LOAD [m,N]: current os load. (red if > 2*#cpu & high cpu) %DCU [m,N]: db cpu otusef as %host cpu. (red if > 99% & high AAS) AAS [s,N]: Average Active Sessions. (red if > #cpu) ASC [c,N]: active Sessions on CPU ASI [c,N]: active Sessions waiting on user I/O ASW [c,N]: active Sessions Waiting, non-ASI (red if > ASC+ASI) ASP [m,N]: active parallel sessions (F/G) AST [c,N]: Active user Sessions Total (ASC+ASI+ASW) UST [c,N]: user Sessions Total (ACT/INA) MBPS [m,N]: i/o megabytes per second (throughput) IOPS [m,N]: i/o requests per second IORL [m,T]: avg synchronous single-block read latency. (red > 20ms) LOGR [s,N]: logical reads per sec PHYR [s,N]: physical reads per sec) PHYW [s,N]: physical writes per sec %FR [s,N]: shared pool free % PGA [s,N]: total pga allocated TEMP [s,N]: temp space used UTPS [s,N]: user transactions per sec UCPS [c,m,N]: user calls per sec SSRT [c,m,T]: sql service response time (T/call) DCTR [m,N]: database cpu time ratio DWTR [m,N]: database wait time ratio. (red if > 50 & high ASW) %DBT [s,N]: instance %Database Time (e.g. non-rac shows 100%)Section 3 - db wait events Top 5 Timed Events o Cluster-wide, non-idle o Ordered by wait time desc EVENT : wait event name. (red if active) (RT) : Real-Time mode WAITS : total waits TIME(s) : total wait time in seconds) AVG_MS : average wait time in milliseconds PCT : percent of wait time (all events) WAIT_CLASS : name of the wait classSection 4 - process o Non-Idle processes o Ordered by event wait time desc ID [N]: inst_id. (red if blocking) SID [N]: session identifier. (red if blocking) SPID [N]: server process os id USERNAME : Oracle user name PROGRAM : process program name SRV : SERVER (dedicated, shared, etc.) SERVICE : db service_name PGA [N]: pga_used_mem. (red if continuously growing) SQL_ID/BLOCKER : sql_id or the final blocker's (inst:sid, in red) OPN : operation name, e.g. select E/T [T]: session elapsed time (active/inactive) STA : ACTive|INActive|KILled|CAChed|SNIped STE : process state, e.g. on CPU or user I/O or WAIting WAIT_CLASS : wait_class for the named event EVENT/*LATCH : session wait event name. Auto toggle with *latch name. (red if process is hung/spin) W/T [T]: event wait time. (red if > 1s)
For Case B:-
We had 20 CPU,so our all 10 jobs are running (Status :-R means Running).Also note 44.4 % CPU is used because out of 20 CPU we are using 10 CPU.Hence there is 50% idle CPU.


For Case B:-

SQL> select bytes/1024/1024/1024 from dba_segments where segment_name='T'; BYTES/1024/1024/1024 ------------------- 7.375
For Case A:-

For Case B:-

For Case A:-

For Case B:-

for Case A:

For Case B:

For Case A:-
For Case A:-

For Case B:-

For Case A:-

For Case B:-

For case A,
For Case A:-

For Case B:-

For case A:-
For Case A:-

For Case B:-

For Case A,
For case A:-

For case B:-

For case A:-

For case B:-


For A:-

For B:-
