net-setup is broken in livecd-tools-2.0.2: - ifconfig has moved from /sbin/ to /sbin/ - eval or dialog changed the behavior for quote handling Reproducible: Always
Created attachment 337330 [details, diff] Fix net-setup in livecd-tools-2.0.2
Index: livecd-functions.sh =================================================================== RCS file: /var/cvsroot/gentoo/src/livecd-tools/livecd-functions.sh,v retrieving revision 1.27 diff -u -B -r1.27 livecd-functions.sh --- livecd-functions.sh 9 Aug 2006 14:41:03 -0000 1.27 +++ livecd-functions.sh 24 Feb 2013 20:57:24 -0000 @@ -26,6 +26,11 @@ fi } +ifconfig() { + [ -x /bin/ifconfig ] && /bin/ifconfig ${@} + [ -x /sbin/ifconfig ] && /sbin/ifconfig ${@} +} + livecd_get_cmdline() { echo "0" > /proc/sys/kernel/printk CMDLINE="$(cat /proc/cmdline)" @@ -241,7 +246,7 @@ GATEWAY="$(cat ${iface}.GW)" dialog --title "DNS server" --inputbox "Please enter a name server to use (hit enter for none:)" 20 50 2> ${iface}.DNS DNS="$(cat ${iface}.DNS)" - /sbin/ifconfig ${iface} ${IP} broadcast ${BROADCAST} netmask ${NETMASK} + ifconfig ${iface} ${IP} broadcast ${BROADCAST} netmask ${NETMASK} if [ -n "${GATEWAY}" ] then /sbin/route add default gw ${GATEWAY} dev ${iface} netmask 0.0.0.0 metric 1 @@ -378,7 +383,7 @@ local opts IFS=" " - for ifname in $(/sbin/ifconfig -a | grep "^[^ ]"); do + for ifname in $(ifconfig -a | grep "^[^ ]"); do ifname="${ifname%% *}" [[ ${ifname} == "lo" ]] && continue opts="${opts} ${ifname} '$(get_ifdesc ${ifname})'" This might work better in the long run. lspci and iwconfig should probably get the same treatment.
this has been fixed in the latest git. just needs a new release made.
release 2.0.4 has been made