From d9a1ed52f947d7b14c3ab6c10e6135f2e15fa24f Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Karol=20Bary=C5=82a?= Date: Wed, 12 Feb 2025 12:50:05 +0100 Subject: [PATCH] CCM: Fix improper display of ip prefix. When passing `NetPrefix` as an argument to `ccm populate` it is formatted using `.to_string()` method. Result of this is then concatenated with the node id, and the result is an "ip" that ccm tries to find in Scylla logs to determine that the node is UP. `.to_string()` implementation was displaying the whole ip, instead of it's first 3 octets, resulting in CCM looking for ips like `127.0.1.02`. Instead the `to_str()` method should be used, that produces ccm-compatible form of the ip range. --- scylla/tests/ccm_integration/ccm/ip_allocator.rs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/scylla/tests/ccm_integration/ccm/ip_allocator.rs b/scylla/tests/ccm_integration/ccm/ip_allocator.rs index e45d142281..e2fce64fc6 100644 --- a/scylla/tests/ccm_integration/ccm/ip_allocator.rs +++ b/scylla/tests/ccm_integration/ccm/ip_allocator.rs @@ -57,7 +57,7 @@ impl NetPrefix { impl std::fmt::Display for NetPrefix { fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result { - write!(f, "{}", self.0) + write!(f, "{}", self.to_str()) } }