DCOS 配置笔记/ICMP Redirect问题

DC/OS 配置记录

这段时间有机会玩了一下DC/OS,配置细节中还有相当多不完善的地方,安装方面的健壮性还有待提升。

可以先看这里了解一下DC/OS 和Mesos是干嘛的 。

然后跟着https://docs.mesosphere.com/1.8/administration/installing/custom/cli/

进行安装。

安装DC/OS的过程遇到的问题主要有两类:

安装过程前置没有达到条件,缺乏检测手段。
像docker 是有 docker-env-check的。

前置的安装条件检测,软件部分需要仔细check,自己需要手工安装。

https://docs.mesosphere.com/

选择很多,但是最后发现可选的其实只有CLI安装(GUI安装不能cover需求)

  1. 启动脚本没有考虑极端网络条件(比如虚拟机)

因为我的环境是四台KVM虚拟机,都是从同一个物理网卡发出数据包,所以路由器会进行一次ICMP Redirect,恰好在DC/OS 的服务启动脚本里有一个ping master的前置条件,使用了 ping -c1 master.mesos,导致ping命令失败。

ping 命令只发送一个包的的时候,会直接失败

$ ping -c1 -vv master.mesos
ping: socket: Permission denied, attempting raw socket...
PING master.mesos (10.155.0.212) 56(84) bytes of data.
From gateway (10.155.0.1): icmp_seq=1 Redirect Host(New nexthop: 10.155.0.212 (10.155.0.212))
Vr HL TOS  Len   ID Flg  off TTL Pro  cks      Src      Dst Data
 4  5  00 5400 1216   0 0040  40  01 b80d 10.155.0.214  10.155.0.212 
From gateway (10.155.0.1) icmp_seq=1 Redirect Host(New nexthop: 10.155.0.212 (10.155.0.212))

--- master.mesos ping statistics ---
1 packets transmitted, 0 received, +1 errors, 100% packet loss, time 0ms

icmp redirect 参考

http://www.cisco.com/c/en/us/support/docs/ip/routing-information-protocol-rip/13714-43.html

When Are ICMP Redirects Sent?

Cisco routers send ICMP redirects when all of these conditions are
met:

The interface on which the packet comes into the router is the same
interface on which the packet gets routed out. The subnet or network
of the source IP address is on the same subnet or network of the
next-hop IP address of the routed packet. The datagram is not
source-routed. The kernel is configured to send redirects. (By
default, Cisco routers send ICMP redirects. The interface subcommand
no ip redirects can be used to disable ICMP redirects.)

Last modification:August 14th, 2017 at 10:38 pm
If you think my article is useful to you, please feel free to appreciate

Leave a Comment