On Mon, Jul 17, 2017 at 05:12:07AM +0200, Adam Borowski wrote: > > That's indeed an interesting issue. Currently, ifupdown doesn't rename > > interfaces. You could add a line like: > > > > post-up ip link set $IFACE name $LOGICAL > > > > Which will do what you want, except ifupdown doesn't track interface > > renames this way and will get very confused. In particular, ifdown will > > not work anymore. So some code should be added to ifupdown to support > > interface renaming. > > This is what I assumed your new code does -- it seemed an obvious and > natural thing to do. Well, it just matched an existing interface to a logical iface stanza, it didn't need to rename anything. The use case is anything outside of ifupdown and its plugins that might use interface names, such as for example netfilter-persistent. > As Ben noticed, the post-up stanza above can't work as Linux doesn't allow > renaming interfaces at that point. It can't work in pre-up either as > ifupdown wouldn't know about the rename. Ah, indeed. > Thus, what about this: > auto mac/00:16:0a:26:99:c6/=en0 > iface en0 inet6 static > address 3:1415:9265:3589:7932:3846:2643:3832/64 > gateway 3:1415:9265:3589::1 > rename > > With the rename command taking an optional argument (the new name) that > defaults to the logical name (ie, after =). Yes, that should be implementable. -- Met vriendelijke groet / with kind regards, Guus Sliepen <guus@debian.org>
Attachment:
signature.asc
Description: PGP signature