Skip to content

Instantly share code, notes, and snippets.

@futuretea
Last active June 14, 2023 04:09
Show Gist options
  • Save futuretea/5dc96493c9f61dca8df82c46ba07ea6f to your computer and use it in GitHub Desktop.
Save futuretea/5dc96493c9f61dca8df82c46ba07ea6f to your computer and use it in GitHub Desktop.
Patch Harvester For Multi-CSI

Patch Harvester For Multi-CSI

Enable the read-write mode (Both v1.1 and v1.2 are required)

The OS file system, like a container image, is image-based and immutable except in some directories. To temporarily enable the read-write mode, please use the following steps:

  • Boot/Reboot the system to GRUB menu. Press ESC to stay on the menu. image

  • Press e on first menuentry. Append rd.cos.debugrw to the linux (loop0)$kernel $kernelcmd line.

image

  • Press Ctrl + x to boot the system.

Patch Harvester images (Only for v1.1)

Download Harvester cluster kubeconfig from Harvester UI, Then execute the following commands:

wget https://raw.githubusercontent.com/futuretea/harvester/multi-csi-1.1/patch-harvester-1.1-multi-csi.sh
chmod +x patch-harvester-1.1-multi-csi.sh
# the first arg is the kubeconfig file path of Harvester cluster
# the second arg is docker image repo
# the third arg is docker image tag
# these images are built from https://github.com/futuretea/harvester/tree/multi-csi-1.1
# include backend and ui support for multi csi
# docker.io/futuretea/harvester:adfc2c7b-amd64
# docker.io/futuretea/harvester-webhook:adfc2c7b-amd64
./patch-harvester-1.1-multi-csi.sh local.yaml futuretea adfc2c7b-amd64

Patch Selinux (Both v1.1 and v1.2 are required)

SSH into each Harvester node, Then execute the following commands:

sudo su	
# selinux workaround	
mv /var/lib/selinux/targeted/active /var/lib/selinux/targeted/previous	
cp --link --recursive /var/lib/selinux/targeted/previous /var/lib/selinux/targeted/active	
semodule -d k3s -d rancher
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment