【问题标题】:Java Linux Arm Remote Debugging With Eclipse: "Profiling and debugging agents are not supported in this VM"使用 Eclipse 进行 Java Linux Arm 远程调试:“此 VM 不支持分析和调试代理”
【发布时间】:2014-06-11 01:58:00
【问题描述】:

我是第一届机器人竞赛图书馆团队的一员。我们有一系列工具允许团队使用 eclipse 以及我们自己的自定义 eclipse 插件编写和调试他们的机器人。在此之前,我们仅限于使用自定义版本的 JDK 1.3 在具有内置调试模式的 CRIO 上运行程序。然而,我们现在使用的是 jdk-linux-arm(用于嵌入式 ARM 芯片的 Java 8 版本)。由于 JNI 依赖关系,为了调试我们的程序,它们必须在芯片上远程运行。

我用来在调试模式下运行程序的命令是:

killall java
killall FRCUserProgram
sleep 1
nohup /usr/local/frc/JRE/bin/java -Xdebug -Xrunjdwp:transport=dt_socket,address=8998,server=y -jar FRCUserProgram.jar

但是当我尝试这个时,我得到以下输出:

[sshexec] killall: java: no process killed
[sshexec] Profiling and debugging agents are not supported in this VM
[sshexec] Error: Could not create the Java Virtual Machine.
[sshexec] Error: A fatal exception has occurred. Program will exit.

还有其他方法可以通过eclipse对JDK Linux Arm进行远程调试吗?这必须能够通过启用断点的 eclipse 运行,以及 eclipse 调试提供的所有其他功能。

【问题讨论】:

    标签: java eclipse debugging embedded-linux


    【解决方案1】:

    重建 jvm 以支持使用 jrecreate 进行调试

    jrecreate --dest tmp/JRE_DEBUG/ --profile compact2 --vm client --kee p-debug-info --debug

    查看此链接http://docs.oracle.com/javase/8/embedded/develop-platforms/jrecreate.htm#CACGABAD

    使用以下命令行运行程序:

    java -XX:+UsePerfData -agentlib:jdwp=transport=dt_socket,address=8348,server=y,suspend=y -jar FRCUserProgram.jar

    【讨论】:

      猜你喜欢
      • 2011-08-14
      • 2010-09-27
      • 2021-02-22
      • 2014-01-09
      • 2012-09-04
      • 2023-03-04
      • 2011-11-01
      • 2011-04-22
      • 1970-01-01
      相关资源
      最近更新 更多