cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 
djall_ibm
Level 3

How to attach a debugger to an installer?

Hello guys,

we are developing a complex installer which extensively uses custom code and custom plugins. We need to be able to debug the code with a more sophisticated approach than just dropping lines to the console here and then.

Therefore, I would like to ask if there is any way to attach a debugger (like Eclipse debugger) to an installer built by IA.

I have thought about building a Java-only installer and then somehow attach it to eclipse, but am wondering if there is anyone with experience about this topic here in the forum.

Thanks!
Labels (1)
0 Kudos
(3) Replies
pv7721
Level 20

0 Kudos
rnavarette
Level 3

For debugging my custom code through IntelliJ, I use this in the installer:

Project>Config>Additional Installer Arguments (without the quotes):
"-Xdebug -Xnoagent -Djava.compiler=NONE -Xrunjdwp:transport=dt_socket,server=y,suspend=n,address=5005"

Then in my IDE I set up remote debugging on port 5005 of localhost or whichever machine you are running the installer on.

Unfortunately, I've yet to figure out how to get the installer to accept those parameters at the command line, rather than coded into the project. If anyone knows the proper way to do that, please share!
0 Kudos
ksmith1874
Level 2

Thanks for this thread. I have recently inherited a IA2014 project and was needing to get some better debugging than what is offered with the command line debug flags. In order to run the install with remote debugging you can use set the environment variable options with the flags set in rnavarette's reply. This has greatly enhanced my ability to see what is going on with the installer during runtime.
0 Kudos