Support for the latest build of L2J Server, get help here with installations, upgrades, problems.
Do not post bugs reports here, use viewforum.php?f=77 instead. There is no support for other server builds than the official provided by l2jserver.com
Error: There was an error while attempting to retrieve the list of currently registered GameServers.Reason: Communications link failure The last packet sent successfully to the server was 0 milliseconds ago. The driver has not received any packets from the server.Exception in thread "main" java.lang.NullPointerException at net.sf.l2j.gsregistering.GameServerRegister.<init>(GameServerRegister.java:45) at net.sf.l2j.gsregistering.BaseGameServerRegister.startCMD(BaseGameServerRegister.java:282) at net.sf.l2j.gsregistering.BaseGameServerRegister.main(BaseGameServerRegister.java:190) at net.sf.l2j.gsregistering.GameServerRegister.main(GameServerRegister.java:33)
I already tried running as root and normal user and I don't use a firewall at the moment, so I don't get the point..
I tried with java6-jdk and java5-jdk installed (via apt).
# ---------------------------------------------------------------------------# Login Server Settings# ---------------------------------------------------------------------------# This is the server configuration file. Here you can set up the connection information for your server.# This was written with the assumption that you are behind a router.# Dumbed Down Definitions...# LAN (LOCAL area network) - typically consists of computers connected to the same router as you.# WAN (WIDE area network) - typically consists of computers OUTSIDE of your router (ie. the internet).# x.x.x.x - Format of an IP address. Do not include the x'es into settings. Must be real numbers.# ---------------------------------------------------------------------------# Networking# ---------------------------------------------------------------------------# This is transmitted to the clients connecting from an external network, so it has to be a public IP or resolvable hostname# Common settings...# 127.0.0.1 - If you are playing alone on a test server# 192.168.x.x - This is if you are on a 192.168.x.x type network (behind a standard consumer router) and want other computers from JUST the internal network to be able to connect# x.x.x.x - WAN IP obtained from http://www.whatismyip.com/. This is if you want people outside your internal network to be able to connect to your server.# ---------------------------------------------------------------------------# Default: 127.0.0.1ExternalHostname = 94.127.**.** # ---------------------------------------------------------------------------# This is transmitted to the client from the same network, so it has to be a local IP or resolvable hostname.# This can be the internal IP such as 127.0.0.1 or the computer's IP such as 192.168.x.x.# ---------------------------------------------------------------------------# Default: 127.0.0.1InternalHostname = 127.0.0.1 # ---------------------------------------------------------------------------# If you are behind a router which using its own local IP for Port Forwarding then set this to the routers# local IP if you want people outside your internal network to be able to connect to your server.# ---------------------------------------------------------------------------# RouterHostname = # Bind ip of the LoginServer, use * to bind on all available IPs# Default: *LoginserverHostname = * # Default: 2106LoginserverPort = 2106 # The address on which login will listen for GameServers, use * to bind on all available IPs# Default: *LoginHostname = * # The port on which login will listen for GameServers# Default: 9014LoginPort = 9014 # The delay in minutes after which the login updates the gameservers IP's (usefull when their ip is dynamic)# Default: 15IpUpdateTime = 15 # ---------------------------------------------------------------------------# Security# ---------------------------------------------------------------------------# Default: TrueLogLoginController = True # How many times you can provide an invalid account/pass before the IP gets banned.# Default: 10LoginTryBeforeBan = 6 # Time you won't be able to login back again after LoginTryBeforeBan tries to login.# Default: 600 (10 minutes)LoginBlockAfterBan = 600 # If set to True any GameServer can register on your login's free slots# Default: FalseAcceptNewGameServer = True # Enforce GameGuard authorization from client?# If True, login server will kick client if the client bypassed GameGuard authentication.# Default: FalseForceGGAuth = False # Flood Protection. All values are in MILISECONDS.# Default: TrueEnableFloodProtection = True # Default: 15FastConnectionLimit = 15 # Default: 700NormalConnectionTime = 700 # Default: 350FastConnectionTime = 350 # Default: 50MaxConnectionPerIP = 50 # ---------------------------------------------------------------------------# Database# ---------------------------------------------------------------------------# Specify the appropriate driver and url for the database you're using.# Examples:# Driver = com.mysql.jdbc.Driver (default)# Driver = org.hsqldb.jdbcDriver# Driver = com.microsoft.sqlserver.jdbc.SQLServerDriverDriver = com.mysql.jdbc.Driver# Database URL# URL = jdbc:mysql://localhost/l2jdb (default)# URL = jdbc:hsqldb:hsql://localhost/l2jdb# URL = jdbc:sqlserver://localhost/database = l2jdb/user = sa/password = URL = jdbc:mysql://localhost/l2jdb# Database user info (default is "root" but it's not recommended)Login = **# Database connection passwordPassword = ** # Default: 10MaximumDbConnections = 10 # Default: 0MaximumDbIdleTime = 0 # ---------------------------------------------------------------------------# Misc.# ---------------------------------------------------------------------------# If False, the license (after the login) will not be shown.# Default: TrueShowLicence = True # Default: TrueAutoCreateAccounts = True # ---------------------------------------------------------------------------# Developer Settings# ---------------------------------------------------------------------------# Default: FalseDebug = False # Default: FalseAssert = False # Default: FalseDeveloper = False
login# loading login configL2Properties: Missing property for key - PacketHandlerDebugL2Properties: Missing property for key - RequestServerIDL2Properties: Missing property for key - AcceptAlternateIDL2Properties: Missing property for key - DatapackRootL2Properties: Missing property for key - RouterHostnameLoading mmo.propertiesL2Properties: Missing property for key - IOSelectorThreadCountMLog clients using java 1.4+ standard logging.Initializing c3p0-0.9.1.2 [built 21-May-2007 15:04:56; debug? true; trace: 10]Initializing c3p0 pool... com.mchange.v2.c3p0.ComboPooledDataSource [ java.beans.IntrospectionException: java.lang.reflect.InvocationTargetException [numThreadsAwaitingCheckoutDefaultUser] ]FATAL: Failed initializing database. Reason: Communications link failure The last packet sent successfully to the server was 0 milliseconds ago. The driver has not received any packets from the server.com.mysql.jdbc.exceptions.jdbc4.CommunicationsException: Communications link failure The last packet sent successfully to the server was 0 milliseconds ago. The driver has not received any packets from the server. at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method) at sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:39) at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:27) at java.lang.reflect.Constructor.newInstance(Constructor.java:513) at com.mysql.jdbc.Util.handleNewInstance(Util.java:406) at com.mysql.jdbc.SQLError.createCommunicationsException(SQLError.java:1119) at com.mysql.jdbc.ConnectionImpl.createNewIO(ConnectionImpl.java:2257) at com.mysql.jdbc.ConnectionImpl.<init>(ConnectionImpl.java:784) at com.mysql.jdbc.JDBC4Connection.<init>(JDBC4Connection.java:46) at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method) at sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:39) at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:27) at java.lang.reflect.Constructor.newInstance(Constructor.java:513) at com.mysql.jdbc.Util.handleNewInstance(Util.java:406) at com.mysql.jdbc.ConnectionImpl.getInstance(ConnectionImpl.java:354) at com.mysql.jdbc.NonRegisteringDriver.connect(NonRegisteringDriver.java:284) at com.mchange.v2.c3p0.DriverManagerDataSource.getConnection(DriverManagerDataSource.java:119) at com.mchange.v2.c3p0.WrapperConnectionPoolDataSource.getPooledConnection(WrapperConnectionPoolDataSource.java:143) at com.mchange.v2.c3p0.WrapperConnectionPoolDataSource.getPooledConnection(WrapperConnectionPoolDataSource.java:132) at com.mchange.v2.c3p0.impl.C3P0PooledConnectionPoolManager.initializeAutomaticTestTable(C3P0PooledConnectionPoolManager.java:772) at com.mchange.v2.c3p0.impl.C3P0PooledConnectionPoolManager.createPooledConnectionPool(C3P0PooledConnectionPoolManager.java:696) at com.mchange.v2.c3p0.impl.C3P0PooledConnectionPoolManager.getPool(C3P0PooledConnectionPoolManager.java:257) at com.mchange.v2.c3p0.impl.C3P0PooledConnectionPoolManager.getPool(C3P0PooledConnectionPoolManager.java:271) at com.mchange.v2.c3p0.impl.AbstractPoolBackedDataSource.getConnection(AbstractPoolBackedDataSource.java:128) at com.l2jserver.L2DatabaseFactory.<init>(L2DatabaseFactory.java:96) at com.l2jserver.L2DatabaseFactory.getInstance(L2DatabaseFactory.java:207) at com.l2jserver.loginserver.L2LoginServer.<init>(L2LoginServer.java:111) at com.l2jserver.loginserver.L2LoginServer.main(L2LoginServer.java:57)Caused by: com.mysql.jdbc.exceptions.jdbc4.CommunicationsException: Communications link failure The last packet sent successfully to the server was 0 milliseconds ago. The driver has not received any packets from the server. at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method) at sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:39) at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:27) at java.lang.reflect.Constructor.newInstance(Constructor.java:513) at com.mysql.jdbc.Util.handleNewInstance(Util.java:406) at com.mysql.jdbc.SQLError.createCommunicationsException(SQLError.java:1119) at com.mysql.jdbc.MysqlIO.<init>(MysqlIO.java:343) at com.mysql.jdbc.ConnectionImpl.createNewIO(ConnectionImpl.java:2178) ... 21 moreCaused by: java.net.SocketException: Network is unreachable at java.net.PlainSocketImpl.socketConnect(Native Method) at java.net.PlainSocketImpl.doConnect(PlainSocketImpl.java:333) at java.net.PlainSocketImpl.connectToAddress(PlainSocketImpl.java:195) at java.net.PlainSocketImpl.connect(PlainSocketImpl.java:182) at java.net.SocksSocketImpl.connect(SocksSocketImpl.java:366) at java.net.Socket.connect(Socket.java:525) at java.net.Socket.connect(Socket.java:475) at java.net.Socket.<init>(Socket.java:372) at java.net.Socket.<init>(Socket.java:215) at com.mysql.jdbc.StandardSocketFactory.connect(StandardSocketFactory.java:253) at com.mysql.jdbc.MysqlIO.<init>(MysqlIO.java:292) ... 22 more
Edit: nvm, just set 0 value at /etc/sysctl.d/bindv6only.conf
./RegisterGameServer.shError: There was an error while attempting to retrieve the list of currently reg istered GameServers.Reason: Communications link failure The last packet sent successfully to the server was 0 milliseconds ago. The driv er has not received any packets from the server.Exception in thread "main" java.lang.NullPointerException at com.l2jserver.gsregistering.GameServerRegister.<init>(GameServerRegis ter.java:46) at com.l2jserver.gsregistering.BaseGameServerRegister.startCMD(BaseGameS erverRegister.java:279) at com.l2jserver.gsregistering.BaseGameServerRegister.main(BaseGameServe rRegister.java:187) at com.l2jserver.gsregistering.GameServerRegister.main(GameServerRegiste r.java:34)
I am readed lot of topics, as I understanded this trouble of connect to mysql data base. So I checked login "loginserver.properties", but I use valid base(i called it l2j), and create spesial user of mysql "l2jroot" that can connect just from localhost without password. My database server locate on same machine, so all shoud be fine?
I have changed java-code, built l2jlogin.jar, substituted it to newer. I have added several System.out.println(Config.DATABASE_LOGIN), and looked that all fine. All entries reading normally. So one row down I looked interesting row : "GameServerTable.load();"... As I understand this is a list with names of servers....maybe, this list I should especially fill ?
System.out.println("some text in L2DatabaseFactory() Constructor. 1"); /* Test the connection */ _source.getConnection().close(); System.out.println("some text in L2DatabaseFactory() Constructor. 2");
"System.out.println" - this is entry I added. So, I've get this throws exception on commands line :
./RegisterGameServer.sh some text in L2DatabaseFactory() Constructor. 1Error: There was an error while attempting to retrieve the list of currently registered GameServers.Reason: Communications link failure The last packet sent successfully to the server was 0 milliseconds ago. The driver has not received any packets from the server.Exception in thread "main" java.lang.NullPointerException at com.l2jserver.gsregistering.GameServerRegister.<init>(GameServerRegister.java:46) at com.l2jserver.gsregistering.BaseGameServerRegister.startCMD(BaseGameServerRegister.java:279) at com.l2jserver.gsregistering.BaseGameServerRegister.main(BaseGameServerRegister.java:187) at com.l2jserver.gsregistering.GameServerRegister.main(GameServerRegister.java:34)
System.out.println("some text in L2DatabaseFactory() Constructor. 1"); System.out.println("some text in L2DatabaseFactory() Constructor, _source.getConnectionTesterClassName() :"+_source.getConnectionTesterClassName() ); /* Test the connection */ _source.getConnection().close(); System.out.println("some text in L2DatabaseFactory() Constructor. 2");
For my side is very interesting, why developer used :