MySQL Verbindung wird abgelehnt

Started by NicoleSophie, October 15, 2020, 05:33:26 PM

Previous topic - Next topic

NicoleSophie

Ich breuchte mal Dringend Eure hilfe.
Ich habe das Webinterface auf einen Webserver und den rest auf einem vServer.

Einrichtung auf dem vServer hat geklappt installation auf dem Webserver auch.

Leider haut die Kommunikation nicht hin.

Das ist die Logdatai:
2020-10-15 17:24:59 START_MANAGER JTS3ServerMod 6.5.7 Hosting Edition (31.01.2020) Instance Manager started...
2020-10-15 17:24:59 SYSTEM_INFO Operating System : Linux (version: 4.19.0-10-amd64 / arch: amd64)
2020-10-15 17:24:59 SYSTEM_INFO Used Java Version: 11.0.8 (path: /usr/lib/jvm/java-11-openjdk-amd64)
2020-10-15 17:24:59 SYSTEM_INFO Current directory: /home/jts3
2020-10-15 17:24:59 CONFIG Loading InstanceManager config file from: /home/jts3/config/JTS3ServerMod_InstanceManager.cfg
2020-10-15 17:24:59 CONFIG Bot chat command !exec is disabled!
2020-10-15 17:24:59 CONFIG Multi IP Mode disabled!
2020-10-15 17:25:00 LOGGER_SQL_ERROR Critical: Cannot connect to MySQL server for logging!
2020-10-15 17:25:00 JTS3ServerMod 6.5.7 Hosting Edition (31.01.2020): EXCEPTION
java.sql.SQLException: Access denied for user 'k128618_jts3 '@'80.241.217.192' (using password: YES)
at com.mysql.jdbc.SQLError.createSQLException(SQLError.java:965)
at com.mysql.jdbc.MysqlIO.checkErrorPacket(MysqlIO.java:3933)
at com.mysql.jdbc.MysqlIO.checkErrorPacket(MysqlIO.java:3869)
at com.mysql.jdbc.MysqlIO.checkErrorPacket(MysqlIO.java:864)
at com.mysql.jdbc.MysqlIO.proceedHandshakeWithPluggableAuthentication(MysqlIO.java:1707)
at com.mysql.jdbc.MysqlIO.doHandshake(MysqlIO.java:1217)
at com.mysql.jdbc.ConnectionImpl.coreConnect(ConnectionImpl.java:2189)
at com.mysql.jdbc.ConnectionImpl.connectOneTryOnly(ConnectionImpl.java:2220)
at com.mysql.jdbc.ConnectionImpl.createNewIO(ConnectionImpl.java:2015)
at com.mysql.jdbc.ConnectionImpl.<init>(ConnectionImpl.java:768)
at com.mysql.jdbc.JDBC4Connection.<init>(JDBC4Connection.java:47)
at java.base/jdk.internal.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method)
at java.base/jdk.internal.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:62)
at java.base/jdk.internal.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:45)
at java.base/java.lang.reflect.Constructor.newInstance(Constructor.java:490)
at com.mysql.jdbc.Util.handleNewInstance(Util.java:425)
at com.mysql.jdbc.ConnectionImpl.getInstance(ConnectionImpl.java:385)
at com.mysql.jdbc.NonRegisteringDriver.connect(NonRegisteringDriver.java:323)
at java.sql/java.sql.DriverManager.getConnection(DriverManager.java:677)
at java.sql/java.sql.DriverManager.getConnection(DriverManager.java:228)
at de.stefan1200.util.MySQLConnect.connect(Unknown Source)
at de.stefan1200.jts3servermod.t.a(Unknown Source)
at de.stefan1200.jts3servermod.t.<init>(Unknown Source)
at de.stefan1200.jts3servermod.f.c(Unknown Source)
at de.stefan1200.jts3servermod.f.<init>(Unknown Source)
at de.stefan1200.jts3servermod.JTS3ServerMod.main(Unknown Source)
2020-10-15 17:25:00 CONFIG MySQL mode enabled!
2020-10-15 17:25:00 MYSQL_ERROR Error while connecting to database: java.sql.SQLException: Access denied for user 'k128618_jts3 '@'80.241.217.192' (using password: YES)
2020-10-15 17:25:00 JTS3ServerMod 6.5.7 Hosting Edition (31.01.2020): EXCEPTION
java.sql.SQLException: Access denied for user 'k128618_jts3 '@'80.241.217.192' (using password: YES)
at com.mysql.jdbc.SQLError.createSQLException(SQLError.java:965)
at com.mysql.jdbc.MysqlIO.checkErrorPacket(MysqlIO.java:3933)
at com.mysql.jdbc.MysqlIO.checkErrorPacket(MysqlIO.java:3869)
at com.mysql.jdbc.MysqlIO.checkErrorPacket(MysqlIO.java:864)
at com.mysql.jdbc.MysqlIO.proceedHandshakeWithPluggableAuthentication(MysqlIO.java:1707)
at com.mysql.jdbc.MysqlIO.doHandshake(MysqlIO.java:1217)
at com.mysql.jdbc.ConnectionImpl.coreConnect(ConnectionImpl.java:2189)
at com.mysql.jdbc.ConnectionImpl.connectOneTryOnly(ConnectionImpl.java:2220)
at com.mysql.jdbc.ConnectionImpl.createNewIO(ConnectionImpl.java:2015)
at com.mysql.jdbc.ConnectionImpl.<init>(ConnectionImpl.java:768)
at com.mysql.jdbc.JDBC4Connection.<init>(JDBC4Connection.java:47)
at java.base/jdk.internal.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method)
at java.base/jdk.internal.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:62)
at java.base/jdk.internal.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:45)
at java.base/java.lang.reflect.Constructor.newInstance(Constructor.java:490)
at com.mysql.jdbc.Util.handleNewInstance(Util.java:425)
at com.mysql.jdbc.ConnectionImpl.getInstance(ConnectionImpl.java:385)
at com.mysql.jdbc.NonRegisteringDriver.connect(NonRegisteringDriver.java:323)
at java.sql/java.sql.DriverManager.getConnection(DriverManager.java:677)
at java.sql/java.sql.DriverManager.getConnection(DriverManager.java:228)
at de.stefan1200.util.MySQLConnect.connect(Unknown Source)
at de.stefan1200.jts3servermod.f.e(Unknown Source)
at de.stefan1200.jts3servermod.f.c(Unknown Source)
at de.stefan1200.jts3servermod.f.<init>(Unknown Source)
at de.stefan1200.jts3servermod.JTS3ServerMod.main(Unknown Source)
2020-10-15 17:25:00 QUIT_MANAGER Error while loading the JTS3ServerMod InstanceManager config file, read error messages above to know more. Quitting now...



