Arthas Hotfix Application

Search JBoss PID

1
2
$ jcmd 
=> 2133763

Hot fix application

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
1. Enter arthas
$ java -jar arthas-boot.jar 2133763
[arthas@2133763]$ jvm
[arthas@2133763]$ sysprop
[arthas@2133763]$ sysenv
[arthas@2133763]$ dashboard
[arthas@2133763]$ thread -b

2. sc - search class
[arthas@2133763]$ sc -d *SendShipInfoTasklet| grep classLoader
=> classLoaderHash 75faff

3. jad - java decompile
[arthas@2133763]$ jad -c 75faff --source-only xx.yy.frt.tasklet.SendShipInfoTasklet -d /tmp > /tmp/SendShipInfoTasklet.java

4. mc - memory compile
[arthas@2133763]$ mc -c 75faff /tmp/SendShipInfoTasklet.java -d /tmp

5. Or compile outside in IDE and place the class into /tmp
[arthas@2133763]$ redefine -c 75faff /tmp/SendShipInfoTasklet.class