diff --git a/xCAT-server/share/xcat/netboot/sle/dracut_033/xcat-prepivot.sh b/xCAT-server/share/xcat/netboot/sle/dracut_033/xcat-prepivot.sh index b5114ef43..039990ab4 100755 --- a/xCAT-server/share/xcat/netboot/sle/dracut_033/xcat-prepivot.sh +++ b/xCAT-server/share/xcat/netboot/sle/dracut_033/xcat-prepivot.sh @@ -134,15 +134,11 @@ function getdevfrommac() { done } -for lf in /tmp/dhclient.*.lease; do - netif=${lf#*.} - netif=${netif%.*} - cp $lf "$NEWROOT/var/lib/dhclient/dhclient-$netif.leases" -done - -if [ -f $NEWROOT/etc/hostname ]; then - echo `hostname -s` > $NEWROOT/etc/hostname -fi +bootif=$(ls /tmp/net.*.conf|sed -e s/.*net\.// -e s/\.conf//) +cat < $NEWROOT/etc/sysconfig/network/ifcfg-$bootif +BOOTPROTO='dhcp' +STARTMODE='auto' +EOF if [ ! -z "$ifname" ]; then MACX=${ifname#*:}