Qrux wrote: > On Mar 30, 2012, at 9:42 AM, xinglp wrote: > > is not really correct, but for a different reason. We should not set > DOWN for an interface with an IP address still configured.
Yes, that was what xinglp was saying. > Hopefully no one is relying on that functionality. And, those who are > should be doing it through their own customs scripts. IMO, that's bad > behavior. The nature of LFS is that users can do their own thing. I don't want to discourage custom scripts. > In fact, ifdown should *only* set DOWN when there are no IP configs > still attached to the logical interface. If there *is* an IP config > still attached to the logical interface, then ifdown should just > report a warning that it cannot set DOWN on that interface because > either 1) there are still IP configs on other linked virtual > interfaces, or 2) that the services failed to properly tear down the > IP configs. It might be hard to distinguish between the two, without > polluting ifdown with more service-like code. Leaving an eth0 up when bringing down eth0:2 is not an error. It shouldn't even get a warning. It would make a normal shutdown quite noisy. > It should be up to the service(s) to bring down the configs. With > respect to virtual interfaces, presumably each eth0:n will be its own > config file, and each ipv4-static (or whatever service gives the IP > config) should tear down the IP config, too. Yes, the service script does remove the ip address. Trying to merge dhcp, bridging, static addresses, multiple IPs, etc is quite involved. > I'm busy ATM, but I'd be willing to get back to this in a week or so > (adding support for virtual interfaces in my proposal). I don't want to go overboard with this and recreate all the different possibilities that are in the commercial distros. Covering ethx:y, bridges, static routes, and dhcp will cover 99% of our users. (A single eth0 probably gets 80%). For things more exotic, a hint will be a better place to go into more detail. -- Bruce -- http://linuxfromscratch.org/mailman/listinfo/lfs-dev FAQ: http://www.linuxfromscratch.org/faq/ Unsubscribe: See the above information page