Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
11 changes: 6 additions & 5 deletions rdma.ifup-ib
Original file line number Diff line number Diff line change
Expand Up @@ -233,11 +233,12 @@ else
fi

if ! LC_ALL=C ip addr ls ${REALDEVICE} | LC_ALL=C grep -q "${ipaddr[$idx]}/${prefix[$idx]}" ; then
[ "${REALDEVICE}" != "lo" ] && [ "${arpcheck[$idx]}" != "no" ] && \
/sbin/arping -q -c 2 -w 3 -D -I ${REALDEVICE} ${ipaddr[$idx]}
if [ $? = 1 ]; then
net_log $"Error, some other host already uses address ${ipaddr[$idx]}."
exit 1
if [ "${REALDEVICE}" != "lo" ] && [ "${arpcheck[$idx]}" != "no" ]; then
/sbin/arping -q -c 2 -w 3 -D -I ${REALDEVICE} ${ipaddr[$idx]}
if [ $? = 1 ]; then
net_log $"Error, some other host already uses address ${ipaddr[$idx]}."
exit 1
fi
fi

if ! ip addr add ${ipaddr[$idx]}/${prefix[$idx]} \
Expand Down