On Wed, Mar 10, 2010 at 10:11 AM, Lucio Correia <[email protected]> wrote:
> Fixes cut command. The output is empty with -f1, it should be -f2.
>
> Signed-off-By: Lucio Correia <[email protected]>
>
> diff -Nurp
> ltp-full-20100228.orig/testcases/kernel/controllers/cpuacct/cpuacct_setup.sh
> ltp-full-20100228.new/testcases/kernel/controllers/cpuacct/cpuacct_setup.sh
> ---
> ltp-full-20100228.orig/testcases/kernel/controllers/cpuacct/cpuacct_setup.sh
> 2010-03-01 11:58:28.000000000 -0300
> +++
> ltp-full-20100228.new/testcases/kernel/controllers/cpuacct/cpuacct_setup.sh
> 2010-03-10 14:59:50.000000000 -0300
> @@ -58,7 +58,7 @@ cleanup ()
> }
> task_kill ()
> {
> - for i in `ps -e | grep cpuacct_taski* | cut -d" " -f1`
> + for i in `ps -e | grep cpuacct_taski* | cut -d" " -f2`
> do
> kill -SIGUSR1 $i
> done
That may fix it on your distro, but it's not guaranteed to be
portable as different versions of ps(1) do different things. A better
idea than the one proposed above would be:
ps -eo 'pid,command' | grep cpuacct_taski | grep -v grep
Jiri may have a better idea of what to do in this case...
Thanks,
-Garrett
------------------------------------------------------------------------------
Download Intel® Parallel Studio Eval
Try the new software tools for yourself. Speed compiling, find bugs
proactively, and fine-tune applications for parallel performance.
See why Intel Parallel Studio got high marks during beta.
http://p.sf.net/sfu/intel-sw-dev
_______________________________________________
Ltp-list mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/ltp-list