mirror of
https://github.com/dennypage/dpinger.git
synced 2024-05-19 06:50:01 +00:00
Confirm that the rrd file is writable before starting
This commit is contained in:
@ -15,6 +15,11 @@ dpinger=/usr/local/bin/dpinger
|
||||
|
||||
|
||||
rrdfile="${name}.rrd"
|
||||
if [ \! -w ${rrdfile} ]
|
||||
then
|
||||
echo "$0: file \"${rrdfile}\" does not exist or is not writable"
|
||||
exit 1
|
||||
fi
|
||||
|
||||
${dpinger} -f ${options} -s 500m -t 60s -r 60s ${targetip} |
|
||||
while read -r latency stddev loss; do
|
||||
|
Reference in New Issue
Block a user