network interruption when there is no change on the netplan config

Bug #2064912 reported by Hua Zhang
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
Netplan
Triaged
Wishlist
Unassigned

Bug Description

Network interruption may occur even when there is no change on the netplan config. eg: when running 'juju config ovn-chassis sriov-numvfs=enp94s0f1:16' to change VF number, it will generate a netplan config file /etc/netplan/150-charm-ovn.yaml . Even if the netplan configs remains unchanged afterwards, running 'netplan apply' can still cause network interruption.

I checked the code [1], it has the following code comment:

        # Re-start service when
        # 1. We have configuration files for it
        # 2. Previously we had config files for it but not anymore
        # Ideally we should compare the content of the *netplan-* files before and
        # after generation to minimize the number of re-starts, but the conditions
        # above works too.

So running 'netplan apply' will cause a networkd restart if there are existing *netplan-* files present. I think we had better compare the content of the *netplan-* files before and after generation to minimize the number of re-starts.

[What is known and has been done so far?]
A snippet from the syslog
https://paste.ubuntu.com/p/4Y49tRxf95/

[Distribution/Release, Package versions, Platform]
Jammy/Yoga

[Steps to Reproduce]
'netplan apply'

[1] https://github.com/canonical/netplan/blob/main/netplan_cli/cli/commands/apply.py#L137

Hua Zhang (zhhuabj)
description: updated
tags: added: sts
Revision history for this message
Lukas Märdian (slyon) wrote (last edit ):

Yes, Netplan should implement improved/seamless "netplan apply" and only re-configure interfaces that actually changes, instead of re-configuring all interfaces or re-starting the full networking daemon.

(See FR-3700)

Changed in netplan:
status: New → Triaged
importance: Undecided → Wishlist
tags: added: foundations-todo
tags: added: fr-3700
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.