Mac os开发环境备忘

1.查找JDK安装路径

打开终端,输入/usr/libexec/java_home -v 1.8 其中1.8为JDK版本号

localhost:~ mac$ /usr/libexec/java_home -v 1.8
/Library/Java/JavaVirtualMachines/jdk1.8.0_111.jdk/Contents/Home

2.启动visualVM

切换到JDK所在目录的bin目录下,运行./jvisualvm,其他包含的可用命令如下: 

appletviewer jarsigner javafxpackager jcmd  jhat  jmc  jstack  keytool  policytool schemagen unpack200
    extcheck java  javah  jconsole jinfo  jps  jstat  native2ascii rmic  serialver wsgen
    idlj  javac  javap  jdb  jjs  jrunscript jstatd  orbd  rmid  servertool wsimport
    jar  javadoc  javapackager jdeps  jmap  jsadebugd jvisualvm pack200  rmiregistry tnameserv xjc