From: Sukadev Bhattiprolu <sukadev-23VcF4HTsmIX0ybBhKVfKdBPR1lH4CV8@public.gmane.org>
To: serue-r/Jw6+rmf7HQT0dZR+AlfA@public.gmane.org
Cc: Containers
<containers-cunTk1MwBs9QetFLy7KEm3xJsTq8ys+cHZ5vskTnxNA@public.gmane.org>
Subject: [PATCH][cr-tests] Have ps list all threads in application
Date: Thu, 10 Dec 2009 20:08:40 -0800 [thread overview]
Message-ID: <20091211040840.GA20947@us.ibm.com> (raw)
From: Sukadev Bhattiprolu <sukadev-23VcF4HTsmIX0ybBhKVfKdBPR1lH4CV8@public.gmane.org>
Date: Tue, 8 Dec 2009 23:13:05 +0530
Subject: [PATCH 1/4] Have ps list all threads in application
Have ps list all threads in application
Signed-off-by: Sukadev Bhattiprolu <sukadev-23VcF4HTsmIX0ybBhKVfKdBPR1lH4CV8@public.gmane.org>
---
process-tree/run-pthread1.sh | 14 +++++++-------
1 files changed, 7 insertions(+), 7 deletions(-)
diff --git a/process-tree/run-pthread1.sh b/process-tree/run-pthread1.sh
index 800ff30..e616753 100755
--- a/process-tree/run-pthread1.sh
+++ b/process-tree/run-pthread1.sh
@@ -40,7 +40,7 @@ checkpoint()
ret=$?
if [ $ret -ne 0 ]; then
$ECHO "***** FAIL: Checkpoint of $pid failed"
- ps aux |grep $TEST_CMD >> $SCRIPT_LOG
+ ps -efL |grep $TEST_CMD >> $SCRIPT_LOG
exit 1;
fi
}
@@ -73,7 +73,7 @@ function create_container()
pid=`cat $TEST_PID_FILE`;
if [ "x$pid" == "x" ]; then
$ECHO "***** FAIL: Invalid container-init pid $pid"
- ps aux |grep $TEST_CMD >> $SCRIPT_LOG
+ ps -efL |grep $TEST_CMD >> $SCRIPT_LOG
exit 1
fi
$ECHO "Created container with pid $pid" >> $SCRIPT_LOG
@@ -93,7 +93,7 @@ function restart_container
if [ $ret -ne 0 ]; then
$ECHO "***** FAIL: Restart of $pid failed"
- ps aux |grep $TEST_CMD >> $SCRIPT_LOG
+ ps -efL |grep $TEST_CMD >> $SCRIPT_LOG
exit 1;
fi
}
@@ -160,7 +160,7 @@ while [ $cnt -lt 15 ]; do
$ECHO "\t- Done creating container, cinit-pid $pid"
wait_for_checkpoint_ready
- ps aux |grep $TEST_CMD >> $SCRIPT_LOG
+ ps -efL |grep $TEST_CMD >> $SCRIPT_LOG
# override default freezerdir
if [ -d $freezerdir ]; then
@@ -169,7 +169,7 @@ while [ $cnt -lt 15 ]; do
freezerdir=$freezermountpoint/$pid
freeze_pid $pid
- num_pids1=`ps aux |grep $TEST_CMD | wc -l`
+ num_pids1=`ps -efL |grep $TEST_CMD | wc -l`
create_fs_snapshot
@@ -189,8 +189,8 @@ while [ $cnt -lt 15 ]; do
sleep 3;
- num_pids2=`ps aux |grep $TEST_CMD | wc -l`
- ps aux |grep $TEST_CMD >> $SCRIPT_LOG
+ num_pids2=`ps -efL |grep $TEST_CMD | wc -l`
+ ps -efL |grep $TEST_CMD >> $SCRIPT_LOG
$ECHO "\t- num_pids1 $num_pids1, num_pids2 $num_pids2";
# ns_exec pid is parent-pid of restarted-container-init
--
1.6.0.4
reply other threads:[~2009-12-11 4:08 UTC|newest]
Thread overview: [no followups] expand[flat|nested] mbox.gz Atom feed
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20091211040840.GA20947@us.ibm.com \
--to=sukadev-23vcf4htsmix0ybbhkvfkdbpr1lh4cv8@public.gmane.org \
--cc=containers-cunTk1MwBs9QetFLy7KEm3xJsTq8ys+cHZ5vskTnxNA@public.gmane.org \
--cc=serue-r/Jw6+rmf7HQT0dZR+AlfA@public.gmane.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox