I have a simple demo console program to debug but surprisingly windbg can't symbols from Microsoft default store.
I do
.reload /f
I get the summary:
************* Symbol Loading Error Summary **************
Module name Error
ConsoleApp PDB not found : cache*
Unable to locate the .pdb file in this location
The system cannot find the file specified : SRV*https://msdl.microsoft.com/download/symbols
The SYMSRV client failed to find a file in the UNC store, or there
is an invalid UNC store (an invalid path or the pingme.txt file is
not present in the root directory), or the file is present in the
symbol server exclusion list.
Symbols file path is
srv*
I was trying to get to work with pdf files of my own application but it can't even find microsoft symbols.
Update
After sorting out other issues, I can reproduce this back. It seems like I was just reading the message wrong. Since the error message was pointing to Microsoft default store, I read it like it didn't find the specified files at Microsoft store...thinking it was not connecting/finding/downloading Microsoft symbols when in fact the major error says it just didn't find my own's application's symbols.
Still, the message is not super clear. For example when I set and add an additional path, says Ok.
0:000> .sympath srv*c:\test\Symbols*https://msdl.microsoft.com/download/symbols;c:\test\hello
DBGHELP: Symbol Search Path: srv*c:\test\symbols*https://msdl.microsoft.com/download/symbols;c:\test\hello
DBGHELP: Symbol Search Path: srv*c:\test\symbols*https://msdl.microsoft.com/download/symbols;c:\test\hello
Symbol search path is: srv*c:\test\Symbols*https://msdl.microsoft.com/download/symbols;c:\test\hello
Expanded Symbol search path is: srv*c:\test\symbols*https://msdl.microsoft.com/download/symbols;c:\test\hello
************* Symbol Path validation summary **************
Response Time (ms) Location
Deferred srv*c:\test\Symbols*https://msdl.microsoft.com/download/symbols
OK c:\test\hello
Now when I .reload /f the symbol loading error summary is this:
************* Symbol Loading Error Summary **************
Module name Error
App The system cannot find the file specified : srv*c:\test\symbols*https://msdl.microsoft.com/download/symbols
The SYMSRV client failed to find a file in the UNC store, or there
is an invalid UNC store (an invalid path or the pingme.txt file is
not present in the root directory), or the file is present in the
symbol server exclusion list.
PDB not found : c:\test\hello\symbols\exe\App.pdb
Unable to locate the .pdb file in this location
I don't know the why unable to load in the path PDB not found : c:\test\hello\symbols\exe\App.pdb?
In the output of your WinDbg session there is
************* Symbol Loading Error Summary **************
Module name Error
ConsoleApp PDB not found : cache*
so there's a module load error for ConsoleApp, which is your application and not a Microsoft application.
Certainly you have not uploaded the symbols of your application to Microsoft, so the symbols cannot be found on https://msdl.microsoft.com/download/symbols.
It seems to me that your application is
either a release build without symbol information at all
a debug build with symbol information but the symbols are not found in the path that is specified within the application
Therefore,
in addition to the Microsoft symbol server (please use .symfix c:\path\to\microsoft-symbols),
make sure you have built PDBs for your application (check your compiler and/or linker settings, depending on the programming language)
add your own symbols to the symbol path (.sympath+ c:\path\to\pdb\).
.reload the symbols
The syntax srv* is documented, but actually I've never seen someone use it in practice, because people want to benefit from symbols stored locally, which increases the performance.
If it still does not work, use !sym noisy and Process Monitor to troubleshoot loading of the symbols. A file name filter for .pdb should help.
The reason for that is
even with !sym noisy, WinDbg does not list all paths where it is actually looking for symbols
the documentation for the symbol load order is incorrect.
The help file says that symbols are loaded in this order
X:\...\symbols\<ext>\<filename>.pdb
X:\...\<ext>\<filename>.pdb
X:\...\<filename>.pdb
But the load order observed by me is
X:\...\<filename>.pdb
X:\...\<ext>\<filename>.pdb
X:\...\symbols\<ext>\<filename>.pdb
what does srv* mean is it all you have got ?
where is the path ?
like say c:\symbols
or f:\mycrap\myuselesssymbols etc etc ?
the path should be something like srv*<your LOCAL DIRECTORY>viz X:\yyyyyy*http://msdl.microsoft.com/download/symbols
you can use .symfix to set a default symbol path prior to .reload /f
Related
In Progress Developer Studio (Eclipse):
How do you set up the project so it won't "compile" (check for errors) in .i (include) files separately?
Now we get a lot of errors because include files can not be run on its own. For example some variables that are used in the .i file are defined in p/w file - that will generate an error.
By default includes are not compiled. The errors shown on include files are caused by other sources (.cls, .p, .w) that failed to compile on that include.
See also : knowledgebase.progress.com/articles/Article/000048421
I have a question, which I'm currently unable to tackle effectively since I'm still unfamiliar with Metro app development. So please bear with me :)
Long story short, I have a large, complex VS2012 Metro app managed+native solution (currently built on Windows 8) into VS2013 targeting Windows 8.1.
I imported the solution into VS2013 (hosted on Windows 8.1), and run the conversion for it and all the sub projects therein. Stuff compile, but it is with the linker that we run into problems. This is an example of the linker errors we get:
error LNK2019: unresolved external symbol __imp___beginthreadex referenced in function <blahblahblah>
error LNK2019: unresolved external symbol __imp___mbsrchr referenced in function <blahblahblah>
error LNK2019: unresolved external symbol _getenv referenced in function <blahblahblah>
error LNK2019: unresolved external symbol __imp___beginthreadex referenced in function <blahblahblah>
error LNK2019: unresolved external symbol __imp___endthreadex referenced in function <blahblahblah>
error LNK2019: unresolved external symbol __imp___mbsrchr referenced in function <blahblahblah>
error LNK2019: unresolved external symbol __imp___mbsnbicmp referenced in function <blahblahblah>
error LNK2019: unresolved external symbol __imp___dupenv_s referenced in function <blahblahblah>
The thing is that for every single symbol that is 'missing', we can see the that the declaration is present in the MS Windows header files supplied with VS2013. Inspecting the references in each sub-project shows that they are referencing the Windows 'core' libs.
Any ideas why this is happening? Thanks.
we can see the that the declaration is present in the MS Windows header files supplied with VS2013. Inspecting the references in each sub-project shows that they are referencing the Windows 'core' libs
It is going to be difficult to diagnose what went wrong with this little information, but it is pretty clear that you are looking in the completely wrong corner for this problem. The missing symbols are not Windows api functions, they are C runtime support functions. They are only used in a C++ project, you've been looking at .NET projects.
So you'll need to focus on the one project that generates these linker errors, it is a C++ project. The linker command that's issued to get it to link to the .lib that has these symbols is completely automagic so there isn't much that can go wrong. The very first thing to do is to force a complete rebuild so it won't use outdated .obj and .lib files that were left over from a previous build in VS2012. Right-click the project and choose Rebuild.
And it is worth taking a look at the .vcxproj file for this project with a text editor (like Notepad) and ensure that the conversion went properly and made the correct changes:
the ToolsVersion property must be changed from "4.0" to "12.0"
the MinimumVisualStudioVersion property must be changed from 11.0 to 12.0
two new properties are added, ApplicationType (Windows Store) and ApplicationTypeRevision (8.1)
every configuration's PlatformToolset property must be changed from v110 to v120
There is a log file in the Debug\projectname.tlog directory named link.read.1.tlog that contains diagnostics, it shows all the .lib files that the linker uses. It must contain this line:
C:\PROGRAM FILES (X86)\MICROSOFT VISUAL STUDIO 12.0\VC\LIB\STORE\VCCORLIBD.LIB
Which is the .lib file that contains these symbols.
I am trying to program the Arudino Nano from Eclipse. It has the same processor as the Uno (Atmega328p). I have had this working before with the Uno, but have since gotten a new hard drive and had to reinstall/reconfigure everything. I am running Fedora 19 with Eclipse Kepler. I am getting an error in the build process that I don't even know where to start looking to solve, and Google hasn't been much help...
Here is the error:
make all
Building target: Arduino_Template.elf
Invoking: AVR C Linker
avr-gcc -Wl,-Map,Arduino_Template.map -mmcu=atmega328p -o "Arduino_Template.elf" ./Analog.o -l/usr/avr
/usr/lib/gcc/avr/4.8.2/../../../../avr/bin/ld: cannot find -l/usr/avr
collect2: error: ld returned 1 exit status
make: *** [Arduino_Template.elf] Error 1
17:29:38 Build Finished (took 124ms)
Has anyone encountered this before? Or does anyone have any suggestions?
Thanks.
The problem could be described like this:
First, the library should be specified only by its name and without the "lib" prefix and the ".a" suffix. The linker (this is where you get the error) will look for the library within the specified in the project paths and will add whatever is necessary to the file library name. So if the library you need is named mystuff it will look for a file named libmystuff.a.
In your case this is specified by the -l/usr/avr which I think could be misconfiguration or you did not copy/paste the entire error output. With the '-l' option you specify the name only, not the entire path to the file.
Second, the path should be specified, in the project configuration, where to look for the libraries, otherwise the linker will look for the library files only within your own project only. Often libraries are part of another project - so you need to adjust the project configuration accordingly.
I had similar problem and this is how I solved it ...
Go to menu Project/Properties. On left - choose "C/C++ Build". On right - choose the tab "Tool Settings". On the tree view choose "AVR C Linker" then "Libraries" sub-item. You are where you may need to make changes.
The list of "Libraries" is where you add libraries names, such as mystuff.
The Libraries Path is where you specify the paths to the libraries. This may look like this: "${workspace_loc:/mystuff/Release}"
The result of this is that the linker will look for this file: /mystuff/Release/libmystuff.a under you workspace root folder.
Hi I'm using MEX in Matlab.
The c code uses boost and a lot of headers are included.
And at first my problem is like this
>>mex readTrackletsMex.cpp
readTrackletsMex.cpp
e:\kitti\tools\devkit\matlab\tracklets.h(7) : fatal error C1083: can not open include file:“boost/serialization/nvp.hpp”: No such file or directory
This is because the include path is not specified. So I copied the headers into "/include/boost/XX" and added "-I" flag.
This time it seems that the compiler cannot find the include path in one of the header file.
>> mex -Iinclude readTrackletsMex.cpp
readTrackletsMex.cpp
include\boost/serialization/nvp.hpp(21) : fatal error C1083: can not open include file:“boost/config.hpp”: No such file or directory
Any idea on this? How do I specify a "global" include path for the compiler?
Thanks for your time.
You could try adding the include paths to the environment variables C_INCLUDE_PATH and CPLUS_INCLUDE_PATH. The other issue may be that you put in -Iinclude, and not -I/include
i have a C++ application compiled with VS 2008 with pdb file enabled. After i tried to use dv command to display local vars, it shows the following message:
Unable to enumerate locals, HRESULT0x80004005
Private symbols (symbols.pri) are required for locals.
Type ".hh dbgerr005" for details.
Note that:
i've run the "dv" command on the
correct frame which has the symbol
file.
i can use "dt" command successfully.
i've included the symbol path
and the pdb file has been loaded
successfully as following:
start end module name
00400000 0043f000 helloworld (private pdb symbols) c:\test...
Does anyone know the cause? Is there any configuration i missed to enable local var watch? Or VS 2008 pdb is not supported by windbg (i'm using the latest windbg version)?
Sorry. i found the windbg has been updated to 6.12 and mine is 6.6. And the issue disappeared after i installed the 6.12.