Installing on top of Debian with Systemd-boot and BTRFS

we don't support that level of customization in the installer for any storage type. but we already create one for the local BTRFS storage, and I think all the other directories except for '/' should be empty on first boot so you could handle that with a hook there..
 
  • Like
Reactions: aureladmin
could you post the output of "proxmox-boot-tool status" and "proxmox-boot-tool refresh", as well as "efibootmgr -v"?
Hi,
Here it is:
Bash:
root@proxmox:~# proxmox-boot-tool status
Re-executing '/usr/sbin/proxmox-boot-tool' in new private mount namespace..
System currently booted with uefi
A1B2-1234 is configured with: uefi (versions: 6.14.11-2-pve)
root@proxmox:~# proxmox-boot-tool refresh
Running hook script 'proxmox-auto-removal'..
Running hook script 'zz-proxmox-boot'..
Re-executing '/etc/kernel/postinst.d/zz-proxmox-boot' in new private mount namespace..
Copying and configuring kernels on /dev/disk/by-uuid/A1B2-1234
    Copying kernel and creating boot-entry for 6.14.11-2-pve
root@proxmox:~# efibootmgr -v
BootCurrent: 0005
Timeout: 1 seconds
BootOrder: 0005,0009,000A,0000,0003,0002,0001,0006,0004
Boot0000  Linux Boot Manager    VenHw(9[REDACTED]cb)
      dp: [REDACTED] 00 cb / [REDACTED] 00
Boot0001  Linux Boot Manager    VenHw(9[REDACTED]cb)
      dp: [REDACTED] 00 cb / [REDACTED] 00
Boot0002  Linux Boot Manager    VenHw(9[REDACTED]cb)
      dp: [REDACTED] 00 cb / [REDACTED] 00
Boot0003  Debian    VenHw(9[REDACTED]cb)5c [REDACTED] 3000
      dp: [REDACTED] 00 cb / [REDACTED] 00
    data: 5c 00 [REDACTED]30 00
Boot0004  Debian    VenHw(9[REDACTED]cb)5c [REDACTED] 3000
      dp: [REDACTED] 00 cb / [REDACTED] 00
    data: 5c 00 [REDACTED]30 00
Boot0005* Linux Boot Manager    HD(1,GPT,02[REDACTED]d800)/File(\EFI\SYSTEMD\SYSTEMD-BOOTX64.EFI)
      dp: 04 01 [REDACTED] 00 / [REDACTED] 00
Boot0006  Linux Boot Manager    VenHw(9[REDACTED]cb)
      dp: [REDACTED] 00 cb / [REDACTED] 00
Boot0009* Debian    HD(1,GPT,02[REDACTED]d800)/File(EFI\DEBIAN\SHIMX64.EFI)5c [REDACTED] 3000
      dp: 04 01 [REDACTED]00 00 / [REDACTED] 00
    data: 5c 00 [REDACTED]30 00
Boot000A* debian    HD(1,GPT,02[REDACTED]d800)/File(\EFI\DEBIAN\SHIMX64.EFI)0000424f
      dp: 04 01 [REDACTED] 00 00 / [REDACTED] 00
    data: 00 00 42 4f
 
Last edited:
and if you now repeat "apt update; apt full-upgrade" does it work?
 
No. Here is the output:
Code:
root@proxmox:~# apt update; apt full-upgrade
Hit:1 http://ftp.u-picardie.fr/debian trixie InRelease
Get:2 http://ftp.u-picardie.fr/debian trixie-updates InRelease [47.3 kB]
Get:3 http://security.debian.org/debian-security trixie-security InRelease [43.4 kB]
Hit:4 http://download.proxmox.com/debian/pve trixie InRelease               
Fetched 90.7 kB in 0s (233 kB/s)
5 packages can be upgraded. Run 'apt list --upgradable' to see them.
Upgrading:                     
  libpve-common-perl  proxmox-kernel-6.14  proxmox-widget-toolkit  pve-firmware

Installing dependencies:
  proxmox-kernel-6.14.11-3-pve-signed

Recommended packages:
  grub-pc  | grub-efi-amd64  | grub-efi-ia32  | grub-efi-arm64

Not upgrading:
  shim-signed

