0

I am trying to generate a minidump of the postgres.exe when it crashes. I followed the postgres wiki, where it states that this function is already included in the new version of postgres. Only the step is to create a crashdumps folder and give it full permissions to it within the data directory.

I use postgres 13, though, it doesn't seem to work for me. https://wiki.postgresql.org/wiki/Getting_a_stack_trace_of_a_running_PostgreSQL_backend_on_Windows

I tried the following portion of the link above, for a minidump for the random crash.

Using crash dumps to debug random and unpredictable backend crashes

If the crashes appear to be random and you don't know how to trigger them, it's hard to connect a debugger to the problem postgres.exe before it crashes.

In PostgreSQL 9.0 and above there is a crash dump hander included in PostgreSQL. To use it:

  • Create a directory named crashdumps (all lowercase) in the PostgreSQL data directory (as shown by SHOW data_directory; in psql)
  • Give the PostgreSQL user (postgres by default) "full control" of it in the security tab of the folder properties.
  • Run the problem code. You don't need to restart Pg or change any settings.
  • When a backend crashes, a Windows minidump should be created in the crashdumps directory.

is there any other way to generate a minidump for a random crash?

0 Answers0