From: Jason <bofh1234567@yahoo.com>
To: Alan Cox <alan@lxorguk.ukuu.org.uk>
Cc: Jan Engelhardt <jengelh@linux01.gwdg.de>, linux-kernel@vger.kernel.org
Subject: Re: SO_REUSEPORT and multicasting
Date: Wed, 14 Jun 2006 10:48:25 -0700 (PDT) [thread overview]
Message-ID: <20060614174825.94383.qmail@web53612.mail.yahoo.com> (raw)
In-Reply-To: <1150296668.3490.46.camel@localhost.localdomain>
--- Alan Cox <alan@lxorguk.ukuu.org.uk> wrote:
> Linux follows the standards draft. SO_REUSEPORT is
> a fairly obscure BSDism.
Standards are good. I like standards. I was not
aware that SO_REUSEPORT was that obscure. My
programming instructor made it sound like every OS
supports it. I guess he was wrong. Is there a Linux
equivalent to SO_REUSEPORT?
> > Yes. My code works great on HP-UX but does
> > nothing on Linux.
>
> That doesn't actually prove very much. Its very easy
> to write incorrect
> code that only works on one system, especially when
> endian-ness gets
> involved with network code.
I have written other unicast programs on Linux and
sftp'd them to HP-UX, compiled, and they ran great.
The only change I have to make between Linux and HP-UX
is in the Makefile. I have change the following line:
INCS= -I. -include /usr/include/errno.h #to use fedora
I comment out the -include on the HP-UX and everything
is great.
This multicast application was based on its TCP
brother. The only difference is removing TCP and
installing multicast support.
> In particular if writing portable code you must
> remember to join the
> group. You must also remember that the various
> htons/htonl macros need
> to be correctly used or your code will break on
> little-endian systems.
All of those macros are used in the multicast.c file I
was given.
> The default IP_MULTICAST_LOOP value is probably also
> worth overriding if
> you are being fairly paranoid.
The wrapper I used has a function to set the TTL and
the loop values. I set the TTL to 3 and the loop to
0.
Thanks,
__________________________________________________
Do You Yahoo!?
Tired of spam? Yahoo! Mail has the best spam protection around
http://mail.yahoo.com
next prev parent reply other threads:[~2006-06-14 17:48 UTC|newest]
Thread overview: 11+ messages / expand[flat|nested] mbox.gz Atom feed top
2006-06-13 19:24 Jason
2006-06-13 20:20 ` Jan Engelhardt
2006-06-14 14:26 ` Jason
2006-06-14 14:51 ` Alan Cox
2006-06-14 17:48 ` Jason [this message]
2006-06-14 22:14 ` David Miller
2006-06-14 22:57 ` Jason
2006-06-14 23:04 ` David Miller
2006-06-15 13:32 ` Jason
2006-06-14 14:40 ` James Courtier-Dutton
2006-06-14 18:04 ` Jason
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=20060614174825.94383.qmail@web53612.mail.yahoo.com \
--to=bofh1234567@yahoo.com \
--cc=alan@lxorguk.ukuu.org.uk \
--cc=jengelh@linux01.gwdg.de \
--cc=linux-kernel@vger.kernel.org \
/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
all inboxes | Powered by JetHome®