Mindi error on UEFI system

Tomas Kopal <[email protected]> Wed, 2 Dec 2020 15:52:15 +0100
Newsgroups gmane.linux.mondo.devel
Message-ID <[email protected]>
Hi,

I am using MondoArchive on my Debian system for some time, and it's been 
always working great. However, after updating to Buster, I started 
receiving errors from mondoarchive (version v3.3.0-r3762). Turns out 
only after upgrade I started doing backups as UEFI. Most issues were 
easy to resolve, but the last one.

During boot disc creation, mindi reports an error:

INFO: Creating a vfat filesystem on /tmp/mondo.tmp.xrh8ft/mindi-bootroot.img
INFO: Mounting /tmp/mondo.tmp.xrh8ft/mindi-bootroot.img on 
/tmp/mondo.tmp.xrh8ft/mpt
INFO: Moving boot info on /tmp/mondo.tmp.xrh8ft/mpt
INFO: Re-Mounting /tmp/mondo.tmp.xrh8ft/mindi-bootroot.img on 
/tmp/mondo.tmp.xrh8ft/mpt
*cp: error writing 
'/tmp/mondo.tmp.xrh8ft/mpt/images/mindi-bootroot.img': No space left on 
device*
INFO: Generating ISO image.
INFO: Invoking /usr/bin/genisoimage -J -r -v -p Mindi -publisher 
http://www.mondorescue.org -A Mindi -V MindiCD -o 
/var/cache/mindi/mindi.iso  -b EFI/isolinux.bin -c EFI/boot.cat 
-no-emul-boot -boot-load-size 4 -boot-info-table -eltorito-alt-boot 
-efi-boot images/mindi-bootroot.img -no-emul-boot .
INFO: Created bootable ISO image at /var/cache/mindi/mindi.iso

After some naive attempts increasing the EXTRA_SPACE parameter, I 
started reading through the code to figure out what happens. And I got 
lost :-(.

Looking at mindi script source, I can see from line 1788 
(http://trac.mondorescue.org/browser/MondoRescue/branches/3.3/mindi/mindi#L1788), 
that $MINDI_TMP/mindi-bootroot.img is an image of vfat partition, 
populated with the contents of the target folder. So far so good.

But, for ISO image on UEFI system (my case), there is more code starting 
on line 1875 
(http://trac.mondorescue.org/browser/MondoRescue/branches/3.3/mindi/mindi#L1875), 
where the final partition image is copied to $MINDI_CACHE, then the 
original image is mounted to $MINDI_TMP/mpt (line 1879). Then the copy 
of the image from $MINDI_CACHE is mounted to $MINDI_TMP/mpt2 (line 
1882), and then *the whole partition image* (mindi-bootroot.img file) 
*is copied to the mounted partition image* folder via command 'cp -a 
$MINDI_TMP/mpt2/images/all.tar.gz $MINDI_CACHE/*mindi-bootroot.img* 
$MINDI_TMP/mpt/images' (line 1886).

How on earth can partition image fit into itself?

I am sure I am missing something, or reading some code somewhere wrong, 
as it looks the code has been there for ages and I found no reports that 
it does not work. Can someone, please, explain to me how this piece of 
code is actually meant to be working? AFAIK vfat can't do sparse files, 
there is no compression... I am lost.

Thank you in advance for any hints.

Tomas

_______________________________________________
Mondo-devel mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/mondo-devel
OpenPGP_signature (application/pgp-signature, 495 B) - not displayed