I have an issue to run a simple code (Hello World) on Microsoft HPC. The code has a breakpoint. After compiling the code in the debug mode, when I submit the executable to the node ( the one I am using) through IScheduler it doesn't hit the breakpoints, however if I just debug the code directly on the node (the same node I'm on) , it hits the breakpoint. Why it is not hitting when I submit via HPC IScheduler? When I use HPC IScheduler it says "The breakpoint will not currently be hit. No symbols have been loaded for this document."
我有一个问题是在Microsoft HPC上运行一个简单的代码(Hello World)。代码有一个断点。在调试模式下编译代码后,当我通过IScheduler将可执行文件提交到节点(我正在使用的那个)时,它没有命中断点,但是如果我只是直接在节点上调试代码(同一个节点我它正在打破断点。当我通过HPC IScheduler提交时为什么不打?当我使用HPC IScheduler时,它说“断点当前不会被命中。此文档没有加载任何符号。”
1 个解决方案
#1
1
If I understand you correctly; you are running the app in two fashions for testing. One locally without the use of the HPC Cluster (where your environment is located is not relevant to this) and then again with the use of the HPC Cluster. When you run it locally you can debug as breakpoints are hit but when you run it through the HPC Cluster you are unable to hit breakpoints.
如果我理解正确的话;您正在以两种方式运行应用程序进行测试。一个本地不使用HPC群集(您的环境所在的位置与此无关),然后再使用HPC群集。当您在本地运行它时,您可以在命中断点时进行调试,但是当您通过HPC群集运行它时,您将无法命中断点。
The issue is because when you run something through the IScheduler which represents the HPC Cluster (be it a SOA Job running through a Broker or a Command Line or MPI Job), it runs under a different process. The application begins to run under the HPC Worker process. If you were to want to debug the application while it is running through the HPC Cluster on your node you would need to attach to the process it was allocated to (there will be 1 HPC Worker Process for each Task running on that node) just as you would if you were attempting to debug a WebService project, WCF Project, or Windows Service. Assuming you are running only a 1 task job you should be able to keep task manager open to see when this process is spun up to get its PID. Unless you put something like a 25~ second pause in the first line of the code representing the application task I wouldn't think you'd be able to attach to the process fast enough to hit your breakpoint.
问题是因为当您通过代表HPC集群的IScheduler运行某些东西(无论是通过Broker或命令行还是MPI作业运行的SOA作业)时,它都会在不同的进程下运行。应用程序开始在HPC Worker进程下运行。如果您想要在节点上运行HPC群集时调试应用程序,则需要将其附加到分配给它的进程(对于该节点上运行的每个任务,将有1个HPC工作进程)如果您尝试调试WebService项目,WCF项目或Windows服务,您会这样做。假设您只运行1个任务作业,您应该能够保持任务管理器处于打开状态,以查看此进程何时启动以获取其PID。除非你在代表应用程序任务的代码的第一行中放置类似25秒的暂停,否则我认为你不能足够快地连接到进程以达到你的断点。
If you are running HPC 2008 R2 and Visual Studio 2010 you can install the Debugging tools provided by Microsoft here; http://www.microsoft.com/en-us/download/details.aspx?id=21705 please note that these tools will not function in Visual Studio 2012, nor will they function in HPC Pack 2012, I cannot vouch for any versions pre-dating version 2008 R2 as I did not test with those versions.
如果您运行的是HPC 2008 R2和Visual Studio 2010,则可以在此处安装Microsoft提供的调试工具; http://www.microsoft.com/en-us/download/details.aspx?id=21705请注意,这些工具将无法在Visual Studio 2012中运行,也无法在HPC Pack 2012中运行,我无法保证任何版本预先约会版本2008 R2,因为我没有测试这些版本。
During the original HPC Pack 2012 beta Microsoft had mentioned that the current 2008 R2 tools would not function in HPC Pack 2012 but that a new version of those tools would potentially be released with the first Service Pack release of HPC Pack 2012; however I have not seen any information yet on any timetable for it.
在最初的HPC Pack 2012测试版中,Microsoft已经提到当前的2008 R2工具在HPC Pack 2012中不起作用,但这些工具的新版本可能会随HPC Pack 2012的第一个Service Pack版本一起发布;但是我还没有看到任何有关它的时间表的信息。
#1
1
If I understand you correctly; you are running the app in two fashions for testing. One locally without the use of the HPC Cluster (where your environment is located is not relevant to this) and then again with the use of the HPC Cluster. When you run it locally you can debug as breakpoints are hit but when you run it through the HPC Cluster you are unable to hit breakpoints.
如果我理解正确的话;您正在以两种方式运行应用程序进行测试。一个本地不使用HPC群集(您的环境所在的位置与此无关),然后再使用HPC群集。当您在本地运行它时,您可以在命中断点时进行调试,但是当您通过HPC群集运行它时,您将无法命中断点。
The issue is because when you run something through the IScheduler which represents the HPC Cluster (be it a SOA Job running through a Broker or a Command Line or MPI Job), it runs under a different process. The application begins to run under the HPC Worker process. If you were to want to debug the application while it is running through the HPC Cluster on your node you would need to attach to the process it was allocated to (there will be 1 HPC Worker Process for each Task running on that node) just as you would if you were attempting to debug a WebService project, WCF Project, or Windows Service. Assuming you are running only a 1 task job you should be able to keep task manager open to see when this process is spun up to get its PID. Unless you put something like a 25~ second pause in the first line of the code representing the application task I wouldn't think you'd be able to attach to the process fast enough to hit your breakpoint.
问题是因为当您通过代表HPC集群的IScheduler运行某些东西(无论是通过Broker或命令行还是MPI作业运行的SOA作业)时,它都会在不同的进程下运行。应用程序开始在HPC Worker进程下运行。如果您想要在节点上运行HPC群集时调试应用程序,则需要将其附加到分配给它的进程(对于该节点上运行的每个任务,将有1个HPC工作进程)如果您尝试调试WebService项目,WCF项目或Windows服务,您会这样做。假设您只运行1个任务作业,您应该能够保持任务管理器处于打开状态,以查看此进程何时启动以获取其PID。除非你在代表应用程序任务的代码的第一行中放置类似25秒的暂停,否则我认为你不能足够快地连接到进程以达到你的断点。
If you are running HPC 2008 R2 and Visual Studio 2010 you can install the Debugging tools provided by Microsoft here; http://www.microsoft.com/en-us/download/details.aspx?id=21705 please note that these tools will not function in Visual Studio 2012, nor will they function in HPC Pack 2012, I cannot vouch for any versions pre-dating version 2008 R2 as I did not test with those versions.
如果您运行的是HPC 2008 R2和Visual Studio 2010,则可以在此处安装Microsoft提供的调试工具; http://www.microsoft.com/en-us/download/details.aspx?id=21705请注意,这些工具将无法在Visual Studio 2012中运行,也无法在HPC Pack 2012中运行,我无法保证任何版本预先约会版本2008 R2,因为我没有测试这些版本。
During the original HPC Pack 2012 beta Microsoft had mentioned that the current 2008 R2 tools would not function in HPC Pack 2012 but that a new version of those tools would potentially be released with the first Service Pack release of HPC Pack 2012; however I have not seen any information yet on any timetable for it.
在最初的HPC Pack 2012测试版中,Microsoft已经提到当前的2008 R2工具在HPC Pack 2012中不起作用,但这些工具的新版本可能会随HPC Pack 2012的第一个Service Pack版本一起发布;但是我还没有看到任何有关它的时间表的信息。