From: "Michael T Kerrisk" <mtk-lists@gmx.net>
To: Fernando Gont <fernando@gont.com.ar>
Cc: netdev@oss.sgi.com
Subject: Re: SO_REUSEADDR behavior different from BSD
Date: Mon, 9 Aug 2004 15:29:30 +0200 (MEST) [thread overview]
Message-ID: <16837.1092058170@www25.gmx.net> (raw)
In-Reply-To: 4.3.2.7.2.20040807232436.00d6da60@pop.gmx.net
[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #1: Type: text/plain; charset="us-ascii", Size: 999 bytes --]
> At 11:34 05/08/2004 -0700, YOSHIFUJI Hideaki wrote:
>
> > > Now, on Linux, at this point, the second instance of the
> > > server fails with EADDRINUSE, even though it did use
> > > SO_REUSEADDR. On FreeBSD 5.1, the second server instance
> > > does successfully bind.
> >
> >This behavior is intended.
> >First socket is REQUIRED to set SO_REUSEADDR
> >I hate BSD's behavior because it is asynmetry.
> >(Both sockets are required to agree on "REUSEADDR.")
>
> Not sure what you mean by "asymetry".
Ferando,
By asymmetry, I understand Hideaki to mean that BSD requires
SO_REUSEADDR in the second server bind(), but not the first.
the Linux philosophy then appears to be symmetry: both server
instances must agree that the socket port is reusable (i.e.,
both must set SO_REUSEADDR).
Cheers,
Michael
--
Michael Kerrisk
mtk-lists@gmx.net
NEU: WLAN-Router für 0,- EUR* - auch für DSL-Wechsler!
GMX DSL = supergünstig & kabellos http://www.gmx.net/de/go/dsl
next prev parent reply other threads:[~2004-08-09 13:29 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
2004-08-04 14:25 SO_REUSEADDR behavior different from BSD Michael T Kerrisk
2004-08-05 14:14 ` bert hubert
2004-08-05 16:36 ` Michael T Kerrisk
2004-08-05 18:20 ` David Stevens
2004-08-05 18:34 ` YOSHIFUJI Hideaki / 吉藤英明
2004-08-08 2:25 ` Fernando Gont
2004-08-09 13:29 ` Michael T Kerrisk [this message]
-- strict thread matches above, loose matches on Subject: below --
2004-08-05 22:25 Michael T Kerrisk
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=16837.1092058170@www25.gmx.net \
--to=mtk-lists@gmx.net \
--cc=fernando@gont.com.ar \
--cc=netdev@oss.sgi.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).