Our product generates minidump files in case something goes wrong. We run a symbol server for storing and accessing the debug symbols of our builds such that we get proper stack traces out of the dump files.
Since our product also runs on other operating systems (in particular Linux and OS X), we started to look at Google breakpad. I appears to use minidumps, too and PDB files for storage. However, I wonder:
(How) can I migrate an existing symbol server to Google breakpad so that I don't lose all the existing symbols? I imagine other people did the same move already, maybe there's some common approach to this?
You have a few options:
run dump_syms (this is a tool that processed pdbs into text-based breakpad's .sym format, comes with breakpad) on all pdbs already in the server and then upload them to your breakpad server (there are a couple options, we use socorro). You will also need to keep running it on all new symbols for the builds you care about.
request symbols from the server as they are needed by stack_walker when it is processing an incoming crash (we haven't done that)
periodically look for missing symbols in last number of crashes, see if they are on a symbol server, run them through dump_syms, upload .syms to your crash server then send crashes to reprocessing.
You will need to hit MS symbol servers for system symbols, so you will have to implement one of later options just for that.
We've went with option 3 for system symbols, but implementation heavily depends on the crash server used (we are using socorro crash-stats, not a recommended configuration). There are multiple python implementation of MS symbol server integration around. From stack_walker you will know the name and GUID of the symbol, so you can ignore PE parsing parts.
A catch to be aware of: there is no concept of symbol server on OSX and breakpad crash dumps are useless there. To reconstruct stack trace from OSX crash you will need access to originating system binaries (to run them through dump_syms). This might not always be possible. You will need to manually build a repository of OSX symbols, see also this: https://wiki.mozilla.org/Breakpad:Symbols
Catch #2: Windows is using case insensitive FS (surprise), and sometimes generated pdbs are lowercased by linker for no good reason (while PE-binary using it is still referencing proper case). This creates headaches if your crash server is running on *nix machine. Consider extracting symbol name from PE binary itself instead of relying on pdb file name in this case.
Catch #3: you will still need to run your symbol server for debugging dump files uploaded by breakpad (in case when stack trace is not enough and you want to open dump in visual studio). BP uses symbol server, not replaces it.