Comments (12)
The request has been released in victoria-metrics-cluster-0.11.14, close as completed.
from helm-charts.
Hello,
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.
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?
from helm-charts.
Sorry for the confusion.
Say the primary cluster has 4 vmstorage pods, and their PVC are vmstorage-0, vmstorage-1, vmstorage-2, vmstorage-3.
Then I want the secondary cluster's vmstorage pods use these PVC respectively. If I set existingClaim to vmstorage-0, all four pods are using the same PVC which is not I want.
from helm-charts.
I got a workaround for this issue, though a bit ugly.
- I updated this line to:
name: {{ .Values.vmstorage.persistentVolume.name | default "vmstorage-volume" }}
so that I can customize the PVC name in the values.yaml.
-
For the primary cluster, I set the
vmstorage.persistentVolume.name
tovmstorage-volume-standby
, so the actual PVC name isvmstorage-volume-standby-victoria-metrics-cluster-vmstorage-{0/1/2/3}
-
For the secondary cluster names as
standby-victoria-metrics-cluster
, I set thevmstorage.persistentVolume.name
tovmstorage-volume
, so the PVC name will be the same as the primary cluster's respectively
from helm-charts.
The reason I try to reuse the PVCs is that I want to use GCP regional persistent disk to improve availability
from helm-charts.
Oh, okay, I'm afraid you can't do that, two vmstorage process can't use the same volume as their storage.
First of all, vmstorage will try to create a flock.lock file under "/vm-data" to make sure it's the only process has exclusive access to "/vm-data", and will panic if it can't acquire the lock.
Even if we remove this check, normally you shouldn't have two different processes to write&read the same volume, it causes data duplicated and conflicted. And if one process causes data corruption, you lose two of them, then there is no sense to call it HA.
from helm-charts.
@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.
from helm-charts.
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.
But if zoneA is not completely down, just several vmstorage nodes are down, e.g storage0 and storage2, in this case, you can't use zoneB to help recovering, since you will get double storage1 and storage3.
Am I understand correctly?
If so, then every method that generates same persistentVolume name for different vmcluster will work, like yours here.
And I don't see how we can improve chart for this particular case.
from helm-charts.
Correct, that's what I mean.
from helm-charts.
Maybe I can raise a PR to make the vmstorage.persistentVolume.name
customizable so that I don't need to host the chart separately? Thanks
from helm-charts.
Maybe I can raise a PR to make the
vmstorage.persistentVolume.name
customizable so that I don't need to host the chart separately? Thanks
yeah, feel free)
You can also try using the k8s stack chart, VMClusterSpec.VMStorage.storage supports customized VolumeClaimTemplate name as well.
from helm-charts.
I created a PR #939
from helm-charts.
Related Issues (20)
- chart "vmagent" version "v0.10.4" not found in https://victoriametrics.github.io/helm-charts/ repository HOT 1
- helm install failed when serviceMonitor is enabled HOT 1
- Allow adding additional labels to alert rules in victoria-metrics-k8s-stack helm chart
- Latest v0.22 victoria-metrics-k8s-stack is unable to uninstall HOT 4
- How to properly setup remoteWrite credentials in vmagent HOT 1
- Deprecated etcd alert "etcdHighNumberOfFailedGRPCRequests" HOT 1
- Errors after upgrading: no matches for kind "VMScrapeConfig" HOT 1
- Helm Charts: missing Ingress Definition for TLS
- Add a `vmstorage.vmbackup.enabled` value to the `victoria-metrics-cluster` chart HOT 1
- Added values file option for -remoteWrite.relabelConfig & -remoteWrite.urlRelabelConfig HOT 3
- Allow setting `metricRelabelings` on ServiceMonitors
- Support options for vmagent to scrape targets via a proxy HOT 2
- Duplicated VictoriaMetrics datasource HOT 1
- [k8s-stack/kube-etcd] Cannot specify mTLS auth configuration HOT 2
- Custom container port name is not supported. HOT 3
- Outdated CRD on victoria-metrics-k8s-stack chart HOT 2
- config-reloader liveness checks failing in victoria-metrics-k8s-stack 0.21.0 HOT 3
- Typo in Role template for Victoria-metrics-operator HOT 1
- Setting Alertmanager's config-reloader container resources in victoria-metrics-k8s-stack values HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from helm-charts.