问题
I am trying to start JConsole from the command line using its Main class.
I extracted the contents of jconsole.jar and in the MANIFEST.MF i can see
Main-Class: sun.tools.jconsole.JConsole
So i am trying to run the following command:
java sun.tools.jconsole.JConsole
But i am getting an exception of:
Error: Could not find or load main class sun.tools.jconsole.JConsole
Can anyone spot what am i missing here?
回答1:
Try to launch like this
java -jar jconsole.jar sun.tools.jconsole.JConsole
来源:https://stackoverflow.com/questions/16242547/jconsole-main-class