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

mysqldump: Allow setting multiple variables in one statement #5401

Closed
morgo opened this issue Nov 5, 2019 · 2 comments · Fixed by #6494
Closed

mysqldump: Allow setting multiple variables in one statement #5401

morgo opened this issue Nov 5, 2019 · 2 comments · Fixed by #6494
Labels
Type: Enhancement Logical improvement (somewhere between a bug and feature)
Milestone

Comments

@morgo
Copy link
Contributor

morgo commented Nov 5, 2019

Feature Description

Mysqldump from MySQL 8.0 requires setting multiple session vars in the one statement. These are session variables which should be safe for Vitess to parse but ignore:

mysql> SET SESSION NET_READ_TIMEOUT= 700;
Query OK, 0 rows affected (0.00 sec)

mysql> set SESSION NET_WRITE_TIMEOUT= 700;
Query OK, 0 rows affected (0.01 sec)

mysql> SET SESSION NET_READ_TIMEOUT= 700, SESSION NET_WRITE_TIMEOUT= 700;
ERROR 1105 (HY000): vtgate: http://morgox1:15001/: syntax error at position 61 near 'NET_WRITE_TIMEOUT'

The workaround is to add the option --skip-network-timeout to mysqldump. i.e.:

mysqldump  --lock-tables=off --quote-names --set-gtid-purged=OFF --no-tablespaces --skip-network-timeout commerce
@morgo morgo added the Type: Enhancement Logical improvement (somewhere between a bug and feature) label Nov 5, 2019
@saifalharthi
Copy link
Contributor

Multiple variables can be set like this mysql> SET SESSION NET_READ_TIMEOUT= 700, NET_WRITE_TIMEOUT= 700;

@aquarapid
Copy link
Contributor

Accidentally reopened.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Type: Enhancement Logical improvement (somewhere between a bug and feature)
Projects
None yet
Development

Successfully merging a pull request may close this issue.

4 participants