diff options
author | Dave Brolley <brolley@redhat.com> | 2008-08-08 15:11:36 -0400 |
---|---|---|
committer | Dave Brolley <brolley@redhat.com> | 2008-08-08 15:11:36 -0400 |
commit | d5658775da9fa0ac792eb3f874df9f7c4d60de7e (patch) | |
tree | f20be52c08db77ff67bf3a448a76339aa5e4c98c /stap-start-server | |
parent | a4cc1d081ede55ed6c743147d62fcc3519f73a71 (diff) | |
download | systemtap-steved-d5658775da9fa0ac792eb3f874df9f7c4d60de7e.tar.gz systemtap-steved-d5658775da9fa0ac792eb3f874df9f7c4d60de7e.tar.xz systemtap-steved-d5658775da9fa0ac792eb3f874df9f7c4d60de7e.zip |
Start/stop the systemtap server from systemtap.exp and not in the top level Makefile.
Diffstat (limited to 'stap-start-server')
-rwxr-xr-x | stap-start-server | 12 |
1 files changed, 7 insertions, 5 deletions
diff --git a/stap-start-server b/stap-start-server index d143e269..eea86526 100755 --- a/stap-start-server +++ b/stap-start-server @@ -16,9 +16,11 @@ stap-serverd </dev/null >/dev/null 2>&1 & server_pid=$! -# Exit if the server did not start ok -(ps | grep -q $server_pid) || exit 1 +# Make sure the server is started +for ((attempt=0; $attempt < 5; ++attempt)) +do + stap-find-servers >/dev/null 2>&1 && echo $server_pid && exit 0 + sleep 1 +done -# The server started ok. Echo its process id. -echo $server_pid -exit 0 +exit 1 # server did not start |