Re: update-initramfs outside of /boot
On Sat 01 Oct 2022 at 20:07:13 +0200, Erwan David wrote: > Le 01/10/2022 à 18:25, Felix Miata a écrit : > > Erwan David composed on 2022-10-01 16:21 (UTC+0200): > > > > > My /boot is 235 MB (from deb 10 installer), however in testing I now > > > have 56MB initramfs files and update-initramfs cannot work for the 3rd > > > kernel to install (and apt autoremove keeps 2 kernels, thus at upgrade > > > there are temporarily 3 kernels). > > > I see that all the files of the initramfs are put in /boot before > > > creating the compressed image, thus the need for place. Is there a way > > > to cofigure update-initrams so that the creation of the im age is done > > > in another filesystem before instalation in /boot ? > > Alternative options: > > > > 1-Move the oldest kernel files to another filesystem, or everything, from > > /boot. > > You don't need them there until time to reboot. > > > > 2-You're not forced to keep two kernels. Remove the non-running one > > manually. > > > > 3-As Stefan already suggested, MODULES=dep. It's routine here. Big initrds > > take > > more time to load, which can be quite noticeable on old hardware. > > > > 4-Is your /boot adjacent to your swap? If yes, easily recreate both, with > > smaller > > swap, larger /boot. Don't forget to adjust fstab for UUID change of swap, > > or apply > > the one from fstab on the new. > > > My /boot is next to an encrypted lvm containing te rest of the disk. I fear > resizing /boot would require a reinstall, I'll set modules=dep It seems that a larger /boot is not an option for you. I also suspect modules=dep may not give you sufficient extra space, but it is worth a try. A lack of success with modules=dep just might propel you towards purging one or more of the installed kernels to improve the situation. -- Brian.
Re: update-initramfs outside of /boot
> Le 01/10/2022 à 18:25, Felix Miata a écrit : > > Erwan David composed on 2022-10-01 16:21 (UTC+0200): > > > >> My /boot is 235 MB (from deb 10 installer), however in testing I > >> now have 56MB initramfs files and update-initramfs cannot work for > >> the 3rd kernel to install (and apt autoremove keeps 2 kernels, > >> thus at upgrade there are temporarily 3 kernels). > >> I see that all the files of the initramfs are put in /boot before > >> creating the compressed image, thus the need for place. Is there a > >> way to cofigure update-initrams so that the creation of the im age > >> is done in another filesystem before instalation in /boot ? > > Alternative options: > > > > 1-Move the oldest kernel files to another filesystem, or > > everything, from /boot. You don't need them there until time to > > reboot. > > > > 2-You're not forced to keep two kernels. Remove the non-running one > > manually. > > > > 3-As Stefan already suggested, MODULES=dep. It's routine here. Big > > initrds take more time to load, which can be quite noticeable on > > old hardware. > > > > 4-Is your /boot adjacent to your swap? If yes, easily recreate > > both, with smaller swap, larger /boot. Don't forget to adjust fstab > > for UUID change of swap, or apply the one from fstab on the new. > > > My /boot is next to an encrypted lvm containing te rest of the disk. > I fear resizing /boot would require a reinstall, I'll set modules=dep If you happen to have extra disk space somewhere else, you could migrate your LVM to the spare disk, then shrink the 'real' LVM and move it to leave space adjacent to /boot, which you could then extend. Finally, migrate the LVM contents back (or copy them piecemeal, I don't know exactly what is possible). Whether that is simpler than a reinstallation will depend on your circumstances.
Re: update-initramfs outside of /boot
> I alreaady have compres=zstd (should be better than lzma). I'd be surprised if `zstd` compresses better than `lzma` (which itself should compress about the same as `xz`). I just tested here and I get zstd => 11049378 xz => 9989884 lzma => 9965122 Maybe with more control over the compression parameters `zstd` can be more competitive, I don't know. In any case, my quick tests do suggest that indeed changing to `lzma` probably won't help you very much (not nearly as much as changing to MODULES=dep). Stefan
Re: update-initramfs outside of /boot
Le 01/10/2022 à 18:25, Felix Miata a écrit : Erwan David composed on 2022-10-01 16:21 (UTC+0200): My /boot is 235 MB (from deb 10 installer), however in testing I now have 56MB initramfs files and update-initramfs cannot work for the 3rd kernel to install (and apt autoremove keeps 2 kernels, thus at upgrade there are temporarily 3 kernels). I see that all the files of the initramfs are put in /boot before creating the compressed image, thus the need for place. Is there a way to cofigure update-initrams so that the creation of the im age is done in another filesystem before instalation in /boot ? Alternative options: 1-Move the oldest kernel files to another filesystem, or everything, from /boot. You don't need them there until time to reboot. 2-You're not forced to keep two kernels. Remove the non-running one manually. 3-As Stefan already suggested, MODULES=dep. It's routine here. Big initrds take more time to load, which can be quite noticeable on old hardware. 4-Is your /boot adjacent to your swap? If yes, easily recreate both, with smaller swap, larger /boot. Don't forget to adjust fstab for UUID change of swap, or apply the one from fstab on the new. My /boot is next to an encrypted lvm containing te rest of the disk. I fear resizing /boot would require a reinstall, I'll set modules=dep
Re: update-initramfs outside of /boot
Erwan David composed on 2022-10-01 16:21 (UTC+0200): > My /boot is 235 MB (from deb 10 installer), however in testing I now > have 56MB initramfs files and update-initramfs cannot work for the 3rd > kernel to install (and apt autoremove keeps 2 kernels, thus at upgrade > there are temporarily 3 kernels). > I see that all the files of the initramfs are put in /boot before > creating the compressed image, thus the need for place. Is there a way > to cofigure update-initrams so that the creation of the im age is done > in another filesystem before instalation in /boot ? Alternative options: 1-Move the oldest kernel files to another filesystem, or everything, from /boot. You don't need them there until time to reboot. 2-You're not forced to keep two kernels. Remove the non-running one manually. 3-As Stefan already suggested, MODULES=dep. It's routine here. Big initrds take more time to load, which can be quite noticeable on old hardware. 4-Is your /boot adjacent to your swap? If yes, easily recreate both, with smaller swap, larger /boot. Don't forget to adjust fstab for UUID change of swap, or apply the one from fstab on the new. -- Evolution as taught in public schools is, like religion, based on faith, not based on science. Team OS/2 ** Reg. Linux User #211409 ** a11y rocks! Felix Miata
Re: update-initramfs outside of /boot
On 2022-10-01 17:26 +0200, Erwan David wrote: > Le 01/10/2022 à 17:16, Stefan Monnier a écrit : >>> My /boot is 235 MB (from deb 10 installer), however in testing I now have >>> 56MB initramfs files and update-initramfs cannot work for the 3rd kernel to >>> install (and apt autoremove keeps 2 kernels, thus at upgrade there are >>> temporarily 3 kernels). The most sustainable solution is to increase your /boot filesystem, which unfortunately might not be convenient. >> MODULES=dep >> >> and >> >> COMPRESS=lzma >> >> in `initramfs.conf` can make a big difference. >> >> >> Stefan >> >> > I alreaady have compres=zstd (should be better than > lzma). modules=most because I do not like the "guess". MODULES=dep should be fine as long as you do not intend to move your disk to another machine. > An d It would > be a temporary mesuer since initramfs siuze keeps growing. I just do > not see the point of building it in /boot rather than eg /tmp or > another directory specified in conf. It would be possible to create the initramfs in another directory, but to ensure atomic upgrades it would have to be copied to /boot anyway _before_ unlinking the old one (if any). Otherwise the system could become unbootable if it crashes at the wrong moment. Cheers, Sven
Re: update-initramfs outside of /boot
Le 01/10/2022 à 17:16, Stefan Monnier a écrit : My /boot is 235 MB (from deb 10 installer), however in testing I now have 56MB initramfs files and update-initramfs cannot work for the 3rd kernel to install (and apt autoremove keeps 2 kernels, thus at upgrade there are temporarily 3 kernels). MODULES=dep and COMPRESS=lzma in `initramfs.conf` can make a big difference. Stefan I alreaady have compres=zstd (should be better than lzma). modules=most because I do not like the "guess". An d It would be a temporary mesuer since initramfs siuze keeps growing. I just do not see the point of building it in /boot rather than eg /tmp or another directory specified in conf.
Re: update-initramfs outside of /boot
> My /boot is 235 MB (from deb 10 installer), however in testing I now have > 56MB initramfs files and update-initramfs cannot work for the 3rd kernel to > install (and apt autoremove keeps 2 kernels, thus at upgrade there are > temporarily 3 kernels). MODULES=dep and COMPRESS=lzma in `initramfs.conf` can make a big difference. Stefan
update-initramfs outside of /boot
My /boot is 235 MB (from deb 10 installer), however in testing I now have 56MB initramfs files and update-initramfs cannot work for the 3rd kernel to install (and apt autoremove keeps 2 kernels, thus at upgrade there are temporarily 3 kernels). I see that all the files of the initramfs are put in /boot before creating the compressed image, thus the need for place. Is there a way to cofigure update-initrams so that the creation of the im age is done in another filesystem before instalation in /boot ?