diff --git a/xCAT-server/lib/xcat/plugins/debian.pm b/xCAT-server/lib/xcat/plugins/debian.pm index 510db7afa..623503b24 100644 --- a/xCAT-server/lib/xcat/plugins/debian.pm +++ b/xCAT-server/lib/xcat/plugins/debian.pm @@ -770,7 +770,7 @@ sub mkinstall #} $kcmdline .= " xcatd=".$instserver; - $kcmdline .= " mirror/http/hostname=".$instserver; +# $kcmdline .= " mirror/http/hostname=".$instserver; if ($maxmem) { $kcmdline.=" mem=$maxmem"; } diff --git a/xCAT-server/share/xcat/install/debian/initoverlay/lib/debian-installer-startup.d/S10detectnic b/xCAT-server/share/xcat/install/debian/initoverlay/lib/debian-installer-startup.d/S10detectnic index 3b0c63317..d17504dfc 100644 --- a/xCAT-server/share/xcat/install/debian/initoverlay/lib/debian-installer-startup.d/S10detectnic +++ b/xCAT-server/share/xcat/install/debian/initoverlay/lib/debian-installer-startup.d/S10detectnic @@ -4,6 +4,7 @@ if echo $BOOTMAC|grep BOOTIF= > /dev/null; then for dir in /sys/class/net/*; do if grep -i $BOOTMAC $dir/address > /dev/null; then debconf-set netcfg/choose_interface `basename $dir` + echo "d-i netcfg/choose_interface select `basename $dir`" >> /preseed.cfg fi done fi diff --git a/xCAT-server/share/xcat/install/scripts/pre.ubuntu b/xCAT-server/share/xcat/install/scripts/pre.ubuntu index 0f1cd4cef..95c95ece9 100644 --- a/xCAT-server/share/xcat/install/scripts/pre.ubuntu +++ b/xCAT-server/share/xcat/install/scripts/pre.ubuntu @@ -4,11 +4,17 @@ if [ ! -c /dev/vcs ]; then mknod /dev/vcs c 7 0 fi +while [ -z "$instdisk" ]; do +VIRTDISKS=`ls /dev/vd*|wc -l` +if [ $VIRTDISKS -gt 0 ]; then for disk in /dev/vd*[^0-9]; do if [ -z "$firstdirectdisk" ]; then firstdirectdisk=$disk; fi #remember first disk as a guess of medium resort #no edd_id in debian installer, no edd hints supported done +fi if [ -z "$firstdirectdisk" ]; then + SCSIDISKS=`ls /dev/sd*|wc -l` + if [ $SCSIDISKS -gt 0 ]; then for disk in /dev/sd*[^0-9]; do currdriver=`udevadm info --attribute-walk --name $disk |grep DRIVERS|grep -v '""'|grep -v '"sd"'|head -n 1|sed -e 's/[^"]*"//' -e 's/"//'` case "$currdriver" in @@ -23,6 +29,7 @@ if [ -z "$firstdirectdisk" ]; then ;; esac done + fi fi if [ -z "$instdisk" ]; then if [ ! -z "$firstdirectdisk" ]; then @@ -33,7 +40,9 @@ if [ -z "$instdisk" ]; then instdisk=$firstdisk fi fi -debconf-set partman-auto/disk "$instdisk" +if [ ! -z "$instdisk" ]; then debconf-set partman-auto/disk "$instdisk"; fi +sleep 0.1 +done &