Das ist die JTS3ServerMod_InstanceManager Datei:

# JTS3ServerMod Instance Manager config file
#
# This file must be saved with the encoding ISO-8859-1!

# A comma seperated list (without spaces) of unique user ids,
# which should be able to use bot full admin commands on all bot instances.
# Bot full admin can also see the TS3 server password and is able to use the !exec command.
# The unique user ids looks like this: mBbHRXwDAG7R19Rv3PorhMwbZW4=
bot_fulladmin_list = OJVjd8pFwstNajK6KKaGy5EOKGs=
# Allow !exec and !execwait commands for bot full admins? 1 = Yes, 0 = No
# This allow you to execute system commands.
# Only use !execwait for commands which quits within some seconds,
# because the bot waits for the end of this command to send you the text output of the program.
# Use !exec for commands with a longer runtime instead,
# this command don't send you any text output, because the bot don't wait for it.
bot_command_exec = 0
# Every time a bot full admin connects to the TS3 server it will be checked if an update for the JTS3ServerMod is available.
# If an update is available, a chat message will be sent to the bot full admin.
# 0 = disable, 1 = final versions, 2 = final and test versions
bot_update_check = 1
# The own personal licence key.
# Read the instructions, to know how to get one, at the download page of the JTS3ServerMod Hosting Edition.
bot_licence_key = xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx2f68762b36
# Add a small delay in milliseconds to the bot starting process.
# Only change this value if you have problems starting all bots at once, like hanging bot threads.
delay_bot_start = 100

