From: Friedrich Weber <f.weber@proxmox.com>
To: Proxmox VE development discussion <pve-devel@lists.proxmox.com>,
Stoiko Ivanov <s.ivanov@proxmox.com>
Subject: Re: [pve-devel] [PATCH 2/2] proxmox-boot-tool: check if correct grub metapackage is installed
Date: Mon, 9 Oct 2023 09:07:25 +0200 [thread overview]
Message-ID: <6f2bca54-e79d-4854-9670-2b704762c537@proxmox.com> (raw)
In-Reply-To: <20231004120558.382180-3-s.ivanov@proxmox.com>
On 04/10/2023 14:05, Stoiko Ivanov wrote:
> diff --git a/src/proxmox-boot/zz-proxmox-boot b/src/proxmox-boot/zz-proxmox-boot
> index 1adc1b1..0d08dbf 100755
> --- a/src/proxmox-boot/zz-proxmox-boot
> +++ b/src/proxmox-boot/zz-proxmox-boot
> @@ -215,6 +215,23 @@ disable_systemd_boot_hook() {
>
> }
>
> +check_grub_efi_package() {
> +
> + if [ -f "${ESP_LIST}" ]; then
> + return
> + fi
> +
> + if [ ! -d /sys/firmware/efi ]; then
> + return
> + fi
> +
> + if [ ! -f /usr/share/doc/grub-efi-amd64/changelog.Debian.gz ]; then
> + return
> + fi
If I understand correctly, this check needs to be inverted, since we do
want to warn if grub-efi-amd64 is *not* installed? (only noticed because
my UEFI-based test machine did not print the warning below on upgrade)
> + warn "uefi-booted system, without grub-efi-amd64 package - /boot/efi will not be updated"
> +
> +}
> +
> set -- $DEB_MAINT_PARAMS
> mode="${1#\'}"
> mode="${mode%\'}"
> @@ -228,6 +245,7 @@ case $0:$mode in
> BOOT_KVERS="$(boot_kernel_list "$@")"
> update_esps
> disable_systemd_boot_hook
> + check_grub_efi_package
> ;;
> */postrm.d/*:|*/postrm.d/*:remove)
> reexec_in_mountns "$@"
> @@ -235,6 +253,7 @@ case $0:$mode in
> BOOT_KVERS="$(boot_kernel_list)"
> update_esps
> disable_systemd_boot_hook
> + check_grub_efi_package
> ;;
> esac
>
next prev parent reply other threads:[~2023-10-09 7:07 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2023-10-04 12:05 [pve-devel] [PATCH kernel-helper/manager] check for fitting grub-meta package on uefi systems Stoiko Ivanov
2023-10-04 12:05 ` [pve-devel] [PATCH 1/2] proxmox-boot-tool: do not exit early in kernel-hook Stoiko Ivanov
2023-10-04 12:05 ` [pve-devel] [PATCH 2/2] proxmox-boot-tool: check if correct grub metapackage is installed Stoiko Ivanov
2023-10-09 7:07 ` Friedrich Weber [this message]
2023-10-04 12:05 ` [pve-devel] [PATCH 1/1] pve7to8: check for proper grub meta-package for bootmode Stoiko Ivanov
2023-10-09 7:11 ` Friedrich Weber
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=6f2bca54-e79d-4854-9670-2b704762c537@proxmox.com \
--to=f.weber@proxmox.com \
--cc=pve-devel@lists.proxmox.com \
--cc=s.ivanov@proxmox.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.