问题
I've been looking for a comparable approach as posted here for Windows Server 2003 for starting jvisualvm under system account. But I got the error:
...\jdk1.6.0_24\bin\jvisualvm.exe exited on ... with error code -1073741819.
I found that jvisualvm is using a configuration file:
...\jdk1.6.0_24\lib\visualvm\etc\visualvm.conf
This configuration file contains a default_userdir
property that points to ${HOME}/...
. The system account seems to have issues with ${HOME}
. Changing this parameter and replace ${HOME}
with C:/Temp
makes the above mentioned solution available for Windows Server 2008 R2 as well.
回答1:
The question has the answer in it, but I wanted to summarize the steps.
Note that for me jvisualvm was not printing or logging anything when it failed to start up. I just had to make sure I updated that conf file correctly.
So just follow the steps from: How do you run jvisualvm.exe under the local system account under Windows Server 2003?
and then use this conf tip.
I was now able to see the processes, but I still cannot capture detailed JVM info like thread dumps.
来源:https://stackoverflow.com/questions/8912831/how-do-you-run-jvisualvm-exe-under-the-local-system-account-under-windows-server