Below script is useful in getting CPU, memory and core, socket information of a database server from SQL prompt. SCRIPT: [crayon-5c40cee7474c6558366750/] OUTPUT: [crayon-5c40cee7474ce857263417/]
Use below query to find the sessions using a lot of CPU. [crayon-5c40cee747c2b786343361/]
Below is the script to find the os server process id of a SID. [crayon-5c40cee747e99331133109/] SEE ALSO – Get sid from ospid
Below script will generate the database size for past few days(per hour) [crayon-5c40cee748100953164758/]
Below are the scripts for finding the sessions holding libary cache lock: For standalone db: [crayon-5c40cee748391929421000/] For RAC DB: [crayon-5c40cee748397393393312/] or [crayon-5c40cee74839a05243...