Created
May 16, 2013 14:28
-
-
Save gnidan/5592114 to your computer and use it in GitHub Desktop.
count remote httpd process in i3 status bar
This file contains hidden or 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
#!/bin/sh | |
# prepend i3status with wb01 | |
# metrics | |
i3status | while : | |
do | |
apache1=`ssh apache1 'ps -ef | grep httpd | wc -l'` | |
apache2=`ssh apache2 'ps -ef | grep httpd | wc -l'` | |
read line | |
echo "wb01: $apache1 | wb02: $apache2 | $line" || exit 1 | |
done |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment