Hey everyone. I made a script that makes it easy to do native ZFS root encryption for Proxmox. It optionally uses tailscale (or sshd) to allow remove unlocks. Check it out, let me know what you think: https://github.com/midzelis/zquickinit
Thanks for your feedback! I'll definately make a remark in the doc. If you happen to be booting the system from a USB drive/PXE - you could theoretically do the SSD secure wipe command. In research, it seems that this is relatively complex to pull off, and varies based on SATA vs SAS vs NVME - so many best to just leave it in the notes, and maybe in the prompts. I could at least include the hdparm/nveme-format/blkdiscard binaries which could help.Looks very interesting. For your "Security Considerations" you could maybe mention that when encrypting an unencrypted rpool the unencrypted data might still be recoverable. Especially when using SSDs there is no way to actually destroy the unencrypted data in the spare area without initializing a "secure erase" command which then would factory reset the whole SSD including the encrypted rpool. So not that useful unless you got a fresh unencrypted rpool that never got any sensitive data on it.
I would always propery wipe the disks and then install an encrypted PVE from scratch.
Features I would really like to see are:
a.) snapshot and rollback of the rpool
b.) host backups and restores to/from PBS
Yes but being able to boot into that ZFSBootmenu to do a manual snapshot or do a rollback would be a very useful recovery feature. Right know there is no official way to backup the PVE host before doing a upgrade nor is it possible to downgrade a PVE. So being able to create a snapshot before doing a major upgrade and a boot menu to easily rollback the rpool/ROOT/pve-1 to a state before that upgrade would be a really nice feature.During the install process, zfs snaphots are used before the process starts, after stage1 (debootstrap), and after stage2 (chroot package install).
You should try it. So much better than VZDump. Faster because of incremental backups and dirty-bitmapping and sooo much more space efficient because of the deduplication. And the ransomware protection, integrity checks, encryption and option to sync multiple PBS are great too.I don't use PBS, but I'd be happy to accept PRs! ;-)
i'm sad that full system encryption is being discussed / asked for again and again when we don't even have complete backup encryption. which is low hanging fruit and should not be hard to implement.
why does nobody ask for that ?
https://bugzilla.proxmox.com/show_bug.cgi?id=4602
https://bugzilla.proxmox.com/show_bug.cgi?id=1560
there is a missing features with ZFS native encryption that won't allow migrations in PVE when an encrypted ZFS pool is involved
See the bug ticket "FS->ZFS storage_migrate does not work if zfs feature@encryption=enabled" from 2019 : https://bugzilla.proxmox.com/show_bug.cgi?id=2350Can you post more specific link? I can't find anything with a quick search and it does not sound related.
Having to RMA a failed system drive?Whats the benefit of encrypting a probably 24/7 running system? I did it as well until somebody explained me how useless it is with something running 24/7 because everything is in memory anyway...
Three situations where it helps:Whats the benefit of encrypting a probably 24/7 running system? I did it as well until somebody explained me how useless it is with something running 24/7 because everything is in memory anyway...
This make's literally no sense. You are afraid that somebody is breaking into your home and steal specifically your nuc because it is looking expensive? In the next sentence you have no problem when your server is running in a datacenter with hardware you probably don't even own and got your hosting provider which can access your system any moment without your knowledge and copying your memory and temper around?Three situations where it helps:
1.) in case someone gets physical access to your server. Not a problem in the datacenter but for a homeserver it isn't that unreasonable that some crackhead breaks into your home and steals something that looks expensive. Something like a tiny NUC running PVE would be such a thing. As soon as he steals it he has to unplug it from power and then all keys in RAM will be lost and all disks encrypted again once its sold and someone tries to power it on
The RMA thing is the only part I am with you but if you want to live up your privacy you have to give up this RMA stuff and descruct it. Then we talk about serious privacy.2.) you got a disk that starts failing. You can't wipe that disk anymore because of the write errors but it is still readable. With an unencrypted disk you can RMA it but then people can access your data. If you need to care about data protection you would need to destroy that disk instead of sending it in for a free repair/replace. With an encrypted disk an RMA wouldn't be an problem as all the data is unusable once the disk is remove from the server.
This is a good example of how to do it. Separate and classify your data and utilize specific technology to cope with it.3.) you don't have to unlock the disks 24/7. You can encrypt single datasets/zvols and only unlock them when needed. This at least helps a bit in case your server gets compromised while some of the data is still locked.
See the bug ticket "FS->ZFS storage_migrate does not work if zfs feature@encryption=enabled" from 2019 : https://bugzilla.proxmox.com/show_bug.cgi?id=2350
I think the point is you get hardware stolen at times, when stolen for the value of the hardware, it's stolen in offline state. It's a legit reason.This make's literally no sense. You are afraid that somebody is breaking into your home and steal specifically your nuc because it is looking expensive? In the next sentence you have no problem when your server is running in a datacenter with hardware you probably don't even own and got your hosting provider which can access your system any moment without your knowledge and copying your memory and temper around?
If you do think encryption does not work, then of course you would never RMA anything and will not use encryption. Maybe it's NSA after you, who knows. NB Destructing something is not so trivial either.The RMA thing is the only part I am with you but if you want to live up your privacy you have to give up this RMA stuff and descruct it. Then we talk about serious privacy.
This!you got a disk that starts failing. You can't wipe that disk anymore because of the write errors but it is still readable.
Currently I do not encrypt my PVE setups but I also make sure the boot disks support Secure Erase, when the disk cannot successfully secure erase, I just keep it for good.
I am not afraid of anyone breaking into my home, but I really fear selling disks to whoever, thats why I hoard them.
It's about who got physical access. A trusted admin of a big hosting company that needs to pass a dozen of checkpoints to get to the server that is protected like a vault or some random hostile dude that simply breaks my window to get access while nobody is at home.This make's literally no sense. You are afraid that somebody is breaking into your home and steal specifically your nuc because it is looking expensive? In the next sentence you have no problem when your server is running in a datacenter with hardware you probably don't even own and got your hosting provider which can access your system any moment without your knowledge and copying your memory and temper around?