Migration from Longhorn installed by Rancher to Longhorn official Chart #12255
Unanswered
simonepittis
asked this question in
Q&A
Replies: 2 comments 4 replies
-
Longhorn v1.8, v1.9 and v1.10 will be added to Rancher v2.13 soon. |
Beta Was this translation helpful? Give feedback.
0 replies
-
|
ok Good... but If someone want to migrate it??? |
Beta Was this translation helpful? Give feedback.
4 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
-
Form Rancher version 2.13.0 the Longhorn App it's removed from "Tools", and probably won't be maintained.
my idea it's move all to Longhorn official chart... but exist a problem.
Rancher made two different apps: longhorn and longhorn-crd
an like normal you you to install/upgrade longhorn you see this error:
helm install longhorn longhorn/longhorn --namespace longhorn-system --version 1.9.2 --create-namespace --dry-run
Error: INSTALLATION FAILED: Unable to continue with install: CustomResourceDefinition "backingimagedatasources.longhorn.io" in namespace "" exists and cannot be imported into the current release: invalid ownership metadata; annotation validation error: key "meta.helm.sh/release-name" must equal "longhorn": current value is "longhorn-crd"
the idea it's make a backup and clean the annotations:
kubectl get crd -l "app.kubernetes.io/instance=longhorn-crd" -o yaml > longhorn-crd-backup.yaml
kubectl get crd | grep longhorn.io | awk '{print $1}' | while read crd; do
kubectl patch crd $crd --type=merge -p '{
"metadata": {
"annotations": {
"meta.helm.sh/release-name": "longhorn",
"meta.helm.sh/release-namespace": "longhorn-system"
},
"labels": {
"app.kubernetes.io/name": "longhorn",
"app.kubernetes.io/instance": "longhorn",
"app.kubernetes.io/managed-by": "helm"
}
}
}'
done
and after make the install/upgarde. But I not sure if this approach can work.
Someone made this migration? I think it's not only me in this situation :-)
Note: I made a backup of all, but I don't want to re install all PVC in the cluster
Beta Was this translation helpful? Give feedback.
All reactions