<html>
  <head>

    <meta http-equiv="content-type" content="text/html; charset=UTF-8">
  </head>
  <body>
    <p><br>
    </p>
    <p>Dear mailinglist,</p>
    <p><br>
    </p>
    <p>We have the following behavour, which occured in about 3% of our
      networks. <br>
    </p>
    <p>We have a default configured of 3 dhcp servers per subnet, but in
      about 3% of all networks, we have unexpectedly 4, from which one
      is in state "reserved_dhcp_port", also there is NO namespace on
      that control/network node. <br>
    </p>
    <p>Setup: Openstack Rocky, Networkmode legacy<br>
    </p>
    <p><br>
    </p>
    <p><tt># openstack port list --device-owner network:dhcp --network
        a2d4605d-997e-4807-9250-c0c80af3183e<br>
+--------------------------------------+------+-------------------+---------------------------------------------------------------------------+--------+<br>
        | ID                                   | Name | MAC
        Address       | Fixed IP
        Addresses                                                       
        | Status |<br>
+--------------------------------------+------+-------------------+---------------------------------------------------------------------------+--------+<br>
        | 40237ca8-aed6-49ee-</tt><tt><tt>xxxx</tt>-49acf97797e4 |     
        | fa:16:3e:e1:33:83 | ip_address='172.16.0.4',
        subnet_id='e4380af7-13b4-xxxx-90ff-6b0a2818052b' | ACTIVE |<br>
        | 6a3898c6-6520-43e7-</tt><tt><tt>xxxx</tt>-e6b2639f2600 |     
        | fa:16:3e:ff:f0:7b | ip_address='172.16.0.2',
        subnet_id='e4380af7-13b4-xxxx-90ff-6b0a2818052b' | ACTIVE |<br>
        | 89479d32-881d-45b9-</tt><tt><tt>xxxx</tt>-1b41ed8fd703 |     
        | fa:16:3e:ef:7d:dc | ip_address='172.16.0.6',
        subnet_id='e4380af7-13b4-</tt><tt><tt>xxxx</tt>-90ff-6b0a2818052b'
        | ACTIVE |<br>
        | eaeb0ef7-48c6-43ea-</tt><tt><tt>xxxx</tt>-8615ed704e48 |     
        | fa:16:3e:66:7c:96 | ip_address='172.16.0.3',
        subnet_id='e4380af7-13b4-</tt><tt><tt>xxxx</tt>-90ff-6b0a2818052b'
        | ACTIVE |<br>
+--------------------------------------+------+-------------------+---------------------------------------------------------------------------+--------+<br>
      </tt><br>
    </p>
    <p>full output of one of that port:<tt><br>
      </tt></p>
    <p><tt># openstack port show </tt><tt>89479d32-881d-45b9-</tt><tt><tt>xxxx</tt>-1b41ed8fd703</tt></p>
    <p><tt>+-------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+<br>
        | Field                   |
Value                                                                                                                                                                                   
        |<br>
+-------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+<br>
        | admin_state_up          |
UP                                                                                                                                                                                      
        |<br>
        | allowed_address_pairs  
|                                                                                                                                                                                         
        |<br>
        | binding_host_id         |
ctl5                                                                                                                                                                         
        |<br>
        | binding_profile        
|                                                                                                                                                                                         
        |<br>
        | binding_vif_details     | datapath_type='system',
        ovs_hybrid_plug='True',
port_filter='True'                                                                                                                      
        |<br>
        | binding_vif_type        |
ovs                                                                                                                                                                                     
        |<br>
        | binding_vnic_type       |
normal                                                                                                                                                                                  
        |<br>
        | created_at              |
2020-01-16T11:22:14Z                                                                                                                                                                    
        |<br>
        | data_plane_status       |
None                                                                                                                                                                                    
        |<br>
        | description            
|                                                                                                                                                                                         
        |<br>
        | device_id               |
reserved_dhcp_port                                                                                                                                                                      
        |<br>
        | device_owner            |
network:dhcp                                                                                                                                                                            
        |<br>
        | dns_assignment          |
None                                                                                                                                                                                    
        |<br>
        | dns_domain              |
None                                                                                                                                                                                    
        |<br>
        | dns_name                |
