Skip to content
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

[TEST] deploy KB with 3 replicas , distributed on 3 nodes. #7360

Open
shanshanying opened this issue May 15, 2024 · 3 comments
Open

[TEST] deploy KB with 3 replicas , distributed on 3 nodes. #7360

shanshanying opened this issue May 15, 2024 · 3 comments
Assignees
Labels
kind/enhancement New feature or request test

Comments

@shanshanying
Copy link
Contributor

shanshanying commented May 15, 2024

Case two cases:

  1. upgrade KB from previous version to 0.8.3 --> upgrade success
  2. install KB 083 with values specifying:
    • replicas
    • kb lables
    • kb affinity
    • dp lables (dp for dataprotection)
    • dp affinity
      installation success, and 3 KB replicas are distributed on 3 DIFFERNET nodes.

here is an example of values.yaml to test:

replicaCount: 3
image:
  tag: 0.8.3-beta.19
extraLabels:
  app.kubernetes.io/component: "kubeblocks"
tolerations:
- key: kb-controller
  operator: Equal
  value: "true"
  effect: NoSchedule
affinity:
  nodeAffinity:
    preferredDuringSchedulingIgnoredDuringExecution:
    - weight: 100
      preference:
        matchExpressions:
        - key: kb-controller
          operator: In
          values:
          - "true"
  podAntiAffinity:
    requiredDuringSchedulingIgnoredDuringExecution:
    - labelSelector:
        matchLabels:
          app.kubernetes.io/instance: kubeblocks
          app.kubernetes.io/component: "kubeblocks"
      topologyKey: kubernetes.io/hostname
dataProtection:
  image:
    tag: 0.8.3-beta.19
  affinity:
    nodeAffinity:
      preferredDuringSchedulingIgnoredDuringExecution:
      - weight: 100
        preference:
          matchExpressions:
          - key: kb-controller
            operator: In
            values:
            - "true"
    podAntiAffinity:
      requiredDuringSchedulingIgnoredDuringExecution:
      - labelSelector:
          matchLabels:
            app.kubernetes.io/instance: kubeblocks
            app.kubernetes.io/component: "dataprotection"
        topologyKey: kubernetes.io/hostname
  extraLabels:
    app.kubernetes.io/component: "dataprotection"
@shanshanying shanshanying added the kind/enhancement New feature or request label May 15, 2024
@shanshanying shanshanying changed the title [test] deploy KB with 3 replicas , distributed on 3 nodes. [TEST] deploy KB with 3 replicas , distributed on 3 nodes. May 15, 2024
@JashBook
Copy link
Collaborator

helm upgrade kubeblocks kb-charts/kubeblocks-0.8.3-beta.22.tgz -i -n kb-system -f kubeblocks-valuse.yaml 
coalesce.go:289: warning: destination for kubeblocks.dataProtection.extraLables is a table. Ignoring non-table value ([])
coalesce.go:237: warning: skipped value for kubeblocks.extraLables: Not a table.
W0515 21:03:19.755735    5043 warnings.go:70] Due to the lack of practical use cases, this API is deprecated from KB 0.9.0.
W0515 21:03:19.757094    5043 warnings.go:70] Due to the lack of practical use cases, this API is deprecated from KB 0.9.0.
W0515 21:03:19.760464    5043 warnings.go:70] Due to the lack of practical use cases, this API is deprecated from KB 0.9.0.
Error: UPGRADE FAILED: cannot patch "kubeblocks-dataprotection" with kind Deployment: Deployment.apps "kubeblocks-dataprotection" is invalid: spec.selector: Invalid value: v1.LabelSelector{MatchLabels:map[string]string{"app.kubernetes.io/component":"dataprotection", "app.kubernetes.io/instance":"kubeblocks", "app.kubernetes.io/name":"kubeblocks"}, MatchExpressions:[]v1.LabelSelectorRequirement(nil)}: field is immutable && cannot patch "kubeblocks" with kind Deployment: Deployment.apps "kubeblocks" is invalid: spec.selector: Invalid value: v1.LabelSelector{MatchLabels:map[string]string{"app.kubernetes.io/component":"kubeblocks", "app.kubernetes.io/instance":"kubeblocks", "app.kubernetes.io/name":"kubeblocks"}, MatchExpressions:[]v1.LabelSelectorRequirement(nil)}: field is immutable

@shanshanying
Copy link
Contributor Author

  1. try INSTALL a new version ,with above mentioned values (to make sure all newly installed KB can be distributed)
  2. upgrade without any new values (to make sure all previously installed versioin can be upgrade)
  3. there is a typo extraLables in my prevous post, fixed as extraLabels.

@JashBook
Copy link
Collaborator

JashBook commented May 27, 2024

Only 3 nodes, addon pod schedule failed: didn't match pod anti-affinity rules with kubeblocks #7426
After increasing nodes to more than 3, install and upgrade kubeblocks were successful.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
kind/enhancement New feature or request test
Projects
None yet
Development

No branches or pull requests

3 participants