Date: Mon, 11 Nov 2002 17:50:02 -0800 (PST) From: Archie Cobbs <archie@packetdesign.com> To: freebsd-bugs@FreeBSD.org Subject: Re: kern/38554: changing interface ipaddress doesn't seem to work Message-ID: <200211120150.gAC1o2wR052271@freefall.freebsd.org>
next in thread | raw e-mail | index | archive | help
The following reply was made to PR kern/38554; it has been noted by GNATS. From: Archie Cobbs <archie@packetdesign.com> To: freebsd-gnats-submit@FreeBSD.org, Guido.Laubner@gmx.de Cc: Subject: Re: kern/38554: changing interface ipaddress doesn't seem to work Date: Mon, 11 Nov 2002 17:49:36 -0800 I've verified that this bug still exists in 4.7-RELEASE. I made sure to delete the old address (replacing it) rather than just adding the new one. What happens is that if you have a connected socket, then change the interface IP address, packets transmitted as a result of writing to the socket still use the old original IP address. This is "logical" because the socket is once and for all time bound to its original source IP address. Of course, any reply packets coming back from the remote host are dropped as they have an unrecognized destination IP address. My test used a TCP socket (ssh connection) but I'm sure that UDP would do the same thing as well. Interestingly, when you change the IP address back to its original value the socket comes back alive. Obviously it would be wrong to force outgoing packets use the new address, so probably the right thing to do here is return ENETDOWN to the write(2) (or whaveter) system call that prompted the outgoing data. -Archie __________________________________________________________________________ Archie Cobbs * Packet Design * http://www.packetdesign.com To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-bugs" in the body of the message
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?200211120150.gAC1o2wR052271>