Bug #82757 --classic not enabled when using --dba enableXProtocol
Submitted: 28 Aug 2016 12:21 Modified: 28 Aug 2016 18:14
Reporter: Daniël van Eeden (OCA) Email Updates:
Status: Verified Impact on me:
None 
Category:MySQL Server: Document Store: MySQL Shell Severity:S3 (Non-critical)
Version:1.0.4 OS:Any
Assigned to: CPU Architecture:Any

[28 Aug 2016 12:21] Daniël van Eeden
Description:
When useing '--dba enableXProtocol' --classic must be used.

However if it is not no error is given but mysqlsh tries to connect to the server with the new protocol, but on the port where mysql listens for the classic protocol... Which gives a not-so-helpful error.

How to repeat:
[dvaneeden@dve-mac msb_5_7_14]$ mysqlsh --user=msandbox --password=msandbox --port=5714 --socket=/tmp/mysql_sandbox5714.sock --dba enableXProtocol
mysqlx: [Warning] Using a password on the command line interface can be insecure.
Creating an X Session to msandbox@localhost:5714
MySQL Error (2027): Unknown message received from server 10

[dvaneeden@dve-mac msb_5_7_14]$ mysqlsh --user=msandbox --password=msandbox --port=5714 --socket=/tmp/mysql_sandbox5714.sock --dba enableXProtocol --classic
mysqlx: [Warning] Using a password on the command line interface can be insecure.
Creating a Classic Session to msandbox@localhost:5714
No default schema selected.

enableXProtocol: Installing plugin mysqlx...
enableXProtocol: done

Suggested fix:
1. auto enable --classic if '--dba enableXProtocol' is used
OR return an error like "Error: '--dba enableXprotocol' requires '--classic'"

2. If a connection is made to the 'classic' port instead of the mysqlx port return a useful error.
"Error: detected classic protocol on localhost:5714, use --classic to connect in classic mode or specify the mysqlx port of the server, which is 33060 by default"
[28 Aug 2016 18:14] MySQL Verification Team
Hello Daniël,

Thank you for the report.

Thanks,
Umesh
[28 Aug 2016 18:14] MySQL Verification Team
related to (2) - Bug #81051