Find the answer to your Linux question:
Results 1 to 3 of 3
Hi, I have a process which runs for a while and then due to some unknown reason ends abruptly without giving a core. I tried looking in the logs and ...
  1. #1
    Just Joined!
    Join Date
    Apr 2010
    Posts
    18

    Process abruptly ends without any error or dump

    Hi,

    I have a process which runs for a while and then due to some unknown reason ends abruptly without giving a core. I tried looking in the logs and after watching for a pattern am still not 100% sure of the reason. So I was wondering if there is a way to catch the signal which ends the process and print some values in the handler function. I have called the handler for SIGTERM and SIGABRT functions but none of these are getting triggered. I looked online and did not find any other option. Can you please suggest if tehre is any other signal that can be caught for this unknown abrupt termination.

    Thanks,

  2. #2
    Linux Guru Irithori's Avatar
    Join Date
    May 2009
    Location
    Munich
    Posts
    2,097
    Maybe it hit some limit?
    Disk full or a threshhold from /etc/security/limits.conf is reached?

    Is there a way to increase verbosity of the log or a debug mode?

    One chance may be to run it with
    Code:
    strace -o tracefile <PROCESS>
    and after it crashed, look at the end of that tracefile
    You must always face the curtain with a bow.

  3. #3
    Just Joined!
    Join Date
    Apr 2010
    Posts
    18
    Hi Irithori,

    Thanks for the response.

    I think I fixed the bug. There were 2 things happening..

    1. One of the pts in the code I was attaching to another tasks memory but was not detaching and number of attaches was exceeding the system limit.

    2. There was another internal code calculation error which was leading to access the wrong memory location. This was the main reason for process ending early.

    Since there was no error thrown and because this was happening in one of the many child processes , it was taking quiet some time to troubleshoot.

    I would definitely use strace the next time. I usually use gdb but it is not as effective with fork. Does strace work well in this regard?

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
...