Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

  • Connect from eclipse Debug Configuration to to KVM host 8787 port for debugging.

How to debug the KVM Agent on 4.2 and RHEL 6.3

kvm agent is running with jsvc tool.

To run the kvm agent in debug mode.

in /etc/init.d/cloudstack-agent
start() method
add -Xrunjdwp:transport=dt_socket,address=8787 after $JSVC.

it will be like $JSVC -Xrunjdwp:transport=dt_socket,address=8787,server=y,suspend=n -cp "$CLASSPATH"

add rule to allow 8787 port in kvm host.

restart the management server. check the port 8787 using netstat -atnp | grep jsvc

connect the debugger from eclipse.