Add support for diskless machines to system monitor
@@ -39,6 +39,9 @@ class SystemMonitor:
disk_ioc = psutil.disk_io_counters()
except Exception:
self._collect_disk_io_counters = False
+ else:
+ if disk_ioc is None: # diskless machine
+ self._collect_disk_io_counters = False
else:
self.last_time_disk = time()
self.read_bytes_disk = deque(maxlen=n)
