[pve-devel] [PATCH storage 0/3] disks: add checks, allow add_storage on other nodes

Aaron Lauterer a.lauterer at proxmox.com
Wed Jul 13 12:47:55 CEST 2022


This series deals mainly with 2 things, adding more checks prior to
actually setting up a new local storage to avoid leaving behind half
provisioned disks in case a storage (lvm, zfs, ...) of the same name
already exists.
Secondly, to change the behavior regarding the "Add Storage" flag. It
allows to keep in enabled and will create the local storage and add the
node to the nodes list of the PVE storage config if there already exists
one in the cluster.

The first patch is a prerequisite to be able to check if a mount path
for the Directory storage type is already mounted.
The second patch implements the actual checks.
The third patch adds the changed behavior for the "Add Storage" part.

More in the actual patches.

Aaron Lauterer (3):
  diskmanage: add mounted_paths
  disks: die if storage name is already in use
  disks: allow add_storage for already configured local storage

 PVE/API2/Disks/Directory.pm | 37 ++++++++++++++++++++++-----------
 PVE/API2/Disks/LVM.pm       | 33 +++++++++++++++++++----------
 PVE/API2/Disks/LVMThin.pm   | 33 +++++++++++++++++++----------
 PVE/API2/Disks/ZFS.pm       | 33 ++++++++++++++++++++---------
 PVE/Diskmanage.pm           | 13 ++++++++++++
 PVE/Storage.pm              | 41 +++++++++++++++++++++++++++++++++++++
 6 files changed, 146 insertions(+), 44 deletions(-)

-- 
2.30.2






More information about the pve-devel mailing list