systemd-networkd is not permanently enabled when the unit is already runtime-enabled

Bug #2073100 reported by Matt Crees
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
kayobe
New
Undecided
Matt Crees

Bug Description

There is a fix in the systemd_service module, but this is not yet in a versioned release: https://github.com/ansible/ansible/commit/3076478892735bd33fd79c14acf3635d004f859f

To recreate:

Start with the service is disabled:

$ systemctl status systemd-networkd
● systemd-networkd.service - Network Configuration
     Loaded: loaded (/lib/systemd/system/systemd-networkd.service; disabled; vendor preset: enabled)

After running a control host bootstrap, it gets temporarily enabled "enabled-runtime".

$ systemctl status systemd-networkd
● systemd-networkd.service - Network Configuration
     Loaded: loaded (/lib/systemd/system/systemd-networkd.service; enabled-runtime; vendor preset: enabled)

Run host configure, it doesn't get enabled permanently because the service module already detects enabled-runtime. It is then restarted, so it goes back to disabled.

TASK [stackhpc.systemd_networkd : enable systemd-networkd] ********************
Friday 12 July 2024 15:28:40 +0000 (0:00:02.375) 0:00:52.532 ***********
ok: [controller0]

RUNNING HANDLER [stackhpc.systemd_networkd : restart systemd-networkd] *******************************************************************************
Friday 12 July 2024 15:28:40 +0000 (0:00:00.050) 0:00:53.112 ***********
changed: [controller0]

$ systemctl status systemd-networkd
● systemd-networkd.service - Network Configuration
     Loaded: loaded (/lib/systemd/system/systemd-networkd.service; disabled; vendor preset: enabled)
     Active: active (running) since Fri 2024-07-12 15:28:41 UTC; 1min 39s ago

Matt Crees (mattcrees)
Changed in kayobe:
assignee: nobody → Matt Crees (mattcrees)
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.