Summary:
  Upgrading: 4, Installing: 1, Removing: 0, Not Upgrading: 1
  1 not fully installed or removed.
  Download size: 262 MB
  Space needed: 624 MB / 500 GB available

Continue? [Y/n] Y
Get:1 http://download.proxmox.com/debian/pve trixie/pve-no-subscription amd64 libpve-common-perl all 9.0.11 [121 kB]
Get:2 http://download.proxmox.com/debian/pve trixie/pve-no-subscription amd64 pve-firmware all 3.17-1 [152 MB]
Get:3 http://download.proxmox.com/debian/pve trixie/pve-no-subscription amd64 proxmox-kernel-6.14.11-3-pve-signed amd64 6.14.11-3 [110 MB]
Get:4 http://download.proxmox.com/debian/pve trixie/pve-no-subscription amd64 proxmox-kernel-6.14 all 6.14.11-3 [11.4 kB]                           
Get:5 http://download.proxmox.com/debian/pve trixie/pve-no-subscription amd64 proxmox-widget-toolkit all 5.0.6 [220 kB]                             
Fetched 262 MB in 7s (36.7 MB/s)                                                                                                                     
(Reading database ... 74542 files and directories currently installed.)
Preparing to unpack .../libpve-common-perl_9.0.11_all.deb ...
Unpacking libpve-common-perl (9.0.11) over (9.0.10) ...
Preparing to unpack .../pve-firmware_3.17-1_all.deb ...
Unpacking pve-firmware (3.17-1) over (3.16-4) ...
Selecting previously unselected package proxmox-kernel-6.14.11-3-pve-signed.
Preparing to unpack .../proxmox-kernel-6.14.11-3-pve-signed_6.14.11-3_amd64.deb ...
Unpacking proxmox-kernel-6.14.11-3-pve-signed (6.14.11-3) ...
Preparing to unpack .../proxmox-kernel-6.14_6.14.11-3_all.deb ...
Unpacking proxmox-kernel-6.14 (6.14.11-3) over (6.14.11-2) ...
Preparing to unpack .../proxmox-widget-toolkit_5.0.6_all.deb ...
Unpacking proxmox-widget-toolkit (5.0.6) over (5.0.5) ...
Setting up proxmox-widget-toolkit (5.0.6) ...
Setting up initramfs-tools (0.148.3) ...
update-initramfs: deferring update (trigger activated)
Setting up pve-firmware (3.17-1) ...
Setting up libpve-common-perl (9.0.11) ...
Setting up proxmox-kernel-6.14.11-3-pve-signed (6.14.11-3) ...
Examining /etc/kernel/postinst.d.
run-parts: executing /etc/kernel/postinst.d/initramfs-tools 6.14.11-3-pve /boot/vmlinuz-6.14.11-3-pve
update-initramfs: Generating /boot/initrd.img-6.14.11-3-pve
Running hook script 'zz-proxmox-boot'..
Re-executing '/etc/kernel/postinst.d/zz-proxmox-boot' in new private mount namespace..
Copying and configuring kernels on /dev/disk/by-uuid/B1C4-5826
    Copying kernel and creating boot-entry for 6.14.11-2-pve
    Copying kernel and creating boot-entry for 6.14.11-3-pve
run-parts: /etc/initramfs/post-update.d//proxmox-boot-sync exited with return code 1
run-parts: /etc/kernel/postinst.d/initramfs-tools exited with return code 1
Failed to process /etc/kernel/postinst.d at /var/lib/dpkg/info/proxmox-kernel-6.14.11-3-pve-signed.postinst line 20.
dpkg: error processing package proxmox-kernel-6.14.11-3-pve-signed (--configure):
 installed proxmox-kernel-6.14.11-3-pve-signed package post-installation script subprocess returned error exit status 2
dpkg: dependency problems prevent configuration of proxmox-kernel-6.14:
 proxmox-kernel-6.14 depends on proxmox-kernel-6.14.11-3-pve-signed | proxmox-kernel-6.14.11-3-pve; however:
  Package proxmox-kernel-6.14.11-3-pve-signed is not configured yet.
  Package proxmox-kernel-6.14.11-3-pve is not installed.
  Package proxmox-kernel-6.14.11-3-pve-signed which provides proxmox-kernel-6.14.11-3-pve is not configured yet.

dpkg: error processing package proxmox-kernel-6.14 (--configure):
 dependency problems - leaving unconfigured
