From 5cd80bfde1b5192a0b9eace4a1e1a45d19b78e0c Mon Sep 17 00:00:00 2001 From: Robin Sonnabend <robin@fsmpi.rwth-aachen.de> Date: Sat, 9 Jul 2022 13:06:10 +0200 Subject: [PATCH] Update ganeti to 3.0.1 (for bullseye) --- .gitlab-ci.yml | 8 ++--- patches/ganeti/add_rbd_cache_support.patch | 20 ----------- patches/ganeti/fix_rbd_showmapped_mimic.patch | 33 ------------------- patches/ganeti/increase_max_disk_count.patch | 11 ------- scripts/ganeti.sh | 5 +-- 5 files changed, 5 insertions(+), 72 deletions(-) delete mode 100644 patches/ganeti/add_rbd_cache_support.patch delete mode 100644 patches/ganeti/fix_rbd_showmapped_mimic.patch delete mode 100644 patches/ganeti/increase_max_disk_count.patch diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml index 9c7de21..d24b1bb 100644 --- a/.gitlab-ci.yml +++ b/.gitlab-ci.yml @@ -1,7 +1,7 @@ --- # yamllint disable-line rule:line-length -image: registry.git.fsmpi.rwth-aachen.de/infra/ci-containers/fsmpi-packages:buster +image: registry.git.fsmpi.rwth-aachen.de/infra/ci-containers/fsmpi-packages:bullseye stages: - build @@ -16,9 +16,9 @@ variables: before_script: # yamllint disable rule:line-length - - echo "deb-src http://ftp.halifax.rwth-aachen.de/debian/ buster main" > /etc/apt/sources.list.d/buster_src.list - - echo "deb-src http://ftp.halifax.rwth-aachen.de/debian/ buster-updates main" >> /etc/apt/sources.list.d/buster_src.list - - echo "deb-src http://security.debian.org/ buster/updates main" >> /etc/apt/sources.list.d/buster_src.list + - echo "deb-src http://ftp.halifax.rwth-aachen.de/debian/ bullseye main" > /etc/apt/sources.list.d/bullseye_src.list + - echo "deb-src http://ftp.halifax.rwth-aachen.de/debian/ bullseye-updates main" >> /etc/apt/sources.list.d/bullseye_src.list + - echo "deb-src http://security.debian.org/ bullseye/updates main" >> /etc/apt/sources.list.d/bullseye_src.list # yamllint enable rule:line-length - apt-get update - apt-get install -y apt-utils diff --git a/patches/ganeti/add_rbd_cache_support.patch b/patches/ganeti/add_rbd_cache_support.patch deleted file mode 100644 index 71593be..0000000 --- a/patches/ganeti/add_rbd_cache_support.patch +++ /dev/null @@ -1,20 +0,0 @@ -Index: ganeti-2.15.2/lib/hypervisor/hv_kvm/__init__.py -=================================================================== ---- ganeti-2.15.2.orig/lib/hypervisor/hv_kvm/__init__.py -+++ ganeti-2.15.2/lib/hypervisor/hv_kvm/__init__.py -@@ -921,12 +921,13 @@ class KVMHypervisor(hv_base.BaseHypervis - disk_cache = up_hvp[constants.HV_DISK_CACHE] - for cfdev, link_name, uri in kvm_disks: - if cfdev.dev_type in constants.DTS_EXT_MIRROR: -- if disk_cache != "none": -+ if disk_cache != "none" and cfdev.dev_type != "rbd": - # TODO: make this a hard error, instead of a silent overwrite - logging.warning("KVM: overriding disk_cache setting '%s' with 'none'" - " to prevent shared storage corruption on migration", - disk_cache) -- cache_val = ",cache=none" -+ disk_cache = "none" -+ cache_val = ",cache=%s" % disk_cache - elif disk_cache != constants.HT_CACHE_DEFAULT: - cache_val = ",cache=%s" % disk_cache - else: diff --git a/patches/ganeti/fix_rbd_showmapped_mimic.patch b/patches/ganeti/fix_rbd_showmapped_mimic.patch deleted file mode 100644 index c57b46b..0000000 --- a/patches/ganeti/fix_rbd_showmapped_mimic.patch +++ /dev/null @@ -1,33 +0,0 @@ -From fa9a8fc141334b176380370b9622a28ad4a066fb Mon Sep 17 00:00:00 2001 -From: Ansgar Jazdzewski <ajaz@spreadshirt.net> -Date: Tue, 19 Feb 2019 10:31:07 +0100 -Subject: [PATCH] fix 'rbd showmapped' for ceph mimic -MIME-Version: 1.0 -Content-Type: text/plain; charset=UTF-8 -Content-Transfer-Encoding: 8bit - -The json ouput changed from list to dict -* http://docs.ceph.com/docs/master/releases/mimic/ - The rbd CLI’s -showmapped JSON and XML output has changed.) ---- - lib/storage/bdev.py | 6 +++++- - 1 file changed, 5 insertions(+), 1 deletion(-) - -diff --git a/lib/storage/bdev.py b/lib/storage/bdev.py -index c7d5f3b6d..7aa09cee6 100644 ---- a/lib/storage/bdev.py -+++ b/lib/storage/bdev.py -@@ -1064,8 +1064,12 @@ def _ParseRbdShowmappedJson(output, volume_pool, volume_name): - except ValueError, err: - base.ThrowError("Unable to parse JSON data: %s" % err) - -+ # since ceph mimic the json output changed from dict to list -+ if isinstance(devices, dict): -+ devices = devices.values() -+ - rbd_dev = None -- for d in devices.values(): # pylint: disable=E1103 -+ for d in devices: - try: - name = d["name"] - except KeyError: diff --git a/patches/ganeti/increase_max_disk_count.patch b/patches/ganeti/increase_max_disk_count.patch deleted file mode 100644 index effedba..0000000 --- a/patches/ganeti/increase_max_disk_count.patch +++ /dev/null @@ -1,11 +0,0 @@ ---- a/src/Ganeti/HTools/Types.hs 2015-12-16 14:34:43.000000000 +0100 -+++ b/src/Ganeti/HTools/Types.hs 2017-11-03 21:42:53.486742240 +0100 -@@ -215,7 +215,7 @@ - } - - maxDisks :: Int --maxDisks = 16 -+maxDisks = 64 - - maxNics :: Int - maxNics = 8 diff --git a/scripts/ganeti.sh b/scripts/ganeti.sh index acc14be..1dedb5a 100755 --- a/scripts/ganeti.sh +++ b/scripts/ganeti.sh @@ -2,13 +2,10 @@ source "${BASH_SOURCE%/*}/common.sh" -get_sources ganeti buster +get_sources ganeti bullseye import_patches ganeti dch_custom "Remove blockdev storage from the movable and mirrored devices lists." -dch_custom "Increase maximum disk count per instance." -dch_custom "Add support for disk cache usage with rbd devices." -dch_custom "Add upstream patch for Ceph mimic compatibility." install_build_deps build -- GitLab