Gen Linux segmentation fault stack trace and log file
search cancel

Gen Linux segmentation fault stack trace and log file

book

Article ID: 267631

calendar_today

Updated On: 10-23-2023

Products

Gen Gen - Run Time Distributed Gen - Workstation Toolset Gen - Host Encyclopedia

Issue/Introduction

The Gen 8.6 client/server code runs fine, but a segmentation fault occurred when running the Gen 8.6 batch code.

A batch environment (XI Batch) is typically used for running batch programs. As a troubleshooting measure, the batch program was run through the command line directly to see what was happening which shows the Segmentation fault and core dump:

# ./LMB1
Segmentation fault (core dumped)


How to diagnose the root cause of the segmentation fault?

Environment

Release : 8.63

Resolution

Capture a stack trace and log file as follows:

  1. Find the core file for the failing executable. NOTE for a core file to be created, the ulimit must be set large enough. 
  2. Run the command 'file <core file>' to identify which executable created this file.
  3. Run the command 'gdb <executable> <core file>'
  4. At the db command prompt, type the command 'where' to display the stack trace.
  5. Run the executable again; however, add a  '-t31 as a parameter to create a logfile named 'lg-<executable>-<pid>.log file