Skip to content

Instantly share code, notes, and snippets.

@jfrobbins
Created July 26, 2013 01:58
Show Gist options
  • Select an option

  • Save jfrobbins/6085456 to your computer and use it in GitHub Desktop.

Select an option

Save jfrobbins/6085456 to your computer and use it in GitHub Desktop.
post some db and network stats for a pump
#!/bin/bash
server=yourpump.pump
port=443
user=yourpumpuser
cd /path/to/pump.io/bin
note=$(echo "DB Stats:
<pre>
")$(du -hs /var/lib/redis/dump*)$(echo "
")$(echo "
")$(redis-cli info|egrep 'memory_human|memory_peak_human')$(echo "
</pre>")$(echo "Network Stats:
")$(echo "<pre>
")$(vnstat)$(echo "
</pre>")
./pump-post-note -p -s $server -P $port -p -u $user -n "$note"
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment