Java freezing up JSS

dustydorey
Contributor III
Contributor III

Hey has anyone else encountered an issue where every once in a while
java seems to eat up a bunch of available memory and then the JSS will
stop responding? If I go in and kill the java process it just restarts
and everything is good to go, but it's kind of obnoxious, and very
random. It just happened here, and no one was actively using Casper.
In fact we're on spring break so most of the computers that are in our
policies and such are shut off too. I had 0 connections to the casper
share, and java was eating up just over 2GB of Real Memory and I believe
over 5GB of virtual.

Thanks

-Dusty-

Dustin Dorey

Technology Support Cluster Specialist

Independant School District 196

Rosemount-Apple Valley-Eagan Public Schools

dustin.dorey at district196.org

651|423|7971

18 REPLIES 18

OPT
New Contributor

Yes I get this at least once a week. I added 16GB RAM to my Xserve (2 x 2.8GHz Quad-core). I then upped the maximum memory in Tomcat to 8GB. I am running 8.4 on 10.6.8 server.

It went some way to helping (i.e. it no locks up the JSS every day).

Yes I can restart, but it is very annoying.

robb1068
Contributor

I just did my client migration today to a new JSS 8.4 server and was surprised to see that java was holding so much memory (4.26GB out of 12GBs). The server (Xserve, 10.6.8) has about 300MBs of free memory and over 5.5GBs of inactive memory.

Oille, are you restarting the java process through the Activity Monitor or Terminal command? Or do you need to restart Tomcat? Thanks!

OPT
New Contributor

Robb - I normally restart Tomcat to get the JSS working again, and bring the memory allocation back down.

Since my last post I also changed the Tomcat memory settings to minimum 2048MB (and maximum 8192MB).

So far I haven't had any more lock ups but the amount of inactive memory has crept back up so I am expecting one sooner or later...

Zvordauk
New Contributor III
New Contributor III

I'm resurrecting this old post as I am experiencing the same thing on a new 10.8.4 Server running Casper 9.0

I've updated to the latest version of Oracle Java but after about 15 mins all available memory is chewed up and I have to use the JSS Database utility to restart Tomcat.

Any advice? I have 140 iPads to enroll and can't get more than a few done at a time :-(

Zvordauk
New Contributor III
New Contributor III

Just to report back in - I updated to 9.0.1 which was released today and this fixed the problem.

Mladen
New Contributor

I have updated JSS this week from Casper 8.71 to 9.11 and I am experiencing same problem. Java is using all available memory, usually within few minutes after Tomcat is restarted.

Jpmvdr
New Contributor

Updating to Java 7 seems to have fixed the issue for me. We are running V9.11

Mladen
New Contributor

Our JSS is running of 10.6.8 server and latest Java version is Java 6.

Jpcorzo
Contributor

Has anybody found a resolution with this issue ? I'm running 10.6.8 with 8.73 Casper Suite with Java 1.6.0_65 running on it. I have to restart the java service at least twice a day now otherwise all JSS services are frozen. No bueno !

Chris_Hafner
Valued Contributor II

I resolved this issue some time ago by adjusting the max threads and connections in both Java and MySQL. Do you know what your current settings are?

Chris_Hafner
Valued Contributor II

I resolved this issue some time ago by adjusting the max threads and connections in both Java and MySQL. Do you know what your current settings are?

Jpcorzo
Contributor

I just increased our MySQL threads to 300 and it is doing much better. Where do you increase the Java threads ? Thanks for the info

Chris_Hafner
Valued Contributor II

OK! So here's the deal. You need to match threads/connections across both Java and MySQL. If 300 threads seemed to have helped you want to do the following:

Change MySQL Threads to 301 (You need an extra one for MySQL itself). You can do this via the database utility (Now I am assuming that your JSS in on a mac. If not let me know and I'll give you the proper file locations.

•FYI, I am running MySQL version 5.5.34

- Set MySQL to allow 301 incoming threads (300 threads for connections +1 for the MySQL root user) -I also set Max Packet size to 256MB

- Modify /Library/JSS/Tomcat/webapps/ROOT/WEB-INF/xml/DataBase.xml so that <MaxPoolSize>300</MaxPoolSize>

- Modify /Library/JSS/Tomcat/conf/server.xml so that any instance of maxThreads is:
maxThreads="750" (This is 2.5 times the number of maximum connections to Tomcat (300)) Last I checked there are two places in the server.xml file where that will occur.

You will need to restart both tomcat and MySQL after this. Also, you will want to check these files after each and every upgrade to the JSS. Often times, especially if you use the installer package, you will find that the Database Connections will often reset to 90.

apredmore
New Contributor II

Where are those (DataBase.xml & server.xml) files located on an Ubuntu install.

Thank You.

Chris_Hafner
Valued Contributor II

/var/lib/tomcat7/webapps/ROOT/WEB-INF/xml/DataBase.xml

and

/var/lib/tomcat7/conf/server.xml

I think...

tuinte
Contributor III

@Chris_Hafner

I owe you a beer.

Chris_Hafner
Valued Contributor II

Many beers will be handed around to everyone at JNUC! I'd have to pass this one on to Dusty, the one who pointed it to me during my CJA ;-)

MacRae
New Contributor

Fantastic @Chris_Hafner ! this fixed my problem too. JSS is flying now! If you're ever in London, call in for a beer! I owe you one.

Thanks
Andy