mirror of https://github.com/alibaba/arthas.git
You cannot select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
63 lines
2.0 KiB
Markdown
63 lines
2.0 KiB
Markdown
3 years ago
|
# Arthas Properties
|
||
5 years ago
|
|
||
|
The `arthas.properties` file is in the arthas directory.
|
||
|
|
||
3 years ago
|
- If it is automatically downloaded arthas, the directory is under `~/.arthas/lib/3.x.x/arthas/`
|
||
|
- If it is a downloaded complete package, under the decompression directory of arthas
|
||
5 years ago
|
|
||
|
## Supported configuration items
|
||
|
|
||
3 years ago
|
::: warning
|
||
|
Note that the configuration must be `camel case`, which is different from the `-` style of spring boot. Only the spring boot application supports both `camel case` and `-` style configuration.
|
||
|
:::
|
||
4 years ago
|
|
||
5 years ago
|
```
|
||
|
#arthas.config.overrideAll=true
|
||
|
arthas.telnetPort=3658
|
||
|
arthas.httpPort=8563
|
||
4 years ago
|
arthas.ip=127.0.0.1
|
||
|
|
||
|
# seconds
|
||
|
arthas.sessionTimeout=1800
|
||
5 years ago
|
|
||
4 years ago
|
#arthas.appName=demoapp
|
||
5 years ago
|
#arthas.tunnelServer=ws://127.0.0.1:7777/ws
|
||
|
#arthas.agentId=mmmmmmyiddddd
|
||
|
```
|
||
|
|
||
3 years ago
|
- If the configuration of `arthas.telnetPort` is -1, the telnet port will not be listened. `arthas.httpPort` is similar.
|
||
|
- If you configure `arthas.telnetPort` to 0, then random listen telnet port, you can find the random port log in `~/logs/arthas/arthas.log`. `arthas.httpPort` is similar.
|
||
5 years ago
|
|
||
3 years ago
|
::: tip
|
||
|
If you want to prevent multiple arthas port conflicts on a machine. It can be configured as a random port, or configured as -1, and use arthas through the tunnel server.
|
||
|
:::
|
||
4 years ago
|
|
||
|
### disable specify commands
|
||
|
|
||
3 years ago
|
::: tip
|
||
|
since 3.5.2
|
||
|
:::
|
||
4 years ago
|
|
||
|
Such as configuration:
|
||
|
|
||
|
```
|
||
|
arthas.disabledCommands=stop,dump
|
||
|
```
|
||
|
|
||
|
It can also be configured on the command line: `--disabled-commands stop,dump`.
|
||
|
|
||
3 years ago
|
::: tip
|
||
|
By default, arthas-spring-boot-starter will disable the `stop` command.
|
||
|
:::
|
||
4 years ago
|
|
||
5 years ago
|
## Configured order
|
||
|
|
||
|
The order of configuration is: command line parameters > System Env > System Properties > arthas.properties.
|
||
|
|
||
|
such as:
|
||
|
|
||
3 years ago
|
- `./as.sh --telnet-port 9999` command line configuration will overwrite the default value `arthas.telnetPort=3658` in `arthas.properties`.
|
||
|
- If the application itself sets system properties `arthas.telnetPort=8888`, it will override the default value `arthas.telnetPort=3658` in `arthas.properties`.
|
||
5 years ago
|
|
||
|
If you want `arthas.properties` to have the highest order, you can configure `arthas.config.overrideAll=true`.
|