Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!

Bug 698388

Summary: net-misc/netifrc: preup() function does not work on bridges as expected
Product: Gentoo Hosted Projects Reporter: Stefan00 <stefan>
Component: netifrcAssignee: netifrc Team <netifrc>
Status: RESOLVED INVALID    
Severity: normal CC: pinkbyte
Priority: Normal    
Version: unspecified   
Hardware: All   
OS: Linux   
Whiteboard:
Package list:
Runtime testing required: ---

Description Stefan00 2019-10-23 14:31:13 UTC
It seems that within netifrc the preup() function does not work properly on bridges if the command issued within thre preup() function needs to address the bridge interface - it’s not existing (yet). 

non-working example:

#/etc/conf.d/net
config_br0="192.168.0.24 netmask 255.255.255.0 brd 192.168.0.255" 
...
preup() {
  ip token set ::24 dev br0
  return 0
}

Looking through the code of netirfc/net/bridge.sh I guess that may even be by design? It's not clear if it's a bug or not documented. 

It would be however nice to have that functionality.

Reproducible: Always
Comment 1 Sergey Popov gentoo-dev 2020-03-10 08:19:35 UTC
As i know, preup() works in such way for any non-physical interfaces - at least for VXLAN and L2TPv3 tunnel interfaces. If you need to tweak bridge properties, your best bet would be postup()