In message <[EMAIL PROTECTED]>, Maxim Konovalov writes:Poul:
On Mon, 19 Jan 2004, 12:07+0100, Poul-Henning Kamp wrote:
Simple question:Probably bin/58012 worth to look (Multihomed tftpd enhancement). Yes,
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 ?
it relies on protocol but still.
But that's not a general solution, and it certainly doesn't solve the problem for my application.
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".
One of the problems I think that is fundamental to BSD and multi-homing is the lack of supports for multiple-default routes. And even in O/S's that do support multiple default routes (aka Linux and winXP) they really don't deal with them correctly...
If you have multiple default gateways (which you probably do if your multi-homed) what you really would like to do is use both of them. One way to do that, that would aid TCP (which probably does not help you) is to have built into the routing system a way to allocate a alternate route... That way when TCP starts hitting RTX-Timeouts it could do something like:
newroute = rtalloc_alt(dst, tcb->old_rt); if ( newroute != tcb->old_rt && newroute) { RT_FREE(tcb->old_rt); tcb->old_rt = newroute }
Now for TCP this would mean a more robust use of a multi-homed host.. For your situation you COULD use something like that but UDP would have to do a heck of a lot more than it currently does with routing .. which I think is zilch right now :--0
sigh... someday BSD's will decide to better support M-Homing.. for now hacks are appropriate :-/
R
-- Randall R. Stewart 815-477-2127 (office) 815-342-5222 (cell phone)
_______________________________________________ [EMAIL PROTECTED] mailing list http://lists.freebsd.org/mailman/listinfo/freebsd-net To unsubscribe, send any mail to "[EMAIL PROTECTED]"