]> git.proxmox.com Git - proxmox-kernel-helper.git/log
proxmox-kernel-helper.git
4 months agobump version to 8.1.0 master
Thomas Lamprecht [Tue, 28 Nov 2023 12:56:34 +0000 (13:56 +0100)]
bump version to 8.1.0

Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
4 months agoRevert "drop auto-adding the simplefb module to initramfs"
Thomas Lamprecht [Tue, 28 Nov 2023 07:59:47 +0000 (08:59 +0100)]
Revert "drop auto-adding the simplefb module to initramfs"

This reverts commit 9c41f9482666a392b80a3c4da3e695c4649d8ee1 as it
seems there are quite a few systems where only the simplefb is
available, so even though this sometimes causes issues it seems less
problematic if present than not.
And the issues are mostly restricted to passthrough and the host
grabbing the GPU through that module, with workarounds possible.

Update the filename while at it.

Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
5 months agobump version to 8.0.9
Thomas Lamprecht [Tue, 21 Nov 2023 20:24:08 +0000 (21:24 +0100)]
bump version to 8.0.9

Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
5 months agoadd dedicated removable installation
Stoiko Ivanov [Tue, 21 Nov 2023 20:19:02 +0000 (21:19 +0100)]
add dedicated removable installation

seems adding `--removable` makes grub install ignore most other
information - e.g. the bootloader-id (guessed based on [0]).
add dedicated call with out `--removable` in addition

Seems that's the reason why our installer also 'rolls its own
removable' [1]

minimally tested with an ISO with this installed and an install with
ZFS on / (RAID1).

[0] https://git.savannah.gnu.org/cgit/grub.git/tree/util/grub-install.c#n1142
[1] https://git.proxmox.com/?p=pve-installer.git;a=blob;f=Proxmox/Install.pm;h=8825699416475b1934527531db4fbb40e9473ce8;hb=HEAD#l608

Signed-off-by: Stoiko Ivanov <s.ivanov@proxmox.com>
5 months agobump version to 8.0.8
Thomas Lamprecht [Tue, 21 Nov 2023 17:05:01 +0000 (18:05 +0100)]
bump version to 8.0.8

Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
5 months agogrub-install: provide --removable to grub-install
Stoiko Ivanov [Tue, 21 Nov 2023 16:56:58 +0000 (17:56 +0100)]
grub-install: provide --removable to grub-install

