Date: Mon, 19 Jan 2004 13:30:18 +0100 From: "Poul-Henning Kamp" <phk@phk.freebsd.dk> To: "Randall R. Stewart (home)" <randall@stewart.chicago.il.us> Cc: net@freebsd.org Subject: Re: Multihomed UDP server Message-ID: <92687.1074515418@critter.freebsd.dk> In-Reply-To: Your message of "Mon, 19 Jan 2004 06:13:25 CST." <400BC9E5.8010609@stewart.chicago.il.us>
next in thread | previous in thread | raw e-mail | index | archive | help
In message <400BC9E5.8010609@stewart.chicago.il.us>, "Randall R. Stewart (home) " writes: >>>On Mon, 19 Jan 2004, 12:07+0100, Poul-Henning Kamp wrote: >>>>Simple question: >>>> >>>>Very simple UDP server daemon. >>>> >>>>Many clients (connect(2)'ing a socket for each is not an option) >>>> >>>>Multihomed machine. >>>> >>>>What's the simple trick to replying with the same source-IP as the >>>>client used as destination-IP ? >> >>I'm considering ways to make sendmsg(2)/recvmsg(2) DTRT, and my >>current candidate is give them a flag bit which says "msg_name has >>both addresses". Following the code it seems that it is in fact possible to do with sendmsg(2)/recvmsg(2) already, and my test shows that at least the receive side works. I challenge anybody to point out where this is mentioned in the docs, and once people give up I'll tell how to do it :-) >Poul: > >One of the problems I think that is fundamental to BSD and >multi-homing is the lack of supports for multiple-default routes. I agree. -- Poul-Henning Kamp | UNIX since Zilog Zeus 3.20 phk@FreeBSD.ORG | TCP/IP since RFC 956 FreeBSD committer | BSD since 4.3-tahoe Never attribute to malice what can adequately be explained by incompetence.
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?92687.1074515418>