# Enable the multi IP mode. 1 = Enable, 0 = Disable
# If slow mode is activated, this feature split bot connections to the Teamspeak 3 servers.
# Events (Chat and some functions) and the Client Database Cache gets an own connection which should solve the IP ban problem.
multiipmode_enable = 0
# Local IP Address of the main connection, make sure that this is not the same as for chat and cache!
multiipmode_ip_main = 123.123.123.123
# Local IP Address of the chat connection, make sure that this is not the same as for main and cache!
multiipmode_ip_chat = 124.124.124.124
# Local IP Address of the cache connection, make sure that this is not the same as for chat and main!
multiipmode_ip_cache = 125.125.125.125
# First local port
multiipmode_portrange_min = 50000
# Last local port
# Make sure, that you have at least 3 ports for every bot, which use the slow mode!
multiipmode_portrange_max = 51999

# Enable the Query Interface of the JTS3ServerMod. 1 = Enable, 0 = Disable
# You are able to start, stop or reload a virtual bot instance using this Query Interface.
telnet_enable = 1
# Choose a port for the Query Interface, default port is 5873.
telnet_port = 5873
# Choose a password for the Query Interface.
# If this password is shorter than 6 characters, the Query Interface will be disabled!
telnet_password = xxxxxxxx
# Choose a network interface for the Query Interface. Only set a single ip address of a local network interface here.
# Set nothing here to bound the Query Interface to all network interfaces (default).
# Example: Set to 127.0.0.1 (IPv4) or ::1 (IPv6) to allow connections only from localhost.
telnet_bindTo =
# A comma seperated list (without spaces) of IP addresses, which are allowed to connect to the Query Interface.
# Leave empty, if every IP address is allowed to connect.
telnet_whitelist = 91.204.46.83
# Log query connection attempts to logfile? 1 = Enable, 0 = Disable
telnet_connection_log = 1
# Enable this to prevent that the JTS3ServerMod process quits if no bot instances are running. 1 = Enable, 0 = Disable
# You can still quit the process with !botquit in TS3 client chat or with botquit on the Query Interface.
telnet_run_forever = 1

# Use a MySQL database to save bot instances and configurations. 1 = Enable, 0 = Disable
# There should be a structure sql file in the documents directory.
# Import this into your MySQL database to create the tables (the included web interface do this already for you).
# But you must fill this tables by yourself, the bot just reads the information out there.
mysql_enable = 1
mysql_host = 91.204.46.83
mysql_port = 3306
mysql_user = k128618_jts3
mysql_password = xxxxxxx
mysql_database = xxxxxxxxx

# Optional MySQL settings, more information on https://dev.mysql.com/doc/connector-j/5.1/en/connector-j-reference-configuration-properties.html#connector-j-reference-set-config
# Possible values: -1 = default, 0 = disable, 1 = enable
mysql_verifyServerCertificate = 0
mysql_useSSL = 0
mysql_requireSSL = -1
mysql_useCompression = -1

# Normal log entries older than X days will be deleted from MySQL jts3servermod_log table. 0 = disable auto delete!
mysql_log_delete = 0
# Connection log entries older than X days will be deleted from MySQL jts3servermod_log table. 0 = disable auto delete!
mysql_connection_log_delete = 0

# Passphrase for the encryption of TS3 server query passwords.
# This key has to be the same as in the PHP PWCrypt class.
# Leave it empty to disable encrypting and decrypting query passwords.
# If the passphrase will be changed after some passwords was encrypted,
# it is not possible to decrypt the encrypted passwords again.
crypt_key =

Stefan1200

#1
Wie ich dir schon per Mail geschrieben habe, musst du folgendes Problem lösen, dann läuft es:
QuoteAccess denied for user 'k128618_jts3   '@'80.241.217.192' (using password: YES)

Die Fehlermeldung kommt vom MySQL Server.

NicoleSophie

Das kommische an der sache ist, der Benutzer name ist von der MYSQL Datenbank und die IP ist der vServer.

Das heißt beides sind 2 verschiedene server.

Stefan1200

Quote from: NicoleSophie on October 16, 2020, 12:23:35 AM
Das kommische an der sache ist, der Benutzer name ist von der MYSQL Datenbank und die IP ist der vServer.
Das heißt beides sind 2 verschiedene server.

MySQL arbeitet bei den Berechtigungen immer mit dem Benutzernamen und der Quell-IP, von wo die Verbindung kommt. D.h. du kannst in MySQL einstellen, dass ein MySQL Benutzer sich nur von einer bestimmten IP Adresse verbinden darf.