I've got the same problem as mentioned here
nc: bind failed: Address already in use
i.e.
$ nc -l 3206
Ncat: bind to :::3206: Address already in use. QUITTING.
Can someone give a 1 line command without pages of explanations, references and alternative methods, on how you free up this port...
nc -litself, where the port is in aTIME_WAITstate. If this is the case you have to wait a short while until the port is released. Check withnetstat -nap | grep :3206– Chris Davies Feb 11 '17 at 00:01ncsetsSO_REUSEADDR... – thrig Feb 11 '17 at 00:24ncon OpenBSD setsSO_REUSEPORT. This implementation is available on Linux too I think (netcat-openbsdin Ubuntu). – Kusalananda Feb 11 '17 at 08:01