None                                                                                                                                                                                    
        |<br>
        | extra_dhcp_opts        
|                                                                                                                                                                                         
        |<br>
        | fixed_ips               | ip_address='172.16.0.6',
        subnet_id='e4380af7-13b4-40f9-</tt><tt><tt>xxxx</tt>-</tt><tt><tt>xxxx</tt>'                                                                                                               
        |<br>
        | id                      |
89479d32-881d-45b9-xxxx-1b41ed8fd703                                                                                                                                                    
        |<br>
        | location                | Munch({'project':
        Munch({'domain_id': None, 'id': u'a772e4ab888e4f</tt><tt><tt>xxxx</tt>',
        'name': 'admin', 'domain_name': 'Default'}), 'cloud': '',
        'region_name': 'ch-zh1', 'zone': None}) |<br>
        | mac_address             | fa:16:3e:ef:7d:xx
                                                                                                                                                                      
        |<br>
        | name                   
|                                                                                                                                                                                         
        |<br>
        | network_id              | a2d4605d-997e-4807-</tt><tt><tt>xxxx</tt>-xxx
                                                                                                                                                   
        |<br>
        | port_security_enabled   |
False                                                                                                                                                                                   
        |<br>
        | project_id              | 232ecbeb96fd4663</tt><tt><tt>xxxx</tt>
                                                                                                                                                       
        |<br>
        | propagate_uplink_status |
None                                                                                                                                                                                    
        |<br>
        | qos_policy_id           |
None                                                                                                                                                                                    
        |<br>
        | resource_request        |
None                                                                                                                                                                                    
        |<br>
        | revision_number         |
8                                                                                                                                                                                       
        |<br>
        | security_group_ids     
|                                                                                                                                                                                         
        |<br>
        | status                  |
ACTIVE                                                                                                                                                                                  
        |<br>
        | tags                   
|                                                                                                                                                                                         
        |<br>
        | trunk_details           |
None                                                                                                                                                                                    
        |<br>
        | updated_at              |
2020-02-14T09:16:57Z                                                                                                                                                                    
        |<br>
