On Tuesday 22 Dec 2015 14:20:26 Kai Krakow wrote:
> Am Tue, 22 Dec 2015 14:04:12 +0000
> 
> schrieb Mick <michaelkintz...@gmail.com>:

> > There is no means of enabling or disabling the ifplugd service that I
> > have found, because there is no /etc/init.d/ifplugd script.  Once
> > installed ifplugd always starts at boot and daemonizes, configuring
> > or tearing down connections as a link is detected or lost.
> 
> As far as I understood, you now start ifplugd using the associated
> net.* init script. Openrc will detect that ifplugd is installed and
> then wait until a cable is plugged, plus starting an instance listening
> on the device.

No, this is not how ifplugd worked, for as long as I can remember.  I never 
started the interface, or had to start ifplugd by an init.d script or 
manually.


> Its clear how it used to work but I think the semantics changed. Since
> I do no longer use openrc I cannot confirm how the rest of the services
> react to and activated net.* init script if ifplugd is active through
> the plugin. I suppose dependent scripts should only be triggered after
> the cable is plugged in.
> 
> This is also why there is no config file: Its configured dynamically
> through the plugin and the interface specific init script.

I can confirm that the config file is only used by the /etc/init.d/ifplugd 
script - which however does not exist on Gentoo.

I created a config file, specified the enp11s0 there, started 
/usr/sbin/ifplugd manually and it still tried to bring up the default eth0 
interface.

Starting ifplugd manually with '-i enp11s0' works as intended.  It brings up 
the NIC and configures the interface:

 ifplugd(enp11s0)[4275]: ifplugd 0.28 initializing.
 ifplugd(enp11s0)[4275]: Using interface enp11s0/00:26:B9:20:B4:9C with driver 
<tg3> (version: 3.137)
 ifplugd(enp11s0)[4275]: Using detection mode: SIOCETHTOOL
 ifplugd(enp11s0)[4275]: Initialization complete, link beat not detected.
 kernel: IPv6: ADDRCONF(NETDEV_UP): enp11s0: link is not ready
 kernel: tg3 0000:0b:00.0 enp11s0: Link is up at 100 Mbps, full duplex
 kernel: tg3 0000:0b:00.0 enp11s0: Flow control is on for TX and on for RX
 kernel: IPv6: ADDRCONF(NETDEV_CHANGE): enp11s0: link becomes ready
 ifplugd(enp11s0)[4275]: Link beat detected.
 ifplugd(enp11s0)[4275]: Executing '/etc/ifplugd/ifplugd.action enp11s0 up'.


> > I started this thread because recently I have to start my wired
> > interface manually, after which point ipfplugd also starts,
> > daemonizes and manages the connection.  This is not how it used to
> > work - I never had to start the wired interface myself.
> 
> This is how it works now: ifplugd is started through the interface
> script.

I hear what you say.  However, this makes me ask - what changed to cause this?  
Things changed since dev-libs/libgudev-230 and sys-fs/udev-225 were installed.  
<=sys-fs/udev-216 and friends used to bring up ifplugd(enp11s0) without any 
intervention from me or from /etc/init.d/ scripts.  So I have to guess that 
something changed in udev to cause this change in behaviour.

Thank you for helping me walk through this.  I'm going to raise a bug report 
and see what the devs think.
-- 
Regards,
Mick

Attachment: signature.asc
Description: This is a digitally signed message part.

Reply via email to