Compare commits
10 Commits
Author | SHA1 | Date | |
---|---|---|---|
387fcfdf6b | |||
d695e855f9 | |||
309b203f5d | |||
de4241161e | |||
1950d22876 | |||
7a32d8da9d | |||
e3b8673789 | |||
9db46d48e4 | |||
d74c3a2d45 | |||
f4e946c262 |
12
CHANGELOG.md
12
CHANGELOG.md
@ -1,5 +1,17 @@
|
||||
## PVC Changelog
|
||||
|
||||
###### [v0.9.107](https://github.com/parallelvirtualcluster/pvc/releases/tag/v0.9.107)
|
||||
|
||||
* [Worker Daemon] Fixes a bug where snapshot removal fails during autobackups
|
||||
|
||||
###### [v0.9.106](https://github.com/parallelvirtualcluster/pvc/releases/tag/v0.9.106)
|
||||
|
||||
* [API Daemon] Fixes a calculation bug when checking storage free space
|
||||
|
||||
###### [v0.9.105](https://github.com/parallelvirtualcluster/pvc/releases/tag/v0.9.105)
|
||||
|
||||
* [API Daemon/Provisioner] Corrects some small bugs with OVA handling
|
||||
|
||||
###### [v0.9.104](https://github.com/parallelvirtualcluster/pvc/releases/tag/v0.9.104)
|
||||
|
||||
* [API Daemon] Fixes a bug that failed uploading of RAW block devices in "storage volume upload"
|
||||
|
@ -179,6 +179,10 @@ def upload_ova(zkhandler, pool, name, ova_size):
|
||||
}
|
||||
retcode = 400
|
||||
return output, retcode
|
||||
else:
|
||||
ova_script = "default_ova"
|
||||
else:
|
||||
ova_script = "ova"
|
||||
|
||||
ova_archive = None
|
||||
|
||||
@ -397,7 +401,14 @@ def upload_ova(zkhandler, pool, name, ova_size):
|
||||
vnc = False
|
||||
serial = True
|
||||
retdata, retcode = provisioner.create_template_system(
|
||||
name, vcpu_count, vram_mb, serial, vnc, vnc_bind=None, ova=ova_id
|
||||
name,
|
||||
vcpu_count,
|
||||
vram_mb,
|
||||
serial,
|
||||
vnc,
|
||||
vnc_bind=None,
|
||||
ova=ova_id,
|
||||
migration_max_downtime=300,
|
||||
)
|
||||
if retcode != 200:
|
||||
return retdata, retcode
|
||||
@ -414,7 +425,7 @@ def upload_ova(zkhandler, pool, name, ova_size):
|
||||
None,
|
||||
None,
|
||||
userdata=None,
|
||||
script="default_ova",
|
||||
script=ova_script,
|
||||
ova=name,
|
||||
arguments=None,
|
||||
)
|
||||
|
@ -221,7 +221,7 @@ def create_template_system(
|
||||
node_selector=None,
|
||||
node_autostart=False,
|
||||
migration_method=None,
|
||||
migration_max_downtime=None,
|
||||
migration_max_downtime=300,
|
||||
ova=None,
|
||||
):
|
||||
if list_template_system(name, is_fuzzy=False)[-1] != 404:
|
||||
|
@ -2,7 +2,7 @@ from setuptools import setup
|
||||
|
||||
setup(
|
||||
name="pvc",
|
||||
version="0.9.104",
|
||||
version="0.9.107",
|
||||
packages=["pvc.cli", "pvc.lib"],
|
||||
install_requires=[
|
||||
"Click",
|
||||
|
@ -469,13 +469,14 @@ def run_vm_backup(zkhandler, celery, config, vm_detail, force_full=False):
|
||||
|
||||
if len(marked_for_deletion) > 0:
|
||||
for backup_to_delete in marked_for_deletion:
|
||||
try:
|
||||
ret = vm.vm_worker_remove_snapshot(
|
||||
zkhandler, None, vm_name, backup_to_delete["snapshot_name"]
|
||||
)
|
||||
if ret is False:
|
||||
error_message = f"Failed to remove obsolete backup snapshot '{backup_to_delete['snapshot_name']}', leaving in tracked backups"
|
||||
except Exception:
|
||||
error_message = f"Failed to remove obsolete backup snapshot '{backup_to_delete['snapshot_name']}', removing from tracked backups anyways"
|
||||
log_err(celery, error_message)
|
||||
else:
|
||||
|
||||
rmtree(f"{vm_backup_path}/{backup_to_delete['snapshot_name']}")
|
||||
tracked_backups.remove(backup_to_delete)
|
||||
|
||||
|
@ -121,6 +121,9 @@ def format_bytes_tohuman(databytes):
|
||||
|
||||
|
||||
def format_bytes_fromhuman(datahuman):
|
||||
if not isinstance(datahuman, str):
|
||||
datahuman = str(datahuman)
|
||||
|
||||
if not re.search(r"[A-Za-z]+", datahuman):
|
||||
dataunit = "B"
|
||||
datasize = float(datahuman)
|
||||
@ -593,11 +596,11 @@ def add_volume(zkhandler, pool, name, size, force_flag=False, zk_only=False):
|
||||
|
||||
# Check if we're greater than 80% utilization after the create; error if so unless we have the force flag
|
||||
pool_total_bytes = (
|
||||
int(pool_information["stats"]["used_bytes"]) + pool_total_free_bytes
|
||||
int(pool_information["stats"]["stored_bytes"]) + pool_total_free_bytes
|
||||
)
|
||||
pool_safe_total_bytes = int(pool_total_bytes * 0.80)
|
||||
pool_safe_free_bytes = pool_safe_total_bytes - int(
|
||||
pool_information["stats"]["used_bytes"]
|
||||
pool_information["stats"]["stored_bytes"]
|
||||
)
|
||||
if size_bytes >= pool_safe_free_bytes and not force_flag:
|
||||
return (
|
||||
@ -653,11 +656,11 @@ def clone_volume(zkhandler, pool, name_src, name_new, force_flag=False):
|
||||
|
||||
# Check if we're greater than 80% utilization after the create; error if so unless we have the force flag
|
||||
pool_total_bytes = (
|
||||
int(pool_information["stats"]["used_bytes"]) + pool_total_free_bytes
|
||||
int(pool_information["stats"]["stored_bytes"]) + pool_total_free_bytes
|
||||
)
|
||||
pool_safe_total_bytes = int(pool_total_bytes * 0.80)
|
||||
pool_safe_free_bytes = pool_safe_total_bytes - int(
|
||||
pool_information["stats"]["used_bytes"]
|
||||
pool_information["stats"]["stored_bytes"]
|
||||
)
|
||||
if size_bytes >= pool_safe_free_bytes and not force_flag:
|
||||
return (
|
||||
@ -718,11 +721,11 @@ def resize_volume(zkhandler, pool, name, size, force_flag=False):
|
||||
|
||||
# Check if we're greater than 80% utilization after the create; error if so unless we have the force flag
|
||||
pool_total_bytes = (
|
||||
int(pool_information["stats"]["used_bytes"]) + pool_total_free_bytes
|
||||
int(pool_information["stats"]["stored_bytes"]) + pool_total_free_bytes
|
||||
)
|
||||
pool_safe_total_bytes = int(pool_total_bytes * 0.80)
|
||||
pool_safe_free_bytes = pool_safe_total_bytes - int(
|
||||
pool_information["stats"]["used_bytes"]
|
||||
pool_information["stats"]["stored_bytes"]
|
||||
)
|
||||
if size_bytes >= pool_safe_free_bytes and not force_flag:
|
||||
return (
|
||||
|
18
debian/changelog
vendored
18
debian/changelog
vendored
@ -1,3 +1,21 @@
|
||||
pvc (0.9.107-0) unstable; urgency=high
|
||||
|
||||
* [Worker Daemon] Fixes a bug where snapshot removal fails during autobackups
|
||||
|
||||
-- Joshua M. Boniface <joshua@boniface.me> Mon, 10 Feb 2025 23:15:21 -0500
|
||||
|
||||
pvc (0.9.106-0) unstable; urgency=high
|
||||
|
||||
* [API Daemon] Fixes a calculation bug when checking storage free space
|
||||
|
||||
-- Joshua M. Boniface <joshua@boniface.me> Mon, 09 Dec 2024 16:45:10 -0500
|
||||
|
||||
pvc (0.9.105-0) unstable; urgency=high
|
||||
|
||||
* [API Daemon/Provisioner] Corrects some small bugs with OVA handling
|
||||
|
||||
-- Joshua M. Boniface <joshua@boniface.me> Tue, 19 Nov 2024 14:43:43 -0500
|
||||
|
||||
pvc (0.9.104-0) unstable; urgency=high
|
||||
|
||||
* [API Daemon] Fixes a bug that failed uploading of RAW block devices in "storage volume upload"
|
||||
|
@ -33,7 +33,7 @@ import os
|
||||
import signal
|
||||
|
||||
# Daemon version
|
||||
version = "0.9.104"
|
||||
version = "0.9.107"
|
||||
|
||||
|
||||
##########################################################
|
||||
|
@ -49,7 +49,7 @@ import re
|
||||
import json
|
||||
|
||||
# Daemon version
|
||||
version = "0.9.104"
|
||||
version = "0.9.107"
|
||||
|
||||
|
||||
##########################################################
|
||||
|
@ -58,7 +58,7 @@ from daemon_lib.automirror import (
|
||||
)
|
||||
|
||||
# Daemon version
|
||||
version = "0.9.104"
|
||||
version = "0.9.107"
|
||||
|
||||
|
||||
config = cfg.get_configuration()
|
||||
|
Reference in New Issue
Block a user