#!/bin/bash
#shopt -s nullglob

#for f in ifcfg-eth0:* 
#do	
#	f=`echo $f | /bin/awk -F "-" '{ print $2 }'`
#	ifconfig $f down
#	sleep 2
#	ifup $f
#done

find /etc/sysconfig/network-scripts/ -name 'ifcfg-eth0:*' -print0|xargs -0 -n 1 echo | awk -F"/" '{ print $5 }' | awk -F"-" '{ print $2 }' | while read f; do
       ifconfig $f down
       sleep 1
       ifup $f
done
