[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: update-initramfs



On Tue 11 Apr 2023 at 10:51:19 (-0400), Marc Auslander wrote:
> On 4/10/2023 11:00 PM, David Wright wrote:
> > On Mon 10 Apr 2023 at 20:17:11 (-0400), Marc Auslander wrote:
> > > I'm on Buster.
> > > 
> > > In /boot I keep a copy of the current working linux named by appending
> > > -knowngood to the four files.  My idea is that if an update fails, I
> > > have a recent working linux.  This is different from vmlinuz.old which
> > > is the previous kernel version.  The updates in question are not to
> > > the kernel but to initrd.image of course.
> > > 
> > > Suddenly, update-initramfs insists in trying to first update
> > > initrd.....-knowngood  which of course fails because there are no
> > > underling file with that name.  This never happened in the past,
> > > AFAIK. Once it fails it gives up.
> > > 
> > > There seems no way to force update-initramfs to update the right kernel.
[ … ]
> thanks but that's the first thing I checked - it's yes, not all.  But
> my backup names contain the current version string.
> 
> I'm not sure about the sort order hack.  My goal is to have
> update-grub see the knowngood as a bootable linux and include it in
> the boot menu. That's also why .bak of initrd isn't good enough - I
> need a complete copy.

Oh, so it's update-grub calling update-initramfs, which could
complicate things.

Quite honestly, I don't see why you want to make what are essentially
backup files into part of the working set for both Grub and initramfs,
meaning they have to process duplicate files.

Any time you have a set of files that you're happy with, why not just
copy them to another directory, like /boot/backups/, adding suitable
suffixes. With Grub's flexibility, it's very easy to boot from those
copies instead. Press e at the blue screen, and tweak the filenames.
If you forget where they are or what they're called, press c instead
and go hunting with ls.

Cheers,
David.


Reply to: