The format command will fail when using other paths like
/dev/disk/by-id/<part> instead of /dev/sdXY directly. It cannot find
the path /sys/block/<disk>/<part>/partition path.
The part name in /dev/disk/by-id is a symlink to /dev/sdXY. At that
point we already have the symlink resolved to the real path. It is
stored in `bdev`.
Signed-off-by: Aaron Lauterer <a.lauterer@proxmox.com>
This fixes selecting kernels for manual inclusion in the ESP which do
not come with a "-pve" in name.
It fixes listing, by just printing out the whole list as is. refresh
complains already if there's a kernel selected but no respective
vmlinuz got found. Additionally, we already plainly add the "manual
kernel list" in kernel_keep_versions, but filter then out any kernel
not containing a "-pve" in boot_kernel_list.
But boot_kernel_list should actually only filter out the kernel meta
packages.
So, use a inverse match and check for a /\d+\.\d+/ pattern, this
seems to work well enough.
Note that kernel_keep_versions doesn't picks up non-pve kernels
anyway, so this only really alters manual selection.
Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
As all operations are done on a single or no version, thus "kernel"
fits minimally better, IMO. But just accept both, for convenience
Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
especially after modifying the manually selected kernels list, we don't
want this to be skipped.
Signed-off-by: Fabian Grünbichler <f.gruenbichler@proxmox.com>
to list custom and automatically selected kernel versions that are synced to configured ESPs
Signed-off-by: Fabian Grünbichler <f.gruenbichler@proxmox.com>
with 'kernels <add|remove>' command in pve-efiboot-tool to add/remove
kernels to/from manual kernel list, and honor it when generating lists
of kernels to not autoremove/sync to ESPs
Signed-off-by: Fabian Grünbichler <f.gruenbichler@proxmox.com>
by re-executing the whole 'pve-efiboot-tool init' command inside a new mount namespace
Co-Developed-By: Thomas Lamprecht <t.lamprecht@proxmox.com>
Signed-off-by: Fabian Grünbichler <f.gruenbichler@proxmox.com>
with (sh) pveesptool to format, initialize and refresh synced ESPs, as
well as the hooks previously shipped via proxmox-ve.
pveesptool based on a never-released version written in perl by Stoiko
Ivanov.
Co-Developed-By: Stoiko Ivanov <s.ivanov@proxmox.com>
Signed-off-by: Fabian Grünbichler <f.gruenbichler@proxmox.com>