forked from cloudkick/agent-plugins
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Added ubic service manager process monitor
- Loading branch information
Showing
1 changed file
with
22 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,22 @@ | ||
#!/bin/bash | ||
|
||
if [ $# -ne 1 ]; then | ||
echo "Usage: $0 <ubic process>" | ||
exit | ||
fi | ||
|
||
process=$1 | ||
|
||
perl -I/usr/local/lib/perl5/site_perl/5.14.1 \ | ||
-I/usr/local/lib/perl5/site_perl/5.14.1/x86_64-linux \ | ||
/usr/local/bin/ubic status | \ | ||
grep -i $process | \ | ||
grep "running" >/dev/null 2>&1 | ||
|
||
if [ $? -ne 0 ]; then | ||
echo "status err no process running!" | ||
else | ||
echo "status ok ok" | ||
fi | ||
|
||
exit |
a3689f8
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Hi. Finally, I've found you!
You asked ubic-related questions on #ubic irc channel some time ago, but both times I was afk and couldn't find any of your contacts online afterward (I tried pretty hard, though!).
Just wanted to tell you that channel is not dead, and if you still have any questions, I'll be happy to help you.
PS: I'm mmcleric, Ubic's author. Sorry for abusing comments as a method of communication :)