From c30c48c9166e4cb5e25dc53f372c2307f6a92aee Mon Sep 17 00:00:00 2001 From: Martin Kourim Date: Wed, 18 Dec 2024 20:11:57 +0100 Subject: [PATCH] fix(netstat_tools): remove CLOSE from netstat command The netstat command was modified to exclude the 'CLOSE' state from the output. This change ensures that only 'LISTEN' and 'TIME_WAIT' states are included, and so no client connection can be matched. --- cardano_node_tests/cluster_management/netstat_tools.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/cardano_node_tests/cluster_management/netstat_tools.py b/cardano_node_tests/cluster_management/netstat_tools.py index f31b1f560..f5c69e2f9 100644 --- a/cardano_node_tests/cluster_management/netstat_tools.py +++ b/cardano_node_tests/cluster_management/netstat_tools.py @@ -15,7 +15,7 @@ def get_netstat_out() -> str: """Get output of the `netstat` command.""" try: return helpers.run_command( - "netstat -pant | grep -E 'LISTEN|TIME_WAIT|CLOSE'", ignore_fail=True, shell=True + "netstat -pant | grep -E 'LISTEN|TIME_WAIT'", ignore_fail=True, shell=True ).decode() except Exception as excp: LOGGER.error(f"Failed to fetch netstat output: {excp}") # noqa: TRY400