Hey,

I would like to propose a feature request:
Add support for Boot Environments and create a tool to manage them.

If you don't know what boot environments are: basically they are 
filesystem-based snapshots of a system, which you can boot into. Among other 
things this enables rollbacks of a system by simply rebooting (such rollbacks 
include version upgrades).

There are quite a few benefits of supporting Boot Environments, for example 
they enable you to basically version control your Proxmox Installation and 
allow the migration of Proxmox Host Systems.


I have documented a Proof of Concept [0] which explains in depth how to enable 
Boot Environments in Proxmox. I have also created a fork [1] of the FreeBSD 
beadm Boot Environment Manager that works with Proxmox and documented how it 
works and how to use it [2].

Both the initial Proof of Concept as well as the Boot Environment Manager are 
written in a way that does not interfere with Proxmox core functionality. This 
means that on one hand I haven't changed any of the Proxmox scripts, but on the 
other hand I've done some things in a more complicated way than would have been 
necessary.

I think, native support for Boot Environments could be achieved by 
changing/adding the following things:

- creating a boot environment manager (e.g. refactoring the beadm fork)

- changing the way files are stored on the EFI Systems Partitions (similiar to 
what is done by the beadm fork, but with deduplication)

- (optionally) increase the EFI Systems Partition in size since with boot 
environments it makes perfect sense to store more kernels than before

- move images, templates and backups from rpool/ROOT/pve-1 into another 
dataset, so the state of those doesn't depend on the active Boot Environment

- (optionally) move other directories off rpool/ROOT/pve-1 as well (e.g. 
/root/, /tmp, /var/log)

- change the /etc/kernel/cmdline file such that the root kernel option always 
points to the boot environment that is active after the next boot (e.g. by 
creating a template file from which this file is generated by the boot 
environment manager)

- change the boot preparation process so it uses the Boot Environment Manager 
(/etc/kernel/postinst.d/zz-pve-efiboot would have to be modified)

What do you think?

Kind Regards!
--
[0] : 
https://tactical-documentation.github.io/post/poc-proxmox-and-boot-environments 
<https://tactical-documentation.github.io/post/poc-proxmox-and-boot-environments[1>
[1 
<https://tactical-documentation.github.io/post/poc-proxmox-and-boot-environments[1>]
 : https://github.com/tactical-documentation/beadm 
<https://github.com/tactical-documentation/beadm>
[2] : 
https://tactical-documentation.github.io/post/a-boot-environment-manager-for-proxmox
 
<https://tactical-documentation.github.io/post/a-boot-environment-manager-for-proxmox>
_______________________________________________
pve-devel mailing list
pve-devel@pve.proxmox.com
https://pve.proxmox.com/cgi-bin/mailman/listinfo/pve-devel

Reply via email to