From de6d6542d28f38ac363fa237efa2fdf2d8b76091 Mon Sep 17 00:00:00 2001 From: Andrey Shevtsov Date: Mon, 16 Sep 2019 14:38:17 -0400 Subject: [PATCH] Handle NVMe devices correctly in diskstat.py --- gmond/python_modules/disk/diskstat.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/gmond/python_modules/disk/diskstat.py b/gmond/python_modules/disk/diskstat.py index 4cde607b1..2695659b0 100644 --- a/gmond/python_modules/disk/diskstat.py +++ b/gmond/python_modules/disk/diskstat.py @@ -197,7 +197,8 @@ def get_partitions(): continue device_name = line.split()[3] device_ends_with_number = re.search('\d$', device_name) - if 'md' in device_name or not device_ends_with_number: + nvme_device = re.search('^nvme\dn1$', device_name) + if 'md' in device_name or nvme_device or not device_ends_with_number: # only include md devices and base block devices devices.append(device_name) out = ' '.join(devices)