pingcap / pingcap/tiup

Tiup will report error when setting up a cluster with tikv labels which not included in location-labels

Open
#1,884 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

type/bug
Dominant language
Go
Stars
466
Forks
338
Avg merge
3d 7h
Merged PRs (30d)
8

Description

Bug Report

Please answer these questions before submitting your issue. Thanks!

  1. What did you do?

For the below configurations

tiup cluster deploy tidb-test v6.0.0 /tmp/topology.yaml --user root -i ~/.ssh/id_ed25519

The /tmp/topology.yaml content:

global:
  user: "tidb"
  ssh_port: 22
  deploy_dir: "/tidb-deploy"
  data_dir: "/tidb-data"
server_configs: {}
pd_servers:
  - host: 10.0.1.4
tidb_servers:
  - host: 10.0.1.7
tikv_servers:
  - host: 10.0.1.1
    config:
      server.labels: { region: "US" }
  1. What did you expect to see?

User want to use placement in sql feature which does not require isolation_labels to be configured in PD. So no error should occur.

  1. What did you see instead?

Error occurs

Error: check TiKV label failed, please fix that before continue:
10.0.1.1:20160:
	label name 'region' is not specified in pd config (replication.location-labels: [])
  1. What version of TiUP are you using (tiup --version)?
1.9.4 tiup
Go Version: go1.17.8
Git Ref: v1.9.4
GitHash: 21178655f26240da5227b64988e066586a4ea6b6

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start by reproducing the tiup cluster deploy command with the supplied topology.yaml, then locate the validation invoked during deployment for tikv server.labels and PD replication.location-labels. Done means a TikV label such as region can be used without requiring it in PD location-labels, while the reported invalid configurations still receive appropriate errors.

Written by the indexing model from the issue text.

Assessment

Tech stack
go
Domain
cli, devops
Issue type
Bug
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.