Our server can no longer query our database
jaytonbye
PROOP

a year ago

MYSQL Workbench still allows us to connect and run Queries, but our server is unable to connect. The log is saying:

{

sqlMessage: "Plugin 'mysqlnativepassword' is not loaded",

sqlState: 'HY000',

fatal: true,

originalUrl: 'mainCronJob',

Error: ERPLUGINISNOTLOADED: Plugin 'mysqlnativepassword' is not loaded

at Handshake.ErrorPacket (/app/node_modules/mysql/lib/protocol/sequences/Handshake.js:123:18)

at Parser.parsePacket (/app/nodemodules/mysql/lib/protocol/Parser.js:433:10)

at Parser.write (/app/node_modules/mysql/lib/protocol/Parser.js:43:10)

at Protocol.write (/app/node_modules/mysql/lib/protocol/Protocol.js:38:16)

at Socket.emit (node:events:517:28)

at Socket.emit (node:domain:489:12)

at Protocol.enqueue (/app/nodemodules/mysql/lib/protocol/Protocol.js:144:48)

at PoolConnection.connect (/app/node_modules/mysql/lib/Connection.js:116:18)

at new Promise ()

at YourCustomTransport. (/app/dist/src/logger.js:102:61)

sqlMessage: "Plugin 'mysqlnativepassword' is not loaded",

23 Replies

jaytonbye
PROOP

a year ago

1fc9ac5f-29f8-4b23-ab28-1eebdaeb8c06


jaytonbye
PROOP

a year ago

We've tried to run: ALTER USER 'youruser'@'%' IDENTIFIED WITH mysqlnativepassword BY 'yourpassword';
FLUSH PRIVILEGES;


jaytonbye
PROOP

a year ago

but it responds with: Error Code: 1524. Plugin 'mysqlnativepassword' is not loaded


jaytonbye
PROOP

a year ago

Can anyone help us? This happened on both our production site and our development site at the same time, we've made no recent code changes.

After the initial error, we tried redeploying both databases, and this is where we currently are.


a year ago

Can you send me a screenshot of your database deployments?


jaytonbye
PROOP

a year ago

1296951143397589000


a year ago

Thank you, finally could you send me a screenshot of the image that the MySQL database is connected to?


jaytonbye
PROOP

a year ago

I'm sorry, I don't know what that means


a year ago

Click on the Settings button


a year ago

and then just send a screenshot of the top-most thing on the page


jaytonbye
PROOP

a year ago

1296951640644911400


a year ago

oh perfect, has it always been pinned to version 8?


jaytonbye
PROOP

a year ago

I do not know


a year ago

Let's hope it was, could you try appending --mysql-native-password=ON to your database start command?
You can find that on the same settings page if you scroll down a bit


jaytonbye
PROOP

a year ago

Ok, i'm trying…


jaytonbye
PROOP

a year ago

It is working, thank you. What caused this issue? It is scary for us, as we sometimes have large events going on with a few hundred people on site; it is dangerous for our business to have outages; we want to bulletproof as much as possible.


a year ago

Railway uses the mysql_native_password plugin for authentication (which is somewhat popular), although it seems MySQL databases on Railway doesn't load that plugin by default so when it redeploys then it has to manually enabled by adding that flag


jaytonbye
PROOP

a year ago

Ok, that could explain what caused the issue for the redployment, but why did it need to be redeployed? This has been working fine for 9 months


a year ago

There was an incident where one of Railway's hosts restarted

You can read more about that here: https://status.railway.app/cm2f8s2p2003vdwesikpxm96a


a year ago

your database was indeed on that host


a year ago

we are sorry for the inconvenience here


jaytonbye
PROOP

a year ago

Ok, thank you Brody. I appreciate the honesty.


a year ago

and thank you fragly for getting them up and running so quickly


Loading...