windows 环境中的 JMX 身份验证文件路径
JMX Authentication files path in windows environment
我正在尝试在 windows 环境中添加 JMX 身份验证。我指的是:http://docs.oracle.com/javase/8/docs/technotes/guides/management/agent.html
我的用例是有 100 个我们通过 jar 分发的奇数桌面客户端。我想将 jmxaccess 和 jmxpassword 文件一起打包。然而,我的初步印象是(根据 oracle 文档)我需要在 JRE_HOME/lib/management 目录中设置密码文件。这对每个用户来说都是非常乏味的。有人可以帮助我理解我们是否可以在 windows 环境中提供自定义路径。 (类似于unix)?
谢谢。
当然,JRE_HOME..路径是默认的。您可以使用像
这样的 CMD 选项
java -Dcom.sun.management.jmxremote.password.file=/location/to/my/file
-Dcom.sun.management.jmxremote.access.file=/location/to/my/file -jar ...
com.sun.management.jmxremote.password.file: Specifies location for password file. If
com.sun.management.jmxremote.authenticate is false, then this property
and the password and access files are ignored. Otherwise, the password
file must exist and be in the valid format. If the password file is
empty or nonexistent, then no access is allowed.
com.sun.management.jmxremote.access.file: Specifies location for the access file. If
com.sun.management.jmxremote.authenticate is false, then this property
and the password and access files are ignored. Otherwise, the access
file must exist and be in the valid format. If the access file is
empty or nonexistent, then no access is allowed.
Source: http://docs.oracle.com/javase/8/docs/technotes/guides/management/agent.html#gdevf
我正在尝试在 windows 环境中添加 JMX 身份验证。我指的是:http://docs.oracle.com/javase/8/docs/technotes/guides/management/agent.html
我的用例是有 100 个我们通过 jar 分发的奇数桌面客户端。我想将 jmxaccess 和 jmxpassword 文件一起打包。然而,我的初步印象是(根据 oracle 文档)我需要在 JRE_HOME/lib/management 目录中设置密码文件。这对每个用户来说都是非常乏味的。有人可以帮助我理解我们是否可以在 windows 环境中提供自定义路径。 (类似于unix)?
谢谢。
当然,JRE_HOME..路径是默认的。您可以使用像
这样的 CMD 选项java -Dcom.sun.management.jmxremote.password.file=/location/to/my/file
-Dcom.sun.management.jmxremote.access.file=/location/to/my/file -jar ...
com.sun.management.jmxremote.password.file: Specifies location for password file. If com.sun.management.jmxremote.authenticate is false, then this property and the password and access files are ignored. Otherwise, the password file must exist and be in the valid format. If the password file is empty or nonexistent, then no access is allowed.
com.sun.management.jmxremote.access.file: Specifies location for the access file. If com.sun.management.jmxremote.authenticate is false, then this property and the password and access files are ignored. Otherwise, the access file must exist and be in the valid format. If the access file is empty or nonexistent, then no access is allowed. Source: http://docs.oracle.com/javase/8/docs/technotes/guides/management/agent.html#gdevf