openstack-train dhcpagent报错

  • Post author:
  • Post category:其他


服务已经起来了,居然报错!!!

[root@openstack01 neutron]# openstack network agent list

+————————————–+——————–+————-+——————-+——-+——-+—————————+

| ID                                   | Agent Type         | Host        | Availability Zone | Alive | State | Binary                    |

+————————————–+——————–+————-+——————-+——-+——-+—————————+

| 2608fa24-3614-4830-b235-61fa82a84f8c | Linux bridge agent | openstack01 | None              | 🙂   | UP    | neutron-linuxbridge-agent |

| 9e8afc78-d8d1-4de7-a46e-08b6eeb5b259 | Metadata agent     | openstack01 | None              | 🙂   | UP    | neutron-metadata-agent    |

| efb46ffd-e2ae-4319-bb35-bdfa6caf1fc7 | DHCP agent         | openstack01 | nova              | 🙂   | UP    | neutron-dhcp-agent        |

+————————————–+——————–+————-+——————-+——-+——-+—————————+

server.log报错

dhcp-agent.log:2020-04-06 16:58:51.643 31650 ERROR neutron.agent.dhcp.agent [req-948f2788-767e-4ead-99b8-f16a93023abd – – – – -] Failed reporting state!: MessagingTimeout: Timed out waiting for a reply to message ID 1e52712ed9374ff5bedf4e746d4cbf57

hcp-agent.log:2020-04-06 16:58:51.643 31650 ERROR neutron.agent.dhcp.agent Traceback (most recent call last):

dhcp-agent.log:2020-04-06 16:58:51.643 31650 ERROR neutron.agent.dhcp.agent   File “/usr/lib/python2.7/site-packages/neutron/agent/dhcp/agent.py”, line 962, in _report_state

dhcp-agent.log:2020-04-06 16:58:51.643 31650 ERROR neutron.agent.dhcp.agent     ctx, self.agent_state, True)

dhcp-agent.log:2020-04-06 16:58:51.643 31650 ERROR neutron.agent.dhcp.agent   File “/usr/lib/python2.7/site-packages/neutron/agent/rpc.py”, line 101, in report_state

dhcp-agent.log:2020-04-06 16:58:51.643 31650 ERROR neutron.agent.dhcp.agent     return method(context, ‘report_state’, **kwargs)

dhcp-agent.log:2020-04-06 16:58:51.643 31650 ERROR neutron.agent.dhcp.agent   File “/usr/lib/python2.7/site-packages/oslo_messaging/rpc/client.py”, line 181, in call

dhcp-agent.log:2020-04-06 16:58:51.643 31650 ERROR neutron.agent.dhcp.agent     transport_options=self.transport_options)

dhcp-agent.log:2020-04-06 16:58:51.643 31650 ERROR neutron.agent.dhcp.agent   File “/usr/lib/python2.7/site-packages/oslo_messaging/transport.py”, line 129, in _send

dhcp-agent.log:2020-04-06 16:58:51.643 31650 ERROR neutron.agent.dhcp.agent     transport_options=transport_options)

dhcp-agent.log:2020-04-06 16:58:51.643 31650 ERROR neutron.agent.dhcp.agent   File “/usr/lib/python2.7/site-packages/oslo_messaging/_drivers/amqpdriver.py”, line 646, in send

dhcp-agent.log:2020-04-06 16:58:51.643 31650 ERROR neutron.agent.dhcp.agent     transport_options=transport_options)

dhcp-agent.log:2020-04-06 16:58:51.643 31650 ERROR neutron.agent.dhcp.agent   File “/usr/lib/python2.7/site-packages/oslo_messaging/_drivers/amqpdriver.py”, line 634, in _send

dhcp-agent.log:2020-04-06 16:58:51.643 31650 ERROR neutron.agent.dhcp.agent     call_monitor_timeout)

dhcp-agent.log:2020-04-06 16:58:51.643 31650 ERROR neutron.agent.dhcp.agent   File “/usr/lib/python2.7/site-packages/oslo_messaging/_drivers/amqpdriver.py”, line 523, in wait

dhcp-agent.log:2020-04-06 16:58:51.643 31650 ERROR neutron.agent.dhcp.agent     message = self.waiters.get(msg_id, timeout=timeout)

dhcp-agent.log:2020-04-06 16:58:51.643 31650 ERROR neutron.agent.dhcp.agent   File “/usr/lib/python2.7/site-packages/oslo_messaging/_drivers/amqpdriver.py”, line 401, in get

dhcp-agent.log:2020-04-06 16:58:51.643 31650 ERROR neutron.agent.dhcp.agent     ‘to message ID %s’ % msg_id)

dhcp-agent.log:2020-04-06 16:58:51.643 31650 ERROR neutron.agent.dhcp.agent MessagingTimeout: Timed out waiting for a reply to message ID 1e52712ed9374ff5bedf4e746d4cbf57

dhcp-agent.log:2020-04-06 16:58:51.643 31650 ERROR neutron.agent.dhcp.agent

dhcp-agent.log:2020-04-06 16:58:51.645 31650 WARNING oslo.service.loopingcall [req-948f2788-767e-4ead-99b8-f16a93023abd – – – – -] Function ‘neutron.agent.dhcp.agent.DhcpAgentWithStateReport._report_state’ run outlasted interval by 30.01 sec

首先查看配置文件有问题

我的配置

[DEFAULT]

interface_driver = linuxbridge

dhcp_driver = neutron.agent.linux.dhcp.Dnsmasq

enable_isolated_metadata = true

查看openstack官网的配置

[DEFAULT]
...
interface_driver = neutron.agent.linux.interface.BridgeInterfaceDriver
dhcp_driver = neutron.agent.linux.dhcp.Dnsmasq
enable_isolated_metadata = True

。。。果然有区别,但这个是2017年的!

这个是新的,没啥区别。地址如下:


https://docs.openstack.org/neutron/train/install/controller-install-option1-rdo.html

网上查到有人更改了时延解决了问题。从第一行看,我也有这个问题。先更改时延试试。在

/etc/neutron/neutron.conf中配置添加


[DEFAULT]


rpc_response_timeout = 200

PS:4分钟后一样报错,不行啊!服务还挂了两个,还不如不改。

more    dhcp.agent.log发现

Successfully reported state after a previous failure.

2020-04-06

22:06:06.862

56481 ERROR neutron.agent.dhcp.agent [req-fc722885-7a02-4f6e-ab2b-d3a49b910833 – – – – -]

Unable to sync network state.: MessagingTimeout: Timed out waiting for a reply to message ID a679bb510525498e854

6cfd04eedc437

………

2020-04-06

22:06:07.426

56481 INFO neutron.agent.dhcp.agent [req-f4ac54cb-9d33-4601-a964-afce13bd28a8 – – – – -]

All active networks have been fetched through RPC.

2020-04-06 22:06:07.427 56481 INFO neutron.agent.dhcp.agent [req-f4ac54cb-9d33-4601-a964-afce13bd28a8 – – – – -]

Synchronizing state complete

这一会接得着一会接不着的有点意思。时间还很接近。会不会是连接数的问题?或者说发起的请求太多了呢?不懂代码,太难了。

使用wireshark,看看包的情况。

shark到几个这样的包,103是我的节点,99是控制端。shark5672

查来查去发现length1514和之后的包必报错。

ifconfig 发现MTU是1500,my god。我在玩蛇。。。。。。



版权声明:本文为idc_lm原创文章,遵循 CC 4.0 BY-SA 版权协议,转载请附上原文出处链接和本声明。