tiup icon indicating copy to clipboard operation
tiup copied to clipboard

Upgrade process use the wrong URL

Open rleungx opened this issue 3 years ago • 1 comments

Bug Report

Please answer these questions before submitting your issue. Thanks!

  1. What did you do? Upgrade cluster

  2. What did you expect to see? Successfully

  3. What did you see instead?

Upgrading component tikv
failed increasing schedule limit: no endpoint available, the last err was: error requesting http://10.4.101.105:2379/pd/api/v1/config/replication-mode, response: {
"code": "input",
"msg": "unexpected end of JSON input",
"data":

{ "Offset": 0 }

See https://github.com/pingcap/tiup/blob/49ee71a1e3efc77793fed1ddcaa37a6965ac5845/pkg/cluster/operation/upgrade.go#L223

https://github.com/pingcap/tiup/blob/49ee71a1e3efc77793fed1ddcaa37a6965ac5845/pkg/cluster/api/pdapi.go#L771

For xxx-schedule-limit, we should use pd/api/v1/config or pd/api/v1/config/schedule instead of pd/api/v1/config/replication-mode. replication-mode hasn't GA for now.

  1. What version of TiUP are you using (tiup --version)? master

rleungx avatar Jun 25 '21 03:06 rleungx

It seems updateReplication() and updateReplicationMode() are different functions in PD server, what would be the correct procedure to change leader-schedule-limit with the /config API?

AstroProfundis avatar Jul 07 '21 07:07 AstroProfundis