Subject: Re: [RFC PATCH] net: ipv6: Make address flushing on ifdown optional

From: Hannes Frederic Sowa <[email-masked]>
Date: Mon, 19 Jan 2015 20:11:52 +0100

On Mo, 2015-01-19 at 09:12 -0700, Harout Hedeshian wrote:
> > I would still prefer that we flush automatically generated addresses and only
> > keep the static and permanent ones.
> > 
> > What do you think?
> > 
> > Bye,
> > Hannes
> 
> If I may offer an opinion, I do feel that there are use cases where flushing the auto-generated addresses in ifdown would not be desirable.
> 
> We have one such use case where information regarding the state of the network beyond the interface is managed through sideband signaling. We know that the auto-generated address would still be valid on ifup because the router information is unchanged. In this case, ifup/down is solely being used as a way for user space to enable/disable all traffic on a particular netdevice for temporary periods.
> 
> That said, I'm not sure how useful this would be for the average user; I see no harm if it is configurable and the default behavior is unchanged. 

Do you think it makes sense to combine the logic with the accept_ra
sysctl?

accept_ra && !flush_addr_on_down -> flush addresses generated by accept_ra logic
!accept_ra && !flush_addr_on_down -> don't flush any addresses

I am not sure about that, feels complicated. Would that suite your usecase?

Bye,
Hannes