You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
please check arthas log. if java version >=9 , try to add jvm options when start your process: --add-opens java.base/jdk.internal.perf=ALL-UNNAMED --add-exports java.base/jdk.internal.perf=ALL-UNNAMED
java.lang.IllegalAccessError: class com.taobao.arthas.core.command.monitor200.PerfCounterCommand (in unnamed module @0x22b84315) cannot access class sun.management.counter.perf.PerfInstrumentation (in module java.management) because module java.management does not export sun.management.counter.perf to unnamed module @0x22b84315
at com.taobao.arthas.core.command.monitor200.PerfCounterCommand.getPerfCounters(PerfCounterCommand.java:105)
at com.taobao.arthas.core.command.monitor200.PerfCounterCommand.process(PerfCounterCommand.java:53)
at com.taobao.arthas.core.shell.command.impl.AnnotatedCommandImpl.process(AnnotatedCommandImpl.java:82)
at com.taobao.arthas.core.shell.command.impl.AnnotatedCommandImpl.access$100(AnnotatedCommandImpl.java:18)
at com.taobao.arthas.core.shell.command.impl.AnnotatedCommandImpl$ProcessHandler.handle(AnnotatedCommandImpl.java:111)
at com.taobao.arthas.core.shell.command.impl.AnnotatedCommandImpl$ProcessHandler.handle(AnnotatedCommandImpl.java:108)
at com.taobao.arthas.core.shell.system.impl.ProcessImpl$CommandProcessTask.run(ProcessImpl.java:385)
at java.base/java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:539)
at java.base/java.util.concurrent.FutureTask.run(FutureTask.java:264)
at java.base/java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.run(ScheduledThreadPoolExecutor.java:304)
at java.base/java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1136)
at java.base/java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:635)
at java.base/java.lang.Thread.run(Thread.java:833)
环境信息
重现问题的步骤
perfcounter
期望的结果
正确输出相关结果
实际运行的结果
please check arthas log. if java version >=9 , try to add jvm options when start your process: --add-opens java.base/jdk.internal.perf=ALL-UNNAMED --add-exports java.base/jdk.internal.perf=ALL-UNNAMED
FIX
根据异常信息查看 未导出
sun.management.counter.perf.PerfInstrumentation
使用java --describe-module java.management
得出以下信息所以需要在目标进程启动之前加上
--add-opens java.management/sun.management.counter.perf=ALL-UNNAMED --add-opens java.management/sun.management.counter=ALL-UNNAMED
启动参数 但是在执行完perfcounter
之后并未提示相关信息.The text was updated successfully, but these errors were encountered: