Uploaded image for project: 'Red Hat OpenStack Services on OpenShift'
  1. Red Hat OpenStack Services on OpenShift
  2. OSPRH-518

BZ#1777891 [RFE] Network cascade deletion

XMLWordPrintable

    • Network cascade deletion
    • False
    • False
    • Proposed
    • Proposed
    • Committed
    • No
    • 100% To Do, 0% In Progress, 0% Done
    • Undefined
    • Networking; Neutron
    • Red Hat OpenStack Services on OpenShift

      To be able to delete a neutron network, first we need to detach its subnet from the router and also eliminate all the ports and subports that are on the network.

      From the OpenShift on OpenStack with Kuryr use case point of view, it would be great to have a similar command to the one already existing for octavia loadbalancers deletion: openstack loadbalancer delete --cascade LB_ID. In the same way as cascade deleting the loadbalancer makes octavia to take care of the listeners, pools and members deletion before deleting the loadbalancer, it will be great to have an 'openstack network delete --cascade NET_ID' (or --force) that takes care of removing the ports/subports associated to that network.

      For the OpenShift on OpenStack with kuryr use case, there is a new network/subnet per each OpenShift namespace. In addition, pods are connected to the Neutron networks by using subports attached to trunks, whose parent port is the one associated to the VM where the pod is running. This leads that everytime a namespace is deleted, instead of just deleting the network, kuryr needs to make the next calls to neutron API:
      a) Detach the subnet from the router
      b) Remove all the ports in DOWN status
      c) Get all the ports in ACTIVE status (those are subports attached to trunks):

      • For each of those ports, find the trunk they are attached to
      • Detach the port from the associated trunk
      • Delete the port
        d) Delete the network. Note this will take care of removing the subnet. But also, if the previous calls to detach the subports and delete them has not yet finished, this call will fail and needs to be retried

            skaplons@redhat.com Slawomir Kaplonski
            jira-bugzilla-migration RH Bugzilla Integration
            rhos-dfg-networking-squad-neutron
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

              Created:
              Updated: