Hi ,
Have the following code
But have an issue trying to get it to interpret the the while loop
i.e print the total any ideas
Code:
t_awk="awk"
fn "pmap" "bash" "-c 'while ((1));do `pmap @PID@ | grep total | ${t_awk} {'print $2'}`; sleep 1 ; done'"
fn ()
{
cmd[$cnt]="${1}"
args[cnt]="${2}"
}