<divid="app"><!--[--><divclass="theme-container"><!--[--><headerclass="navbar"><divclass="toggle-sidebar-button"title="toggle sidebar"aria-expanded="false"role="button"tabindex="0"><divclass="icon"aria-hidden="true"><span></span><span></span><span></span></div></div><span><ahref="/en/"class=""><!----><spanclass="site-name can-hide">arthas</span></a></span><divclass="navbar-items-wrapper"style=""><!--[--><!--]--><navclass="navbar-items can-hide"><!--[--><divclass="navbar-item"><ahref="/en/"class=""aria-label="HOME"><!--[--><!--]--> HOME <!--[--><!--]--></a></div><divclass="navbar-item"><aclass="external-link"href="/doc/arthas-tutorials.html?language=en&id=arthas-basics"rel="noopener noreferrer"target="_blank"aria-label="ONLINE TUTORIALS"><!--[--><!--]--><span>ONLINE TUTORIALS</span><span><svgclass="external-link-icon"xmlns="http://www.w3.org/2000/svg"aria-hidden="true"focusable="false"x="0px"y="0px"viewbox="0 0 100 100"width="15"height="15"><pathfill="currentColor"d="M18.8,85.1h56l0,0c2.2,0,4-1.8,4-4v-32h-8v28h-48v-48h28v-8h-32l0,0c-2.2,0-4,1.8-4,4v56C14.8,83.3,16.6,85.1,18.8,85.1z"></path><polygonfill="currentColor"points="45.7,48.7 51.3,54.3 77.2,28.5 77.2,37.2 85.2,37.2 85.2,14.9 62.8,14.9 62.8,22.9 71.5,22.9"></polygon></svg><spanclass="external-link-icon-sr-only">open in new window</span></span><!--[--><!--]--></a></div><divclass="navbar-item"><ahref="/en/doc"class="router-link-active"aria-label="DOCS"><!--[--><!--]--> DOCS <!--[--><!--]--></a></div><divclass="navbar-item"><divclass="navbar-dropdown-wrapper"><buttonclass="navbar-dropdown-title"type="button"aria-label="SOLUTIONS"><spanclass="title">SOLUTIONS</span><spanclass="arrow down"></span></button><buttonclass="navbar-dropdown-title-mobile"type="button"aria-label="SOLUTIONS"><spanclass="title">SOLUTIONS</span><spanclass="right arrow"></span></button><ulstyle="display:none;"class="navbar-dropdown"><!--[--><liclass="navbar-dropdown-item"><aclass="external-link"href="https://cn.aliyun.com/product/aliware/mse?spm=arthas.topbar.0.0.0"rel="noopener noreferrer"target="_blank"aria-label="Microservice solutions"><!--[--><!--]--><span>Microservice solutions</span><span><svgclass="external-link-icon"xmlns="http://www.w3.org/2000/svg"aria-hidden="true"focusable="false"x="0px"y="0px"viewbox="0 0 100 100"width="15"height="15"><pathfill="currentColor"d="M18.8,85.1h56l0,0c2.2,0,4-1.8,4-4v-32h-8v28h-48v-48h28v-8h-32l0,0c-2.2,0-4,1.8-4,4v56C14.8,83.3,16.6,85.1,18.8,85.1z"></path><polygonfill="currentColor"points="45.7,48.7 51.3,54.3 77.2,28.5 77.2,37.2 85.2,37.2 85.2,14.9 62.8,14.9 62.8,22.9 71.5,22.9"></polygon></svg><spanclass="external-link-icon-sr-only">open in new window</span></span><!--[--><!--]--></a></li><liclass="navbar-dropdown-item"><aclass="external-link"href="https://www.aliyun.com/aliware/txc?spm=arthas.topbar.0.0.0"rel="noopener noreferrer"target="_blank"aria-label="Distributed transaction solutions"><!--[--><!--]--><span>Distributed transaction solutions</span><span><svgclass="external-link-icon"xmlns="http://www.w3.org/2000/svg"aria-hidden="true"focusable="false"x="0px"y="0px"viewbox="0 0 100 100"width="15"height="15"><pathfill="currentColor"d="M18.8,85.1h56l0,0c2.2,0,4-1.8,4-4v-32h-8v28h-48v-48h28v-8h-32l0,0c-2.2,0-4,1.8-4,4v56C14.8,83.3,16.6,85.1,18.8,85.1z"></path><polygonfill="currentColor"points="45.7,48.7 51.3,54.3 77.2,28.5 77.2,37.2 85.2,37.2 85.2,14.9 62.8,14.9 62.8,22.9 71.5,22.9"></polygon></svg><spanclass="external-link-icon-sr-only">open in new window</span></span><!--[--><!--]--></a></li><liclass="navbar-dropdown-item"><aclass="external-link"href="https://www.aliyun.com/product/ahas?spm=arthas.topbar.0.0.0"rel="noopener noreferrer"target="_blank"aria-label="High-availability solution"><!--[--><!--]--><span>High-availability solution</span><span><svgclass="external-link-icon"xmlns="http://www.w3.org/2000/svg"aria-hidden="true"focusable="false"x="0px"y="0px"viewbox="0 0 100 100"width="15"height="15"><pathfill="currentColor"d="M1
</code></pre><divclass="line-numbers"aria-hidden="true"><divclass="line-number"></div></div></div><p>See more at <ahref="/en/doc/options.html"class="">options</a></p><divclass="custom-container tip"><pclass="custom-container-title">TIP</p><p>To support the jars appended by java.lang.instrument.Instrumentation#appendToBootstrapClassLoaderSearch need to enable unsafe.</p></div><h3id="how-to-view-the-result-in-json-format"tabindex="-1"><aclass="header-anchor"href="#how-to-view-the-result-in-json-format"aria-hidden="true">#</a> How to view the result in <code>json</code> format</h3><divclass="language-bash ext-sh line-numbers-mode"><preclass="language-bash"><code>options json-format <spanclass="token boolean">true</span>
</code></pre><divclass="line-numbers"aria-hidden="true"><divclass="line-number"></div></div></div><p>See more at <ahref="/en/doc/options.html"class="">options</a></p><h3id="can-arthas-trace-native-methods"tabindex="-1"><aclass="header-anchor"href="#can-arthas-trace-native-methods"aria-hidden="true">#</a> Can arthas trace native methods</h3><p>No.</p><h3id="can-arthas-view-the-value-of-a-variable-in-memory"tabindex="-1"><aclass="header-anchor"href="#can-arthas-view-the-value-of-a-variable-in-memory"aria-hidden="true">#</a> Can arthas view the value of a variable in memory?</h3><ol><li>You can use <ahref="/en/doc/vmtool.html"class=""><code>vmtool</code></a> command.</li><li>You can use some tricks to intercept the object with the <ahref="/en/doc/tt.html"class=""><code>tt</code></a> command, or fetch it from a static method.</li></ol><h3id="how-to-filter-method-with-the-same-name"tabindex="-1"><aclass="header-anchor"href="#how-to-filter-method-with-the-same-name"aria-hidden="true">#</a> How to filter method with the same name?</h3><p>You can used all variables in <ahref="/en/doc/advice-class.html"class="">fundamental fields in expressions</a> for the condition express to filter method with the same name, you can use the number of parameters <code>params.length ==1</code>,parameter type <code>params[0] instanceof java.lang.Integer</code>,return value type <code>returnObj instanceof java.util.List</code> and so on in one or more combinations as condition express.</p><p>You can use <code>-v</code> to view the condition express result <ahref="https://github.com/alibaba/arthas/issues/1348"target="_blank"rel="noopener noreferrer">https://github.com/alibaba/arthas/issues/1348<span><svgclass="external-link-icon"xmlns="http://www.w3.org/2000/svg"aria-hidden="true"focusable="false"x="0px"y="0px"viewbox="0 0 100 100"width="15"height="15"><pathfill="currentColor"d="M18.8,85.1h56l0,0c2.2,0,4-1.8,4-4v-32h-8v28h-48v-48h28v-8h-32l0,0c-2.2,0-4,1.8-4,4v56C14.8,83.3,16.6,85.1,18.8,85.1z"></path><polygonfill="currentColor"points="45.7,48.7 51.3,54.3 77.2,28.5 77.2,37.2 85.2,37.2 85.2,14.9 62.8,14.9 62.8,22.9 71.5,22.9"></polygon></svg><spanclass="external-link-icon-sr-only">open in new window</span></span></a></p><p>example <ahref="/en/doc/quick-start.html"class="">math-game</a></p><divclass="language-bash ext-sh line-numbers-mode"><preclass="language-bash"><code><spanclass="token function">watch</span> demo.MathGame primeFactors <spanclass="token string">'{params,returnObj,throwExp}'</span><spanclass="token string">'params.length >0 && returnObj instanceof java.util.List'</span> -v
</code></pre><divclass="line-numbers"aria-hidden="true"><divclass="line-number"></div></div></div><h3id="how-to-watch-or-trace-constructor"tabindex="-1"><aclass="header-anchor"href="#how-to-watch-or-trace-constructor"aria-hidden="true">#</a> How to watch or trace constructor?</h3><divclass="language-bash ext-sh line-numbers-mode"><preclass="language-bash"><code><spanclass="token function">watch</span> demo.MathGame <spanclass="token operator"><</span>init<spanclass="token operator">></span><spanclass="token string">'{params,returnObj,throwExp}'</span> -v
</code></pre><divclass="line-numbers"aria-hidden="true"><divclass="line-number"></div></div></div><h3id="how-to-watch-or-trace-inner-classes"tabindex="-1"><aclass="header-anchor"href="#how-to-watch-or-trace-inner-classes"aria-hidden="true">#</a> How to watch or trace inner classes?</h3><p>In the JVM specification the name of inner classes is <code>OuterClass$InnerClass</code>.</p><divclass="language-bash ext-sh line-numbers-mode"><preclass="language-bash"><code><spanclass="token function">watch</span> OuterClass<spanclass="token variable">$InnerClass</span>
</code></pre><divclass="line-numbers"aria-hidden="true"><divclass="line-number"></div></div></div><h3id="enter-unicode-characters"tabindex="-1"><aclass="header-anchor"href="#enter-unicode-characters"aria-hidden="true">#</a> Enter Unicode characters</h3><p>Convert Unicode characters to <code>\u</code> representation:</p><divclass="language-bash ext-sh line-numbers-mode"><preclass="language-bash"><code>ognl <spanclass="token string">'@java.lang.System@out.println("Hello \u4e2d\u6587")'</span>
</code></pre><divclass="line-numbers"aria-hidden="true"><divclass="line-number"></div></div></div><h3id="java-lang-classformaterror-null-skywalking-arthas-compatible-use"tabindex="-1"><aclass="header-anchor"href="#java-lang-classformaterror-null-skywalking-arthas-compatible-use"aria-hidden="true">#</a> java.lang.ClassFormatError: null, skywalking arthas compatible use</h3><p>When error log appear <code>java.lang.ClassFormatError: null</code>, it is usually modified by other bytecode tools that are not compatible with arthas modified bytecode.</p><p>For example: use skywalking V8.1.0 below <ahref="https://github.com/alibaba/arthas/issues/1141"target="_blank"rel="noopener noreferrer">cannot trace, watch classes enhanced by skywalking agent<span><svgclass="external-link-icon"xmlns="http://www.w3.org/2000/svg"aria-hidden="true"focusable="false"x="0px"y="0px"viewbox="0 0 100 100"width="15"height="15"><pathfill="currentColor"d="M18.8,85.1h56l0,0c2.2,0,4-1.8,4-4v-32h-8v28h-48v-48h28v-8h-32l0,0c-2.2,0-4,1.8-4,4v56C14.8,83.3,16.6,85.1,18.8,85.1z"></path><polygonfill="currentColor"points="45.7,48.7 51.3,54.3 77.2,28.5 77.2,37.2 85.2,37.2 85.2,14.9 62.8,14.9 62.8,22.9 71.5,22.9"></polygon></svg><spanclass="external-link-icon-sr-only">open in new window</span></span></a>, V8.1.0 or above is compatible, refer to skywalking configuration for more details. <ahref="https://github.com/apache/skywalking/blob/master/docs/en/FAQ/Compatible-with-other-javaagent-bytecode-processing.md#"target="_blank"rel="noopener noreferrer">skywalking compatible with other javaagent bytecode processing<span><svgclass="external-link-icon"xmlns="http://www.w3.org/2000/svg"aria-hidden="true"focusable="false"x="0px"y="0px"viewbox="0 0 100 100"width="15"height="15"><pathfill="currentColor"d="M18.8,85.1h56l0,0c2.2,0,4-1.8,4-4v-32h-8v28h-48v-48h28v-8h-32l0,0c-2.2,0-4,1.8-4,4v56C14.8,83.3,16.6,85.1,18.8,85.1z"></path><polygonfill="currentColor"points="45.7,48.7 51.3,54.3 77.2,28.5 77.2,37.2 85.2,37.2 85.2,14.9 62.8,14.9 62.8,22.9 71.5,22.9"></polygon></svg><spanclass="external-link-icon-sr-only">open in new window</span></span></a>.</p><h4id="class-redefinition-failed-attempted-to-change-the-schema-add-remove-fields"tabindex="-1"><aclass="header-anchor"href="#class-redefinition-failed-attempted-to-change-the-schema-add-remove-fields"aria-hidden="true">#</a> class redefinition failed: attempted to change the schema (add/remove fields)</h4><p>Reference: <ahref="https://github.com/alibaba/arthas/issues/2165"target="_blank"rel="noopener noreferrer">https://github.com/alibaba/arthas/issues/2165<span><svgclass="external-link-icon"xmlns="http://www.w3.org/2000/svg"aria-hidden="true"focusable="false"x="0px"y="0px"viewbox="0 0 100 100"width="15"height="15"><pathfill="currentColor"d="M18.8,85.1h56l0,0c2.2,0,4-1.8,4-4v-32h-8v28h-48v-48h28v-8h-32l0,0c-2.2,0-4,1.8-4,4v56C14.8,83.3,16.6,85.1,18.8,85.1z"></path><polygonfill="currentColor"points="45.7,48.7 51.3,54.3 77.2,28.5 77.2,37.2 85.2,37.2 85.2,14.9 62.8,14.9 62.8,22.9 71.5,22.9"></polygon></svg><spanclass="external-link-icon-sr-only">open in new window</span></span></a></p><h3id="can-i-use-arthas-offline"tabindex="-1"><aclass="header-anchor"href="#can-i-use-arthas-offline"aria-hidden="true">#</a> Can I use arthas offline?</h3><p>Yes. Just download the full size package and unzip it, refer to: <ahref="/en/doc/download.html"class="">Download</a>.</p><h3id="attach-the-process-with-pid-1-in-docker-k8s-failed"tabindex="-1"><aclass="header-anchor"href="#attach-the-process-with-pid-1-in-docker-k8s-failed"aria-hidden="true">#</a> Attach the process with pid 1 in docker/k8s failed</h3><p>Reference: <ahref="https://github.com/alibaba/arthas/issues/362#issuecomment-448185416"target="_blank"rel="noopener noreferrer">https://github.com/alibaba/arthas/issues/362#issuecomment-448185416<span><svgclass="external-link-icon"xmlns="http://www.w3.org/2000/svg"aria-hidden="true"focusable="false"x="0px"y="0px"viewbox="0 0 100 100"width="15"height="15"><pathf