+-------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+<br>
      </tt></p>
    <p><tt>ctl5:~# ip netns |grep a2d4605d</tt><tt><br>
      </tt><tt>ctl5:~# </tt><br>
    </p>
    <p><br>
    </p>
    <p><br>
    </p>
    <p><b>Workaround:</b> I can easily delete those ports manually and
      everything seems to be ok (openstack delete port <portid>) <br>
    </p>
    <p><br>
    </p>
    <p>When I tried figuring out, what happens, when I disable dhcp in
      an affected subnet, the following happens (different example):</p>
    <p>The 6f34 is a reserved port (last line)<br>
    </p>
    <p><tt># openstack port list --device-owner network:dhcp --network
        8589eb04-228f-4ae1-af71-a0bc5335f9c5</tt><tt><br>
      </tt><tt>+--------------------------------------+------+-------------------+-----------------------------------------------------------------------------+--------+</tt><tt><br>
      </tt><tt>| ID                                   | Name | MAC
        Address       | Fixed IP
        Addresses                                                         
        | Status |</tt><tt><br>
      </tt><tt>+--------------------------------------+------+-------------------+-----------------------------------------------------------------------------+--------+</tt><tt><br>
      </tt><tt>| 23f9e5d7-75a2-440a-</tt><tt><tt>xxxx</tt>-d82000286fbe
        |      | fa:16:3e:8b:e2:a8 | ip_address='192.168.50.3',
        subnet_id='882b360a-eae1-4736-xxxx-af752f552440' | ACTIVE |</tt><tt><br>
      </tt><tt>| 352bc1a4-e002-440b-</tt><tt><tt>xxxx</tt>-0383cfb1632b
        |      | fa:16:3e:29:46:6b | ip_address='192.168.50.5',
        subnet_id='882b360a-eae1-4736-</tt><tt><tt>xxxx</tt>-af752f552440'
        | ACTIVE |</tt><tt><br>
      </tt><tt>| 6ee79608-7834-4015-</tt><tt><tt>xxxx</tt>-fda3f47b5e59
        |      | fa:16:3e:0c:b6:60 | ip_address='192.168.50.4',
        subnet_id='882b360a-eae1-4736-</tt><tt><tt>xxxx</tt>-af752f552440'
        | ACTIVE |</tt><tt><br>
      </tt><tt>| 6f3435f8-23c0-427c-</tt><tt><tt>xxxx</tt>-fca1a6910aff
        |      | fa:16:3e:2d:35:b6 | ip_address='192.168.50.2',
        subnet_id='882b360a-eae1-4736-</tt><tt><tt>xxxx</tt>-af752f552440'
        | ACTIVE |</tt><tt><br>
      </tt><tt>+--------------------------------------+------+-------------------+-----------------------------------------------------------------------------+--------+</tt><tt><br>
      </tt><br>
    </p>
    <p>- I disable dhcp (openstack subnet set --no-dhcp
      <subnetid>), expected to remove all dhcp ports, but the what
      happens is that all "healthy" dhcp ports will be removed, the
      reserved port remains</p>
    <p><tt># openstack port list --device-owner network:dhcp --network
        8589eb04-228f-4ae1-af71-a0bc5335f9c5</tt><tt><br>
      </tt><tt>+--------------------------------------+------+-------------------+-----------------------------------------------------------------------------+--------+</tt><tt><br>
      </tt><tt>| ID                                   | Name | MAC
        Address       | Fixed IP
        Addresses                                                         
        | Status |</tt><tt><br>
      </tt><tt>+--------------------------------------+------+-------------------+-----------------------------------------------------------------------------+--------+</tt><tt><br>
      </tt><tt>| 6f3435f8-23c0-427c-</tt><tt><tt><tt>xxxx</tt></tt>-fca1a6910aff
        |      | fa:16:3e:2d:35:b6 | ip_address='192.168.50.2',
        subnet_id='882b360a-eae1-4736-</tt><tt><tt><tt>xxxx</tt></tt>-af752f552440'
        | ACTIVE |</tt><tt><br>
      </tt><tt>+--------------------------------------+------+-------------------+-----------------------------------------------------------------------------+--------+</tt><br>
      <br>
    </p>
    <p>- when I now reenable dhcp, nothing happens, still the single,
      reserved port is existing, no new ports are created. Just the
      state went from ACTIVE to DOWN to ACTIVE<br>
    </p>
    <p><tt># openstack subnet set --dhcp
        882b360a-eae1-4736-a276-af752f552440</tt><tt><br>
      </tt><tt># openstack port list --device-owner network:dhcp
        --network 8589eb04-228f-4ae1-</tt><tt><tt><tt><tt>xxxx</tt></tt></tt>-a0bc5335f9c5</tt><tt><br>
      </tt><tt>+--------------------------------------+------+-------------------+-----------------------------------------------------------------------------+--------+</tt><tt><br>
      </tt><tt>| ID                                   | Name | MAC
        Address       | Fixed IP
        Addresses                                                         
        | Status |</tt><tt><br>
      </tt><tt>+--------------------------------------+------+-------------------+-----------------------------------------------------------------------------+--------+</tt><tt><br>
      </tt><tt>| 6f3435f8-23c0-427c-</tt><tt><tt><tt><tt>xxxx</tt></tt></tt>-fca1a6910aff
        |      | fa:16:3e:2d:35:b6 | ip_address='192.168.50.2',
        subnet_id='882b360a-eae1-4736-</tt><tt><tt><tt><tt>xxxx</tt></tt></tt>-af752f552440'
        | DOWN   |</tt><tt><br>
      </tt><tt>+--------------------------------------+------+-------------------+-----------------------------------------------------------------------------+--------+</tt><tt><br>
      </tt><tt>s# openstack port list --device-owner network:dhcp
        --network 8589eb04-228f-4ae1-</tt><tt><tt><tt><tt>xxxx</tt></tt></tt>-a0bc5335f9c5</tt><tt><br>
      </tt><tt>+--------------------------------------+------+-------------------+-----------------------------------------------------------------------------+--------+</tt><tt><br>
      </tt><tt>| ID                                   | Name | MAC
        Address       | Fixed IP
        Addresses                                                         
        | Status |</tt><tt><br>
      </tt><tt>+--------------------------------------+------+-------------------+-----------------------------------------------------------------------------+--------+</tt><tt><br>
      </tt><tt>| 6f3435f8-23c0-427c-</tt><tt><tt><tt><tt>xxxx</tt></tt></tt>-fca1a6910aff
        |      | fa:16:3e:2d:35:b6 | ip_address='192.168.50.2',
        subnet_id='882b360a-eae1-4736-</tt><tt><tt><tt><tt>xxxx</tt></tt></tt>-af752f552440'
        | ACTIVE |</tt><tt><br>
      </tt><tt>+--------------------------------------+------+-------------------+-----------------------------------------------------------------------------+--------+</tt><br>
    </p>
    <p><br>
    </p>
    <p>- after deleting the port manually and disable/enable dhcp, 3 new
      working ports are created</p>
    <p><tt># openstack port delete 6f3435f8-23c0-427c-</tt><tt><tt><tt><tt><tt>xxxx</tt></tt></tt></tt>-fca1a6910aff<br>
        # openstack port list --device-owner network:dhcp --network
        8589eb04-228f-4ae1-</tt><tt><tt><tt><tt><tt>xxxx</tt></tt></tt></tt>-a0bc5335f9c5<br>
        <br>
        # openstack subnet set --no-dhcp 882b360a-eae1-4736-</tt><tt><tt><tt><tt><tt>xxxx</tt></tt></tt></tt>-af752f552440<br>
        # openstack subnet set --dhcp 882b360a-eae1-4736-</tt><tt><tt><tt><tt><tt>xxxx</tt></tt></tt></tt>-af752f552440<br>
        # openstack port list --device-owner network:dhcp --network
        8589eb04-228f-4ae1-</tt><tt><tt><tt><tt><tt>xxxx</tt></tt></tt></tt>-a0bc5335f9c5<br>
      </tt><tt># openstack port list --device-owner network:dhcp
        --network 8589eb04-228f-4ae1-</tt><tt><tt><tt><tt><tt>xxxx</tt></tt></tt></tt>-a0bc5335f9c5</tt><tt><br>
      </tt><tt>+--------------------------------------+------+-------------------+-----------------------------------------------------------------------------+--------+</tt><tt><br>
      </tt><tt>| ID                                   | Name | MAC
        Address       | Fixed IP
        Addresses                                                         
        | Status |</tt><tt><br>
      </tt><tt>+--------------------------------------+------+-------------------+-----------------------------------------------------------------------------+--------+</tt><tt><br>
      </tt><tt>| 9fd63011-2b1f-410a-</tt><tt><tt><tt><tt><tt>xxxx</tt></tt></tt></tt>-40d42779c637
        |      | fa:16:3e:15:be:fd | ip_address='192.168.50.4',
        subnet_id='882b360a-eae1-4736-</tt><tt><tt><tt><tt><tt>xxxx</tt></tt></tt></tt>-af752f552440'
        | ACTIVE |</tt><tt><br>
      </tt><tt>| cdd32840-7899-47b2-</tt><tt><tt><tt><tt><tt>xxxx</tt></tt></tt></tt>-7d36eae515a2
        |      | fa:16:3e:4c:40:5c | ip_address='192.168.50.3',
        subnet_id='882b360a-eae1-4736-</tt><tt><tt><tt><tt><tt>xxxx</tt></tt></tt></tt>-af752f552440'
        | ACTIVE |</tt><tt><br>
      </tt><tt>| dc1eeba2-4afd-4502-</tt><tt><tt><tt><tt><tt>xxxx</tt></tt></tt></tt>-7370d086e553
        |      | fa:16:3e:29:29:5d | ip_address='192.168.50.2',
        subnet_id='882b360a-eae1-4736-</tt><tt><tt><tt><tt><tt>xxxx</tt></tt></tt></tt>-af752f552440'
        | ACTIVE |</tt><tt><br>
      </tt><tt>+--------------------------------------+------+-------------------+-----------------------------------------------------------------------------+--------+</tt><tt><br>
      </tt><br>
    </p>
    <p>Any ideas where those are coming from? <br>
      <br>
    </p>
    <p>thanks a lot <br>
    </p>
    <p>Nicolas<br>
    </p>
    <pre class="moz-signature" cols="72">-- 
</pre>
  </body>
</html>