How to find cpu and memory information of oracle database server

Below script is useful in getting CPU, memory and core, socket information of a database server from SQL prompt. SCRIPT: [crayon-5cbe70f0a14a2102471389/] OUTPUT: [crayon-5cbe70f0a14a9107485901/]

Find sessions consuming lot of CPU

Use below query to find the sessions using a lot of CPU. [crayon-5cbe70f0a1bc2353233381/]

Get ospid from sid

Below is the script to find the os server process id of a SID. [crayon-5cbe70f0a1e4c337872129/] SEE ALSO – Get sid from ospid

Get hourly database growth report

Below script will generate the database size for past few days(per hour) [crayon-5cbe70f0a20c5079059552/]

Find sessions holding library cache lock

Below are the scripts for finding the sessions holding libary cache lock: For standalone db: [crayon-5cbe70f0a2347887923741/] For RAC DB: [crayon-5cbe70f0a234d642927173/] or [crayon-5cbe70f0a235090543...

Skip to toolbar