Description of problem: After recent initscripts update starting up a network failed to rename a machine with a DHCP assigned address from 'localhost'. The culprit turned out to be ifup-post. It find address by doing this: IPADDR=$(LANG=C ip -o -4 addr ls dev ${DEVICE} | awk '{ print $4 }') If ${DEVICE} in question happen to have also some additional alias addresses this returns all of these and makes a subsequnt call to 'ipcalc' very unhappy. A solution is to use only the first address as reported by 'ip'. A simple patch is attached. BTW - earlier in 'ifup-post' there is the following line: if [ "$PEERDNS" != "no" -o -n "$RESOLV_MODS" -a "$RESOLV_MODS" != "no" ]; then Is this really what is supposed to be there or rather if [ "$PEERDNS" != "no" ] || \ [ -n "$RESOLV_MODS" -a "$RESOLV_MODS" != "no" ]; then was really meant? Quite possibly what is there is fine but a logic is surely not so clear on the first look. Version-Release number of selected component (if applicable): initscripts-8.51-1
Created attachment 148836 [details] change to make ifup-post to work again
Added in CVS, will be in 8.52-1. Thanks!