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

Script doesn't recognize config.js mysql IP #9

Open
DomoRomDom opened this issue Jan 30, 2025 · 1 comment
Open

Script doesn't recognize config.js mysql IP #9

DomoRomDom opened this issue Jan 30, 2025 · 1 comment

Comments

@DomoRomDom
Copy link

DomoRomDom commented Jan 30, 2025

The issue is that the Script reads the Pterodactyl IP instead of the Config.JS file.

The script is reading 185.223.xx.xx instead of 15.235.xx.xx

The bot is hosted at a different IP address.

Running the bot via Pterodactyl NodeJS.

Logs

Error connecting to MySQL: Error: ER_ACCESS_DENIED_ERROR: Access denied for user 'ogpuser'@'185.223.xxx.xxx' (using password: YES) at Sequence._packetToError (/home/container/node_modules/mysql/lib/protocol/sequences/Sequence.js:47:14) at Handshake.ErrorPacket (/home/container/node_modules/mysql/lib/protocol/sequences/Handshake.js:123:18) at Protocol._parsePacket (/home/container/node_modules/mysql/lib/protocol/Protocol.js:291:23) at Parser._parsePacket (/home/container/node_modules/mysql/lib/protocol/Parser.js:433:10) at Parser.write (/home/container/node_modules/mysql/lib/protocol/Parser.js:43:10) at Protocol.write (/home/container/node_modules/mysql/lib/protocol/Protocol.js:38:16) at Socket.<anonymous> (/home/container/node_modules/mysql/lib/Connection.js:88:28) at Socket.<anonymous> (/home/container/node_modules/mysql/lib/Connection.js:526:10) at Socket.emit (node:events:513:28) at addChunk (node:internal/streams/readable:324:12) -------------------- at Protocol._enqueue (/home/container/node_modules/mysql/lib/protocol/Protocol.js:144:48) at Protocol.handshake (/home/container/node_modules/mysql/lib/protocol/Protocol.js:51:23) at Connection.connect (/home/container/node_modules/mysql/lib/Connection.js:116:18) at Object.<anonymous> (/home/container/src/commands/creategame.js:24:12) at Module._compile (node:internal/modules/cjs/loader:1159:14) at Module._extensions..js (node:internal/modules/cjs/loader:1213:10) at Module.load (node:internal/modules/cjs/loader:1037:32) at Module._load (node:internal/modules/cjs/loader:878:12) at Module.require (node:internal/modules/cjs/loader:1061:19) at require (node:internal/modules/cjs/helpers:103:18) { code: 'ER_ACCESS_DENIED_ERROR', errno: 1045, sqlMessage: "Access denied for user 'ogpuser'@'185.223xx.xx' (using password: YES)", sqlState: '28000', fatal: true }

config.js
serverip: "15.235.1xx.xxx", //Server IP for hosting ip: "http://xxx",//Your panel ip (Ex: panel.ares-host.com) remote_server_id: "1", //Your remote server ID (change this based on your remote ID) token: "MTMzNDA3MzU2MDkzMDU4MjU5MA.GV8z8V.ZwdqpyKgVPeWs7rjZjujzUSO1T-pdy5kcg6wwE",//Bot Token mysqlhost: "15.235.1xx.xx",//"5.252.100.174", mysqluser: "ogpuser",//Mysql User mysqlpw: "8OxxxP",//Mysql Password mysqldb: "ogp_panel"//Mysql Database of OGP (Default: ogp_panel)

@notN1CHO
Copy link
Owner

Hello, I think its a problem from mysql server connection, you may need to allow the ip of the vps.
try this command in terminal
sudo ufw allow from <BOT_IP> to any port 3306

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants