0

enter image description here

And when the program exits, there is still a jvm instance, like this: enter image description here

What is the function of the second jvm instance?

zhongwei
  • 325
  • 1
  • 5
  • 15
  • IDEA is itself a Java program. Is that what you mean? – Wander Nauta Nov 27 '15 at 12:50
  • No, when I terminate the left jvm instance after program completed, the IDEA won't exit. So the left jvm instance must not be the IDEA process. – zhongwei Nov 27 '15 at 12:52
  • 1
    I still think it could be an instance of the JVM that IDEA uses. When you right-click the process and go to 'Properties', it'll tell you the path to the executable - does that path happen to be in your IDEA install directory? – Wander Nauta Nov 27 '15 at 12:55
  • No, the two instances are all the same path:jdk8/bin – zhongwei Nov 27 '15 at 12:58
  • Then I don't know. If you really want to know, you could use [Process Explorer](https://technet.microsoft.com/en-us/sysinternals/bb896653?f=255&MSPPError=-2147217396) to find out who started the process and which command-line flags were passed. – Wander Nauta Nov 27 '15 at 13:10
  • 1
    [Process Explorer](https://technet.microsoft.com/en-us/sysinternals/bb896653?f=255&MSPPError=-2147217396) is helpful. I find that the left process is started by IDEA, but not itself. Thank you! – zhongwei Nov 27 '15 at 13:19

1 Answers1

0

Use "jps": http://docs.oracle.com/javase/7/docs/technotes/tools/share/jps.html

> jps -l
5334 scala.tools.nsc.MainGenericRunner
5853 sun.tools.jps.Jps
5838 /home/reza/.i/tools/sbt-0.13.9/bin/sbt-launch.jar

Maybe these questions help you about that: How to execute "jps'' command on Windows 8? and How to set java_home on Windows 7?

Community
  • 1
  • 1
Reza Same'ei
  • 819
  • 8
  • 22