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

add recommendations options to mydumper #828

Merged
merged 3 commits into from
Aug 29, 2019
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion charts/tidb-backup/values.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,7 @@ storage:
size: 100Gi

# backupOptions is the options of mydumper https://github.com/maxbube/mydumper/blob/master/docs/mydumper_usage.rst#options
backupOptions: "--verbose=3"
backupOptions: "-t 16 -F 256 --skip-tz-utc --verbose=3"
Copy link
Member

Choose a reason for hiding this comment

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

Add simple descriptions for these default options.

  • -t is thread count, larger thread count will speed up the backup, but may impact the performance of the upstream TiDB.
  • -F is the chunk size, a big table is partitioned into many chunks.

Other useful options are -B for database, and -T for tables. See https://github.com/maxbube/mydumper/blob/master/docs/mydumper_usage.rst#options for more options.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

done

# Set the tidb_snapshot to be used for the backup
# Use `show master status` to get the ts:
# MySQL [(none)]> show master status;
Expand Down
2 changes: 1 addition & 1 deletion charts/tidb-cluster/values.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -520,7 +520,7 @@ scheduledBackup:
# https://kubernetes.io/docs/tasks/job/automated-tasks-with-cron-jobs/#starting-deadline
startingDeadlineSeconds: 3600
# https://github.com/maxbube/mydumper/blob/master/docs/mydumper_usage.rst#options
options: "--verbose=3"
options: "-t 16 -F 256 --skip-tz-utc --verbose=3"
# secretName is the name of the secret which stores user and password used for backup
# Note: you must give the user enough privilege to do the backup
# you can create the secret by:
Expand Down
1 change: 0 additions & 1 deletion tests/actions.go
Original file line number Diff line number Diff line change
Expand Up @@ -1818,7 +1818,6 @@ func (oa *operatorActions) DeployAdHocBackup(info *TidbClusterConfig) error {
"user": "root",
"password": info.Password,
"storage.size": "10Gi",
"backupOptions": "\"--verbose=3\"",
"initialCommitTs": strings.TrimSpace(tsStr),
}

Expand Down