Uploaded image for project: 'RHEL'
  1. RHEL
  2. RHEL-67324

adding "absent" in a route reactivates the connection

    • No
    • Important
    • rhel-sst-network-management
    • ssg_networking
    • 5
    • Hide
      Customer/Partner Jira ID Customer Case Status Details
      Nokia RHEL-67324 03834014 This issue relates to unexpected network reactivation when marking routes as “absent” within Nmstate policies and this leads to network disconnections. Engineering will investigate the root cause and find possible adjustments to prevent this network reactivation. The next steps are to confirm the cause and develop a solution to apply configurations without the flapping.
       [2024-11-18] An investigation spike (NMT-1263)  has been created to address the workaround currently implemented in Nmstate for managing routes that is linked to this issue. This work is ongoing within the current sprint.
      Show
      Customer/Partner Jira ID Customer Case Status Details Nokia RHEL-67324 03834014 This issue relates to unexpected network reactivation when marking routes as “absent” within Nmstate policies and this leads to network disconnections. Engineering will investigate the root cause and find possible adjustments to prevent this network reactivation. The next steps are to confirm the cause and develop a solution to apply configurations without the flapping.   [2024-11-18] An investigation spike (NMT-1263)  has been created to address the workaround currently implemented in Nmstate for managing routes that is linked to this issue. This work is ongoing within the current sprint.
    • False
    • Hide

      None

      Show
      None
    • None
    • None
    • Hide

      Given a system admin is configuring a NNCP with routes configured for a specific connection,

      When they add an "absent" state to any route in the policy,

      Then, the system should update the route configuration without deactivating or reactivating the connection.

      Definition of Done:

      • The implementation meets the acceptance criteria
      • Integration tests are written and pass
      • The code is part of a downstream build attached to an errata
      • The fix is backported into RHEL-9.2.z
      Show
      Given a system admin is configuring a NNCP with routes configured for a specific connection, When they add an "absent" state to any route in the policy, Then, the system should update the route configuration without deactivating or reactivating the connection. Definition of Done: The implementation meets the acceptance criteria Integration tests are written and pass The code is part of a downstream build attached to an errata The fix is backported into RHEL-9.2.z
    • None
    • None
    • None

      This comes from this bug RHEL-64707, but when a new 'absent' is added to a route in an NNCP

      k-nmstate version

      $ oc  get csv -n openshift-nmstate
      NAME                                              DISPLAY                       VERSION               REPLACES   PHASE
      kubernetes-nmstate-operator.4.14.0-202409250809   Kubernetes NMState Operator   4.14.0-202409250809              Succeeded 

      Steps to reproduce the issue:

      • Create a NNCP as follows:
      $ cat 02_NNCP_ROUTE.yaml_1
      apiVersion: nmstate.io/v1
      kind: NodeNetworkConfigurationPolicy
      metadata:
        name: bond-tenant-vlan111-ipv4-route-new
      spec:
        nodeSelector:
          node-role.kubernetes.io/worker: ""
        desiredState:
          interfaces:
          - name: vlan111
            description: static IP on vlan111
            type: vlan
            state: up
          routes:
            config:
            - destination: xxxxx
              next-hop-address: xxxxx
              next-hop-interface: vlan111
            - destination: xxxxx
              next-hop-address: xxxxx
              next-hop-interface: vlan111
            - destination: xxxxx
              next-hop-address: xxxxx
              next-hop-interface: vlan111
            - destination: xxxxx
              next-hop-address: xxxxx
              next-hop-interface: vlan111
            - destination: xxxxx
              next-hop-address: xxxxx
              next-hop-interface: vlan111
            - destination: xxxxx
              next-hop-address: xxxxx
              next-hop-interface: vlan111
            - destination:  xxxxx
              next-hop-address: xxxxx
              next-hop-interface: vlan111
            - destination:  xxxxx
              next-hop-address: xxxxx
              next-hop-interface: vlan111  
      
      $ oc apply -f 02_NNCP_ROUTE.yaml_1
      nodenetworkconfigurationpolicy.nmstate.io/bond-tenant-vlan111-ipv4-route-new configured
      
      $ oc get nncp bond-tenant-vlan111-ipv4-route-new
      NAME                                 STATUS      REASON
      bond-tenant-vlan111-ipv4-route-new   Available   SuccessfullyConfigured
      
      $ oc get nnce | grep new 
      sno-ctlplane-0.5g-deployment.lab.bond-tenant-vlan111-ipv4-route-new   Available   6m42s        SuccessfullyConfigured
      sno-ctlplane-1.5g-deployment.lab.bond-tenant-vlan111-ipv4-route-new   Available   6m43s        SuccessfullyConfigured
      sno-ctlplane-2.5g-deployment.lab.bond-tenant-vlan111-ipv4-route-new   Available   6m43s        SuccessfullyConfigured
      • Add "a new 'absent' in a route:
      $ cat 02_NNCP_ROUTE.yaml_1
      apiVersion: nmstate.io/v1
      kind: NodeNetworkConfigurationPolicy
      metadata:
        name: bond-tenant-vlan111-ipv4-route-new
      spec:
        nodeSelector:
          node-role.kubernetes.io/worker: ""
        desiredState:
          interfaces:
          - name: vlan111
            description: static IP on vlan111
            type: vlan
            state: up
          routes:
            config:
            - destination: xxxxx
              next-hop-address: xxxxx
              next-hop-interface: vlan111
            - destination: xxxxx
              next-hop-address: xxxxx
              next-hop-interface: vlan111
            - destination: xxxxx
              next-hop-address: xxxxx
              next-hop-interface: vlan111
            - destination: xxxxx
              next-hop-address: xxxxx
              next-hop-interface: vlan111
            - destination: xxxxx
              next-hop-address: xxxxx
              next-hop-interface: vlan111
            - destination: xxxxx
              next-hop-address: xxxxx
              next-hop-interface: vlan111
            - destination:  xxxxx
              next-hop-address: xxxxx
              next-hop-interface: vlan111
            - destination:  xxxxx
              next-hop-address: xxxxx
              next-hop-interface: vlan111  
              state: absent
      
      $ oc apply -f 02_NNCP_ROUTE.yaml_1
      nodenetworkconfigurationpolicy.nmstate.io/bond-tenant-vlan111-ipv4-route-new configured

      NM logs:

      Nov 13 12:05:07 sno-ctlplane-0.5g-deployment.lab NetworkManager[1182]: <info>  [1731499507.2698] audit: op="checkpoint-create" arg="/org/freedesktop/NetworkManager/Checkpoint/17" pid=2694539 uid=0 result="success"
      Nov 13 12:05:07 sno-ctlplane-0.5g-deployment.lab NetworkManager[1182]: <info>  [1731499507.2713] audit: op="checkpoint-adjust-rollback-timeout" arg="/org/freedesktop/NetworkManager/Checkpoint/17" pid=2694539 uid=0 result="success"
      Nov 13 12:05:07 sno-ctlplane-0.5g-deployment.lab NetworkManager[1182]: <info>  [1731499507.6014] device (vlan111): state change: activated -> deactivating (reason 'user-requested', sys-iface-state: 'managed')
      Nov 13 12:05:07 sno-ctlplane-0.5g-deployment.lab NetworkManager[1182]: <info>  [1731499507.6032] audit: op="connection-deactivate" uuid="724ba310-d8e6-45db-b424-8804e16f14ea" name="vlan111" pid=2694539 uid=0 result="success"
      Nov 13 12:05:07 sno-ctlplane-0.5g-deployment.lab NetworkManager[1182]: <info>  [1731499507.6084] audit: op="connection-update" uuid="724ba310-d8e6-45db-b424-8804e16f14ea" name="vlan111" args="ipv4.routes" pid=2694539 uid=0 result="success"
      Nov 13 12:05:07 sno-ctlplane-0.5g-deployment.lab NetworkManager[1182]: <info>  [1731499507.6272] device (vlan111): state change: deactivating -> disconnected (reason 'user-requested', sys-iface-state: 'managed')
      Nov 13 12:05:07 sno-ctlplane-0.5g-deployment.lab NetworkManager[1182]: <info>  [1731499507.6477] device (vlan111): state change: disconnected -> unmanaged (reason 'user-requested', sys-iface-state: 'managed')
      Nov 13 12:05:07 sno-ctlplane-0.5g-deployment.lab NetworkManager[1182]: <info>  [1731499507.9098] audit: op="device-reapply" interface="vlan111" pid=2694539 uid=0 result="fail" reason="Device is not activated"
      Nov 13 12:05:07 sno-ctlplane-0.5g-deployment.lab NetworkManager[1182]: <info>  [1731499507.9148] device (vlan111): state change: unmanaged -> unavailable (reason 'managed', sys-iface-state: 'external')
      Nov 13 12:05:07 sno-ctlplane-0.5g-deployment.lab NetworkManager[1182]: <info>  [1731499507.9164] device (vlan111): state change: unavailable -> disconnected (reason 'user-requested', sys-iface-state: 'managed')
      Nov 13 12:05:07 sno-ctlplane-0.5g-deployment.lab NetworkManager[1182]: <info>  [1731499507.9183] device (vlan111): Activation: starting connection 'vlan111' (724ba310-d8e6-45db-b424-8804e16f14ea)
      Nov 13 12:05:07 sno-ctlplane-0.5g-deployment.lab NetworkManager[1182]: <info>  [1731499507.9184] audit: op="connection-activate" uuid="724ba310-d8e6-45db-b424-8804e16f14ea" name="vlan111" pid=2694539 uid=0 result="success"
      Nov 13 12:05:07 sno-ctlplane-0.5g-deployment.lab NetworkManager[1182]: <info>  [1731499507.9189] device (vlan111): carrier: link connected
      Nov 13 12:05:07 sno-ctlplane-0.5g-deployment.lab NetworkManager[1182]: <info>  [1731499507.9192] device (vlan111): state change: disconnected -> prepare (reason 'none', sys-iface-state: 'managed')
      Nov 13 12:05:07 sno-ctlplane-0.5g-deployment.lab NetworkManager[1182]: <info>  [1731499507.9202] device (vlan111): state change: prepare -> config (reason 'none', sys-iface-state: 'managed')
      Nov 13 12:05:07 sno-ctlplane-0.5g-deployment.lab NetworkManager[1182]: <info>  [1731499507.9221] device (vlan111): state change: config -> ip-config (reason 'none', sys-iface-state: 'managed')
      Nov 13 12:05:07 sno-ctlplane-0.5g-deployment.lab NetworkManager[1182]: <info>  [1731499507.9228] audit: op="checkpoint-adjust-rollback-timeout" arg="/org/freedesktop/NetworkManager/Checkpoint/17" pid=2694539 uid=0 result="success"
      Nov 13 12:05:07 sno-ctlplane-0.5g-deployment.lab NetworkManager[1182]: <info>  [1731499507.9246] device (vlan111): state change: ip-config -> ip-check (reason 'none', sys-iface-state: 'managed')
      Nov 13 12:05:08 sno-ctlplane-0.5g-deployment.lab NetworkManager[1182]: <info>  [1731499508.1483] device (vlan111): state change: ip-check -> secondaries (reason 'none', sys-iface-state: 'managed')
      Nov 13 12:05:08 sno-ctlplane-0.5g-deployment.lab NetworkManager[1182]: <info>  [1731499508.1485] device (vlan111): state change: secondaries -> activated (reason 'none', sys-iface-state: 'managed')
      Nov 13 12:05:08 sno-ctlplane-0.5g-deployment.lab NetworkManager[1182]: <info>  [1731499508.1492] device (vlan111): Activation: successful, device activated.
      Nov 13 12:05:09 sno-ctlplane-0.5g-deployment.lab NetworkManager[1182]: <info>  [1731499509.3580] checkpoint[0x5642cc9296e0]: destroy /org/freedesktop/NetworkManager/Checkpoint/17
      Nov 13 12:05:09 sno-ctlplane-0.5g-deployment.lab NetworkManager[1182]: <info>  [1731499509.3588] audit: op="checkpoint-destroy" arg="/org/freedesktop/NetworkManager/Checkpoint/17" pid=2694646 uid=0 result="success"
      Nov 13 12:06:03 sno-ctlplane-0.5g-deployment.lab NetworkManager[1182]: <info>  [1731499563.5727] manager: (9ce135801c052c4): new Veth device (/org/freedesktop/NetworkManager/Devices/10477)
      Nov 13 12:06:03 sno-ctlplane-0.5g-deployment.lab NetworkManager[1182]: <info>  [1731499563.5745] device (9ce135801c052c4): carrier: link connected
      Nov 13 12:06:03 sno-ctlplane-0.5g-deployment.lab NetworkManager[1182]: <info>  [1731499563.5951] manager: (9ce135801c052c4): new Open vSwitch Port device (/org/freedesktop/NetworkManager/Devices/10478) 

      Expected results:  reapplying configuration instead of reactivates the connection

       

        1. nm-no-bug-reapply.sh
          1 kB
        2. nm-no-bug-down.sh
          1 kB
        3. nm-bug.sh
          1 kB

              ihuguet@redhat.com Inigo Huguet
              rhn-support-jclaretm Jorge Claret Membrado
              Network Management Team Network Management Team
              Mingyu Shi Mingyu Shi
              Votes:
              0 Vote for this issue
              Watchers:
              10 Start watching this issue

                Created:
                Updated: