java - High Perm Generation and Low Old Generation -



java - High Perm Generation and Low Old Generation -

we have increment memory jvm 256m , old generation looks little perm generation quite high 80%. sample info capture via jstat below. high perm generation indicate here?

timestamp s0c s1c s0u s1u ec european union oc ou pc pu ygc ygct fgc fgct gct 173656.0 1152.0 1216.0 864.0 0.0 84928.0 26778.0 174784.0 11967.6 21248.0 17057.8 62 3.653 0 0.000 3.653 173671.0 1152.0 1216.0 864.0 0.0 84928.0 27843.4 174784.0 11967.6 21248.0 17057.8 62 3.653 0 0.000 3.653 173686.1 1152.0 1216.0 864.0 0.0 84928.0 27843.4 174784.0 11967.6 21248.0 17057.8 62 3.653 0 0.000 3.653 173701.1 1152.0 1216.0 864.0 0.0 84928.0 27843.4 174784.0 11967.6 21248.0 17057.8 62 3.653 0 0.000 3.653 173716.0 1152.0 1216.0 864.0 0.0 84928.0 27843.4 174784.0 11967.6 21248.0 17057.8 62 3.653 0 0.000 3.653

samples before restart

timestamp s0c s1c s0u s1u ec european union oc ou pc pu ygc ygct fgc fgct gct 261578.8 0.00 16.89 68.70 8.89 80.74 45 2.551 0 0.000 2.551 261593.8 0.00 16.89 70.97 8.89 80.74 45 2.551 0 0.000 2.551 261608.8 0.00 16.89 72.49 8.89 80.74 45 2.551 0 0.000 2.551 261623.8 0.00 16.89 75.00 8.89 80.74 45 2.551 0 0.000 2.551 261638.8 0.00 16.89 77.76 8.89 80.74 45 2.551 0 0.000 2.551 261653.8 0.00 16.89 80.77 8.89 80.74 45 2.551 0 0.000 2.551 261668.8 0.00 16.89 83.03 8.89 80.74 45 2.551 0 0.000 2.551 261683.8 0.00 16.89 85.29 8.89 80.74 45 2.551 0 0.000 2.551 261698.8 0.00 16.89 87.57 8.89 80.74 45 2.551 0 0.000 2.551 261713.8 0.00 16.89 90.57 8.89 80.74 45 2.551 0 0.000 2.551 261728.8 0.00 16.89 93.35 8.89 80.74 45 2.551 0 0.000 2.551 261743.8 0.00 16.89 95.61 8.89 80.74 45 2.551 0 0.000 2.551 261758.8 0.00 16.89 98.61 8.89 80.74 45 2.551 0 0.000 2.551 261773.8 20.83 0.00 1.36 8.95 80.74 46 2.685 0 0.000 2.685 261788.8 20.83 0.00 4.66 8.95 80.74 46 2.685 0 0.000 2.685 261803.8 20.83 0.00 6.88 8.95 80.74 46 2.685 0 0.000 2.685 261818.8 20.83 0.00 9.67 8.95 80.74 46 2.685 0 0.000 2.685 261833.8 20.83 0.00 10.78 8.95 80.74 46 2.685 0 0.000 2.685 261848.8 20.83 0.00 13.56 8.95 80.74 46 2.685 0 0.000 2.685 261863.9 20.83 0.00 15.78 8.95 80.74 46 2.685 0 0.000 2.685 261878.8 20.83 0.00 19.32 8.95 80.74 46 2.685 0 0.000 2.685 261893.8 20.83 0.00 21.55 8.95 80.74 46 2.685 0 0.000 2.685 261908.8 20.83 0.00 24.33 8.95 80.74 46 2.685 0 0.000 2.685 261923.8 20.83 0.00 27.11 8.95 80.74 46 2.685 0 0.000 2.685 261938.8 20.83 0.00 29.84 8.95 80.74 46 2.685 0 0.000 2.685 261953.8 20.83 0.00 32.06 8.95 80.74 46 2.685 0 0.000 2.685 261968.8 20.83 0.00 34.85 8.95 80.74 46 2.685 0 0.000 2.685 261983.8 20.83 0.00 38.89 8.95 80.74 46 2.685 0 0.000 2.685

samples afte restart

