Search code examples
c++visual-studio-2012visual-studio-2017remote-debugging

How to setup remote debugging


I'm working with Visual Studio 2017. On a remote machine, there is Visual Studio 2012. There I start up msvsmon.exe as administrator, and in the "Tools" menu, I set "No authentication", "Allow any user to debug" (in order to be really sure that I'm not blocked because of permission issues).

On my local PC, I try to setup a debugging session, as follows:

  • Connection Type: Remote (no authentication)
  • Connection Target: Find => MachineName: "<_remote_machine>"

A ping request to "<_remote_machine>" is successful.

However now connections are found, and in the msvsmon.exe debugging monitor, no messages are seen.

What can cause this and how can I solve it?

P.s. I know that there might be mismatches between the 2012 and 2017 versions, but in that case I expect an error message to be shown in the debugging monitor, but as I said there is nothing there.


Solution

  • As mentioned by Jszpilewski, simply copying the "Remote Debugger" directory to the remote machine and launching msvsmon.exe from there is the start of the answer.

    Following point: once the remote debugger is started, it says something like "Msvsmon started a new server named '<Machine_Name:Port>'.

    On the local machine you just need to copy/paste this into the "Connection Target" box => Don't try to use the "Find" button, it's a waste of time.