Blob Blame History Raw
From f7e924c577cf113360798b1a670c584a3308c73f Mon Sep 17 00:00:00 2001
From: Frederick Grose <fgrose@sugarlabs.org>
Date: Sun, 9 Aug 2020 00:23:54 -0400
Subject: [PATCH] dmsquash-live-root: Remove obsolete osmin.img processing.

osmin.img is no longer used by anaconda or generated by
livemedia-creator.  livecd-creator will soon drop it as well.
Removing this code will allow OverlayFS boots to proceed  when
osmin.img is present in the .iso image.
---
 modules.d/90dmsquash-live/dmsquash-live-root.sh | 20 --------------------
 1 file changed, 20 deletions(-)

diff --git a/modules.d/90dmsquash-live/dmsquash-live-root.sh b/modules.d/90dmsquash-live/dmsquash-live-root.sh
index 6324fe83..d686d255 100755
--- a/modules.d/90dmsquash-live/dmsquash-live-root.sh
+++ b/modules.d/90dmsquash-live/dmsquash-live-root.sh
@@ -268,20 +268,6 @@ do_live_overlay() {
 }
 # end do_live_overlay()
 
-# we might have a genMinInstDelta delta file for anaconda to take advantage of
-if [ -e /run/initramfs/live/${live_dir}/osmin.img ]; then
-    OSMINSQFS=/run/initramfs/live/${live_dir}/osmin.img
-    # decompress the delta data
-    dd if=$OSMINSQFS of=/run/initramfs/osmin.img 2> /dev/null
-    OSMIN_SQUASHED_LOOPDEV=$( losetup -f )
-    losetup -r $OSMIN_SQUASHED_LOOPDEV /run/initramfs/osmin.img
-    mkdir -m 0755 -p /run/initramfs/squashfs.osmin
-    mount -n -t squashfs -o ro $OSMIN_SQUASHED_LOOPDEV /run/initramfs/squashfs.osmin
-    OSMIN_LOOPDEV=$( losetup -f )
-    losetup -r $OSMIN_LOOPDEV /run/initramfs/squashfs.osmin/osmin
-    umount -l /run/initramfs/squashfs.osmin
-fi
-
 # we might have an embedded fs image on squashfs (compressed live)
 if [ -e /run/initramfs/live/${live_dir}/${squash_image} ]; then
     SQUASHED="/run/initramfs/live/${live_dir}/${squash_image}"
@@ -370,12 +356,6 @@ if [ -n "$FSIMG" ]; then
     fi
 fi
 
-if [ -b "$OSMIN_LOOPDEV" ]; then
-    # set up the devicemapper snapshot device, which will merge
-    # the normal live fs image, and the delta, into a minimzied fs image
-    echo "0 $sz snapshot $BASE_LOOPDEV $OSMIN_LOOPDEV P 8" | dmsetup create --readonly live-osimg-min
-fi
-
 if [ -n "$reloadsysrootmountunit" ]; then
     eval "$reloadsysrootmountunit"
     systemctl daemon-reload