openSUSE / wicked

Framework for network configuration
https://en.opensuse.org/Portal:Wicked
GNU General Public License v2.0
101 stars 50 forks source link

ifcfg script is not triggered when cable is disconnected #992

Open Trekky12 opened 10 months ago

Trekky12 commented 10 months ago

I have two network interfaces eth0 and eth1 on openSUSE 15.4. While eth1 is static in the air-gapped local network I want to be able to update the server and connect a cable to eth0 for internet access (dhcp). I then need to delete the default gateway published by dhcp when the cable on eth0 is disconnected. Therefore I have added a POST_DOWN_SCRIPT variable on ifcfg-eth0.

Unfortunately this script is not triggered when the cable is disconnected but only when using wicked ifdown eth0.

wicked ifstatus eth0 shows no-carrier but state device-up which maybe is the problem here?

Is there any solution to trigger a script when the interface has no-carrier?