Skip to content
New issue

Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? # to your account

Connection Refused using velocity and mariadb #1264

Open
2 tasks done
hensolo11 opened this issue Nov 20, 2024 · 1 comment
Open
2 tasks done

Connection Refused using velocity and mariadb #1264

hensolo11 opened this issue Nov 20, 2024 · 1 comment
Labels
bug Something isn't working

Comments

@hensolo11
Copy link

What happened?

[13:22:09 INFO] [fastlogin]: Using legacy scheduler
[13:22:11 INFO] [fastlogin.hikari.HikariDataSource]: fastlogin - Starting...
[13:22:14 ERROR] [fastlogin.hikari.pool.HikariPool]: fastlogin - Exception during pool initialization.
java.sql.SQLNonTransientConnectionException: Socket fail to connect to host:address=(host=127.0.0.1)(port=3306)(type=primary). Connection refused

Steps to reproduce

Install latest Velocity version, install FastLoginVelocity, set up mariadb database and put credentials in the config file of the plugin. I checked mariadb is running, i added permissions for that user, opened firewall for port 3306. Error persists

Plugin list

fastlogin, skinrestorer, luckperms

Configuration file

https://hastebin.com/share/kotomepeqe.yaml

Server log

[13:22:09 INFO] [fastlogin]: Using legacy scheduler
[13:22:11 INFO] [fastlogin.hikari.HikariDataSource]: fastlogin - Starting...
[13:22:14 ERROR] [fastlogin.hikari.pool.HikariPool]: fastlogin - Exception during pool initialization.
java.sql.SQLNonTransientConnectionException: Socket fail to connect to host:address=(host=127.0.0.1)(port=3306)(type=primary). Connection refused
at fastlogin.mariadb.jdbc.client.impl.ConnectionHelper.connectSocket(ConnectionHelper.java:126) ~[?:?]
at fastlogin.mariadb.jdbc.client.impl.StandardClient.(StandardClient.java:130) ~[?:?]
at fastlogin.mariadb.jdbc.Driver.connect(Driver.java:69) ~[?:?]
at fastlogin.mariadb.jdbc.Driver.connect(Driver.java:95) ~[?:?]
at fastlogin.mariadb.jdbc.Driver.connect(Driver.java:26) ~[?:?]
at fastlogin.hikari.util.DriverDataSource.getConnection(DriverDataSource.java:138) ~[?:?]
at fastlogin.hikari.pool.PoolBase.newConnection(PoolBase.java:364) ~[?:?]
at fastlogin.hikari.pool.PoolBase.newPoolEntry(PoolBase.java:206) ~[?:?]
at fastlogin.hikari.pool.HikariPool.createPoolEntry(HikariPool.java:476) ~[?:?]
at fastlogin.hikari.pool.HikariPool.checkFailFast(HikariPool.java:561) ~[?:?]
at fastlogin.hikari.pool.HikariPool.(HikariPool.java:115) ~[?:?]
at fastlogin.hikari.HikariDataSource.(HikariDataSource.java:81) ~[?:?]
at com.github.games647.fastlogin.core.storage.SQLStorage.(SQLStorage.java:85) ~[?:?]
at com.github.games647.fastlogin.core.storage.MySQLStorage.(MySQLStorage.java:41) ~[?:?]
at com.github.games647.fastlogin.core.shared.FastLoginCore.setupDatabase(FastLoginCore.java:254) ~[?:?]
at com.github.games647.fastlogin.velocity.FastLoginVelocity.onProxyInitialization(FastLoginVelocity.java:100) ~[?:?]
at com.github.games647.fastlogin.velocity.Lmbda$1.execute(Unknown Source) ~[?:?]
at com.velocitypowered.proxy.event.UntargetedEventHandler$VoidHandler.lambda$buildHandler$0(UntargetedEventHandler.java:56) ~[server.jar:3.4.0-SNAPSHOT (git-cefa3b27-b450)]
at com.velocitypowered.proxy.event.VelocityEventManager.fire(VelocityEventManager.java:676) ~[server.jar:3.4.0-SNAPSHOT (git-cefa3b27-b450)]
at com.velocitypowered.proxy.event.VelocityEventManager.lambda$fire$5(VelocityEventManager.java:541) ~[server.jar:3.4.0-SNAPSHOT (git-cefa3b27-b450)]
at java.base/java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1144) ~[?:?]
at java.base/java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:642) ~[?:?]
at java.base/java.lang.Thread.run(Thread.java:1583) [?:?]
Caused by: java.net.ConnectException: Connection refused
at java.base/sun.nio.ch.Net.pollConnect(Native Method) ~[?:?]
at java.base/sun.nio.ch.Net.pollConnectNow(Net.java:682) ~[?:?]
at java.base/sun.nio.ch.NioSocketImpl.timedFinishConnect(NioSocketImpl.java:542) ~[?:?]
at java.base/sun.nio.ch.NioSocketImpl.connect(NioSocketImpl.java:592) ~[?:?]
at java.base/java.net.SocksSocketImpl.connect(SocksSocketImpl.java:327) ~[?:?]
at java.base/java.net.Socket.connect(Socket.java:751) ~[?:?]
at fastlogin.mariadb.jdbc.client.impl.ConnectionHelper.connectSocket(ConnectionHelper.java:120) ~[?:?]
... 22 more

Plugin version

latest

Platform

Velocity

Relevance

  • I tried the latest build
    (build refers to development builds not necessary a release version; i.e. v1.10 is out of date)

  • I checked for existing tickets -
    If there are, please vote them with a thumbs reaction and not create new ones

@hensolo11 hensolo11 added the bug Something isn't working label Nov 20, 2024
@games647
Copy link
Owner

games647 commented Dec 2, 2024

You don't need to open the firewall if it's running locally. You can check listening processes with their ports with ss -tlpn.

# for free to join this conversation on GitHub. Already have an account? # to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants