• Failed to bind port


     2020-06-10 16:21:29.881 22084 ERROR neutron.plugins.ml2.managers [req-12a91f60-3c8c-4ffc-b7fb-52a7f9fdc94d - - - - -] Failed to bind port fbd63d58-49c1-4b94-88ba-e07106447361 on host bogon for vnic_type normal using segments [{'network_id': 'cd8ed2a7-4ef6-4fc0-bda4-c5a25ee01fd5', 'segmentation_id': 1, 'physical_network': u'physnet_vlan', 'id': '144eabfd-7029-4003-b999-66b87388b1ff', 'network_type': u'vlan'}]

    105229 2020-06-10 16:21:29.873 22084 DEBUG neutron.plugins.ml2.drivers.mech_agent [req-12a91f60-3c8c-4ffc-b7fb-          52a7f9fdc94d - - - - -] Attempting to bind port fbd63d58-49c1-4b94-88ba-e07106447361 on network cd8ed2a7-         4ef6-4fc0-bda4-c5a25ee01fd5 bind_port /usr/lib/python2.7/site-packages/neutron/plugins/ml2/drivers/               mech_agent.py:87
    105230 2020-06-10 16:21:29.879 22084 DEBUG neutron.plugins.ml2.drivers.mech_agent [req-12a91f60-3c8c-4ffc-b7fb-          52a7f9fdc94d - - - - -] Port fbd63d58-49c1-4b94-88ba-e07106447361 on network cd8ed2a7-4ef6-4fc0-bda4-             c5a25ee01fd5 not bound, no agent of type Open vSwitch agent registered on host bogon bind_port /usr/lib/          python2.7/site-packages/neutron/plugins/ml2/drivers/mech_agent.py:101
    105231 2020-06-10 16:21:29.880 22084 DEBUG neutron.plugins.ml2.drivers.mech_agent [req-12a91f60-3c8c-4ffc-b7fb-          52a7f9fdc94d - - - - -] Attempting to bind port fbd63d58-49c1-4b94-88ba-e07106447361 on network cd8ed2a7-         4ef6-4fc0-bda4-c5a25ee01fd5 bind_port /usr/lib/python2.7/site-packages/neutron/plugins/ml2/drivers/               mech_agent.py:87
    105232 2020-06-10 16:21:29.880 22084 DEBUG neutron.plugins.ml2.drivers.mech_agent [req-12a91f60-3c8c-4ffc-b7fb-          52a7f9fdc94d - - - - -] Refusing to bind due to unsupported vnic_type: normal bind_port /usr/lib/python2.7/       site-packages/neutron/plugins/ml2/drivers/mech_agent.py:92
    105233 2020-06-10 16:21:29.881 22084 INFO networking_generic_switch.generic_switch_mech [req-12a91f60-3c8c-4ffc-         b7fb-52a7f9fdc94d - - - - -]  begin bond port
    105234 2020-06-10 16:21:29.881 22084 INFO networking_generic_switch.generic_switch_mech [req-12a91f60-3c8c-4ffc-         b7fb-52a7f9fdc94d - - - - -]   port id fbd63d58-49c1-4b94-88ba-e07106447361

     

    669     def _update_port_dict_binding(self, port, binding):
     670         port[portbindings.VNIC_TYPE] = binding.vnic_type
     671         port[portbindings.PROFILE] = self._get_profile(binding)
     672         if port['device_owner'] == const.DEVICE_OWNER_DVR_INTERFACE:
     673             port[portbindings.HOST_ID] = ''
     674             port[portbindings.VIF_TYPE] = portbindings.VIF_TYPE_DISTRIBUTED
     675             port[portbindings.VIF_DETAILS] = {}
     676         else:
     677             port[portbindings.HOST_ID] = binding.host
     678             port[portbindings.VIF_TYPE] = binding.vif_type
     679             port[portbindings.VIF_DETAILS] = self._get_vif_details(binding)

    def _bind_port_if_needed(self, context, allow_notify=False,
                                 need_notify=False, allow_commit=True):
        ....
        “会调用_attempt_binding函数,”
        bind_context, need_notify, try_again = self._attempt_binding(
                    context, need_notify)
        ....
     
    def _attempt_binding(self, context, need_notify):
        ....
        bind_context = self._bind_port(context)
        ....
     
    接下来调用_bind_port函数:
    
        def _bind_port(self, orig_context):
            # Construct a new PortContext from the one from the previous
            # transaction.
            port = orig_context.current
            orig_binding = orig_context._binding
            new_binding = models.PortBinding(
                host=orig_binding.host,
                vnic_type=orig_binding.vnic_type,
                profile=orig_binding.profile,
                vif_type=portbindings.VIF_TYPE_UNBOUND,
                vif_details=''
            )
            self._update_port_dict_binding(port, new_binding)
            new_context = driver_context.PortContext(
                self, orig_context._plugin_context, port,
                orig_context.network.current, new_binding, None,
                original_port=orig_context.original)
     
            # Attempt to bind the port and return the context with the
            # result.
            “相信大家看到这个就比较熟悉了,通过mechanism manager调用driver的接口”
            self.mechanism_manager.bind_port(new_context)

     

  • 相关阅读:
    kafka.common.FailedToSendMessageException: Failed to send messages after 3 tries.
    MYSQL 大数据
    MYSQL 数据库优化
    原始代理需要改进的地方
    JDK动态代理
    使用CGLIB生成代理
    Spring
    Struts2面试题
    hibernate面试题
    Mac下创建隐藏用户
  • 原文地址:https://www.cnblogs.com/dream397/p/13100963.html
Copyright © 2020-2023  润新知