timestamp s0c s1c s0u s1u ec european union oc ou pc pu ygc ygct fgc fgct gct 135.8 0.00 0.00 72.71 0.00 70.88 0 0.000 0 0.000 0.000 150.8 0.00 0.00 76.71 0.00 70.91 0 0.000 0 0.000 0.000 165.8 0.00 0.00 78.71 0.00 70.94 0 0.000 0 0.000 0.000 180.7 0.00 0.00 82.71 0.00 72.79 0 0.000 0 0.000 0.000 195.8 0.00 0.00 84.71 0.00 72.81 0 0.000 0 0.000 0.000 210.8 0.00 0.00 88.71 0.00 72.90 0 0.000 0 0.000 0.000 225.8 0.00 0.00 92.71 0.00 72.93 0 0.000 0 0.000 0.000 240.8 0.00 0.00 94.71 0.00 72.95 0 0.000 0 0.000 0.000 255.8 0.00 0.00 100.00 0.00 73.02 0 0.000 0 0.000 0.000 270.8 0.00 78.72 6.68 0.00 73.49 1 0.286 0 0.000 0.286 285.8 0.00 78.72 10.66 0.00 73.50 1 0.286 0 0.000 0.286 300.8 0.00 78.72 14.32 0.00 73.54 1 0.286 0 0.000 0.286 315.8 0.00 78.72 18.89 0.00 73.57 1 0.286 0 0.000 0.286 330.8 0.00 78.72 24.85 0.00 73.57 1 0.286 0 0.000 0.286 345.8 0.00 78.72 30.18 0.00 76.84 1 0.286 0 0.000 0.286 360.8 0.00 78.72 32.82 0.00 76.86 1 0.286 0 0.000 0.286 375.8 0.00 78.72 36.04 0.00 76.87 1 0.286 0 0.000 0.286 390.8 0.00 78.72 40.00 0.00 76.89 1 0.286 0 0.000 0.286 405.8 0.00 78.72 43.96 0.00 76.91 1 0.286 0 0.000 0.286 420.8 0.00 78.72 46.61 0.00 76.92 1 0.286 0 0.000 0.286 435.8 0.00 78.72 47.63 0.00 76.92 1 0.286 0 0.000 0.286 450.8 0.00 78.72 47.63 0.00 76.92 1 0.286 0 0.000 0.286 465.8 0.00 78.72 47.63 0.00 76.92 1 0.286 0 0.000 0.286 480.8 0.00 78.72 47.63 0.00 76.92 1 0.286 0 0.000 0.286 495.8 0.00 78.72 48.54 0.00 76.93 1 0.286 0 0.000 0.286 510.8 0.00 78.72 48.54 0.00 76.93 1 0.286 0 0.000 0.286 525.8 0.00 78.72 48.54 0.00 76.93 1 0.286 0 0.000 0.286 540.8 0.00 78.72 49.11 0.00 76.93 1 0.286 0 0.000 0.286 555.8 0.00 78.72 49.11 0.00 76.93 1 0.286 0 0.000 0.286 570.8 0.00 78.72 49.11 0.00 76.93 1 0.286 0 0.000 0.286 585.8 0.00 78.72 49.11 0.00 76.93 1 0.286 0 0.000 0.286 600.8 0.00 78.72 49.11 0.00 76.93 1 0.286 0 0.000 0.286 615.8 0.00 78.72 49.11 0.00 76.93 1 0.286 0 0.000 0.286 630.8 0.00 78.72 49.11 0.00 76.93 1 0.286 0 0.000 0.286 645.8 0.00 78.72 49.98 0.00 76.93 1 0.286 0 0.000 0.286 660.8 0.00 78.72 49.98 0.00 76.93 1 0.286 0 0.000 0.286 675.8 0.00 78.72 49.98 0.00 76.93 1 0.286 0 0.000 0.286 690.8 0.00 78.72 49.98 0.00 76.93 1 0.286 0 0.000 0.286 705.8 0.00 78.72 49.98 0.00 76.93 1 0.286 0 0.000 0.286 720.8 0.00 78.72 50.55 0.00 76.93 1 0.286 0 0.000 0.286 735.8 0.00 78.72 51.12 0.00 76.93 1 0.286 0 0.000 0.286 750.8 0.00 78.72 51.12 0.00 76.93 1 0.286 0 0.000 0.286 765.8 0.00 78.72 51.12 0.00 76.93 1 0.286 0 0.000 0.286 780.8 0.00 78.72 51.12 0.00 76.93 1 0.286 0 0.000 0.286 795.8 0.00 78.72 51.12 0.00 76.93 1 0.286 0 0.000 0.286 810.8 0.00 78.72 51.12 0.00 76.93 1 0.286 0 0.000 0.286 825.8 0.00 78.72 51.69 0.00 76.93 1 0.286 0 0.000 0.286 840.8 0.00 78.72 51.69 0.00 76.93 1 0.286 0 0.000 0.286 855.8 0.00 78.72 51.69 0.00 76.93 1 0.286 0 0.000 0.286 870.8 0.00 78.72 51.69 0.00 76.93 1 0.286 0 0.000 0.286 885.8 0.00 78.72 52.26 0.00 76.95 1 0.286 0 0.000 0.286 900.8 0.00 78.72 52.26 0.00 76.95 1 0.286 0 0.000 0.286 915.8 0.00 78.72 53.12 0.00 76.95 1 0.286 0 0.000 0.286 930.8 0.00 78.72 53.69 0.00 76.95 1 0.286 0 0.000 0.286 945.8 0.00 78.72 53.69 0.00 76.95 1 0.286 0 0.000 0.286 960.8 0.00 78.72 53.69 0.00 76.95 1 0.286 0 0.000 0.286 975.8 0.00 78.72 53.69 0.00 76.95 1 0.286 0 0.000 0.286 990.8 0.00 78.72 53.69 0.00 76.95 1 0.286 0 0.000 0.286 1005.8 0.00 78.72 53.69 0.00 76.95 1 0.286 0 0.000 0.286 1020.8 0.00 78.72 53.69 0.00 76.95 1 0.286 0 0.000 0.286 1035.8 0.00 78.72 53.69 0.00 76.95 1 0.286 0 0.000 0.286 1050.8 0.00 78.72 54.27 0.00 76.95 1 0.286 0 0.000 0.286 1065.8 0.00 78.72 54.27 0.00 76.95 1 0.286 0 0.000 0.286 1080.8 0.00 78.72 54.27 0.00 76.95 1 0.286 0 0.000 0.286 1095.8 0.00 78.72 54.27 0.00 76.95 1 0.286 0 0.000 0.286 1110.8 0.00 78.72 55.12 0.00 76.97 1 0.286 0 0.000 0.286 1125.8 0.00 78.72 55.46 0.00 76.97 1 0.286 0 0.000 0.286 1140.8 0.00 78.72 56.03 0.00 76.97 1 0.286 0 0.000 0.286 1155.9 0.00 78.72 56.03 0.00 76.97 1 0.286 0 0.000 0.286 1170.8 0.00 78.72 56.03 0.00 76.97 1 0.286 0 0.000 0.286 1185.9 0.00 78.72 56.03 0.00 76.97 1 0.286 0 0.000 0.286 1200.9 0.00 78.72 56.03 0.00 76.97 1 0.286 0 0.000 0.286 1215.9 0.00 78.72 56.03 0.00 76.97 1 0.286 0 0.000 0.286 1230.9 0.00 78.72 56.03 0.00 76.97 1 0.286 0 0.000 0.286 1245.9 0.00 78.72 56.03 0.00 76.97 1 0.286 0 0.000 0.286 1260.9 0.00 78.72 56.03 0.00 76.97 1 0.286 0 0.000 0.286 1275.9 0.00 78.72 56.03 0.00 76.97 1 0.286 0 0.000 0.286 1290.9 0.00 78.72 56.03 0.00 76.97 1 0.286 0 0.000 0.286 1305.9 0.00 78.72 56.03 0.00 76.97 1 0.286 0 0.000 0.286 1320.9 0.00 78.72 56.03 0.00 76.97 1 0.286 0 0.000 0.286