noticed while installing with secure-boot enabled on ZFS RAID1:
The system has no entry to boot from in the efi-vars and
the entry for the first disk simply does not boot (I assume OVMF tries
the default bootx64.efi.

Since `proxmox-boot-tool init` should only be done for ESPs, which are
dedicated to proxmox products I don't think that this will cause many
regressions

For comparison - our installer has done the manual equivalent of the
--removable option for installs on ext4 for quite a while.

minimally tested on a VM during install.

Reported-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
Signed-off-by: Stoiko Ivanov <s.ivanov@proxmox.com>
5 months agobump version to 8.0.7
Thomas Lamprecht [Tue, 21 Nov 2023 08:18:57 +0000 (09:18 +0100)]
bump version to 8.0.7

Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
5 months agogrub-wrapper: don't fail on reinit/refresh error
Fabian Grünbichler [Tue, 21 Nov 2023 07:53:05 +0000 (08:53 +0100)]
grub-wrapper: don't fail on reinit/refresh error

these can happen for example if the system
- is set up to boot using systemd-boot
- but grub updates trigger a call to "grub-install"
- and systemd-boot is not installed

in this case, "proxmox-boot-tool reinit" will fail because of the lack of
"systemd-boot", and the upgrade triggering the grub-install call would error
out.

all the error messages/warnings are still printed and hopefully noticed.

Signed-off-by: Fabian Grünbichler <f.gruenbichler@proxmox.com>
5 months agobump version to 8.0.6
Thomas Lamprecht [Mon, 20 Nov 2023 17:13:19 +0000 (18:13 +0100)]
bump version to 8.0.6

Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
5 months agokernel lists: add/handle -signed variant
Fabian Grünbichler [Mon, 20 Nov 2023 14:09:44 +0000 (15:09 +0100)]
kernel lists: add/handle -signed variant

only the package name is different, the file paths are identical and they are
not co-installable.

Signed-off-by: Fabian Grünbichler <f.gruenbichler@proxmox.com>
Reviewed-by: Stoiko Ivanov <s.ivanov@proxmox.com>
Tested-by: Stoiko Ivanov <s.ivanov@proxmox.com>
5 months agogrub-install: trigger re-init and refresh on EFI
Fabian Grünbichler [Mon, 20 Nov 2023 14:09:43 +0000 (15:09 +0100)]
grub-install: trigger re-init and refresh on EFI

and add shim- to the list of packages that are allowed to trigger.

Signed-off-by: Fabian Grünbichler <f.gruenbichler@proxmox.com>
Reviewed-by: Stoiko Ivanov <s.ivanov@proxmox.com>
Tested-by: Stoiko Ivanov <s.ivanov@proxmox.com>
5 months agoadd support for grub-on-esp (re)init
Fabian Grünbichler [Mon, 20 Nov 2023 14:09:42 +0000 (15:09 +0100)]
add support for grub-on-esp (re)init

init has to be explicit, re-init is auto-detected based on presense of
'proxmox' Grub EFI binary on ESP.

Signed-off-by: Fabian Grünbichler <f.gruenbichler@proxmox.com>
Reviewed-by: Stoiko Ivanov <s.ivanov@proxmox.com>
Tested-by: Stoiko Ivanov <s.ivanov@proxmox.com>
5 months agobump version to 8.0.5
Thomas Lamprecht [Thu, 16 Nov 2023 15:28:55 +0000 (16:28 +0100)]
bump version to 8.0.5

Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
5 months agodrop auto-adding the simplefb module to initramfs
Thomas Lamprecht [Thu, 16 Nov 2023 14:08:07 +0000 (15:08 +0100)]
drop auto-adding the simplefb module to initramfs

Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
5 months agobump version to 8.0.4
Thomas Lamprecht [Mon, 6 Nov 2023 17:00:29 +0000 (18:00 +0100)]
bump version to 8.0.4

Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
5 months agorework no-grub-efi package warning
Thomas Lamprecht [Mon, 6 Nov 2023 16:58:47 +0000 (17:58 +0100)]
rework no-grub-efi package warning

Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
5 months agoproxmox-boot-tool: check if correct grub metapackage is installed
Stoiko Ivanov [Wed, 11 Oct 2023 13:23:41 +0000 (15:23 +0200)]
proxmox-boot-tool: check if correct grub metapackage is installed

this part of the hook applies only to systems not using pbt for
bootmangement.

Currently our ISO installs grub-pc unconditionally - and never the
conflicting grub-efi-amd64. Both packages are responsible for
running grub-install (for the appropriate disks) upon an upgrade of
grub.

This results in grub currently not getting updated on uefi-booted
systems (which do not use proxmox-boot-tool).

The patch causes a warning to be printed to notify the user.

Also considered putting the check+warning in d/postinst - but this way
it will get triggered more often (upon every
kernel-upgrade/update-initramfs, instead of only on
proxmox-kernel-helper updates, which are less often), increasing the
chances of being noticed.

checking for the changelog-presence was chosen, over `dpkg-query` for
the status, for consistency with the similar patch for pve7to8 (and
potentially a small speed-gain).

Suggested-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
Signed-off-by: Stoiko Ivanov <s.ivanov@proxmox.com>
Reviewed-by: Friedrich Weber <f.weber@proxmox.com>
Tested-by: Friedrich Weber <f.weber@proxmox.com>
5 months agoproxmox-boot-tool: do not exit early in kernel-hook
Stoiko Ivanov [Wed, 11 Oct 2023 13:23:40 +0000 (15:23 +0200)]
proxmox-boot-tool: do not exit early in kernel-hook

update_esps is called first in the actual execution below - exiting
early does not work for systems that don't use proxmox-boot-tool if a
check added later needs to work there too.

Signed-off-by: Stoiko Ivanov <s.ivanov@proxmox.com>
Reviewed-by: Friedrich Weber <f.weber@proxmox.com>
Tested-by: Friedrich Weber <f.weber@proxmox.com>
8 months agobump version to 8.0.3
Fabian Grünbichler [Tue, 1 Aug 2023 10:25:32 +0000 (12:25 +0200)]
bump version to 8.0.3

Signed-off-by: Fabian Grünbichler <f.gruenbichler@proxmox.com>
9 months agopve-kernel -> proxmox-kernel rename
Fabian Grünbichler [Tue, 18 Jul 2023 07:56:34 +0000 (09:56 +0200)]
pve-kernel -> proxmox-kernel rename

following the rename in our kernel packaging, otherwise the scripts here
wouldn't pick up the new kernels (except if currently booted).

Signed-off-by: Fabian Grünbichler <f.gruenbichler@proxmox.com>
9 months agoboot tool: fix grep misinterpretation of arguments starting with a hyphen
Hannes Laimer [Fri, 23 Jun 2023 06:13:52 +0000 (08:13 +0200)]
boot tool: fix grep misinterpretation of arguments starting with a hyphen

`proxmox-boot-tool kernel remove --help`, or any version agrument
that started with a '-', lead to the grep usage message being written
into /etc/kernel/proxmox-boot-manual-kernels. The problem was `grep`
interpreted the kernel version agrument as an option since it starts
with '-'.

10 months agoproxmox boot: avoid double quotes for printf format text
Thomas Lamprecht [Thu, 22 Jun 2023 06:48:39 +0000 (08:48 +0200)]
proxmox boot: avoid double quotes for printf format text

most shells interpret the ! contained in "double quotes" as event and
try to resolve that, luckily dash doesn't do that but still simply
dangerous to do such stuff..

Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
10 months agobump version to 8.0.2
Thomas Lamprecht [Thu, 22 Jun 2023 06:37:32 +0000 (08:37 +0200)]
bump version to 8.0.2

Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
10 months agoboot tool: always check first if hookfile exists
Thomas Lamprecht [Thu, 22 Jun 2023 06:37:11 +0000 (08:37 +0200)]
boot tool: always check first if hookfile exists

Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
10 months agoboot tool: ignore unreachable commands
Thomas Lamprecht [Thu, 22 Jun 2023 06:34:22 +0000 (08:34 +0200)]
boot tool: ignore unreachable commands

Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
10 months agobump version to 8.0.1
Thomas Lamprecht [Wed, 21 Jun 2023 15:15:13 +0000 (17:15 +0200)]
bump version to 8.0.1

Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
10 months agod/control: downgrade systemd-boot dependency to suggests
Thomas Lamprecht [Wed, 21 Jun 2023 15:26:05 +0000 (17:26 +0200)]
d/control: downgrade systemd-boot dependency to suggests

by default recommends get pulled in on upgrades, at least if the user
did not disable this or used the respective CLI switch, so go for a
suggests instead:

Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
10 months agod/control: add Recommends on systemd-boot
Stoiko Ivanov [Wed, 21 Jun 2023 14:32:27 +0000 (16:32 +0200)]
d/control: add Recommends on systemd-boot

systemd-boot is a separate binary package, and proxmox-boot-tool needs
it in the uefi-case as boot-loader for the ESPs

Not adding as Depends, because it is not strictly necessary for
proxmox-boot-tool (pinning is independent as is its use on legacy-boot
systems)

Signed-off-by: Stoiko Ivanov <s.ivanov@proxmox.com>
Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
10 months agoproxmox-boot: warn on missing systemd-boot package
Stoiko Ivanov [Wed, 21 Jun 2023 14:32:26 +0000 (16:32 +0200)]
proxmox-boot: warn on missing systemd-boot package

With the shipping of systemd-boot as separate package, we cannot rely
on `bootctl` being present in all systems (e.g. currently all systems
upgraded from PVE 7 will not automatically pull systemd-boot in.

This patch adds a check for existence + warning with an explanation to
the only invocation of bootctl in the boot-tool codebase

Signed-off-by: Stoiko Ivanov <s.ivanov@proxmox.com>
Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
10 months agoboot-tool: disarm upstream systemd-boot hookscripts
Stoiko Ivanov [Wed, 21 Jun 2023 14:32:25 +0000 (16:32 +0200)]
boot-tool: disarm upstream systemd-boot hookscripts

With Debian Bookworm systemd-boot is a separate binary-package,
instead of part of the main systemd package.
Since it's not installed by default, Debian-upstream has added
hook-scripts to the package, which manage kernel copying to the esp
(kernel-install).

The hookscripts print a warning if the ESP is not mounted at
$SYSTEMD_ESP_PATH or /boot/efi, /efi or /boot - through `bootctl
is-installed --quiet` [0,1].

This patch adds a function, which disables the hookscripts from
upstream if /etc/kernel/proxmox-boot-uuids is present.
It adds an explanation as marker and 'exit 0' on top of the script, so
that users know why the scripts were touched (e.g. when a new
systemd-boot hookscript version from upstream asks what to do with the
local modifications)

While editing shell-script hooks from other packages is quite brittle
it still seems like the best option, to support most use-cases
(including users, who don't use proxmox-boot-tool, but want to
manually install systemd-boot).
Alternatives considered:
* dpkg-divert for all hookscripts - sadly the Debian policy manual
  warns against this
* adding Replaces: systemd-boot to d/control - afaict this would need
  systemd-boot to also declare this for proxmox-kernel-helper [3]

Tested on 2 VMs installed with the 8.0 ISO (once with legacy once with
uefi boot)

[0]
https://github.com/systemd/systemd/blob/8a38b62f37189b071a30f208530ce5dc278e521e/src/shared/find-esp.c#L503
[1]
https://github.com/systemd/systemd/blob/8a38b62f37189b071a30f208530ce5dc278e521e/src/boot/bootctl.c#L90
[2] https://www.debian.org/doc/debian-policy/ap-pkg-diversions.html
[3] https://www.debian.org/doc/debian-policy/ch-relationships.html

Reported-by: Aaron Lauterer <a.lauterer@proxmox.com>
Signed-off-by: Stoiko Ivanov <s.ivanov@proxmox.com>
 [T: avoid potential false exit code, use if ]
Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
11 months agodebian: wrap-and-sort -tkn
Thomas Lamprecht [Fri, 26 May 2023 12:43:31 +0000 (14:43 +0200)]
debian: wrap-and-sort -tkn

Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
11 months agobump version to 8.0.0
Thomas Lamprecht [Fri, 26 May 2023 12:09:25 +0000 (14:09 +0200)]
bump version to 8.0.0

Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
11 months agod/control: raise standards version compliance to 4.6.2
Thomas Lamprecht [Fri, 26 May 2023 12:09:18 +0000 (14:09 +0200)]
d/control: raise standards version compliance to 4.6.2

Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
11 months agod/control: define compat level via build-depends and raise to 13
Thomas Lamprecht [Fri, 26 May 2023 12:08:58 +0000 (14:08 +0200)]
d/control: define compat level via build-depends and raise to 13

Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
11 months agoadd .gitignore file
Thomas Lamprecht [Fri, 26 May 2023 12:26:12 +0000 (14:26 +0200)]
add .gitignore file

Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
11 months agobuildsys: derive upload dist automatically
Thomas Lamprecht [Fri, 26 May 2023 12:10:07 +0000 (14:10 +0200)]
buildsys: derive upload dist automatically

Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
11 months agoseparate packaging and source build system
Thomas Lamprecht [Fri, 26 May 2023 12:08:23 +0000 (14:08 +0200)]
separate packaging and source build system

Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
11 months agod/control: drop build-dependencies on essential sed package
Thomas Lamprecht [Fri, 26 May 2023 11:55:15 +0000 (13:55 +0200)]
d/control: drop build-dependencies on essential sed package

Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
11 months agobuildsys: add DSC & sbuild convenience target
Thomas Lamprecht [Fri, 26 May 2023 11:53:39 +0000 (13:53 +0200)]
buildsys: add DSC & sbuild convenience target

Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
11 months agobuildsys: make build-dir generation atomic
Thomas Lamprecht [Fri, 26 May 2023 11:40:20 +0000 (13:40 +0200)]
buildsys: make build-dir generation atomic

Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
11 months agomakefile: convert to use simple parenthesis
Thomas Lamprecht [Fri, 26 May 2023 11:39:57 +0000 (13:39 +0200)]
makefile: convert to use simple parenthesis

Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
13 months agobump version to 7.4-1
Fabian Grünbichler [Mon, 20 Mar 2023 13:23:26 +0000 (14:23 +0100)]
bump version to 7.4-1

Signed-off-by: Fabian Grünbichler <f.gruenbichler@proxmox.com>
13 months agorename /usr/share/pve-kernel-helper
Fabian Grünbichler [Thu, 16 Mar 2023 10:05:06 +0000 (11:05 +0100)]
rename /usr/share/pve-kernel-helper

and ensure upgrades that also involve a kernel install/uninstall/upgrade still
work by symlinking the old path to the new one.

Signed-off-by: Fabian Grünbichler <f.gruenbichler@proxmox.com>
15 months agorename binary package
Fabian Grünbichler [Tue, 10 Jan 2023 15:16:36 +0000 (16:16 +0100)]
rename binary package

and B+R+P old name.

Signed-off-by: Fabian Grünbichler <f.gruenbichler@proxmox.com>
15 months agoremove meta package(s)
Fabian Grünbichler [Tue, 10 Jan 2023 15:06:02 +0000 (16:06 +0100)]
remove meta package(s)

this repository now only contains the kernel helper/boot tool.

Signed-off-by: Fabian Grünbichler <f.gruenbichler@proxmox.com>
15 months agobump version to 7.3-2
Thomas Lamprecht [Tue, 10 Jan 2023 09:36:04 +0000 (10:36 +0100)]
bump version to 7.3-2

Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
16 months agobump version to 7.3-1
Thomas Lamprecht [Tue, 13 Dec 2022 15:16:17 +0000 (16:16 +0100)]
bump version to 7.3-1

Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
17 months agobump version to 7.2-14
Thomas Lamprecht [Mon, 14 Nov 2022 20:05:30 +0000 (21:05 +0100)]
bump version to 7.2-14

Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
18 months agobump version to 7.2-13
Thomas Lamprecht [Tue, 4 Oct 2022 15:28:03 +0000 (17:28 +0200)]
bump version to 7.2-13

Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
19 months agobump version to 7.2-12
Thomas Lamprecht [Mon, 12 Sep 2022 13:41:12 +0000 (15:41 +0200)]
bump version to 7.2-12

Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
19 months agoproxmox-boot: re-add include of helper-functions
Stoiko Ivanov [Mon, 12 Sep 2022 13:31:05 +0000 (15:31 +0200)]
proxmox-boot: re-add include of helper-functions

this fixes ccfbe44f75316d41e271f68a725accbd90655456

in the patch I accidentally removed the include of the helper
functions - the code uses `warn` from there

reported in our enterprise support portal and in our community-forum:
https://forum.proxmox.com/threads/.114998

reproduced with a VM:
* legacy bios
* installed PVE 6.3 (so that p-b-t was not used for legacy systems)
* then upgraded to a bullseye snapshot of 01.09.2022
* then upgraded to the last bullseye point-release
- this patch fixes the issue there.

The issue should not occur on systems using p-b-t or not using zfs
for /.

Signed-off-by: Stoiko Ivanov <s.ivanov@proxmox.com>
19 months agobump version to 7.2-11
Thomas Lamprecht [Wed, 7 Sep 2022 13:24:32 +0000 (15:24 +0200)]
bump version to 7.2-11

Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
19 months agodepend on 5.19 as opt-in kernel for bullseye based Proxmox releases
Thomas Lamprecht [Wed, 7 Sep 2022 13:24:28 +0000 (15:24 +0200)]
depend on 5.19 as opt-in kernel for bullseye based Proxmox releases

Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
19 months agod/postinst: drop initramfs update for internal bogus package
Thomas Lamprecht [Wed, 7 Sep 2022 13:15:02 +0000 (15:15 +0200)]
d/postinst: drop initramfs update for internal bogus package

Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
19 months agobump version to 7.2-10
Thomas Lamprecht [Mon, 29 Aug 2022 16:23:24 +0000 (18:23 +0200)]
bump version to 7.2-10

Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
20 months agobump version to 7.2-9
Thomas Lamprecht [Tue, 9 Aug 2022 13:08:14 +0000 (15:08 +0200)]
bump version to 7.2-9

Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
21 months agobump version to 7.2-8
Thomas Lamprecht [Wed, 27 Jul 2022 12:27:37 +0000 (14:27 +0200)]
bump version to 7.2-8

Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
21 months agobuildsys: ignore irrelevant lintian overrides
Thomas Lamprecht [Thu, 21 Jul 2022 06:31:49 +0000 (08:31 +0200)]
buildsys: ignore irrelevant lintian overrides

it would be nice to get a proxmox-boot-tool man page though, so keep
that

Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
21 months agobump version to 7.2-7
Thomas Lamprecht [Thu, 21 Jul 2022 05:37:06 +0000 (07:37 +0200)]
bump version to 7.2-7

Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
22 months agobump version to 7.2-6
Thomas Lamprecht [Thu, 23 Jun 2022 12:04:19 +0000 (14:04 +0200)]
bump version to 7.2-6

Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
22 months agobump version to 7.2-5
Thomas Lamprecht [Fri, 17 Jun 2022 13:52:24 +0000 (15:52 +0200)]
bump version to 7.2-5

Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
22 months agobump version to 7.2-4
Thomas Lamprecht [Thu, 2 Jun 2022 12:44:31 +0000 (14:44 +0200)]
bump version to 7.2-4

Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
23 months agobump version to 7.2-3
Thomas Lamprecht [Wed, 4 May 2022 14:55:29 +0000 (16:55 +0200)]
bump version to 7.2-3

Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
23 months agobump version to 7.2-2
Thomas Lamprecht [Wed, 27 Apr 2022 17:08:55 +0000 (19:08 +0200)]
bump version to 7.2-2

Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
23 months agoproxmox-boot: add reinit subcommand
Stoiko Ivanov [Fri, 11 Mar 2022 19:05:40 +0000 (20:05 +0100)]
proxmox-boot: add reinit subcommand

to iterate over all configured ESPs and refresh the boot-loader
installations.

the init function was changed to not run refresh directly - to prevent
refresh from running once for each ESP

currently reinit does not imply refresh

Signed-off-by: Stoiko Ivanov <s.ivanov@proxmox.com>
23 months agorename pve-efiboot-manual-kernels to proxmox-boot-manual-kernels
Stoiko Ivanov [Fri, 11 Mar 2022 19:05:39 +0000 (20:05 +0100)]
rename pve-efiboot-manual-kernels to proxmox-boot-manual-kernels

was forgotten during the general renaming of pve-efiboot ->
proxmox-boot.

follows commit 8c0a22adfe15dc00cf2194647bb254201d8d187b

Signed-off-by: Stoiko Ivanov <s.ivanov@proxmox.com>
2 years agop-b-t: pinning: output hint on next-boot only pinning
Thomas Lamprecht [Tue, 26 Apr 2022 10:40:03 +0000 (12:40 +0200)]
p-b-t: pinning: output hint on next-boot only pinning

Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
2 years agop-b-t: pinning: prompt for auto-refresh on interactive seesion
Thomas Lamprecht [Tue, 26 Apr 2022 09:37:53 +0000 (11:37 +0200)]
p-b-t: pinning: prompt for auto-refresh on interactive seesion

Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
Reviewed-by: Stoiko Ivanov <s.ivanov@proxmox.com>
Tested-by: Stoiko Ivanov <s.ivanov@proxmox.com>
2 years agoproxmox-boot: fix #3729 add --graceful to bootctl invocation
Stoiko Ivanov [Mon, 25 Apr 2022 16:33:01 +0000 (18:33 +0200)]
proxmox-boot: fix #3729 add --graceful to bootctl invocation

The version of systemd boot in bullseye, tries writing an efivar which
is not writeable on certain (broken) UEFIs (HP thin clients).

The issue was not present in the version in buster (the variable
simply did not get written) and can be worked around by adding
--graceful to the `bootctl install` command.

see also:
https://github.com/systemd/systemd/issues/13603

Signed-off-by: Stoiko Ivanov <s.ivanov@proxmox.com>
2 years agod/copyright: update years
Thomas Lamprecht [Fri, 22 Apr 2022 10:15:57 +0000 (12:15 +0200)]
d/copyright: update years

Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
2 years agobump version to 7.2-1
Thomas Lamprecht [Fri, 22 Apr 2022 09:39:26 +0000 (11:39 +0200)]
bump version to 7.2-1

Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
2 years agobump version to 7.1-14
Thomas Lamprecht [Tue, 29 Mar 2022 13:48:33 +0000 (15:48 +0200)]
bump version to 7.1-14

Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
2 years agobump version to 7.1-13
Thomas Lamprecht [Sat, 12 Mar 2022 14:39:52 +0000 (15:39 +0100)]
bump version to 7.1-13

Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
2 years agoboot tool: seletive usage help message
Thomas Lamprecht [Fri, 4 Mar 2022 10:08:07 +0000 (11:08 +0100)]
boot tool: seletive usage help message

Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
2 years agokernel pinning: note when overriding previous pin
Thomas Lamprecht [Fri, 4 Mar 2022 10:05:23 +0000 (11:05 +0100)]
kernel pinning: note when overriding previous pin

Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
2 years agokernel pinning: output possible kversions on bad usage
Thomas Lamprecht [Fri, 4 Mar 2022 10:04:54 +0000 (11:04 +0100)]
kernel pinning: output possible kversions on bad usage

Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
2 years agoboot-tool: shellcheck lint fixes
Thomas Lamprecht [Tue, 22 Feb 2022 16:28:34 +0000 (17:28 +0100)]
boot-tool: shellcheck lint fixes

Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
2 years agoproxmox-boot: add pin/unpin functionality for non-p-b-t systems
Stoiko Ivanov [Fri, 11 Feb 2022 15:15:44 +0000 (16:15 +0100)]
proxmox-boot: add pin/unpin functionality for non-p-b-t systems

While running `update-grub` directly in this case is a divergence from
the semantics of the command when p-b-t handles booting it makes the
cleanup in the `next-boot` case a bit tidier.

fetching the next-boot version explicitly again before setting the
provided version is to cover the sequence:
p-b-t kernel pin <ver1> --next-boot ; p-b-t kernel pin <ver2>

Signed-off-by: Stoiko Ivanov <s.ivanov@proxmox.com>
Reviewed-by: Fabian Grünbichler <f.gruenbichler@proxmox.com>
Tested-by: Fabian Grünbichler <f.gruenbichler@proxmox.com>
Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
2 years agoproxmox-boot: add --next-boot option kernel pin command
Stoiko Ivanov [Fri, 11 Feb 2022 15:15:43 +0000 (16:15 +0100)]
proxmox-boot: add --next-boot option kernel pin command

by setting the desired version in a dedicated file, which is used
by the systemd service as condition for removing it and refreshing
upon reboot.

Signed-off-by: Stoiko Ivanov <s.ivanov@proxmox.com>
Reviewed-by: Fabian Grünbichler <f.gruenbichler@proxmox.com>
Tested-by: Fabian Grünbichler <f.gruenbichler@proxmox.com>
Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
2 years agofix #3761: proxmox-boot: add pin/unpin for kernel-version
Stoiko Ivanov [Fri, 11 Feb 2022 15:15:42 +0000 (16:15 +0100)]
fix #3761: proxmox-boot: add pin/unpin for kernel-version

The 2 commands follow the mechanics of p-b-t kernel add/remove in
writing the desired abi-version to a config-file in /etc/kernel and
actually modifying the boot-loader configuration upon p-b-t refresh.

A dedicated new file is used instead of writing the version (with some
kind of annotation) to the manual kernel list to keep parsing the file
simple (and hopefully also cause fewer problems with manually edited
files)

For systemd-boot we write the entry into the loader.conf on the ESP(s)
instead of relying on the `bootctl set-default` mechanics (bootctl(1))
which write the entry in an EFI-var. This was preferred, because of a
few reports of unwriteable EFI-vars on some systems (e.g. DELL servers
have a setting preventing writing EFI-vars from the OS). The rationale
in `Why not simply rely on the EFI boot menu logic?` from [0] also
makes a few points in that direction.

For grub the following choices were made:
* write the pinned version (or actually the menu-path leading to it)
  to a snippet in /etc/default/grub.d instead of editing the grub.cfg
  files on the partition. Mostly to divert as little as possible from
  the grub-workflow I assume people are used to.
* the 'root-device-id' part of the menu-entries is parsed from
  /boot/grub/grug.cfg since it was stable (the same on all ESPs and in
  /boot/grub), saves us from copying the part of "find device behind
  /, mangle it if zfs/btrfs, call grub_probe a few times" part of
  grub-mkconfig - and seems a bit more robust

Tested with a BIOS and an UEFI VM with / on ZFS.

[0] https://systemd.io/BOOT_LOADER_SPECIFICATION/

Signed-off-by: Stoiko Ivanov <s.ivanov@proxmox.com>
Reviewed-by: Fabian Grünbichler <f.gruenbichler@proxmox.com>
Tested-by: Fabian Grünbichler <f.gruenbichler@proxmox.com>
Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
2 years agoproxmox-boot: return empty if file does not exist in get_first_line
Stoiko Ivanov [Fri, 11 Feb 2022 15:15:41 +0000 (16:15 +0100)]
proxmox-boot: return empty if file does not exist in get_first_line

makes using this helper shorter in most cases

Signed-off-by: Stoiko Ivanov <s.ivanov@proxmox.com>
Reviewed-by: Fabian Grünbichler <f.gruenbichler@proxmox.com>
Tested-by: Fabian Grünbichler <f.gruenbichler@proxmox.com>
Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
2 years agobump version to 7.1-12
Thomas Lamprecht [Mon, 14 Feb 2022 14:13:10 +0000 (15:13 +0100)]
bump version to 7.1-12

Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
2 years agohelpers postinst: fixup initrd onetime after update
Thomas Lamprecht [Mon, 14 Feb 2022 14:08:28 +0000 (15:08 +0100)]
helpers postinst: fixup initrd onetime after update

Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
2 years agoinitrd modules: use simplefb
Thomas Lamprecht [Mon, 14 Feb 2022 14:07:24 +0000 (15:07 +0100)]
initrd modules: use simplefb

while it's the legacy variant it actually works over simpledrm with
amdgpu (glitches) and nvidia (complete breakage)

Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
2 years agobump version to 7.1-11
Thomas Lamprecht [Tue, 8 Feb 2022 11:31:16 +0000 (12:31 +0100)]
bump version to 7.1-11

Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
2 years agoship config to always include simpledrm module in initrd
Thomas Lamprecht [Fri, 11 Feb 2022 15:28:24 +0000 (16:28 +0100)]
ship config to always include simpledrm module in initrd

to ensure the newly switched on SYS_FB kconfig doesn't breaks the
using the fb for the kernel, e.g., via fbcon

Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
2 years agoproxmox-boot: add get_first_line_from_file helper and use it
Stoiko Ivanov [Mon, 31 Jan 2022 17:59:15 +0000 (18:59 +0100)]
proxmox-boot: add get_first_line_from_file helper and use it

Signed-off-by: Stoiko Ivanov <s.ivanov@proxmox.com>
2 years agoproxmox-boot: drop unused potential_esps function
Stoiko Ivanov [Mon, 31 Jan 2022 17:59:14 +0000 (18:59 +0100)]
proxmox-boot: drop unused potential_esps function

Signed-off-by: Stoiko Ivanov <s.ivanov@proxmox.com>
2 years agobump version to 7.1-10
Thomas Lamprecht [Fri, 4 Feb 2022 05:58:28 +0000 (06:58 +0100)]
bump version to 7.1-10

Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
2 years agobump version to 7.1-9
Thomas Lamprecht [Mon, 31 Jan 2022 11:10:07 +0000 (12:10 +0100)]
bump version to 7.1-9

Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
2 years agobump version to 7.1-8
Thomas Lamprecht [Tue, 11 Jan 2022 12:45:52 +0000 (13:45 +0100)]
bump version to 7.1-8

Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
2 years agobump version to 7.1-7
Thomas Lamprecht [Tue, 14 Dec 2021 20:29:03 +0000 (21:29 +0100)]
bump version to 7.1-7

Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
2 years agofix #3781: add Provides: wireguard-modules to control.in
Stoiko Ivanov [Mon, 13 Dec 2021 14:52:15 +0000 (15:52 +0100)]
fix #3781: add Provides: wireguard-modules to control.in

without this line `apt install wireguard` pulls in Debian's kernel +
firmware which confilcts with pve-firmware - forcing users to install
via `apt install --no-install-recommends wireguard-tools` in order to
get the userspace utils.

Plain debian has the 'Provides' in the meta-package[0]
(linux-image-amd64), so following this add it to pve-kernel-$MAJ.$MIN

versioned dependency added since wireguard has a versioned dependency
on wireguard-modules.

[0] https://salsa.debian.org/kernel-team/linux/-/blob/master/debian/templates/control.image.meta.in

Signed-off-by: Stoiko Ivanov <s.ivanov@proxmox.com>
2 years agod/control.in: Provide linux-image/linux-headers
Stoiko Ivanov [Mon, 13 Dec 2021 14:52:14 +0000 (15:52 +0100)]
d/control.in: Provide linux-image/linux-headers

pve-kernel-$MAJ.$MIN (e.g. pve-kernel-5.15) is the equivalent
to linux-image-amd64 for plain debian systems (similarly
pve-headers-$MAJ.$MIN).

Providing the plain debian meta-packages should improve the user
experience, for example when users install DKMS packages, which have a
dependency on linux-headers-amd64.

Signed-off-by: Stoiko Ivanov <s.ivanov@proxmox.com>
2 years agoproxmox-boot: drop useless assignment to self
Thomas Lamprecht [Tue, 30 Nov 2021 18:01:32 +0000 (19:01 +0100)]
proxmox-boot: drop useless assignment to self

Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
2 years agoproxmox-boot: handle /etc/kernel/cmdline without any newline
Thomas Lamprecht [Tue, 30 Nov 2021 17:53:55 +0000 (18:53 +0100)]
proxmox-boot: handle /etc/kernel/cmdline without any newline

Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
2 years agobump version to 7.1-6
Thomas Lamprecht [Tue, 30 Nov 2021 15:43:30 +0000 (16:43 +0100)]
bump version to 7.1-6

Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
2 years agobump version to 7.1-5
Thomas Lamprecht [Tue, 30 Nov 2021 12:30:39 +0000 (13:30 +0100)]
bump version to 7.1-5

Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
2 years agoproxmox-boot: esp config: align options argunment vertically
Thomas Lamprecht [Thu, 11 Nov 2021 10:11:23 +0000 (11:11 +0100)]
proxmox-boot: esp config: align options argunment vertically

Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
2 years agoproxmox-boot: read only first line of /etc/kernel/cmdline
Stoiko Ivanov [Wed, 10 Nov 2021 15:25:10 +0000 (16:25 +0100)]
proxmox-boot: read only first line of /etc/kernel/cmdline

following the commit of removing the wrong indentation of the linux
and initrd lines - this commit strips empty lines (and leading
trailing whitespace) in /etc/kernel/cmdline.

I managed to reproduce the issue reported in the forum [0] by adding
empty lines to /etc/kernel/cmdline) - without this - systemd-boot
booted quite happily even with the indentation.

considered using perl -pe with multiline matching but thanks to
Thomas' suggestion went with the shell-builtin read.

the check for existance of 'root=' in the resulting CMDLINE was added,
since my test-system had an empty line in the beginning, which again
rendered it unbootable.

quickly tested on a VM.

[0]: https://forum.proxmox.com/threads/problem-with-proxmox-boot-tool.99043/

Signed-off-by: Stoiko Ivanov <s.ivanov@proxmox.com>