On Mon, Jun 22, 2009 at 1:49 AM, Claudio Jeker<cje...@diehard.n-r-g.com> wrote: > On Sun, Jun 21, 2009 at 05:57:09PM -0700, patrick keshishian wrote: >> On Sun, Jun 21, 2009 at 3:42 PM, Philip Guenther<guent...@gmail.com> wrote: >> > On Sun, Jun 21, 2009 at 10:36 AM, patrick keshishian<pkesh...@gmail.com> >> wrote: >> >> >> Maybe I just wrote too many words. In simple terms, once a new route >> >> has been added to the routing table, all traffic should consider the >> >> new route right? So, is the ppp interface treated differently when it >> >> comes to routing in OpenBSD? >> > >> > Does this quote from the netstat(8) manpage explain the behavior? >> > B B B B Connection oriented protocols normally hold on to a single route >> > B B B B for the duration of a connection while connectionless protocols obtain >> a >> > B B B B route while sending to the same destination. >> >> ah, yes. this is good, as it confirms part of my observation; note >> that i was not specific on the type of socket used, because it did not >> make a difference. I simply said "same socket descriptor", indicating >> one created prior to the establishment of the new route. >> >> e.g., I can start a ping going for the particular host on the remote >> network, next establish the route and the pings continue out on the >> physical interface. If I start a new ping, those packets, now, go >> through the ppp0 interface. As verified with tcpdump. >> >> So, it seems, based on my observations, routes are "sticky" with >> respect to sockets; even non-TCP sockets, which seems bit odd. Do you >> not agree? >> > > Yes, sockets cache routes and that's good and it will most probably > not change anytime soon. If the route becomes unavailable a new lookup > will be done.
Thanks for your reply. Last night I started to dig through sources for this answer and I found this out looking at ip_output() (assuming I'm on the right trail). Cheers, --patrick