0

As described in How do SO_REUSEADDR and SO_REUSEPORT differ?, since Linux kernel 3.9, SO_REUSEPORT is available.

To my understanding, SO_REUSEPORT can do all things that SO_REUSEADDR can do, but more handy.

So, can we safely say:

SO_REUSEADDR has been depecated by SO_REUSEPORT under Linux?

Cfun
  • 4,720
  • 4
  • 16
  • 40
xmllmx
  • 33,981
  • 13
  • 121
  • 269
  • "can we safely say: SO_REUSEADDR has been depecated by SO_REUSEPORT under Linux?" - No, because it is **not marked** as deprecated. See e.g. [man socket](http://man7.org/linux/man-pages/man7/socket.7.html). (The fact that one option is superseded by another one doesn't *automatically* deprecate the first option. Deprecation is an **official procedure**.) – Tsyvarev May 16 '20 at 17:30
  • Can we safely ignore `SO_REUSEADDR` because we already have `SO_REUSEADDR`? – xmllmx May 16 '20 at 17:38
  • 1
    Neither from `man socket` nor from the [answer](https://stackoverflow.com/a/14388707/3440745) to the question you refer I see no evidence that `SO_REUSEPORT` can replace `SO_REUSEADDR` in all aspects on Linux. – Tsyvarev May 16 '20 at 18:02
  • I cannot imagine any scenario in which `SO_REUSEPORT` doesn't work but `SO_REUSEADDR` works. – xmllmx May 16 '20 at 18:04

0 Answers0