Oracle FAQ Your Portal to the Oracle Knowledge Grid
HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US
 

Home -> Community -> Mailing Lists -> Oracle-L -> script to calculate memory usage by oracle processes in AIX ?

script to calculate memory usage by oracle processes in AIX ?

From: Prem Khanna J <premj_at_rediffmail.com>
Date: 9 Jul 2004 03:27:16 -0000
Message-ID: <20040709032716.3132.qmail@webmail10.rediffmail.com>


Hi All,
the env is oracle 9.2.0.4/AIX5.2

in order to calculate the memory used by each oracle server process on AIX,i am using the following method (as said in a metalink doc 123754.1):

$ps -ef | grep oracledev01 | grep -v grep | awk '{print $2}'
this gives me the PID of all oracle server process.around 60 in my case.here dev01 is my ORACLE_SID.

Then...

$ps v <2023464> | awk '{print $7-$10}

this gives me the memory used by one oracle server process. i have to replace the PID within <> above and do it for 60 processes.

so i made it like

$ps -ef | grep oracledev01 | grep -v grep | awk '{print $2}' | xargs ps v <2023464> | awk '{print $7-$10}

but this just gives the output for the first process only and not all 60 processes .excuse me for my poor scripting.i am new to it.How do i do this in a small shell/perl script ? can someone help me ?

Regards,
Prem.



Please see the official ORACLE-L FAQ: http://www.orafaq.com

To unsubscribe send email to: oracle-l-request_at_freelists.org put 'unsubscribe' in the subject line.
--
Archives are at http://www.freelists.org/archives/oracle-l/
FAQ is at http://www.freelists.org/help/fom-serve/cache/1.html
-----------------------------------------------------------------
Received on Thu Jul 08 2004 - 22:23:56 CDT

Original text of this message

HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US