go-ipfs version: 0.4.23-6ce9a355f
Repo version: 7
System version: amd64/linux
Golang version: go1.13.7
The random port selection for outgoing connections doesn't seem to be working as a fallback if the port cannot be reused (or the debug output is wrong?):
Then the dials fail, because the port cannot be reused, and the log suggests, that the daemon tries to use a random port, but just uses the default port instead - which obviously fails:
Feb 21 22:03:16 i3 ipfs[14426]: 22:03:16.977 DEBUG reuseport-: failed to reuse port, dialing with a random port: dial tcp4 0.0.0.0:4001->172.x.x.x:4001: connect: cannot assign requested address reuseport.go:60
Found while digging to the debug code for https://github.com/ipfs/go-ipfs/issues/6921
That's... confusing. We log that _before_ we try dialing again. The error is from the first (reuseport) dial, not the second.