使用参考
USAGE:
sysprop [-h] [property-name] [property-value]
SUMMARY:
Display, and change all the system properties.
EXAMPLES:
sysprop
sysprop file.encoding
sysprop production.mode true
WIKI:
https://arthas.aliyun.com/doc/sysprop
OPTIONS:
-h, --help this help
<property-name> property name
<property-value> property value
查看所有属性
[arthas@24264]$ sysprop
KEY VALUE
------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
awt.toolkit sun.awt.X11.XToolkit
file.encoding.pkg sun.io
java.specification.version 1.8
sun.cpu.isalist
sun.jnu.encoding UTF-8
java.class.path ./like/target/interaction-like.jar
java.vm.vendor Oracle Corporation
sun.arch.data.model 64
com.alibaba.csp.ahas.shaded.com.ali true
baba.metrics.struct_reporter.init_f
lag
java.vendor.url http://java.oracle.com/
user.timezone Asia/Shanghai
os.name Linux
java.vm.specification.version 1.8
user.country US
sun.java.launcher SUN_STANDARD
sun.boot.library.path /usr/local/jdk1.8.0_161/jre/lib/amd64
sun.java.command ./like/target/interaction-like.jar --spring.profiles.active=fat
sun.cpu.endian little
user.home /home/webuser
user.language en
java.specification.vendor Oracle Corporation
java.home /usr/local/jdk1.8.0_161/jre
file.separator /
line.separator
java.vm.specification.vendor Oracle Corporation
java.specification.name Java Platform API Specification
ahas.version 1.8.4_1.8.7
java.awt.graphicsenv sun.awt.X11GraphicsEnvironment
java.awt.headless true
sun.boot.class.path /usr/local/jdk1.8.0_161/jre/lib/resources.jar:/usr/local/jdk1.8.0_161/jre/lib/rt.jar:/usr/local/jdk1.8.0_161/jre/lib/sunrsasign.jar:/usr/local/jdk1
.8.0_161/jre/lib/jsse.jar:/usr/local/jdk1.8.0_161/jre/lib/jce.jar:/usr/local/jdk1.8.0_161/jre/lib/charsets.jar:/usr/local/jdk1.8.0_161/jre/lib/jfr.
jar:/usr/local/jdk1.8.0_161/jre/classes
java.protocol.handler.pkgs org.springframework.boot.loader
sun.management.compiler HotSpot 64-Bit Tiered Compilers
java.runtime.version 1.8.0_161-b12
user.name webuser
path.separator :
os.version 3.10.0-229.el7.x86_64
java.endorsed.dirs /usr/local/jdk1.8.0_161/jre/lib/endorsed
java.runtime.name Java(TM) SE Runtime Environment
file.encoding UTF-8
spring.beaninfo.ignore true
sun.nio.ch.bugLevel
java.vm.name Java HotSpot(TM) 64-Bit Server VM
jetty.git.hash b1e6b55512e008f7fbdf1cbea4ff8a6446d1073b
java.vendor.url.bug http://bugreport.sun.com/bugreport/
java.io.tmpdir /tmp
com.zaxxer.hikari.pool_number 1
java.version 1.8.0_161
user.dir /home/webuser/middleplatform-interaction
os.arch amd64
PID 24264
java.vm.specification.name Java Virtual Machine Specification
java.awt.printerjob sun.print.PSPrinterJob
app.id 100076
sun.os.patch.level unknown
java.library.path /usr/java/packages/lib/amd64:/usr/lib64:/lib64:/lib:/usr/lib
java.vm.info mixed mode
java.vendor Oracle Corporation
java.vm.version 25.161-b12
java.ext.dirs /usr/local/jdk1.8.0_161/jre/lib/ext:/usr/java/packages/lib/ext
sun.io.unicode.encoding UnicodeLittle
java.class.version 52.0
apollo.meta http://beta.config.csdn.net:8080
查看单个属性
支持通过TAB键自动补全
$ sysprop java.version
java.version=1.8.0_51
修改单个属性
$ sysprop user.country
user.country=US
$ sysprop user.country CN
Successfully changed the system property.
user.country=CN