PermGen space error - Glassfish Server

后端 未结 4 1156
夕颜
夕颜 2020-12-13 00:57

I am running java web application using Hibernate and glassfish Server. I am getting

java.lang.OutOfMemoryError: PermGen space exception when after I d

4条回答
  •  一整个雨季
    2020-12-13 01:09

    To solve this problem ( in linux based os ) do following

    1) increase memory (so that this problem don't come frequently ) by configuring "domain.xml" in

    /glassfish/domain/domain1/config

    search for

    -XX:MaxPermSize=

    set it to higher value eg- 198m or 256m

    2) kill the glassfish process to free the port on which it was running ( in my case it was 8686) open terminal (in linux based os) and type -

    sudo netstat -npl | grep 8686

    this will result in something like..

    tcp6 0 0 :::8686 :::* LISTEN 3452/java

    next use

    kill -9 3452 to kill that process ( 3452 in this case )

    Now try to start glassfish, it should start.

提交回复
热议问题