VS.NET C++ Debugger no longer loads DLL symbols when we attach to the host process.

We've notice a problem recently whereby attaching the debugger to our host process no longer allows us to debug our DLLs.

Repro: set a breakpoint in DLL then go to Debug-menu->Processes and attach to the host process.

Result: the DLL's breakpoint is now shown with a ' ' (question mark) in it, indicating that the symbols were not loaded.

This used to work OK, so we are wondering: what has changed Also, how do we fix this



Answer this question

VS.NET C++ Debugger no longer loads DLL symbols when we attach to the host process.

  • Vijay R

    By the way, in VS.NET 2003, Modules Window, clicking on any of the modules and using the right mouse-button menu to reload symbols opens a dialog box which let's you browse to and the select the appropriate pdb file (it defaults to the correct folder), unfortunately selecting the correct pdb makes no difference.

    It's handy being able to verify that the correct pdb file is being used, by explicitly specifying it, like that. However, as this made no difference, it looks like the problem is not caused by the debugger being unable to locate the correct pdb files...so what else could it be


  • Sarath.

    OTP

    redirected from Visual C++ General to Visual Studio Debugger by Bite



  • Matt MacDonald

    Hi Azeem,

    Thanks for the suggestion. It sounds like a v. useful feature, unfortunately we are not permitted to upgrade to VS2005 yet (although we have an MSDN subscription - so it is available to us). Perhaps I should try upgrading a few projects to see if it provides further insight.

    The VS solution was built fresh, with no additional changes (we are familiar with the problems that occur if that isn't the case). I tried adding the path to the pdbs in the project but it made no difference. By the way:

    1. this used to work.

    2. we keep our pdb files in a "pdb"-folder, inside our main "bin"-folder.


  • Tomys

     

    [Thanks for moving this to the appropriate area. ;) ]

    Some more info:

    - Microsoft Development Environment 2003 Version 7.1.3088

    - Microsoft Visual C++ .NET   69586-335-0000007-18989

    -  This problem affects all developers and machines

    - This problem impacts two separate executable projects (which have minimal functionality in common, trace-logging) & their supporting DLLs. 

    - The two projects are built from two separate VS solutions.

    - Built both the executables & DLLs  using: debug win32

    - Debugging on development machines, running Windows XP Professional, latest service packs.

    - As always, Executables & DLLs are deposited into the common bin/debug folder e.g. E:\mynode\bin\debug

    - As always, pdb files are deposited in the common bin/debug/pdb folder e.g. E:\mynode\bin\debug\pdb

    - Executables & DLLs are usually copied to a separate installed area bin-folder for running/testing/debugging e.g. C:\myproduct\bin.  (Although loading DLLs from this folder or from the build node at run-time makes no difference).

    One of the executables concerned is a host for "add ins", consequently this problem effects debugging of all of our run-time loadable add-ins (& we have more than a dozen).

    This started being a problem about 6 months ago but we only just realised that everybody is affected.  I suspect some solution/project setting may have been changed or some Windows patch might have changed something -- just a guess.  I suspect this can be resolved by setting some configuration item somewhere.

     


  • J.Suazo

    Hi,

    The PDB file has to match up with the DLL, otherwise VS will not load the PDB. This means that if you re-built the DLL and deployed it but didn't copy over the new PDB it will not load. Any post-processing of DLL after the build could cause it not to be loaded for the same reason.

    In VS 2005 if you go to modules window and select Load Symbol Information... from conext menu of a module it will list the places it looked for a PDB and why it didn't load a certain PDB. This isn't available in VS 2003 however.

    Azeem Khan

    VS Debugger.


  • Cyrus Chan

    Here is the "Modules" screen:

      SvrHub.exe 00400000-00440000 C:\XXXServer\bin\SvrHub.exe 1 0.00.0.0 [6020] SvrHub.exe: Native 18/01/2007 2:15 PM Symbols loaded.
       7C900000-7C9B0000   2  [6020] SvrHub.exe: Native 04/08/2004 7:56 AM No symbols loaded.
       7C800000-7C8F4000   3  [6020] SvrHub.exe: Native 05/07/2006 10:55 AM No symbols loaded.
       10000000-1003C000   4  [6020] SvrHub.exe: Native 18/01/2007 2:15 PM No symbols loaded.
    *  00320000-0037C000*   5  [6020] SvrHub.exe: Native 18/01/2007 2:15 PM No symbols loaded.
       71AD0000-71AD9000   6  [6020] SvrHub.exe: Native 04/08/2004 7:57 AM No symbols loaded.
       71AB0000-71AC7000   7  [6020] SvrHub.exe: Native 04/08/2004 7:57 AM No symbols loaded.
       77C10000-77C68000   8  [6020] SvrHub.exe: Native 04/08/2004 7:59 AM No symbols loaded.
       71AA0000-71AA8000   9  [6020] SvrHub.exe: Native 04/08/2004 7:57 AM No symbols loaded.
       77DD0000-77E6B000   10  [6020] SvrHub.exe: Native 04/08/2004 7:56 AM No symbols loaded.
       77E70000-77F01000   11  [6020] SvrHub.exe: Native 04/08/2004 7:56 AM No symbols loaded.
       74000000-74056000   12  [6020] SvrHub.exe: Native 04/08/2004 7:56 AM No symbols loaded.
       77F60000-77FD6000   13  [6020] SvrHub.exe: Native 14/09/2006 8:39 AM No symbols loaded.
       77F10000-77F57000   14  [6020] SvrHub.exe: Native 29/12/2005 2:54 AM No symbols loaded.
       77D40000-77DD0000   15  [6020] SvrHub.exe: Native 02/03/2005 6:09 PM No symbols loaded.
       763B0000-763F9000   16  [6020] SvrHub.exe: Native 04/08/2004 7:56 AM No symbols loaded.
       5D090000-5D12A000   17  [6020] SvrHub.exe: Native 25/08/2006 3:45 PM No symbols loaded.
       7C9C0000-7D1D5000   18  [6020] SvrHub.exe: Native 13/07/2006 1:33 PM No symbols loaded.
       774E0000-7761D000   19  [6020] SvrHub.exe: Native 26/07/2005 4:39 AM No symbols loaded.
       77120000-771AC000   20  [6020] SvrHub.exe: Native 04/08/2004 7:57 AM No symbols loaded.
       74320000-7435D000   21  [6020] SvrHub.exe: Native 04/08/2004 7:57 AM No symbols loaded.
       711A0000-711A6000   22  [6020] SvrHub.exe: Native 04/08/2004 7:57 AM No symbols loaded.
       77C00000-77C08000   23  [6020] SvrHub.exe: Native 04/08/2004 7:56 AM No symbols loaded.
       77A80000-77B14000   24  [6020] SvrHub.exe: Native 04/08/2004 7:56 AM No symbols loaded.
       77B20000-77B32000   25  [6020] SvrHub.exe: Native 04/08/2004 7:57 AM No symbols loaded.
    *  00380000-003BF000*   26  [6020] SvrHub.exe: Native 18/01/2007 2:14 PM No symbols loaded.
       02800000-028EC000   27  [6020] SvrHub.exe: Native 23/10/2003 6:11 PM No symbols loaded.
       10200000-10287000   28  [6020] SvrHub.exe: Native 19/03/2003 3:03 AM No symbols loaded.
       7C140000-7C357000   29  [6020] SvrHub.exe: Native 19/03/2003 4:28 AM No symbols loaded.
    *  00440000-0049E000*   30  [6020] SvrHub.exe: Native 18/01/2007 2:15 PM No symbols loaded.
       0A9F0000-0A9F5000   31  [6020] SvrHub.exe: Native 27/11/1996 9:12 AM No symbols loaded.
       773D0000-774D3000   32  [6020] SvrHub.exe: Native 25/08/2006 3:45 PM No symbols loaded.
       20000000-20017000   33  [6020] SvrHub.exe: Native 04/08/2004 7:57 AM No symbols loaded.
       5D360000-5D36E000   34  [6020] SvrHub.exe: Native 19/03/2003 4:44 AM No symbols loaded.
       77B40000-77B62000   35  [6020] SvrHub.exe: Native 04/08/2004 7:56 AM No symbols loaded.
    *  02790000-027F8000*   36  [6020] SvrHub.exe: Native 23/01/2007 3:25 PM No symbols loaded.
    *  03DF0000-03EE1000*   37  [6020] SvrHub.exe: Native 23/01/2007 3:26 PM No symbols loaded.
    *  03EF0000-03F39000*   38  [6020] SvrHub.exe: Native 23/01/2007 3:21 PM No symbols loaded.
       5AD70000-5ADA8000   39  [6020] SvrHub.exe: Native 04/08/2004 7:56 AM No symbols loaded.
    *  04090000-04127000*   40  [6020] SvrHub.exe: Native 23/01/2007 3:26 PM No symbols loaded.
    *  04230000-042F3000*   41  [6020] SvrHub.exe: Native 23/01/2007 3:26 PM No symbols loaded.
    *  04400000-0449C000*   42  [6020] SvrHub.exe: Native 23/01/2007 3:22 PM No symbols loaded.
       63000000-63036000   43  [6020] SvrHub.exe: Native 18/01/2007 1:39 PM No symbols loaded.
    *  045C0000-045FD000*   44  [6020] SvrHub.exe: Native 23/01/2007 3:27 PM No symbols loaded.
       71A50000-71A8F000   45  [6020] SvrHub.exe: Native 04/08/2004 7:59 AM No symbols loaded.
       76F20000-76F47000   46  [6020] SvrHub.exe: Native 26/06/2006 5:37 PM No symbols loaded.
       76FB0000-76FB8000   47  [6020] SvrHub.exe: Native 04/08/2004 7:56 AM No symbols loaded.
       76F60000-76F8C000   48  [6020] SvrHub.exe: Native 04/08/2004 7:56 AM No symbols loaded.
       662B0000-66308000   49  [6020] SvrHub.exe: Native 04/08/2004 7:56 AM No symbols loaded.
       71A90000-71A98000   50  [6020] SvrHub.exe: Native 04/08/2004 7:57 AM No symbols loaded.
       76FD0000-7704F000   51  [6020] SvrHub.exe: Native 26/07/2005 4:39 AM No symbols loaded.
       77050000-77115000   52  [6020] SvrHub.exe: Native 04/08/2004 7:56 AM No symbols loaded.
       765B0000-765D5000   53  [6020] SvrHub.exe: Native 04/08/2004 7:57 AM No symbols loaded.
    *  04E10000-050D5000*   54  [6020] SvrHub.exe: Native 04/08/2004 7:56 AM No symbols loaded.
       73160000-731D7000   55  [6020] SvrHub.exe: Native 04/08/2004 7:57 AM No symbols loaded.
       75350000-75361000   56  [6020] SvrHub.exe: Native 04/08/2004 7:57 AM No symbols loaded.
       4DD00000-4DD81000   57  [6020] SvrHub.exe: Native 04/08/2004 7:59 AM No symbols loaded.
       60E30000-60E47000   58  [6020] SvrHub.exe: Native 04/08/2004 7:57 AM No symbols loaded.
       5B860000-5B8B4000   59  [6020] SvrHub.exe: Native 17/08/2006 12:28 PM No symbols loaded.
       77FE0000-77FF1000   60  [6020] SvrHub.exe: Native 04/08/2004 7:56 AM No symbols loaded.
       76620000-7675C000   61  [6020] SvrHub.exe: Native 26/07/2005 4:39 AM No symbols loaded.
       75130000-75144000   62  [6020] SvrHub.exe: Native 26/07/2005 4:39 AM No symbols loaded.
       750F0000-75103000   63  [6020] SvrHub.exe: Native 01/03/2006 7:42 PM No symbols loaded.
       76D10000-76D21000   64  [6020] SvrHub.exe: Native 04/08/2004 7:56 AM No symbols loaded.
       750B0000-750C2000   65  [6020] SvrHub.exe: Native 04/08/2004 7:56 AM No symbols loaded.
       769C0000-76A73000   66  [6020] SvrHub.exe: Native 04/08/2004 7:56 AM No symbols loaded.
       6D4F0000-6D50B000   67  [6020] SvrHub.exe: Native 04/08/2004 7:56 AM No symbols loaded.
       71F80000-71F84000   68  [6020] SvrHub.exe: Native 04/08/2004 7:56 AM No symbols loaded.
    *  054C0000-05517000*   69  [6020] SvrHub.exe: Native 10/01/2007 11:05 AM No symbols loaded.
    *  05520000-05548000*   70  [6020] SvrHub.exe: Native 10/01/2007 10:43 AM No symbols loaded.
       5F400000-5F4ED000   71  [6020] SvrHub.exe: Native 28/02/2004 12:16 AM No symbols loaded.
    *  05550000-055BC000*   72  [6020] SvrHub.exe: Native 17/02/2004 12:16 PM No symbols loaded.
       10480000-104FE000   73  [6020] SvrHub.exe: Native 29/08/2000 9:09 AM No symbols loaded.
    *  055C0000-055F8000*   74  [6020] SvrHub.exe: Native 10/01/2007 11:05 AM No symbols loaded.
       5F500000-5F5CB000   75  [6020] SvrHub.exe: Native 28/02/2004 12:17 AM No symbols loaded.
       5F700000-5F74A000   76  [6020] SvrHub.exe: Native 28/02/2004 12:17 AM No symbols loaded.
    *  05600000-05642000*   77  [6020] SvrHub.exe: Native 10/01/2007 11:05 AM No symbols loaded.
    *  05650000-05656000*   78  [6020] SvrHub.exe: Native 26/05/2006 4:36 PM No symbols loaded.
    *  05670000-05676000*   79  [6020] SvrHub.exe: Native 26/05/2006 4:36 PM No symbols loaded.
       77C70000-77C93000   80  [6020] SvrHub.exe: Native 04/08/2004 7:59 AM No symbols loaded.
       76D60000-76D79000   81  [6020] SvrHub.exe: Native 19/05/2006 12:59 PM No symbols loaded.
       767A0000-767B3000   82  [6020] SvrHub.exe: Native 04/08/2004 7:56 AM No symbols loaded.
       0A690000-0A739000   83  [6020] SvrHub.exe: Native 23/01/2007 3:26 PM No symbols loaded.
       76FC0000-76FC6000   84  [6020] SvrHub.exe: Native 26/06/2006 5:37 PM No symbols loaded.
    *  057A0000-0589E000*   85  [6020] SvrHub.exe: Native 23/01/2007 3:27 PM No symbols loaded.
    *  058A0000-058E4000*   86  [6020] SvrHub.exe: Native 04/08/2004 7:57 AM No symbols loaded.
       1B000000-1B170000   87  [6020] SvrHub.exe: Native 19/02/2004 3:42 AM No symbols loaded.
       1B5D0000-1B665000   88  [6020] SvrHub.exe: Native 06/05/2004 10:40 PM No symbols loaded.
       5D130000-5D13E000   89  [6020] SvrHub.exe: Native 04/08/2004 7:57 AM No symbols loaded.
       1B2C0000-1B2CD000   90  [6020] SvrHub.exe: Native 09/05/2002 6:09 PM No symbols loaded.
       1B2D0000-1B2F6000   91  [6020] SvrHub.exe: Native 06/05/2004 10:40 PM No symbols loaded.
       5FE80000-5FE9B000   92  [6020] SvrHub.exe: Native 04/08/2004 7:57 AM No symbols loaded.
       74060000-740B1000   93  [6020] SvrHub.exe: Native 04/08/2004 7:57 AM No symbols loaded.
    *  06E30000-06E35000*   94  [6020] SvrHub.exe: Native 04/08/2004 7:57 AM No symbols loaded.
    *  06E80000-06E8F000*   95  [6020] SvrHub.exe: Native 04/08/2004 5:21 AM No symbols loaded.
    *  04950000-049DC000*   96  [6020] SvrHub.exe: Native 23/01/2007 3:23 PM No symbols loaded.
    *  06620000-0669E000*   97  [6020] SvrHub.exe: Native 23/01/2007 3:23 PM No symbols loaded.
    *  066A0000-0671D000*   98  [6020] SvrHub.exe: Native 23/01/2007 3:23 PM No symbols loaded.
    *  06720000-067CC000*   99  [6020] SvrHub.exe: Native 23/01/2007 3:26 PM No symbols loaded.
    *  067D0000-06856000*   100  [6020] SvrHub.exe: Native 18/01/2007 12:21 PM No symbols loaded.
    *  049E0000-04A45000*   101  [6020] SvrHub.exe: Native 23/01/2007 3:23 PM No symbols loaded.
    *  06860000-068CF000*   102  [6020] SvrHub.exe: Native 23/01/2007 3:22 PM No symbols loaded.
    *  068D0000-06964000*   103  [6020] SvrHub.exe: Native 23/01/2007 3:22 PM No symbols loaded.
    *  06970000-06A41000*   104  [6020] SvrHub.exe: Native 23/01/2007 3:22 PM No symbols loaded.
    *  06A50000-06B0C000*   105  [6020] SvrHub.exe: Native 19/03/2003 3:04 AM No symbols loaded.
    *  06B10000-06B93000*   106  [6020] SvrHub.exe: Native 23/01/2007 3:26 PM No symbols loaded.
    *  06BA0000-06C32000*   107  [6020] SvrHub.exe: Native 23/01/2007 3:24 PM No symbols loaded.

     

    Explicitly setting the executable & DLL projects' Configuration Properties->Debugging->Symbol Path ...setting to the path of the symbols files (using  explicit paths or using macros) made no difference.  So why can't the Visual Studio Debugger find the symbols (or why isn't it looking)


  • VS.NET C++ Debugger no longer loads DLL symbols when we attach to the host process.