mirror of
https://gitee.com/arthas/arthas.git
synced 2024-12-02 04:08:34 +08:00
update doc
This commit is contained in:
parent
421dca08c9
commit
85058adc5d
@ -95,6 +95,53 @@ Arthas支持使用管道对上述命令的结果进行进一步的处理,如`s
|
||||
|
||||
* [以java agent方式启动](agent.md)
|
||||
|
||||
|
||||
## as.sh 和 arthas-boot 技巧
|
||||
|
||||
* 通过`select`功能选择attach的进程。
|
||||
|
||||
正常情况下,每次执行`as.sh`/`arthas-boot.jar`需要选择,或者指定PID。这样会比较麻烦,因为每次启动应用,它的PID会变化。
|
||||
|
||||
比如,已经启动了`arthas-demo.jar`,使用`jps`命令查看:
|
||||
|
||||
```bash
|
||||
$ jps
|
||||
58883 arthas-demo.jar
|
||||
58884 Jps
|
||||
```
|
||||
|
||||
通过`select`参数可以指定进程名字,非常方便。
|
||||
|
||||
```bash
|
||||
$ ./as.sh --select arthas-demo
|
||||
Arthas script version: 3.3.6
|
||||
[INFO] JAVA_HOME: /tmp/java/8.0.222-zulu
|
||||
Arthas home: /Users/admin/.arthas/lib/3.3.6/arthas
|
||||
Calculating attach execution time...
|
||||
Attaching to 59161 using version /Users/admin/.arthas/lib/3.3.6/arthas...
|
||||
|
||||
real 0m0.572s
|
||||
user 0m0.281s
|
||||
sys 0m0.039s
|
||||
Attach success.
|
||||
telnet connecting to arthas server... current timestamp is 1594280799
|
||||
Trying 127.0.0.1...
|
||||
Connected to localhost.
|
||||
Escape character is '^]'.
|
||||
,---. ,------. ,--------.,--. ,--. ,---. ,---.
|
||||
/ O \ | .--. ''--. .--'| '--' | / O \ ' .-'
|
||||
| .-. || '--'.' | | | .--. || .-. |`. `-.
|
||||
| | | || |\ \ | | | | | || | | |.-' |
|
||||
`--' `--'`--' '--' `--' `--' `--'`--' `--'`-----'
|
||||
|
||||
|
||||
wiki https://alibaba.github.io/arthas
|
||||
tutorials https://alibaba.github.io/arthas/arthas-tutorials
|
||||
version 3.3.6
|
||||
pid 58883
|
||||
```
|
||||
|
||||
|
||||
## 用户数据回报
|
||||
|
||||
在`3.1.4`版本后,增加了用户数据回报功能,方便统一做安全或者历史数据统计。
|
||||
|
@ -90,6 +90,52 @@ Arthas supports living inside a browser. The communication between arthas and br
|
||||
|
||||
* [Start as a Java Agent](agent.md)
|
||||
|
||||
|
||||
## as.sh and arthas-boot tips
|
||||
|
||||
* Select the process to be attached via the `select` option.
|
||||
|
||||
Normally, `as.sh`/`arthas-boot.jar` needs to a pid, bacause the pid will change.
|
||||
|
||||
For example, with `arthas-demo.jar` already started, use the `jps` command to see.
|
||||
|
||||
```bash
|
||||
$ jps
|
||||
58883 arthas-demo.jar
|
||||
58884 Jps
|
||||
```
|
||||
|
||||
The `select` option allows you to specify a process name, which is very convenient.
|
||||
|
||||
```bash
|
||||
$ ./as.sh --select arthas-demo
|
||||
Arthas script version: 3.3.6
|
||||
[INFO] JAVA_HOME: /tmp/java/8.0.222-zulu
|
||||
Arthas home: /Users/admin/.arthas/lib/3.3.6/arthas
|
||||
Calculating attach execution time...
|
||||
Attaching to 59161 using version /Users/admin/.arthas/lib/3.3.6/arthas...
|
||||
|
||||
real 0m0.572s
|
||||
user 0m0.281s
|
||||
sys 0m0.039s
|
||||
Attach success.
|
||||
telnet connecting to arthas server... current timestamp is 1594280799
|
||||
Trying 127.0.0.1...
|
||||
Connected to localhost.
|
||||
Escape character is '^]'.
|
||||
,---. ,------. ,--------.,--. ,--. ,---. ,---.
|
||||
/ O \ | .--. ''--. .--'| '--' | / O \ ' .-'
|
||||
| .-. || '--'.' | | | .--. || .-. |`. `-.
|
||||
| | | || |\ \ | | | | | || | | |.-' |
|
||||
`--' `--'`--' '--' `--' `--' `--'`--' `--'`-----'
|
||||
|
||||
|
||||
wiki https://alibaba.github.io/arthas
|
||||
tutorials https://alibaba.github.io/arthas/arthas-tutorials
|
||||
version 3.3.6
|
||||
pid 58883
|
||||
```
|
||||
|
||||
## User data report
|
||||
|
||||
After the `3.1.4` version, arthas support user data report.
|
||||
@ -106,6 +152,3 @@ There is a sample data report in the tunnel server that users can implement on t
|
||||
* [log the output](save-log.md)
|
||||
* [batch](batch-support.md)
|
||||
* [how to use ognl](https://github.com/alibaba/arthas/issues/11)
|
||||
|
||||
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user