What a week it has been!
I’ve read a lot, about chroot-ing, Calamares, GRUB, subsystem mounting, bind-mounts, and much more.
This week I’ve crafted a tiny script that enables me to repeat the mounting of an ISO file to a stable OS, and next, chroot into it. The result is almost as if the live-environment was started from an USB stick.
Almost… the actual kernel of the host and the kernel the live system requires should be compatible. Besides, the chroot-ed environment has no D-Bus and systemd, but it will run several graphical applications (on the screen of the host), including Calamares. And that matters.
Using this method I am able to persist the “live”-environment (of an ISO delivering itself in statu nascendi). I am able to play with its Calamares setting and provided configurations, persist its logfiles, etc. And… important for me, install the OS to an external SSD (and not wipe away the host OS).
If tried it first on decent hardware, and not on ye olde laptop that made me do all this.
Gaining speed throughout means gaining momentum, not spending (or loosing) a lot of time on outdated and minimal hardware, and foremost not ruining the target disk.
I’ve succeeded in the end. Done development and testing with a specimen of Lubuntu 23.04 OS, and it installs without problem on hardware where it already would install from USB.
When I tried the procedure on the troubled laptop with an (recent, but not too recent) ISO of Lubuntu 23.04 the result was as expected: failure to install. This is what I’d been expecting.
So, I am now all set and done to figure out the why of my problem with Lubuntu 23.04 on my little laptop. I also found out how to compile Calamares from source in my live environment (just in case debugging of its Python scripts would not suffice).
However…before diving into the configuration and greasy details of Calamares (being able to do this was the reason I have been doing this excercise in the first place), I’ve tried my script one more time with an absolute recent daily ISO of Lubuntu 23.04 (and not one from January 20th).
To my surprise: this daily will install on my troublesome laptop. Autonomously (from stick) and also with the help of my script.
So, most likely I’ve escaped from another week of reading and debugging Calamares Python code, and who knows what more. This case is now definitively closed for me.
What a week it has been
PS: Calamares is not intended to be used like I’ve been doing, and there where a few small glitches at the end of the whole processing, after the bootloader step. I did not bother about them, and worked around them.
PS2: I saw that the calamares software as packaged by Ubuntu (I guess) differs a bit in version numbering between around January 20th and yesterday.