‘Client does not support authentication protocol requested by server; consider upgrading MySQL client’, PROTOCOL_ENQUEUE_AFTER_FATAL_ERROR

PROTOCOL_ENQUEUE_AFTER_FATAL_ERROR
PROTOCOL_ENQUEUE_AFTER_FATAL_ERROR

{ Error: ER_NOT_SUPPORTED_AUTH_MODE: Client does not support authentication protocol requested by server; consider upgrading MySQL client
    at Handshake.Sequence._packetToError (/root/pingnovel/node_modules/mysql/lib/protocol/sequences/Sequence.js:47:14)
    at Handshake.ErrorPacket (/root/pingnovel/node_modules/mysql/lib/protocol/sequences/Handshake.js:123:18)
    at Protocol._parsePacket (/root/pingnovel/node_modules/mysql/lib/protocol/Protocol.js:291:23)
    at Parser._parsePacket (/root/pingnovel/node_modules/mysql/lib/protocol/Parser.js:433:10)
    at Parser.write (/root/pingnovel/node_modules/mysql/lib/protocol/Parser.js:43:10)
    at Protocol.write (/root/pingnovel/node_modules/mysql/lib/protocol/Protocol.js:38:16)
    at Socket. (/root/pingnovel/node_modules/mysql/lib/Connection.js:91:28)
    at Socket. (/root/pingnovel/node_modules/mysql/lib/Connection.js:525:10)
    at emitOne (events.js:116:13)
    at Socket.emit (events.js:211:7)
    --------------------
    at Protocol._enqueue (/root/pingnovel/node_modules/mysql/lib/protocol/Protocol.js:144:48)
    at Protocol.handshake (/root/pingnovel/node_modules/mysql/lib/protocol/Protocol.js:51:23)
    at Connection.connect (/root/pingnovel/node_modules/mysql/lib/Connection.js:119:18)
    at Object. (/root/pingnovel/src/db1.js:11:12)
    at Module._compile (module.js:652:30)
    at Object.Module._extensions..js (module.js:663:10)
    at Module.load (module.js:565:32)
    at tryModuleLoad (module.js:505:12)
    at Function.Module._load (module.js:497:3)
    at Function.Module.runMain (module.js:693:10)
  code: 'ER_NOT_SUPPORTED_AUTH_MODE',
  errno: 1251,
  sqlMessage: 'Client does not support authentication protocol requested by server; consider upgrading MySQL client',
  sqlState: '08004',
  fatal: true }


这种授权协议问题,可以通过使用MYSQL NATIVE PASSWORD来解决,例如:


ALTER USER ABC IDENTIFIED WITH mysql_native_password BY 'password'

Comment

*

沪ICP备14014813号-2

沪公网安备 31010802001379号