Skip to content
This repository has been archived by the owner on Jun 24, 2021. It is now read-only.

Optimization rolling update pd #883

Merged
merged 10 commits into from
Aug 12, 2019
Merged

Optimization rolling update pd #883

merged 10 commits into from
Aug 12, 2019

Conversation

liubo0127
Copy link
Contributor

@liubo0127 liubo0127 commented Aug 5, 2019

Divide the pd node into two groups(leader and follower), upgrade the follower first, and finally upgrade the leader.
@LinuxGit @superlzs0476 PTAL

tags:
- pd
tasks:
- name: Get pd leader
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

register: pd_status
- name: Failed when one node of pd is unhealthy
fail:
msg: "Some pd node is unhealth"
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

syntax error

groups: pd_servers_followers
pd_client_port: "{{ pd_client_port }}"
deploy_dir: "{{ deploy_dir }}"
pd_peer_port: "{{ pd_peer_port }}"
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It seems that pd_servers_followers groups don't have group variables in
https://github.com/pingcap/tidb-ansible/blob/master/group_vars/pd_servers.yml and other customized host variables.

@@ -54,8 +54,101 @@
- current_version.stdout_lines[0].replace(' ','').split(':')[1] < "v2.0.1"
- tidb_version >= "v2.1.0" or tidb_version == "latest"

- hosts: pd_servers
any_errors_fatal: true
serial: 1
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

don't need serial: 1?


- hosts: pd_servers
any_errors_fatal: true
serial: 1
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

ditto

Copy link
Contributor

@LinuxGit LinuxGit left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@liubo0127 liubo0127 merged commit 546dcb6 into pingcap:master Aug 12, 2019
@liubo0127 liubo0127 deleted the liubo/update-rolling-pd branch August 12, 2019 09:12
liubo0127 added a commit that referenced this pull request Aug 12, 2019
* Optimization rolling update pd
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants