Thread: Details of Segmentation Fault

Details of Segmentation Fault

From
Steve Horn
Date:
I am trying to get the details of a segmentation fault that I'm encountering when running a function from the pgRouting library.  The log in /var/log/postgresql doesn't give me a lot of detail:

2012-09-09 21:03:36 EDT LOG:  server process (PID 20008) was terminated by signal 11: Segmentation fault
2012-09-09 21:03:36 EDT LOG:  terminating any other active server processes
2012-09-09 21:03:36 EDT WARNING:  terminating connection because of crash of another server process
2012-09-09 21:03:36 EDT DETAIL:  The postmaster has commanded this server process to roll back the current transaction and exit, because another server process exited abnormally and possibly corrupted shared memory.
2012-09-09 21:03:36 EDT HINT:  In a moment you should be able to reconnect to the database and repeat your command.

... etc.

Is there any other place to check that would give me a better idea of what happened?

Thanks!

--
Steve Horn

Re: Details of Segmentation Fault

From
Tom Lane
Date:
Steve Horn <steve@stevehorn.cc> writes:
> I am trying to get the details of a segmentation fault that I'm
> encountering when running a function from the pgRouting library.  The log
> in /var/log/postgresql doesn't give me a lot of detail:

No, it wouldn't.  You should try to get a stack trace.  See
https://wiki.postgresql.org/wiki/Generating_a_stack_trace_of_a_PostgreSQL_backend

            regards, tom lane


Re: Details of Segmentation Fault

From
"Kevin Grittner"
Date:
Steve Horn  wrote:
> I am trying to get the details of a segmentation fault that I'm
> encountering when running a function from the pgRouting library.
> The log in /var/log/postgresql doesn't give me a lot of detail:
>
> 2012-09-09 21:03:36 EDT LOG: server process (PID 20008) was
> terminated by signal 11: Segmentation fault
> 2012-09-09 21:03:36 EDT LOG: terminating any other active server
> processes
> 2012-09-09 21:03:36 EDT WARNING: terminating connection because of
> crash of another server process
> 2012-09-09 21:03:36 EDT DETAIL: The postmaster has commanded this
> server process to roll back the current transaction and exit,
> because another server process exited abnormally and possibly
> corrupted shared memory.
> 2012-09-09 21:03:36 EDT HINT: In a moment you should be able to
> reconnect to the database and repeat your command.
>
> ... etc.
>
> Is there any other place to check that would give me a better idea
> of what happened?

You could try to get a stack trace:

http://wiki.postgresql.org/wiki/Generating_a_stack_trace_of_a_PostgreSQL_backend

Note that people can be more helpful if you include more information,
like your OS and the version of PostgreSQL.

-Kevin


Re: Details of Segmentation Fault

From
Steve Horn
Date:
Ubuntu 12.02, PostgreSQL 9.1

Thanks!

On Mon, Sep 10, 2012 at 8:27 AM, Kevin Grittner <Kevin.Grittner@wicourts.gov> wrote:
Steve Horn  wrote:
> I am trying to get the details of a segmentation fault that I'm
> encountering when running a function from the pgRouting library.
> The log in /var/log/postgresql doesn't give me a lot of detail:
>
> 2012-09-09 21:03:36 EDT LOG: server process (PID 20008) was
> terminated by signal 11: Segmentation fault
> 2012-09-09 21:03:36 EDT LOG: terminating any other active server
> processes
> 2012-09-09 21:03:36 EDT WARNING: terminating connection because of
> crash of another server process
> 2012-09-09 21:03:36 EDT DETAIL: The postmaster has commanded this
> server process to roll back the current transaction and exit,
> because another server process exited abnormally and possibly
> corrupted shared memory.
> 2012-09-09 21:03:36 EDT HINT: In a moment you should be able to
> reconnect to the database and repeat your command.
>
> ... etc.
>
> Is there any other place to check that would give me a better idea
> of what happened?

You could try to get a stack trace:

http://wiki.postgresql.org/wiki/Generating_a_stack_trace_of_a_PostgreSQL_backend

Note that people can be more helpful if you include more information,
like your OS and the version of PostgreSQL.

-Kevin



--
Steve Horn