diff --git a/network/ports.go b/network/ports.go index 0a4fa43d..ebf290e6 100644 --- a/network/ports.go +++ b/network/ports.go @@ -41,6 +41,11 @@ nextPort: } } + // Log if it took more than 10 attempts. + if i >= 10 { + log.Warningf("network: took %d attempts to find a suitable unused port for pre-auth", i+1) + } + // The checks have passed. We have found a good unused port. return port, true }