子网上的系统是否能够响应所有主机的多播?
使用 netstat 并检查 224.0.0.1 中接口的成员资格:
onitroad # netstat -gn|grep 224.0.0.1 lo0 224.0.0.1 1 hme0 224.0.0.1 1
如果 netstat -gn 输出显示无法响应 ALL-SYSTEMS 多播 (224.0.0.1) 的接口,则使用 route -p 命令添加主机路由。
测试 IPMP 故障转移
我们可以使用 if_mpadm 命令非常轻松地检查接口的故障和修复。
"-d" 分离接口,而 "-r" 重新连接它。
# if_mpadm -d ce0 # if_mpadm -r ce0
检查消息文件
首先要做的是检查 /var/adm/messages 文件并查找与 mpathd 相关的错误。
我们可能会发现与 IPMP 相关的不同错误(以及消息),如下所示。
消息文件中的错误很容易告诉我们 IPMP 配置中的问题。
1. interfaces configured for IPMP showing as "FAILED" in "ifconfig -a" output 2. "Successfully failed over from NIC xxxx to NIC xxxx", "NIC repair detected on " "Successfully failed back to NIC ", "The link has come up on ", "The link has gone down on " 3. "No test address configured on interface disabling probe-based failure detection on it" 4. "Test address address is not unique; disabling probe based failure detection on "
检查 in.mpathd 守护进程是否正在运行
in.mpathd 守护进程负责检测和修复 IPMP 故障。
检查进程是否在系统上运行:
# ps -ef | grep mpath root 2222 1 0 20:41:10 ? 0:06 /usr/lib/inet/in.mpathd
如果它没有运行,只需运行以下命令即可启动它:
# /usr/lib/inet/in.mpathd
要使 in.mpathd 守护进程在对其进行任何更改后重新读取 /etc/default/mpathd 配置文件,请使用:
# pkill -HUP in.mpathd
检查 ifconfig 命令输出中的标志
ifconfig -a 命令输出显示与 IPMP 和接口配置相关的各种标志。
1. interfaces configured for IPMP missing the "UP" and/or "RUNNING" flag in the ifconfig -a output 2. interfaces configured for IPMP showing as "FAILED" in "ifconfig -a" output
与 IPMP 相关的各种标志及其含义是:
deprecated -> can only be used as test address for IPMP and not for any actual data transfer by applications. -failover -> does not failover when the interface fails standby -> makes the interface to be used as standby
如果界面未显示 RUNNING 标志,请检查以下任何命令的输出,以确保服务器和交换机端口之间有工作链接。
# ndd -get /dev/[interface] adv_autoneg_cap -- make sure you have set the interface first before getting the auto neg property value
# kstat -p |grep e1000g:0 |grep auto
# dladm show-dev
确保交换机端口设置为自动协商。
从服务器端断开并重新连接以太网以重新协商与交换机端口的链接速度。
如果界面未显示 UP 标志,请使用:
# ifconfig [interface in group] up
联系支持人员提供数据
如果一切都失败,最后一个选择是联系 oracle 支持。
将以下数据提供给 oracle 支持以进行故障排除。
1.窥探
# snoop -d (first interface in the group) -o /tmp/ -s 60 -q # snoop -d (second interface in the group) -o /tmp/ -s 60 -q
2.资源管理器
太阳资源管理器输出:
# explorer -- the command may vary with hardware
- dladm
dladm show-dev > show-dev.out dladm show-link > show-link.out dladm show-aggr -L > show-aggr.out
确定默认路由器是否正确应答 ICMP 探测
基于探测的 IPMP 将使用任何链路上的路由器来发送 ICMP 探测并侦听响应。
我们可以监控 snoop 命令的输出,以确保 onlink 路由器正在响应 ping。
in.mpathd 守护进程使用测试地址与 IP 链接上的其他目标交换 ICMP 探测(也称为探测流量)。
探测流量有助于确定接口及其 NIC 的状态,包括接口是否发生故障。
探针验证接口的发送和接收路径是否正常工作。
在第一个窗口中:
onitroad # snoop -d hme0 icmp Using device /dev/hme (promiscuous mode)
在第二个窗口中:
onitroad # ping 192.168.1.1 192.168.1.1 is alive
这里 192.168.1.1 是默认路由器。
我们可以在 netstat -nrv 输出中检查默认路由器。
现在在第一个窗口中,我们应该能够看到流量:
onitroad -> 192.168.1.1 ICMP Echo request (ID: 1023 Sequence number: 0) 192.168.1.1 -> onitroad ICMP Echo reply (ID: 1023 Sequence number: 0)
这里第一行是传出的 ICMP 请求(“ping”),第二行是 ICMP 回复。
如果我们使用的是基于探针的 IPMP(带有 -failover 标记的接口),则使用 pkill 从 in.mpathd 提供调试快照并检查输出到 /var/adm/messages 的“probes lost”消息:
# pkill -USR1 mpathd # tail -20 /var/adm/messages
Solaris IP 多路径为网络堆栈提供高可用性和负载平衡功能。
它确保避免网络侧的任何单点故障。
在配置 IPMP 时甚至配置 IPMP 之后,我们可能会遇到问题。
以下是对Solaris IPMP 配置中的问题进行故障排除的一些提示和技巧。
VCS“多网卡”是否与 IPMP 一起使用?
VCS 使用称为多 NIC 的资源类型来配置使用 solaris mpathd 守护程序的 IPMP。
通过检查 /var/adm/messages 文件中的 VCS 相关错误,确保我们没有使用 VCS。
# ps -ef|grep -i multi # grep -i LLT /var/adm/messages # grep -i GAB /var/adm/messages
如果我们正在使用 VCS,请检查 main.cf 文件中的配置详细信息和 hastatus 命令以检查 MULTI-NIC 资源是否配置正确且运行良好。