1
0
Fork 0
mirror of https://github.com/munin-monitoring/contrib.git synced 2025-07-25 02:18:08 +00:00

Fixed bug wrt config command when no filtering was specified

This commit is contained in:
Troels Arvin 2010-08-31 17:33:50 +02:00 committed by Steve Schnepp
parent 926efac501
commit 4323adbf08

View file

@ -54,7 +54,7 @@ X and Y are translated into a regular expression like:
# SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
# ====================================================================
# $Id: scsi_queue 13409 2010-07-26 14:58:15Z tra $
# $Id: scsi_queue 13630 2010-08-31 15:29:14Z tra $
# Note to self:
# The fields in /proc/scsi/sg/devices are:
@ -84,7 +84,7 @@ def bailout(msg):
def print_config(devices,filter_from,filter_through):
title_qualification = ''
if devfilter_regex:
if filter_from and filter_through:
title_qualification = ' for devices sd%s through sd%s' % (filter_from,filter_through)
print 'graph_title SCSI queue busy values' + title_qualification
@ -217,6 +217,8 @@ if n_args > 2:
devfilter_regex = None
called_as = os.path.basename(sys.argv[0])
match = re.match(my_canonical_name+'_([^_])_through_([^_])', called_as)
filter_from = None
filter_through = None
if match:
filter_from = match.group(1)
filter_through = match.group(2)