openvz arping: Device venet0 not available, /etc/sysconfig/network-scripts/ifup-aliases[308]: Error, some other host already uses address


diff --git a/sysconfig/network-scripts/ifup-aliases b/sysconfig/network-scripts/ifup-aliases
index e66cb81..2989b8d 100755
--- a/sysconfig/network-scripts/ifup-aliases
+++ b/sysconfig/network-scripts/ifup-aliases
@@ -267,7 +267,8 @@ function new_interface ()
is_available ${parent_device} && \
( grep -qswi "up" /sys/class/net/${parent_device}/operstate || grep -qswi "1" /sys/class/net/${parent_device}/carrier ) ; then
echo $"Determining if ip address ${IPADDR} is already in use for device ${parent_device}..."
- if ! /sbin/arping -q -c 2 -w ${ARPING_WAIT:-3} -D -I ${parent_device} ${IPADDR} ; then
+ /sbin/arping -q -c 2 -w ${ARPING_WAIT:-3} -D -I ${parent_device} ${IPADDR}
+ if [ $? = 1 ]; then
net_log $"Error, some other host already uses address ${IPADDR}."
return 1
fi

wget https://git.fedorahosted.org/cgit/initscripts.git/snapshot/initscripts-55a50ebc591ebd0f4cfbb8ecc204fa20ee6a7368.tar.gz

vzlist | grep VZ_name # Get container ID
cp -v initscripts-55a50ebc591ebd0f4cfbb8ecc204fa20ee6a7368.tar.gz /vz/root/C_ID/root/ # where C_ID is container ID

vzctl enter C_ID
tar xvf initscripts-55a50ebc591ebd0f4cfbb8ecc204fa20ee6a7368.tar.gz sysconfig/network-scripts/ifup-aliases
mv -v /etc/sysconfig/network-scripts/ifup-aliases /etc/sysconfig/network-scripts/ifup-aliases.orig
cp sysconfig/network-scripts/ifup-aliases /etc/sysconfig/network-scripts/ifup-aliases
service network restart

Restarting network (via systemctl): [ OK ]

One thought on “openvz arping: Device venet0 not available, /etc/sysconfig/network-scripts/ifup-aliases[308]: Error, some other host already uses address

  1. Besik K.

    Hi,

    There’s a fix for CentOS 7 if anyone having this issue:

    – sudo nano /etc/sysconfig/network-scripts/ifup-aliases
    – Find the line:

    is_available ${parent_device} && \

    – Below that, find:

    if ! /sbin/arping -q -c 2 -w ${ARPING_WAIT:-3} -D -I ${parent_device} ${IPADDR} ; then

    – Take out “if ! ” and ” ; then”
    – Below that line, add:

    if [ $? = 1 ]; then

    – Save and Close
    – reboot container

    Reply

Leave a Reply

Your email address will not be published. Required fields are marked *