export LIVEMEDIA=${x#*=} ;;
live-media-timeout=*)
export LIVEMEDIA_TIMEOUT=${x#live-media-timeout=} ;;
+ live-media-offset=*)
+ export LIVEMEDIA_OFFSET=${x#live-media-offset=} ;;
locale=*|debian-installer/locale=*)
export LOCALE=${x#*=} ;;
keyb=*|kbd-chooser/method=*)
modprobe "${MP_QUIET}" af_packet # For DHCP
- ipconfig ${DEVICE} /tmp/net-${DEVICE}.conf
+ ipconfig ${DEVICE} /tmp/net-${DEVICE}.conf | tee /netboot.config
if [ "${NFSROOT}" = "auto" ]; then
NFSROOT=${ROOTSERVER}:${ROOTPATH}
rofsstring=${rofsstring%:}
mkdir -p /cow
+
cowdevice="tmpfs"
cow_fstype="tmpfs"
if [ -z "${devname}" ]; then
devname=$(sys2dev "${sysdev}")
fi
+
+ if [ -n "${LIVEMEDIA_OFFSET}" ]; then
+ loopdevname=$(setup_loop "${devname}" "loop" "/sys/block/loop*" "${LIVEMEDIA_OFFSET}")
+ devname="${loopdevname}"
+ fi
+
fstype=$(get_fstype "${devname}")
if is_supported_fs ${fstype}; then
mount -t ${fstype} -o ro "${devname}" $mountpoint || continue
umount $mountpoint
fi
fi
+
+ if [ -n "${LIVEMEDIA_OFFSET}" ]; then
+ losetup -d "${loopdevname}"
+ fi
return 1
}
fi
else
# Scan local devices for the image
- for i in 0 1 2 3 4 5 6 7 8 9 a b c d e f 10 11 12 13; do
+ for i in 0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19; do
livefs_root=$(find_livefs $i)
if [ -n "${livefs_root}" ]; then
break