From: Dennis Schafroth Date: Fri, 11 Mar 2011 12:27:56 +0000 (+0100) Subject: Merge branch 'master' of ssh://git.indexdata.com/home/git/pub/pazpar2 X-Git-Tag: v1.5.6~41 X-Git-Url: http://jsfdemo.indexdata.com/?a=commitdiff_plain;h=e2de92cec639e50141ac603f78f4020c5cd054ed;hp=8432e60d3fa90e5bb4abf49607fdeca3fa8a19ba;p=pazpar2-moved-to-github.git Merge branch 'master' of ssh://git.indexdata.com/home/git/pub/pazpar2 --- diff --git a/.gitignore b/.gitignore index c54152a..1b85e92 100644 --- a/.gitignore +++ b/.gitignore @@ -15,3 +15,4 @@ Doxyfile dox deb-src Debug +*~ \ No newline at end of file diff --git a/etc/check-pazpar2.sh b/etc/check-pazpar2.sh new file mode 100755 index 0000000..c5d97d6 --- /dev/null +++ b/etc/check-pazpar2.sh @@ -0,0 +1,68 @@ +#!/bin/sh + +usage() +{ +cat < /dev/null` + +if [ $? -ne 0 ] ; then + MSG="FATAL failed to communicate with pazpar2" + exit 128 +fi + +if [ "$WARN_LEVEL" != "" ] ; then + if [ $SESSIONS -gt $WARN_LEVEL ]; then + MSG="WARNING " + rc=1; + fi +fi + +if [ "$CRIT_LEVEL" != "" ] ; then + if [ $SESSIONS -gt $CRIT_LEVEL ]; then + MSG="CRITICAL " + rc=2; + fi +fi + +echo "SESSIONS $MSG $SESSIONS ($CLIENTS) | $SESSIONS;$WARN_LEVEL;$CRIT_LEVEL " +exit $rc + diff --git a/etc/server-status-nagios.xsl b/etc/server-status-nagios.xsl new file mode 100644 index 0000000..56f53fa --- /dev/null +++ b/etc/server-status-nagios.xsl @@ -0,0 +1,26 @@ + + + + + + + + + + + export SESSIONS= + + + + export CLIENTS= + + + + export RESULTSETS= + + + + + + diff --git a/test/test_sru-proxy.urls b/test/test_sru-proxy.urls index e405879..0c9d239 100644 --- a/test/test_sru-proxy.urls +++ b/test/test_sru-proxy.urls @@ -1,4 +1,4 @@ -http://localhost:9763/search.pz2?command=init&clear=0&service=sru-proxy +http://localhost:9763/search.pz2?command=init&clear=1&service=sru-proxy http://localhost:9763/search.pz2?session=1&command=settings&pz:sru%5Bkb.dadsthirdnode.cvt.dk%2Fsru-proxy%5D=get&pz%3Aname%5Bkb.dadsthirdnode.cvt.dk%2Fsru-proxy%5D=sru-proxy&pz%3Axslt%5Bkb.dadsthirdnode.cvt.dk%2Fsru-proxy%5D=dads-pz2.xsl&pz%3Aqueryencoding%5Bkb.dadsthirdnode.cvt.dk%2Fsru-proxy%5D=UTF-8&pz%3Aapdulog%5Bkb.dadsthirdnode.cvt.dk%2Fsru-proxy%5D=1&pz%3Asru_version%5Bkb.dadsthirdnode.cvt.dk%2Fsru-proxy%5D=1.1&pz%3Aextra_args%5Bkb.dadsthirdnode.cvt.dk%2Fsru-proxy%5D=%26x-facet_def%3Ddtic_test%26x-noxsl%3D1&pz:query_syntax%5Bkb.dadsthirdnode.cvt.dk%2Fsru-proxy%5D=pqf http://localhost:9763/search.pz2?session=1&command=search&query=water 4 http://localhost:9763/search.pz2?session=1&command=show&block=1