Problems with GlassFish PermGen Space

0

I have a project that runs a web control system, it has a web service rest for querying and collecting data from mobile devices. It performs perfectly, but the project is still under development. It has happened three times, from the Glassfish crash and display the error message PermGen Space. I command it to restart, but it keeps trying to deploy and nothing. I was able to resolve this the first time by removing the server, adding it again, creating a new domain and creating a new project with this new instance of the server. But if I have to do this every day, HD will be missing and I will not finish the project.

I'm using NetBeans 7.3.1 | JDK 1.7 | Glassfish 4.0

I need to urgently resolve this. If anyone can help, I'll be grateful.

    
asked by anonymous 21.06.2016 / 23:46

1 answer

0

Heap memory problem.

  • In the "domain.xml" file in the

    / glassfish / domain / domain1 / config

  • find:

    <jvm-options>-XX:MaxPermSize=
    

    Assign 256m or 512m value

  • Terminate the Glassfish process through the terminal, eg my wheel nets 8080:

    sudo netstat -npl | grep 8080

  • This should turn out to be something like

    tcp6 0 0 :::8080 :::* LISTEN **3312**/java
    

    Then kill the process:

    kill -9 **3312** (note que 3312 é o numero do processo resultante acima).
    

    Try to raise Glassfish again.

    On Windows I do not know the commands to terminate, but I believe that if you reboot the machine, you can resolve it after hitting the xml file in step 1.

        
    23.06.2016 / 19:38