Jump to content
  • 0

Possible Problem with L2J - Need Help


Question

Posted

Hi guys.After about 2 months of search I didn't find the problem I have with my ping.Server keep crushing.Until I saw this while server was on.The only custom script I use is a scheme buffer.Can anybody help me?Do anybody know what this means :

 

 

javapossibleproblem.png

 

 

Thanks a lot :D

10 answers to this question

Recommended Posts

  • 0
Posted

The problem is the scheme buffer as it accesses the database and not closing the connection each time the buffer is used. Basically each time a player uses the scheme buffer a new connection is opened and never closed, so if the buffer is used 300 times a day that's how many connection are left open.

 

After a short time the server gets overloaded with open connections and crashes.

 

You have to fix the script to close the connection after each use; you can increase the mysql connections but it will only delay the crash a little longer.

  • 0
Posted

The problem is the scheme buffer as it accesses the database and not closing the connection each time the buffer is used. Basically each time a player uses the scheme buffer a new connection is opened and never closed, so if the buffer is used 300 times a day that's how many connection are left open.

 

After a short time the server gets overloaded with open connections and crashes.

 

You have to fix the script to close the connection after each use; you can increase the mysql connections but it will only delay the crash a little longer.

 

Thanks a lot man!But how can I fix the script?I don't have any idea on java :( and scheme buffer is really helpful..Can someone see where is the problem if I upload the script?Please ? ►_◄

 

Scheme Buffer : http://www.mediafire.com/?iqigg3nn14na5n4

  • 0
Posted

What does this mean? Do I need to add it somewhere in my script?

 

Yes. I'm not going to search through the code there because I hate python. But how it works is your connection is created like:

Connection connection = L2DatabaseFactory.getInstance().getConnection();

 

The name won't be exactly the same, but after you're done with your query and you have your results, you need to:

connection.close();

 

How good is your understanding of java/python?

  • 0
Posted

Yes. I'm not going to search through the code there because I hate python. But how it works is your connection is created like:

Connection connection = L2DatabaseFactory.getInstance().getConnection();

 

The name won't be exactly the same, but after you're done with your query and you have your results, you need to:

connection.close();

 

How good is your understanding of java/python?

 

I have never worked with python or java :( but I understand a little...Do I need to replace something or to add something?

  • 0
Posted

I have never worked with python or java :( but I understand a little...Do I need to replace something or to add something?

 

I dunno, I'm not looking through that code.

 

Connections do get closed. There is a timeout, but it is better to close them manually.

 

Eventually, however in the time that there isn't a timeout theres connections being made every time the people go the buffer.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Answer this question...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.



×
×
  • Create New...