diff --git a/xCAT-server/share/xcat/netboot/add-on/statelite/rc.statelite b/xCAT-server/share/xcat/netboot/add-on/statelite/rc.statelite index 9f735c49a..e403514ad 100755 --- a/xCAT-server/share/xcat/netboot/add-on/statelite/rc.statelite +++ b/xCAT-server/share/xcat/netboot/add-on/statelite/rc.statelite @@ -576,7 +576,7 @@ ResolveLinks #cp -r -a ${DEFAULT}/* /.snapshot/tmpfs/ # foo # If the resolv.conf is not setup in rootimg, copy the dhcp generated one into rootimg -if grep --quiet --no-messages "Dummy resolv.conf" "$MNTDIR/etc/resolv.conf"; then +if grep -q -s "Dummy resolv.conf" "$MNTDIR/etc/resolv.conf"; then /bin/cat /etc/resolv.conf > $MNTDIR/etc/resolv.conf fi