Processing triggers for pve-manager (9.0.10) ...
Processing triggers for pve-ha-manager (5.0.4) ...
Processing triggers for initramfs-tools (0.148.3) ...
update-initramfs: Generating /boot/initrd.img-6.14.11-3-pve
Running hook script 'zz-proxmox-boot'..
Re-executing '/etc/kernel/postinst.d/zz-proxmox-boot' in new private mount namespace..
Copying and configuring kernels on /dev/disk/by-uuid/B1C4-5826
    Copying kernel and creating boot-entry for 6.14.11-2-pve
    Copying kernel and creating boot-entry for 6.14.11-3-pve
run-parts: /etc/initramfs/post-update.d//proxmox-boot-sync exited with return code 1
dpkg: error processing package initramfs-tools (--configure):
 installed initramfs-tools package post-installation script subprocess returned error exit status 1
Errors were encountered while processing:
 proxmox-kernel-6.14.11-3-pve-signed
 proxmox-kernel-6.14
 initramfs-tools
Error: Sub-process /usr/bin/dpkg returned an error code (1)
 
could you adapt the hook that is executed and add "set -x" at the top, and then retry?
 
I did it for two scripts:
/etc/kernel/postinst.d/zz-proxmox-boot
/etc/initramfs/post-update.d//proxmox-boot-sync (do not know where these two slashes come from!)

Output here: https://bin.infini.fr/?02a613b4b8ebf0f2#9DfCDhYz3CRLQobBzvQsv7WRZccFYmADPRPkRbBRJ6LB

Excerpt:
Bash:
Failed to process /etc/kernel/postinst.d at /var/lib/dpkg/info/proxmox-kernel-6.14.11-3-pve-signed.postinst line 20.
dpkg: error processing package proxmox-kernel-6.14.11-3-pve-signed (--configure):
 installed proxmox-kernel-6.14.11-3-pve-signed package post-installation script subprocess returned error exit status 2
dpkg: dependency problems prevent configuration of proxmox-kernel-6.14:
 proxmox-kernel-6.14 depends on proxmox-kernel-6.14.11-3-pve-signed | proxmox-kernel-6.14.11-3-pve; however:
  Package proxmox-kernel-6.14.11-3-pve-signed is not configured yet.
  Package proxmox-kernel-6.14.11-3-pve is not installed.
  Package proxmox-kernel-6.14.11-3-pve-signed which provides proxmox-kernel-6.14.11-3-pve is not configured yet.

dpkg: error processing package proxmox-kernel-6.14 (--configure):
 dependency problems - leaving unconfigured
Processing triggers for initramfs-tools (0.148.3) ...

Note: /dev/disk/by-uuid/A1B2-3434 is mounted on /boot/efi
 
Last edited:
Note: /dev/disk/by-uuid/A1B2-3434 is mounted on /boot/efi

if you are using proxmox-boot-tool, nothing should be mounted on /boot/efi.. please undo that and also post the output of "find /var/tmp/espmounts", thanks!
 
I have unmounted /boot/efi and did the upgrade. I have no error message again. And no output for "find /var/tmp/espmounts".

Here is the full output:
https://bin.infini.fr/?ddfb9667262cd060#8aHbvJZBDHma97fcRSCAAmb7uC6uUaY6GBfaZE3wMNBH

Woud you please explain why does proxmox-boot-tool need me to unmount /boot/efi? Do you mean I should remove it from my /etc/fstab? Or should I change from /boot/efi to /boot parent directory?
Thank you very much!

PS: My Debian installed was mostly based on: https://gist.github.com/meeas/b574e4bede396783b1898c90afa20a30
 
proxmox-boot-tool expects to fully manage the ESPs - it mounts them on-demand and unmounts them again afterwards. so yes, please remove the /etc/fstab entry!
 
  • Like
Reactions: Stoiko Ivanov
Thanks a lot @fabian for this help and explanations!

I've just re-read https://pve.proxmox.com/wiki/Host_Bootloader where I found the explanation for this: "The ESPs are not kept mounted during regular operation. This helps to preventfilesystem corruption to the vfat formatted ESPs in case of a system crash,and removes the need to manually adapt /etc/fstab in case the primary bootdevice fails." This is definitely a good idea!