classes used

import java.io.*; import java.net.*; import java.util.*; import java.util.date; import java.text.*; import java.text.dateformat; import java.text.simpledateformat; import java.io.ioexception; import java.sql.connection; import java.sql.drivermanager; import java.sql.statement; import java.sql.sqlexception; import java.sql.*; import java.util.concurrent.linkedblockingqueue; import javax.mail.message; import javax.mail.messagingexception; import javax.mail.passwordauthentication; import javax.mail.session; import javax.mail.transport; import javax.mail.internet.internetaddress; import javax.mail.internet.mimemessage; import com.jolbox.bonecp.bonecp; import com.jolbox.bonecp.bonecpconfig;

skeleton of codes.

public static void main(string[] args) { new sserver7888(); } sserver7888() { try{ final serversocket serversocketconn = new serversocket(7888); while (true){ try{ socket socketconn1 = serversocketconn.accept(); new thread(new connectionhandler(socketconn1)).start(); } catch(exception e){ e.printstacktrace(system.out); } } } grab (exception e) { e.printstacktrace(system.out); } } class connectionhandler implements runnable { private socket receivedsocketconn1; connectionhandler(socket receivedsocketconn1) { this.receivedsocketconn1=receivedsocketconn1; } public void run() { while ((nextchar=readin1.read()) != -1) { completemessage += (char) nextchar; if (nextchar == '*') { //calling of various function depends on input info completemessage=""; } } } } }

you app running - there nil special here.

in 60 seconds no gc run (neither little nor total gc) it seems minimum number of objects generated, there slight increment in eden space

if application running before (meaning classes loaded) don't have worry permgen space.

otherwise nice if show memory-related scheme parameters.

concerning 2nd , 3rd samples:

the 2nd sample (before restart) shows the application has never run fullgc. means, space objects enough. technically no alter in permgen space, means the application loaded required classes, no new classloading happens.

the 3rd illustration (after restart) shows application loading necessary classes, @ end technically no new classes loaded minutes. not mean, never happen, means app after 20 minutes already loaded required classes. so, no new big increment expected.

although may happen hidden part of application becomes active, , load number of classes, imagine have 5 times more space allocated. also, it finite process, after class loaded, not loaded again.

java garbage-collection jvm jstat

Comments

Popular posts from this blog

web services - java.lang.NoClassDefFoundError: Could not initialize class net.sf.cglib.proxy.Enhancer -

Accessing MATLAB's unicode strings from C -

javascript - mongodb won't find my schema method in nested container -