aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorPetter Reinholdtsen <pere@hungry.com>2006-08-24 08:50:19 +0000
committerPetter Reinholdtsen <pere@hungry.com>2006-08-24 08:50:19 +0000
commitb432aeac18c27f343374d9ce1d616bb48225a815 (patch)
tree4e647c693832ef7e17ed1940f9c4445147803bda
parent406fe8d52ca2b6be3a0ec90b1aa25a2ceca56565 (diff)
downloadsitesummary-b432aeac18c27f343374d9ce1d616bb48225a815.tar.gz
sitesummary-b432aeac18c27f343374d9ce1d616bb48225a815.tar.bz2
sitesummary-b432aeac18c27f343374d9ce1d616bb48225a815.tar.xz
Reduce noise level and lot to syslog when something fail.
-rw-r--r--sitesummary-client12
1 files changed, 11 insertions, 1 deletions
diff --git a/sitesummary-client b/sitesummary-client
index 2f053da..de31f66 100644
--- a/sitesummary-client
+++ b/sitesummary-client
@@ -15,6 +15,12 @@ fragdirs="/usr/lib/sitesummary/collect.d \
# storage area on diskless clients, so use /tmp/.
tmpdir=/tmp/sitesummary-$$
+log() {
+ msg="$@"
+ echo "$msg"
+ logger -p user.info -t sitesummary-client "$msg"
+}
+
# Read the package default
[ -f /usr/share/sitesummary/config ] && . /usr/share/sitesummary/config
for confdir in \
@@ -39,5 +45,9 @@ done
tar zcf $tmpdir.tar.gz .
for url in $serverurls ; do
#WGETOPTS="--no-check-certificate"
- wget $WGETOPTS --post-file $tmpdir.tar.gz -O $tmpdir.result $url
+ if wget -q $WGETOPTS --post-file $tmpdir.tar.gz -O $tmpdir.result $url ; then
+ :
+ else
+ log "error: unable to submit to '$url'"
+ fi
done