-
Notifications
You must be signed in to change notification settings - Fork 306
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Cannot support existingClaim and different pvc for different vmstorage pods at the same time #938
Comments
Hello,
You want the secondary cluster to use the PVC and PV of the primary cluster, then you don't want them to use the same PVC. Got me confused, could you elaborate? |
Sorry for the confusion. |
I got a workaround for this issue, though a bit ugly.
so that I can customize the PVC name in the values.yaml.
|
The reason I try to reuse the PVCs is that I want to use GCP regional persistent disk to improve availability |
Oh, okay, I'm afraid you can't do that, two vmstorage process can't use the same volume as their storage. |
@Haleygo Thanks for your reply. I understand your concern. I should have pointed out that the secondary cluster will not write&read to the same volume with the primary cluster at the same time, it is only for disaster recovery. In other words, the secondary cluster will be started when we find the primary cluster is unavailable and not working anymore. |
So you have two different available zone or region, the first vmcluster deployed on zoneA, second one on zoneB and components on zoneB are all stopped(replicas=0) at first. If zoneA is completely down, you can increase zoneB vmcluster's replicas(it's the same as creating a new vmcluster) and use zoneB. If so, then every method that generates same persistentVolume name for different vmcluster will work, like yours here. |
Correct, that's what I mean. |
Maybe I can raise a PR to make the |
yeah, feel free) You can also try using the k8s stack chart, VMClusterSpec.VMStorage.storage supports customized VolumeClaimTemplate name as well. |
I created a PR #939 |
The request has been released in victoria-metrics-cluster-0.11.14, close as completed. |
Hi Team, I'm trying to setup two VictoriaMetrics clusters in two GCP zones separately.
For the primary cluster, I set
existingClaim
to empty string to let the statefulset usevolumeClaimTemplates
.For the secondary cluster which is used in case of the primary zone is down, I try to make it use the PVC and PV of the primary cluster, but it seems impossible now. If I set
existingClaim
, all vmstorage pods will use the same PVC, that is not what I want.The text was updated successfully, but these errors were encountered: