On Wed, Jan 13, 2016 at 04:00:16PM +0100, Martin Pitt wrote: > > Why should ifupdown tear down the network on shutdown then? > > E. g. LTSP creates an ifupdown stanza like "iface eth0 inet manual" > for the remote root interface to prevent NetworkManager from > (auto-)connecting/disconnecting eth0. NM ignores interfaces that are > configured in ifupdown, thus preventing the user from shooting > herself into the foot by accidentally/maliciously clicking on > "disconnect" in the network icon.
Ugh. That's totally wrong. Why doesn't LTSP tell NetworkManager itself to stop messing with eth0? Instead of adding a stanza to /e/n/i, just write this to /etc/NetworkManager/NetworkManager.conf: [keyfile] unmanaged-devices=interface-name=eth0 > This use case actually got broken > by the overzealous patch in #809169 which added this: > > down > + /bin/ip link set dev %iface% down 2>/dev/null || true \ > + if (iface_is_link()) > > for "manual" interfaces. I. e. "ifdown eth0" on the above "manual" > interface example would actually down the interface. This isn't > documented behaviour, and breaks this (IMHO) valid use case to mark an > interface as "please leave me alone". I'd say that the latter use case is invalid. > I also looked at open-iscsi in Ubuntu. That package has a weird patch > which hacks ifupdown's state files to think that eth0 is already up, Oh god. That's also completely wrong. Ifupdown 0.8 and later uses per-interface state files (because they can be locked individually), the /run/network/ifstate file is still there for now but it might be phased out. > Again the check_network_file_systems() check prevented a shutdown hang > here. But this whole approach is just wrong, and we need to fix that > on the Ubuntu side to generate an ifupdown interface stanza on first > boot on the fly (this is also necessary for the ifnames changes, as > it's not guaranteed to be eth0 these days). This part isn't really > relevant for you, but I wanted to mention it here for the record. What I am willing to do is to add the keyword "no-auto-down" to interface stanza's, which will prevent the interface from being brought down using "ifdown -a". -- Met vriendelijke groet / with kind regards, Guus Sliepen <g...@debian.org>
signature.asc
Description: Digital signature