diff --git a/sysSentry-1.0.2/src/python/sentryCollector/collect_config.py b/sysSentry-1.0.2/src/python/sentryCollector/collect_config.py index 5aa38ec89e6c5729892b4e1f67c83f1967ed48e2..7ca9898bf27197f331a0a302742b21fc6a31a9b7 100644 --- a/sysSentry-1.0.2/src/python/sentryCollector/collect_config.py +++ b/sysSentry-1.0.2/src/python/sentryCollector/collect_config.py @@ -127,9 +127,9 @@ class CollectConfig: CONF_IO, CONF_IO_MAX_SAVE, CONF_IO_MAX_SAVE_DEFAULT) result_io_config[CONF_IO_MAX_SAVE] = CONF_IO_MAX_SAVE_DEFAULT # disk - disk = io_map_value.get(CONF_IO_DISK).lower() + disk = io_map_value.get(CONF_IO_DISK) if disk: - disk_str = disk.replace(" ", "") + disk_str = disk.lower().replace(" ", "") pattern = r'^[a-zA-Z0-9-_,]+$' if not re.match(pattern, disk_str): logging.warning("module_name = %s section, field = %s is incorrect, use default %s", diff --git a/sysSentry-1.0.2/src/python/sentryCollector/collect_io.py b/sysSentry-1.0.2/src/python/sentryCollector/collect_io.py index 11c9d9ab9249b77fa173b1eab498bd237c51e753..f699c3cf176394ab96e64fe5eaa18712befb3134 100644 --- a/sysSentry-1.0.2/src/python/sentryCollector/collect_io.py +++ b/sysSentry-1.0.2/src/python/sentryCollector/collect_io.py @@ -156,7 +156,7 @@ class CollectIo(): for line in file: count += line.count('.op=' + Io_Category[category].upper()) if count > 0: - logging.info(f"io_dump info : {disk_name}, {stage}, {category}, {count}") + logging.info(f"io_dump info : {disk_name}, {stage}, {Io_Category[category]}, {count}") except FileNotFoundError: logging.error("The file %s does not exist.", io_dump_file) return count @@ -318,7 +318,7 @@ class CollectIo(): curr_io_length = self.get_ebpf_io_length(curr_latency=curr_latency, prev_latency=prev_latency) curr_io_dump = self.get_ebpf_io_dump(curr_io_dump_count=curr_io_dump_count, prev_io_dump_count=prev_io_dump_count) if curr_io_dump > 0: - logging.info(f"ebpf io_dump info : {disk_name}, {stage}, {category}, {curr_io_dump}") + logging.info(f"ebpf io_dump info : {disk_name}, {stage}, {io_type}, {curr_io_dump}") IO_GLOBAL_DATA[disk_name][stage][io_type].insert(0, [curr_lat, curr_io_dump, curr_io_length, curr_iops]) logging.debug(f"ebpf collect data : {IO_GLOBAL_DATA}") elapsed_time = time.time() - start_time