Menu

Marauroa errors,can anyone help me?

Developers
brucelei
2007-03-09
2013-06-06
  • brucelei

    brucelei - 2007-03-09

    I deploy marauroa-1.34 and stendhal-0.57 in my own machine,server and client can run normal,and I can play game too,but sometimes I exit stendhal,the server will show some error info like this:

    ********************************************************************************
    220562 ERROR marauroa.server.game.JDBCTransaction  - rollback failed
    java.sql.SQLException: No operations allowed after connection closed.Connection was implicitly closed due to underlying exception/error:

    ** BEGIN NESTED EXCEPTION **

    com.mysql.jdbc.CommunicationsException
    MESSAGE: Communications link failure due to underlying exception:

    ** BEGIN NESTED EXCEPTION **

    java.net.SocketException
    MESSAGE: Software caused connection abort: recv failed

    STACKTRACE:

    java.net.SocketException: Software caused connection abort: recv failed
            at java.net.SocketInputStream.socketRead0(Native Method)
            at java.net.SocketInputStream.read(Unknown Source)
            at com.mysql.jdbc.util.ReadAheadInputStream.fill(ReadAheadInputStream.java:113)
            at com.mysql.jdbc.util.ReadAheadInputStream.readFromUnderlyingStreamIfNecessary(ReadAheadInputStream.java:160)
            at com.mysql.jdbc.util.ReadAheadInputStream.read(ReadAheadInputStream.java:188)
            at com.mysql.jdbc.MysqlIO.readFully(MysqlIO.java:1902)
            at com.mysql.jdbc.MysqlIO.reuseAndReadPacket(MysqlIO.java:2351)
            at com.mysql.jdbc.MysqlIO.checkErrorPacket(MysqlIO.java:2862)
            at com.mysql.jdbc.MysqlIO.sendCommand(MysqlIO.java:1571)
            at com.mysql.jdbc.MysqlIO.sqlQueryDirect(MysqlIO.java:1666)
            at com.mysql.jdbc.Connection.execSQL(Connection.java:2988)
            at com.mysql.jdbc.Connection.execSQL(Connection.java:2917)
            at com.mysql.jdbc.Statement.execute(Statement.java:529)
            at marauroa.server.game.JDBCTransaction.begin(JDBCTransaction.java:58)
            at marauroa.server.game.PlayerEntryContainer.setRPObject(PlayerEntryContainer.java:772)
            at marauroa.server.game.GameServerManager.processLogoutEvent(GameServerManager.java:325)
            at marauroa.server.game.GameServerManager.run(GameServerManager.java:164)

    ** END NESTED EXCEPTION **

    Last packet sent to the server was 0 ms ago.

    STACKTRACE:

    com.mysql.jdbc.CommunicationsException: Communications link failure due to underlying exception:

    ** BEGIN NESTED EXCEPTION **

    java.net.SocketException
    MESSAGE: Software caused connection abort: recv failed

    STACKTRACE:

    java.net.SocketException: Software caused connection abort: recv failed
            at java.net.SocketInputStream.socketRead0(Native Method)
            at java.net.SocketInputStream.read(Unknown Source)
            at com.mysql.jdbc.util.ReadAheadInputStream.fill(ReadAheadInputStream.java:113)
            at com.mysql.jdbc.util.ReadAheadInputStream.readFromUnderlyingStreamIfNecessary(ReadAheadInputStream.java:160)
            at com.mysql.jdbc.util.ReadAheadInputStream.read(ReadAheadInputStream.java:188)
            at com.mysql.jdbc.MysqlIO.readFully(MysqlIO.java:1902)
            at com.mysql.jdbc.MysqlIO.reuseAndReadPacket(MysqlIO.java:2351)
            at com.mysql.jdbc.MysqlIO.checkErrorPacket(MysqlIO.java:2862)
            at com.mysql.jdbc.MysqlIO.sendCommand(MysqlIO.java:1571)
            at com.mysql.jdbc.MysqlIO.sqlQueryDirect(MysqlIO.java:1666)
            at com.mysql.jdbc.Connection.execSQL(Connection.java:2988)
            at com.mysql.jdbc.Connection.execSQL(Connection.java:2917)
            at com.mysql.jdbc.Statement.execute(Statement.java:529)
            at marauroa.server.game.JDBCTransaction.begin(JDBCTransaction.java:58)
            at marauroa.server.game.PlayerEntryContainer.setRPObject(PlayerEntryContainer.java:772)
            at marauroa.server.game.GameServerManager.processLogoutEvent(GameServerManager.java:325)
            at marauroa.server.game.GameServerManager.run(GameServerManager.java:164)

    ** END NESTED EXCEPTION **

    Last packet sent to the server was 0 ms ago.
            at com.mysql.jdbc.MysqlIO.reuseAndReadPacket(MysqlIO.java:2563)
            at com.mysql.jdbc.MysqlIO.checkErrorPacket(MysqlIO.java:2862)
            at com.mysql.jdbc.MysqlIO.sendCommand(MysqlIO.java:1571)
            at com.mysql.jdbc.MysqlIO.sqlQueryDirect(MysqlIO.java:1666)
            at com.mysql.jdbc.Connection.execSQL(Connection.java:2988)
            at com.mysql.jdbc.Connection.execSQL(Connection.java:2917)
            at com.mysql.jdbc.Statement.execute(Statement.java:529)
            at marauroa.server.game.JDBCTransaction.begin(JDBCTransaction.java:58)
            at marauroa.server.game.PlayerEntryContainer.setRPObject(PlayerEntryContainer.java:772)
            at marauroa.server.game.GameServerManager.processLogoutEvent(GameServerManager.java:325)
            at marauroa.server.game.GameServerManager.run(GameServerManager.java:164)

    ** END NESTED EXCEPTION **

            at com.mysql.jdbc.Connection.checkClosed(Connection.java:1842)
            at com.mysql.jdbc.Connection.rollback(Connection.java:4724)
            at marauroa.server.game.JDBCTransaction.rollback(JDBCTransaction.java:78)
            at marauroa.server.game.PlayerEntryContainer.setRPObject(PlayerEntryContainer.java:795)
            at marauroa.server.game.GameServerManager.processLogoutEvent(GameServerManager.java:325)
            at marauroa.server.game.GameServerManager.run(GameServerManager.java:164)
    220593 WARN  marauroa.server.game.PlayerEntryContainer  - error setting RPObject
    marauroa.server.game.TransactionException: Communications link failure due to underlying exception:

    ** BEGIN NESTED EXCEPTION **

    java.net.SocketException
    MESSAGE: Software caused connection abort: recv failed

    STACKTRACE:

    java.net.SocketException: Software caused connection abort: recv failed
            at java.net.SocketInputStream.socketRead0(Native Method)
            at java.net.SocketInputStream.read(Unknown Source)
            at com.mysql.jdbc.util.ReadAheadInputStream.fill(ReadAheadInputStream.java:113)
            at com.mysql.jdbc.util.ReadAheadInputStream.readFromUnderlyingStreamIfNecessary(ReadAheadInputStream.java:160)
            at com.mysql.jdbc.util.ReadAheadInputStream.read(ReadAheadInputStream.java:188)
            at com.mysql.jdbc.MysqlIO.readFully(MysqlIO.java:1902)
            at com.mysql.jdbc.MysqlIO.reuseAndReadPacket(MysqlIO.java:2351)
            at com.mysql.jdbc.MysqlIO.checkErrorPacket(MysqlIO.java:2862)
            at com.mysql.jdbc.MysqlIO.sendCommand(MysqlIO.java:1571)
            at com.mysql.jdbc.MysqlIO.sqlQueryDirect(MysqlIO.java:1666)
            at com.mysql.jdbc.Connection.execSQL(Connection.java:2988)
            at com.mysql.jdbc.Connection.execSQL(Connection.java:2917)
            at com.mysql.jdbc.Statement.execute(Statement.java:529)
            at marauroa.server.game.JDBCTransaction.begin(JDBCTransaction.java:58)
            at marauroa.server.game.PlayerEntryContainer.setRPObject(PlayerEntryContainer.java:772)
            at marauroa.server.game.GameServerManager.processLogoutEvent(GameServerManager.java:325)
            at marauroa.server.game.GameServerManager.run(GameServerManager.java:164)

    ** END NESTED EXCEPTION **

    Last packet sent to the server was 0 ms ago.
            at marauroa.server.game.JDBCTransaction.begin(JDBCTransaction.java:60)
            at marauroa.server.game.PlayerEntryContainer.setRPObject(PlayerEntryContainer.java:772)
            at marauroa.server.game.GameServerManager.processLogoutEvent(GameServerManager.java:325)
            at marauroa.server.game.GameServerManager.run(GameServerManager.java:164)
    Caused by: com.mysql.jdbc.CommunicationsException: Communications link failure due to underlying exception:

    ** BEGIN NESTED EXCEPTION **

    java.net.SocketException
    MESSAGE: Software caused connection abort: recv failed

    STACKTRACE:

    java.net.SocketException: Software caused connection abort: recv failed
            at java.net.SocketInputStream.socketRead0(Native Method)
            at java.net.SocketInputStream.read(Unknown Source)
            at com.mysql.jdbc.util.ReadAheadInputStream.fill(ReadAheadInputStream.java:113)
            at com.mysql.jdbc.util.ReadAheadInputStream.readFromUnderlyingStreamIfNecessary(ReadAheadInputStream.java:160)
            at com.mysql.jdbc.util.ReadAheadInputStream.read(ReadAheadInputStream.java:188)
            at com.mysql.jdbc.MysqlIO.readFully(MysqlIO.java:1902)
            at com.mysql.jdbc.MysqlIO.reuseAndReadPacket(MysqlIO.java:2351)
            at com.mysql.jdbc.MysqlIO.checkErrorPacket(MysqlIO.java:2862)
            at com.mysql.jdbc.MysqlIO.sendCommand(MysqlIO.java:1571)
            at com.mysql.jdbc.MysqlIO.sqlQueryDirect(MysqlIO.java:1666)
            at com.mysql.jdbc.Connection.execSQL(Connection.java:2988)
            at com.mysql.jdbc.Connection.execSQL(Connection.java:2917)
            at com.mysql.jdbc.Statement.execute(Statement.java:529)
            at marauroa.server.game.JDBCTransaction.begin(JDBCTransaction.java:58)
            at marauroa.server.game.PlayerEntryContainer.setRPObject(PlayerEntryContainer.java:772)
            at marauroa.server.game.GameServerManager.processLogoutEvent(GameServerManager.java:325)
            at marauroa.server.game.GameServerManager.run(GameServerManager.java:164)

    ** END NESTED EXCEPTION **

    Last packet sent to the server was 0 ms ago.
            at com.mysql.jdbc.MysqlIO.reuseAndReadPacket(MysqlIO.java:2563)
            at com.mysql.jdbc.MysqlIO.checkErrorPacket(MysqlIO.java:2862)
            at com.mysql.jdbc.MysqlIO.sendCommand(MysqlIO.java:1571)
            at com.mysql.jdbc.MysqlIO.sqlQueryDirect(MysqlIO.java:1666)
            at com.mysql.jdbc.Connection.execSQL(Connection.java:2988)
            at com.mysql.jdbc.Connection.execSQL(Connection.java:2917)
            at com.mysql.jdbc.Statement.execute(Statement.java:529)
            at marauroa.server.game.JDBCTransaction.begin(JDBCTransaction.java:58)
            ... 3 more
    220609 ERROR marauroa.server.game.GameServerManager  - Exception while storing character
    marauroa.server.game.GenericDatabaseException: marauroa.server.game.TransactionException: Communications link failure due to underlying exception:

    ** BEGIN NESTED EXCEPTION **

    java.net.SocketException
    MESSAGE: Software caused connection abort: recv failed

    STACKTRACE:

    java.net.SocketException: Software caused connection abort: recv failed
            at java.net.SocketInputStream.socketRead0(Native Method)
            at java.net.SocketInputStream.read(Unknown Source)
            at com.mysql.jdbc.util.ReadAheadInputStream.fill(ReadAheadInputStream.java:113)
            at com.mysql.jdbc.util.ReadAheadInputStream.readFromUnderlyingStreamIfNecessary(ReadAheadInputStream.java:160)
            at com.mysql.jdbc.util.ReadAheadInputStream.read(ReadAheadInputStream.java:188)
            at com.mysql.jdbc.MysqlIO.readFully(MysqlIO.java:1902)
            at com.mysql.jdbc.MysqlIO.reuseAndReadPacket(MysqlIO.java:2351)
            at com.mysql.jdbc.MysqlIO.checkErrorPacket(MysqlIO.java:2862)
            at com.mysql.jdbc.MysqlIO.sendCommand(MysqlIO.java:1571)
            at com.mysql.jdbc.MysqlIO.sqlQueryDirect(MysqlIO.java:1666)
            at com.mysql.jdbc.Connection.execSQL(Connection.java:2988)
            at com.mysql.jdbc.Connection.execSQL(Connection.java:2917)
            at com.mysql.jdbc.Statement.execute(Statement.java:529)
            at marauroa.server.game.JDBCTransaction.begin(JDBCTransaction.java:58)
            at marauroa.server.game.PlayerEntryContainer.setRPObject(PlayerEntryContainer.java:772)
            at marauroa.server.game.GameServerManager.processLogoutEvent(GameServerManager.java:325)
            at marauroa.server.game.GameServerManager.run(GameServerManager.java:164)

    ** END NESTED EXCEPTION **

    Last packet sent to the server was 0 ms ago.
            at marauroa.server.game.PlayerEntryContainer.setRPObject(PlayerEntryContainer.java:797)
            at marauroa.server.game.GameServerManager.processLogoutEvent(GameServerManager.java:325)
            at marauroa.server.game.GameServerManager.run(GameServerManager.java:164)
    Caused by: marauroa.server.game.TransactionException: Communications link failure due to underlying exception:

    ** BEGIN NESTED EXCEPTION **

    java.net.SocketException
    MESSAGE: Software caused connection abort: recv failed

    STACKTRACE:

    java.net.SocketException: Software caused connection abort: recv failed
            at java.net.SocketInputStream.socketRead0(Native Method)
            at java.net.SocketInputStream.read(Unknown Source)
            at com.mysql.jdbc.util.ReadAheadInputStream.fill(ReadAheadInputStream.java:113)
            at com.mysql.jdbc.util.ReadAheadInputStream.readFromUnderlyingStreamIfNecessary(ReadAheadInputStream.java:160)
            at com.mysql.jdbc.util.ReadAheadInputStream.read(ReadAheadInputStream.java:188)
            at com.mysql.jdbc.MysqlIO.readFully(MysqlIO.java:1902)
            at com.mysql.jdbc.MysqlIO.reuseAndReadPacket(MysqlIO.java:2351)
            at com.mysql.jdbc.MysqlIO.checkErrorPacket(MysqlIO.java:2862)
            at com.mysql.jdbc.MysqlIO.sendCommand(MysqlIO.java:1571)
            at com.mysql.jdbc.MysqlIO.sqlQueryDirect(MysqlIO.java:1666)
            at com.mysql.jdbc.Connection.execSQL(Connection.java:2988)
            at com.mysql.jdbc.Connection.execSQL(Connection.java:2917)
            at com.mysql.jdbc.Statement.execute(Statement.java:529)
            at marauroa.server.game.JDBCTransaction.begin(JDBCTransaction.java:58)
            at marauroa.server.game.PlayerEntryContainer.setRPObject(PlayerEntryContainer.java:772)
            at marauroa.server.game.GameServerManager.processLogoutEvent(GameServerManager.java:325)
            at marauroa.server.game.GameServerManager.run(GameServerManager.java:164)

    ** END NESTED EXCEPTION **

    Last packet sent to the server was 0 ms ago.
            at marauroa.server.game.JDBCTransaction.begin(JDBCTransaction.java:60)
            at marauroa.server.game.PlayerEntryContainer.setRPObject(PlayerEntryContainer.java:772)
            ... 2 more
    Caused by: com.mysql.jdbc.CommunicationsException: Communications link failure due to underlying exception:

    ** BEGIN NESTED EXCEPTION **

    java.net.SocketException
    MESSAGE: Software caused connection abort: recv failed

    STACKTRACE:

    java.net.SocketException: Software caused connection abort: recv failed
            at java.net.SocketInputStream.socketRead0(Native Method)
            at java.net.SocketInputStream.read(Unknown Source)
            at com.mysql.jdbc.util.ReadAheadInputStream.fill(ReadAheadInputStream.java:113)
            at com.mysql.jdbc.util.ReadAheadInputStream.readFromUnderlyingStreamIfNecessary(ReadAheadInputStream.java:160)
            at com.mysql.jdbc.util.ReadAheadInputStream.read(ReadAheadInputStream.java:188)
            at com.mysql.jdbc.MysqlIO.readFully(MysqlIO.java:1902)
            at com.mysql.jdbc.MysqlIO.reuseAndReadPacket(MysqlIO.java:2351)
            at com.mysql.jdbc.MysqlIO.checkErrorPacket(MysqlIO.java:2862)
            at com.mysql.jdbc.MysqlIO.sendCommand(MysqlIO.java:1571)
            at com.mysql.jdbc.MysqlIO.sqlQueryDirect(MysqlIO.java:1666)
            at com.mysql.jdbc.Connection.execSQL(Connection.java:2988)
            at com.mysql.jdbc.Connection.execSQL(Connection.java:2917)
            at com.mysql.jdbc.Statement.execute(Statement.java:529)
            at marauroa.server.game.JDBCTransaction.begin(JDBCTransaction.java:58)
            at marauroa.server.game.PlayerEntryContainer.setRPObject(PlayerEntryContainer.java:772)
            at marauroa.server.game.GameServerManager.processLogoutEvent(GameServerManager.java:325)
            at marauroa.server.game.GameServerManager.run(GameServerManager.java:164)

    ** END NESTED EXCEPTION **

    Last packet sent to the server was 0 ms ago.
            at com.mysql.jdbc.MysqlIO.reuseAndReadPacket(MysqlIO.java:2563)
            at com.mysql.jdbc.MysqlIO.checkErrorPacket(MysqlIO.java:2862)
            at com.mysql.jdbc.MysqlIO.sendCommand(MysqlIO.java:1571)
            at com.mysql.jdbc.MysqlIO.sqlQueryDirect(MysqlIO.java:1666)
            at com.mysql.jdbc.Connection.execSQL(Connection.java:2988)
            at com.mysql.jdbc.Connection.execSQL(Connection.java:2917)
            at com.mysql.jdbc.Statement.execute(Statement.java:529)
            at marauroa.server.game.JDBCTransaction.begin(JDBCTransaction.java:58)
            ... 3 more
    247703 INFO  marauroa.server.game.Statistics  - Total/Used memory: 56116/44176

    ********************************************************************************

    But these error will not appear everytime I exit stendhal,maybe it's the database's problem,I have deployed the server and client according to the manul doc.
    I have send a mail to arianne_rpg,and I hope get the answer in here,thank you!

     
    • brucelei

      brucelei - 2007-03-09

      I have found the root cause,my mysql config is not proper,I set:
      wait_timeout= 120
      interactive_timeout = 120

      So if player leave in the game over 2 minutes,marauroa will lost the db connection.

      Delete above 2 lines and restart mysql,then it's ok.

      But I have a little doubt,why marauroa depend the mysql's timeout?The default timeout value is 8 hours,then it means player can't leave in the game over 8 hours?

      Continue...

       
      • Miguel Angel Blanch Lardin

        Marauroa *opens* a mysql connection. If the connection is not used in TIMEOUT value, the connection is closed. As I told you server should automatically reopen the connection when that happens.
        I don't think you see the problem with a common value for MySQL timeout, as each five minutes banned ip are loaded from database.

         
      • Miguel Angel Blanch Lardin

        Ok, I reverified your problem and effectively Marauroa reopens the connection to mySQL if it is not valid.
        Just open marauroa and in your mysql run this:

        show processlist;
        kill <processid of marauroa>

        Now connection to database is killed, you will see that marauroa shows you that exception, but just after that, the server should keep working correctly. Give a try if you want.

        Regards,
        Miguel

         
        • brucelei

          brucelei - 2007-03-12

          Hi Miguel!
          I have tested it as you said above.Yes,the server can keep working.

          But I still have a doubt about this:
          #######################################################################
          I don't think you see the problem with a common value for MySQL timeout, as each five minutes banned ip are loaded from database.
          #######################################################################

          I set the mysql:
          wait_timeout= 360

          When I stayed in game over 6 minutes and exit,the marauroa server still shows exception,and player's new state(such as money,position) can't be saved in DB.
          Follow that,I must try login to server twice,then everything will be ok,but the game data of last turn can't see any more:(

           
          • Miguel Angel Blanch Lardin

            Ok, I see.
            Seems that server try database, so it is rejected because connection is closed, so it fails and next time a transaction is retrieved a new connection is created, so yes, you are right, some data may be lost. I report a bug about this.

            Thanks a lot.

             
    • Miguel Angel Blanch Lardin

      ok, great.
      Anyway, as I told you, I will investigate a work around this...

       

Anonymous
Anonymous

Add attachments
Cancel