SlideShare a Scribd company logo
1 of 41
Download to read offline
Linux
Core Dump Analysis
Dmitry Vostokov
Software Diagnostics Services
Prerequisites
Basic Linux troubleshooting
GDB Commands
We use these boxes to
introduce GDB commands
used in practice exercises
© 2015 Software Diagnostics Services
Training Goals
 Review fundamentals
 Learn how to collect core dumps
 Learn how to analyze core dumps
© 2015 Software Diagnostics Services
Training Principles
 Talk only about what I can show
 Lots of pictures
 Lots of examples
 Original content
© 2015 Software Diagnostics Services
Schedule Summary
Day 1
 Analysis Fundamentals (30 minutes)
 Core dump collection methods (10 minutes)
 Basic Core Memory Dumps (1 hour 20 minutes)
Day 2
 Core Memory Dumps (2 hours)
© 2015 Software Diagnostics Services
Part 1: Fundamentals
© 2015 Software Diagnostics Services
Memory/Kernel/User Space
© 2015 Software Diagnostics Services
Kernel Space
User Space
0000000000000000
00007FFFFFFFFFFF
NULL Pointers
000000000000FFFF
0000000000010000
App/Process/Library
© 2015 Software Diagnostics Services
Kernel Space
User Space (PID 9200)
0000000000010000
00007FFFFFFFFFFF
App0
App0
libc.so
ld.solibc.so
ld.so
Process Memory Dump
GDB Commands
info sharedlibrary
Lists dynamic libraries
maintenance info sections
Lists memory regions
© 2015 Software Diagnostics Services
core
Kernel Space
0000000000010000
00007FFFFFFFFFFF
User Space (PID 9200)
App0
libc.so
ld.so
Lightweight Processes (Threads)
GDB Commands
info threads
Lists threads
thread <n>
Switches between threads
thread apply all bt
Lists stack traces from all
threads
© 2015 Software Diagnostics Services
Kernel Space
User Space (PID 9400)
App1
LWP 9401LWP 9400
libc.so
ld.so
libpthread.so
Thread Stack Raw Data
GDB Commands
x/<n>a <address>
Prints n addresses with
corresponding symbol
mappings if any
© 2015 Software Diagnostics Services
Kernel Space
User Space (PID 9400)
App1
LWP 9401LWP 9400
libc.so
ld.so
libpthread.so
Stack for LWP 9401 (TID)
Stack for LWP 9400 (TID)
Thread Stack Trace
GDB Commands
(gdb) bt
#0 0x00007fe9676bf48d in FunctionD ()
#1 0x00007fe9676bf300 in FunctionC ()
#2 0x00000000004005ca in FunctionB ()
#3 0x00000000004005da in FunctionA ()
© 2015 Software Diagnostics Services
User Stack for LWP 10707
FunctionA
FunctionB
FunctionC
Saves return address
FunctionA+110
Saves return address
FunctionB+220
FunctionD
Saves return address
FunctionC+130
Resumes from address
FunctionA+110
Resumes from address
FunctionB+220
Resumes from address
FunctionC+130
FunctionA()
{
...
FunctionB();
...
}
FunctionB()
{
...
FunctionC();
...
}
FunctionC()
{
...
FunctionD();
...
}
Return address FunctionC+130
0x00007fe9676bf300
Return address FunctionB+220
0x00000000004005ca
Return address FunctionA+110
0x00000000004005da
GDB vs. WinDbg
WinDbg Commands
0:000> kn
00 00007fe9676bf300 Module!FunctionD+offset
01 00000000004005ca Module!FunctionC+130
02 00000000004005da AppA!FunctionB+220
03 0000000000000000 AppA!FunctionA+110
© 2015 Software Diagnostics Services
GDB Commands
(gdb) bt
#0 0x00007fe9676bf48d in FunctionD ()
#1 0x00007fe9676bf300 in FunctionC ()
#2 0x00000000004005ca in FunctionB ()
#3 0x00000000004005da in FunctionA ()
Thread Stack Trace (no symbols)
GDB Commands
(gdb) bt
#0 0x00007fe9676bf48d in FunctionD ()
#1 0x00007fe9676bf300 in FunctionC ()
#2 0x00000000004005ca in ?? ()
#3 0x00000000004005da in ?? ()
© 2015 Software Diagnostics Services
User Stack for LWP 10707
Return address FunctionC+130
0x00007fe9676bf300
Return address
0x00000000004005ca
Return address
0x00000000004005da
Symbol file App.sym
FunctionA 22000 - 23000
FunctionB 32000 - 33000
Exceptions (Access Violation)
GDB Commands
(gdb) x <address>
0x<address>: Cannot access
memory at address 0x<address>
© 2015 Software Diagnostics Services
User Space (PID 3604)
App
Signal 11 (segmentation fault)M
NULL pointer 0x0M
libc.so
ld.so
libpthread.so
Stack for LWP 3605 (TID)
Stack for LWP 3604 (TID)
Exceptions (Runtime)
© 2015 Software Diagnostics Services
User Space (PID 3714)
App
libc.so
ld.so
libpthread.so
Stack for LWP 3715 (TID)
Stack for LWP 3714 (TID)
M
throws exception
Signal 6 (abort)
libstdc++.so
Pattern-Oriented Diagnostic Analysis
Information Collection
(Scripts)
Information Extraction
(Checklists)
Problem Identification
(Patterns)
Problem Resolution
Troubleshooting
Suggestions
Debugging Strategy
Diagnostic Pattern: a common recurrent identifiable problem together with a set of
recommendations and possible solutions to apply in a specific context.
© 2015 Software Diagnostics Services
Diagnostic Analysis Pattern: a common recurrent analysis technique and method
of diagnostic pattern identification in a specific context.
Diagnostic Problem: a set of indicators (symptoms, signs) describing a problem.
Diagnostics Pattern Language: common names of diagnostic and diagnostic analysis
patterns. The same language for any operating system: Windows, Mac OS X, Linux, ...
Part 2: Core Dump Collection
© 2015 Software Diagnostics Services
Enabling Collection
 Temporary for the current user:
$ ulimit -c unlimited
 Permanent for every user except root:
Edit the file: /etc/security/limits.conf
Add or uncomment the line:
* soft core unlimited
To limit root to 1GB add or uncomment this line:
root hard core 1000000
© 2015 Software Diagnostics Services
Generation Methods
 kill (requires ulimit):
$ kill –s SIGQUIT PID
$ kill –s SIGABRT PID
 gcore:
$ gcore PID
© 2015 Software Diagnostics Services
Part 3: Practice Exercises
© 2015 Software Diagnostics Services
Links
 Memory Dumps:
NOT IN THE PUBLIC PREVIEW VERSION
 Exercise Transcripts:
NOT IN THE PUBLIC PREVIEW VERSION
© 2015 Software Diagnostics Services
Exercise 0
 Goal: Install GDB and check if GDB loads a core dump
correctly
 Patterns: Incorrect Stack Trace
 ALCDA-DumpsExercise-A0.pdf
© 2015 Software Diagnostics Services
Process Core Dumps
Exercises A1-A12
© 2015 Software Diagnostics Services
Exercise A1
 Goal: Learn how to list stack traces, disassemble functions,
check their correctness, dump data, get environment
 Patterns: Manual Dump, Stack Trace, Stack Trace
Collection, Annotated Disassembly, Paratext, Not My
Version, Environment Hint
 ALCDA-DumpsExercise-A1.pdf
© 2015 Software Diagnostics Services
Exercise A2D
 Goal: Learn how to identify exceptions, find problem threads
and CPU instructions
 Patterns: NULL Pointer (data), Active Thread
 ALCDA-DumpsExercise-A2D.pdf
© 2015 Software Diagnostics Services
Exercise A2C
 Goal: Learn how to identify exceptions, find problem threads
and CPU instructions
 Patterns: NULL Pointer (code), Active Thread
 ALCDA-DumpsExercise-A2C.pdf
© 2015 Software Diagnostics Services
Exercise A3
 Goal: Learn how to identify spiking threads
 Patterns: Spiking Thread
 ALCDA-DumpsExercise-A3.pdf
© 2015 Software Diagnostics Services
Exercise A4
 Goal: Learn how to identify heap regions and heap
corruption
 Patterns: Heap Corruption
 ALCDA-DumpsExercise-A4.pdf
© 2015 Software Diagnostics Services
Exercise A5
 Goal: Learn how to identify stack corruption
 Patterns: Local Buffer Overflow, Execution Residue
 ALCDA-DumpsExercise-A5.pdf
© 2015 Software Diagnostics Services
Exercise A6
 Goal: Learn how to identify stack overflow, stack boundaries,
reconstruct stack trace
 Patterns: Stack Overflow, Execution Residue
 ALCDA-DumpsExercise-A6.pdf
© 2015 Software Diagnostics Services
Exercise A7
 Goal: Learn how to identify active threads
 Patterns: Divide by Zero, Active Thread
 ALCDA-DumpsExercise-A7.pdf
© 2015 Software Diagnostics Services
Exercise A8
 Goal: Learn how to identify runtime exceptions, past
execution residue and stack traces, identify handled
exceptions
 Patterns: C++ Exception, Execution Residue, Coincidental
Symbolic Information, Handled Exception
 ALCDA-DumpsExercise-A8.pdf
© 2015 Software Diagnostics Services
Exercise A9
 Goal: Learn how to identify heap leaks
 Patterns: Heap Leak, Execution Residue, Module Hint
 ALCDA-DumpsExercise-A9.pdf
© 2015 Software Diagnostics Services
Exercise A10
 Goal: Learn how to identify heap contention wait chains,
synchronization issues, advanced disassembly, dump arrays
 Patterns: Double Free, Heap Contention, Wait Chain,
Critical Region, Self-Diagnosis
 ALCDA-DumpsExercise-A10.pdf
© 2015 Software Diagnostics Services
Exercise A11
 Goal: Learn how to identify synchronization wait chains,
deadlocks, hidden and handled exceptions
 Patterns: Wait Chains, Deadlock, Execution Residue,
Handled Exception
 ALCDA-DumpsExercise-A11.pdf
© 2015 Software Diagnostics Services
Exercise A12
 Goal: Learn how to dump memory for post-processing, get
the list of functions and module variables, load symbols,
inspect arguments and local variables
 Patterns: Module Variable
 ALCDA-DumpsExercise-A12.pdf
© 2015 Software Diagnostics Services
Pattern Links (Linux and GDB)
Active Thread Annotated Disassembly
C++ Exception Coincidental Symbolic Information
Critical Region Deadlock
Divide by Zero Environment Hint
Execution Residue Handled Exception
Heap Contention Heap Corruption
Heap Leak Lateral Damage
Local Buffer Overflow Manual Dump
Module Hint Module Variable
Not My Version NULL Pointer (code)
NULL Pointer (data) Paratext
Self-Diagnosis Spiking Thread
Stack Overflow Stack Trace
Stack Trace Collection Wait Chain
© 2015 Software Diagnostics Services
Resources
 Software Diagnostics Institute
 Pattern-Driven Software Diagnostics
 Pattern-Based Software Diagnostics
 Debugging TV
 Rosetta Stone for Debuggers
 Accelerated Mac OS X Core Dump Analysis
 GDB Pocket Reference
 Memory Dump Analysis Anthology (some articles in volumes 1 and 7 cover GDB)
Forthcoming volume 9 will have additional GDB articles
© 2015 Software Diagnostics Services
Q&A
Please send your feedback using the contact
form on PatternDiagnostics.com
© 2015 Software Diagnostics Services
Thank you for attendance!
© 2015 Software Diagnostics Services

More Related Content

What's hot

Linux Performance Profiling and Monitoring
Linux Performance Profiling and MonitoringLinux Performance Profiling and Monitoring
Linux Performance Profiling and MonitoringGeorg Schönberger
 
LISA2019 Linux Systems Performance
LISA2019 Linux Systems PerformanceLISA2019 Linux Systems Performance
LISA2019 Linux Systems PerformanceBrendan Gregg
 
Kernel_Crash_Dump_Analysis
Kernel_Crash_Dump_AnalysisKernel_Crash_Dump_Analysis
Kernel_Crash_Dump_AnalysisBuland Singh
 
Kernel Recipes 2017: Using Linux perf at Netflix
Kernel Recipes 2017: Using Linux perf at NetflixKernel Recipes 2017: Using Linux perf at Netflix
Kernel Recipes 2017: Using Linux perf at NetflixBrendan Gregg
 
eBPF - Rethinking the Linux Kernel
eBPF - Rethinking the Linux KerneleBPF - Rethinking the Linux Kernel
eBPF - Rethinking the Linux KernelThomas Graf
 
LCU14-410: How to build an Energy Model for your SoC
LCU14-410: How to build an Energy Model for your SoCLCU14-410: How to build an Energy Model for your SoC
LCU14-410: How to build an Energy Model for your SoCLinaro
 
Profiling your Applications using the Linux Perf Tools
Profiling your Applications using the Linux Perf ToolsProfiling your Applications using the Linux Perf Tools
Profiling your Applications using the Linux Perf ToolsemBO_Conference
 
DPDK: Multi Architecture High Performance Packet Processing
DPDK: Multi Architecture High Performance Packet ProcessingDPDK: Multi Architecture High Performance Packet Processing
DPDK: Multi Architecture High Performance Packet ProcessingMichelle Holley
 
LSFMM 2019 BPF Observability
LSFMM 2019 BPF ObservabilityLSFMM 2019 BPF Observability
LSFMM 2019 BPF ObservabilityBrendan Gregg
 
The Linux Block Layer - Built for Fast Storage
The Linux Block Layer - Built for Fast StorageThe Linux Block Layer - Built for Fast Storage
The Linux Block Layer - Built for Fast StorageKernel TLV
 
Building Network Functions with eBPF & BCC
Building Network Functions with eBPF & BCCBuilding Network Functions with eBPF & BCC
Building Network Functions with eBPF & BCCKernel TLV
 
HKG15-107: ACPI Power Management on ARM64 Servers (v2)
HKG15-107: ACPI Power Management on ARM64 Servers (v2)HKG15-107: ACPI Power Management on ARM64 Servers (v2)
HKG15-107: ACPI Power Management on ARM64 Servers (v2)Linaro
 
Security Monitoring with eBPF
Security Monitoring with eBPFSecurity Monitoring with eBPF
Security Monitoring with eBPFAlex Maestretti
 
Linux Performance Analysis: New Tools and Old Secrets
Linux Performance Analysis: New Tools and Old SecretsLinux Performance Analysis: New Tools and Old Secrets
Linux Performance Analysis: New Tools and Old SecretsBrendan Gregg
 
Linux kernel tracing
Linux kernel tracingLinux kernel tracing
Linux kernel tracingViller Hsiao
 
Introduction to eBPF and XDP
Introduction to eBPF and XDPIntroduction to eBPF and XDP
Introduction to eBPF and XDPlcplcp1
 

What's hot (20)

Linux Performance Profiling and Monitoring
Linux Performance Profiling and MonitoringLinux Performance Profiling and Monitoring
Linux Performance Profiling and Monitoring
 
DPDK KNI interface
DPDK KNI interfaceDPDK KNI interface
DPDK KNI interface
 
DPDK In Depth
DPDK In DepthDPDK In Depth
DPDK In Depth
 
LISA2019 Linux Systems Performance
LISA2019 Linux Systems PerformanceLISA2019 Linux Systems Performance
LISA2019 Linux Systems Performance
 
Kernel_Crash_Dump_Analysis
Kernel_Crash_Dump_AnalysisKernel_Crash_Dump_Analysis
Kernel_Crash_Dump_Analysis
 
Kernel Recipes 2017: Using Linux perf at Netflix
Kernel Recipes 2017: Using Linux perf at NetflixKernel Recipes 2017: Using Linux perf at Netflix
Kernel Recipes 2017: Using Linux perf at Netflix
 
Understanding DPDK
Understanding DPDKUnderstanding DPDK
Understanding DPDK
 
eBPF - Rethinking the Linux Kernel
eBPF - Rethinking the Linux KerneleBPF - Rethinking the Linux Kernel
eBPF - Rethinking the Linux Kernel
 
LCU14-410: How to build an Energy Model for your SoC
LCU14-410: How to build an Energy Model for your SoCLCU14-410: How to build an Energy Model for your SoC
LCU14-410: How to build an Energy Model for your SoC
 
Profiling your Applications using the Linux Perf Tools
Profiling your Applications using the Linux Perf ToolsProfiling your Applications using the Linux Perf Tools
Profiling your Applications using the Linux Perf Tools
 
DPDK: Multi Architecture High Performance Packet Processing
DPDK: Multi Architecture High Performance Packet ProcessingDPDK: Multi Architecture High Performance Packet Processing
DPDK: Multi Architecture High Performance Packet Processing
 
LSFMM 2019 BPF Observability
LSFMM 2019 BPF ObservabilityLSFMM 2019 BPF Observability
LSFMM 2019 BPF Observability
 
The Linux Block Layer - Built for Fast Storage
The Linux Block Layer - Built for Fast StorageThe Linux Block Layer - Built for Fast Storage
The Linux Block Layer - Built for Fast Storage
 
Building Network Functions with eBPF & BCC
Building Network Functions with eBPF & BCCBuilding Network Functions with eBPF & BCC
Building Network Functions with eBPF & BCC
 
HKG15-107: ACPI Power Management on ARM64 Servers (v2)
HKG15-107: ACPI Power Management on ARM64 Servers (v2)HKG15-107: ACPI Power Management on ARM64 Servers (v2)
HKG15-107: ACPI Power Management on ARM64 Servers (v2)
 
Security Monitoring with eBPF
Security Monitoring with eBPFSecurity Monitoring with eBPF
Security Monitoring with eBPF
 
Linux Performance Analysis: New Tools and Old Secrets
Linux Performance Analysis: New Tools and Old SecretsLinux Performance Analysis: New Tools and Old Secrets
Linux Performance Analysis: New Tools and Old Secrets
 
Linux kernel tracing
Linux kernel tracingLinux kernel tracing
Linux kernel tracing
 
Introduction to eBPF and XDP
Introduction to eBPF and XDPIntroduction to eBPF and XDP
Introduction to eBPF and XDP
 
Linux Network Stack
Linux Network StackLinux Network Stack
Linux Network Stack
 

Similar to Accelerated Linux Core Dump Analysis training public slides

Accelerated Mac OS X Core Dump Analysis training public slides
Accelerated Mac OS X Core Dump Analysis training public slidesAccelerated Mac OS X Core Dump Analysis training public slides
Accelerated Mac OS X Core Dump Analysis training public slidesDmitry Vostokov
 
Accelerated Windows Memory Dump Analysis
Accelerated Windows Memory Dump AnalysisAccelerated Windows Memory Dump Analysis
Accelerated Windows Memory Dump AnalysisDmitry Vostokov
 
Accelerated Windows Debugging 3 training public slides
Accelerated Windows Debugging 3 training public slidesAccelerated Windows Debugging 3 training public slides
Accelerated Windows Debugging 3 training public slidesDmitry Vostokov
 
Accelerated .NET Memory Dump Analysis training public slides
Accelerated .NET Memory Dump Analysis training public slidesAccelerated .NET Memory Dump Analysis training public slides
Accelerated .NET Memory Dump Analysis training public slidesDmitry Vostokov
 
Accelerated Windows Malware Analysis with Memory Dumps
Accelerated Windows Malware Analysis with Memory DumpsAccelerated Windows Malware Analysis with Memory Dumps
Accelerated Windows Malware Analysis with Memory DumpsDmitry Vostokov
 
Accelerated Disassembly, Reconstruction and Reversing training public slides
Accelerated Disassembly, Reconstruction and Reversing training public slidesAccelerated Disassembly, Reconstruction and Reversing training public slides
Accelerated Disassembly, Reconstruction and Reversing training public slidesDmitry Vostokov
 
Why use Gitlab
Why use GitlabWhy use Gitlab
Why use Gitlababenyeung1
 
Why and How to Run Your Own Gitlab Runners as Your Company Grows
Why and How to Run Your Own Gitlab Runners as Your Company GrowsWhy and How to Run Your Own Gitlab Runners as Your Company Grows
Why and How to Run Your Own Gitlab Runners as Your Company GrowsNGINX, Inc.
 
Linux kernel debugging(PDF format)
Linux kernel debugging(PDF format)Linux kernel debugging(PDF format)
Linux kernel debugging(PDF format)yang firo
 
Linux kernel debugging(ODP format)
Linux kernel debugging(ODP format)Linux kernel debugging(ODP format)
Linux kernel debugging(ODP format)yang firo
 
Schneider Electric Scada Global Support Provides Troubleshooting and Technica...
Schneider Electric Scada Global Support Provides Troubleshooting and Technica...Schneider Electric Scada Global Support Provides Troubleshooting and Technica...
Schneider Electric Scada Global Support Provides Troubleshooting and Technica...Preeya Selvarajah
 
Kandroid for nhn_deview_20131013_v5_final
Kandroid for nhn_deview_20131013_v5_finalKandroid for nhn_deview_20131013_v5_final
Kandroid for nhn_deview_20131013_v5_finalNAVER D2
 
Dot Net Application Monitoring
Dot Net Application MonitoringDot Net Application Monitoring
Dot Net Application MonitoringRavi Okade
 
Sprint 49 review
Sprint 49 reviewSprint 49 review
Sprint 49 reviewManageIQ
 
May2010 hex-core-opt
May2010 hex-core-optMay2010 hex-core-opt
May2010 hex-core-optJeff Larkin
 
OSMC 2012 | Shinken by Jean Gabès
OSMC 2012 | Shinken by Jean GabèsOSMC 2012 | Shinken by Jean Gabès
OSMC 2012 | Shinken by Jean GabèsNETWAYS
 
Troubleshooting .net core on linux
Troubleshooting .net core on linuxTroubleshooting .net core on linux
Troubleshooting .net core on linuxPavel Klimiankou
 
A165 tools for java and javascript
A165 tools for java and javascriptA165 tools for java and javascript
A165 tools for java and javascriptToby Corbin
 

Similar to Accelerated Linux Core Dump Analysis training public slides (20)

Accelerated Mac OS X Core Dump Analysis training public slides
Accelerated Mac OS X Core Dump Analysis training public slidesAccelerated Mac OS X Core Dump Analysis training public slides
Accelerated Mac OS X Core Dump Analysis training public slides
 
Accelerated Windows Memory Dump Analysis
Accelerated Windows Memory Dump AnalysisAccelerated Windows Memory Dump Analysis
Accelerated Windows Memory Dump Analysis
 
Accelerated Windows Debugging 3 training public slides
Accelerated Windows Debugging 3 training public slidesAccelerated Windows Debugging 3 training public slides
Accelerated Windows Debugging 3 training public slides
 
Accelerated .NET Memory Dump Analysis training public slides
Accelerated .NET Memory Dump Analysis training public slidesAccelerated .NET Memory Dump Analysis training public slides
Accelerated .NET Memory Dump Analysis training public slides
 
Accelerated Windows Malware Analysis with Memory Dumps
Accelerated Windows Malware Analysis with Memory DumpsAccelerated Windows Malware Analysis with Memory Dumps
Accelerated Windows Malware Analysis with Memory Dumps
 
Accelerated Disassembly, Reconstruction and Reversing training public slides
Accelerated Disassembly, Reconstruction and Reversing training public slidesAccelerated Disassembly, Reconstruction and Reversing training public slides
Accelerated Disassembly, Reconstruction and Reversing training public slides
 
Why use Gitlab
Why use GitlabWhy use Gitlab
Why use Gitlab
 
Why and How to Run Your Own Gitlab Runners as Your Company Grows
Why and How to Run Your Own Gitlab Runners as Your Company GrowsWhy and How to Run Your Own Gitlab Runners as Your Company Grows
Why and How to Run Your Own Gitlab Runners as Your Company Grows
 
Linux kernel debugging(PDF format)
Linux kernel debugging(PDF format)Linux kernel debugging(PDF format)
Linux kernel debugging(PDF format)
 
Linux kernel debugging(ODP format)
Linux kernel debugging(ODP format)Linux kernel debugging(ODP format)
Linux kernel debugging(ODP format)
 
Schneider Electric Scada Global Support Provides Troubleshooting and Technica...
Schneider Electric Scada Global Support Provides Troubleshooting and Technica...Schneider Electric Scada Global Support Provides Troubleshooting and Technica...
Schneider Electric Scada Global Support Provides Troubleshooting and Technica...
 
taddm
taddmtaddm
taddm
 
Kandroid for nhn_deview_20131013_v5_final
Kandroid for nhn_deview_20131013_v5_finalKandroid for nhn_deview_20131013_v5_final
Kandroid for nhn_deview_20131013_v5_final
 
Dot Net Application Monitoring
Dot Net Application MonitoringDot Net Application Monitoring
Dot Net Application Monitoring
 
Sprint 49 review
Sprint 49 reviewSprint 49 review
Sprint 49 review
 
May2010 hex-core-opt
May2010 hex-core-optMay2010 hex-core-opt
May2010 hex-core-opt
 
OSMC 2012 | Shinken by Jean Gabès
OSMC 2012 | Shinken by Jean GabèsOSMC 2012 | Shinken by Jean Gabès
OSMC 2012 | Shinken by Jean Gabès
 
Troubleshooting .net core on linux
Troubleshooting .net core on linuxTroubleshooting .net core on linux
Troubleshooting .net core on linux
 
A165 tools for java and javascript
A165 tools for java and javascriptA165 tools for java and javascript
A165 tools for java and javascript
 
Spug pt session2 - debuggingl
Spug pt session2 - debugginglSpug pt session2 - debuggingl
Spug pt session2 - debuggingl
 

More from Dmitry Vostokov

More from Dmitry Vostokov (20)

Debugging TV Frame 0x1C
Debugging TV Frame 0x1CDebugging TV Frame 0x1C
Debugging TV Frame 0x1C
 
Debugging TV Frame 0x1A
Debugging TV Frame 0x1ADebugging TV Frame 0x1A
Debugging TV Frame 0x1A
 
Debugging TV Frame 0x34
Debugging TV Frame 0x34Debugging TV Frame 0x34
Debugging TV Frame 0x34
 
Debugging TV Frame 0x33
Debugging TV Frame 0x33Debugging TV Frame 0x33
Debugging TV Frame 0x33
 
Debugging TV Frame 0x31
Debugging TV Frame 0x31Debugging TV Frame 0x31
Debugging TV Frame 0x31
 
Debugging TV Frame 0x25
Debugging TV Frame 0x25Debugging TV Frame 0x25
Debugging TV Frame 0x25
 
Debugging TV Frame 0x24
Debugging TV Frame 0x24Debugging TV Frame 0x24
Debugging TV Frame 0x24
 
Debugging TV Frame 0x21
Debugging TV Frame 0x21Debugging TV Frame 0x21
Debugging TV Frame 0x21
 
Debugging TV Frame 0x20
Debugging TV Frame 0x20Debugging TV Frame 0x20
Debugging TV Frame 0x20
 
Debugging TV Frame 0x19
Debugging TV Frame 0x19Debugging TV Frame 0x19
Debugging TV Frame 0x19
 
Debugging TV Frame 0x18
Debugging TV Frame 0x18Debugging TV Frame 0x18
Debugging TV Frame 0x18
 
Debugging TV Frame 0x17
Debugging TV Frame 0x17Debugging TV Frame 0x17
Debugging TV Frame 0x17
 
Debugging TV Frame 0x16
Debugging TV Frame 0x16Debugging TV Frame 0x16
Debugging TV Frame 0x16
 
Debugging TV Frame 0x15
Debugging TV Frame 0x15Debugging TV Frame 0x15
Debugging TV Frame 0x15
 
Debugging TV Frame 0x14
Debugging TV Frame 0x14Debugging TV Frame 0x14
Debugging TV Frame 0x14
 
Debugging TV Frame 0x13
Debugging TV Frame 0x13Debugging TV Frame 0x13
Debugging TV Frame 0x13
 
Debugging TV Frame 0x12
Debugging TV Frame 0x12Debugging TV Frame 0x12
Debugging TV Frame 0x12
 
Debugging TV Frame 0x11
Debugging TV Frame 0x11Debugging TV Frame 0x11
Debugging TV Frame 0x11
 
Debugging TV Frame 0x10
Debugging TV Frame 0x10Debugging TV Frame 0x10
Debugging TV Frame 0x10
 
Debugging TV Frame 0x0F
Debugging TV Frame 0x0FDebugging TV Frame 0x0F
Debugging TV Frame 0x0F
 

Recently uploaded

Try MyIntelliAccount Cloud Accounting Software As A Service Solution Risk Fre...
Try MyIntelliAccount Cloud Accounting Software As A Service Solution Risk Fre...Try MyIntelliAccount Cloud Accounting Software As A Service Solution Risk Fre...
Try MyIntelliAccount Cloud Accounting Software As A Service Solution Risk Fre...MyIntelliSource, Inc.
 
KnowAPIs-UnknownPerf-jaxMainz-2024 (1).pptx
KnowAPIs-UnknownPerf-jaxMainz-2024 (1).pptxKnowAPIs-UnknownPerf-jaxMainz-2024 (1).pptx
KnowAPIs-UnknownPerf-jaxMainz-2024 (1).pptxTier1 app
 
Adobe Marketo Engage Deep Dives: Using Webhooks to Transfer Data
Adobe Marketo Engage Deep Dives: Using Webhooks to Transfer DataAdobe Marketo Engage Deep Dives: Using Webhooks to Transfer Data
Adobe Marketo Engage Deep Dives: Using Webhooks to Transfer DataBradBedford3
 
Cloud Management Software Platforms: OpenStack
Cloud Management Software Platforms: OpenStackCloud Management Software Platforms: OpenStack
Cloud Management Software Platforms: OpenStackVICTOR MAESTRE RAMIREZ
 
Call Girls in Naraina Delhi 💯Call Us 🔝8264348440🔝
Call Girls in Naraina Delhi 💯Call Us 🔝8264348440🔝Call Girls in Naraina Delhi 💯Call Us 🔝8264348440🔝
Call Girls in Naraina Delhi 💯Call Us 🔝8264348440🔝soniya singh
 
Building a General PDE Solving Framework with Symbolic-Numeric Scientific Mac...
Building a General PDE Solving Framework with Symbolic-Numeric Scientific Mac...Building a General PDE Solving Framework with Symbolic-Numeric Scientific Mac...
Building a General PDE Solving Framework with Symbolic-Numeric Scientific Mac...stazi3110
 
The Essentials of Digital Experience Monitoring_ A Comprehensive Guide.pdf
The Essentials of Digital Experience Monitoring_ A Comprehensive Guide.pdfThe Essentials of Digital Experience Monitoring_ A Comprehensive Guide.pdf
The Essentials of Digital Experience Monitoring_ A Comprehensive Guide.pdfkalichargn70th171
 
ODSC - Batch to Stream workshop - integration of Apache Spark, Cassandra, Pos...
ODSC - Batch to Stream workshop - integration of Apache Spark, Cassandra, Pos...ODSC - Batch to Stream workshop - integration of Apache Spark, Cassandra, Pos...
ODSC - Batch to Stream workshop - integration of Apache Spark, Cassandra, Pos...Christina Lin
 
Engage Usergroup 2024 - The Good The Bad_The Ugly
Engage Usergroup 2024 - The Good The Bad_The UglyEngage Usergroup 2024 - The Good The Bad_The Ugly
Engage Usergroup 2024 - The Good The Bad_The UglyFrank van der Linden
 
Alluxio Monthly Webinar | Cloud-Native Model Training on Distributed Data
Alluxio Monthly Webinar | Cloud-Native Model Training on Distributed DataAlluxio Monthly Webinar | Cloud-Native Model Training on Distributed Data
Alluxio Monthly Webinar | Cloud-Native Model Training on Distributed DataAlluxio, Inc.
 
Project Based Learning (A.I).pptx detail explanation
Project Based Learning (A.I).pptx detail explanationProject Based Learning (A.I).pptx detail explanation
Project Based Learning (A.I).pptx detail explanationkaushalgiri8080
 
Russian Call Girls in Karol Bagh Aasnvi ➡️ 8264348440 💋📞 Independent Escort S...
Russian Call Girls in Karol Bagh Aasnvi ➡️ 8264348440 💋📞 Independent Escort S...Russian Call Girls in Karol Bagh Aasnvi ➡️ 8264348440 💋📞 Independent Escort S...
Russian Call Girls in Karol Bagh Aasnvi ➡️ 8264348440 💋📞 Independent Escort S...soniya singh
 
Steps To Getting Up And Running Quickly With MyTimeClock Employee Scheduling ...
Steps To Getting Up And Running Quickly With MyTimeClock Employee Scheduling ...Steps To Getting Up And Running Quickly With MyTimeClock Employee Scheduling ...
Steps To Getting Up And Running Quickly With MyTimeClock Employee Scheduling ...MyIntelliSource, Inc.
 
Asset Management Software - Infographic
Asset Management Software - InfographicAsset Management Software - Infographic
Asset Management Software - InfographicHr365.us smith
 
5 Signs You Need a Fashion PLM Software.pdf
5 Signs You Need a Fashion PLM Software.pdf5 Signs You Need a Fashion PLM Software.pdf
5 Signs You Need a Fashion PLM Software.pdfWave PLM
 
The Real-World Challenges of Medical Device Cybersecurity- Mitigating Vulnera...
The Real-World Challenges of Medical Device Cybersecurity- Mitigating Vulnera...The Real-World Challenges of Medical Device Cybersecurity- Mitigating Vulnera...
The Real-World Challenges of Medical Device Cybersecurity- Mitigating Vulnera...ICS
 
Salesforce Certified Field Service Consultant
Salesforce Certified Field Service ConsultantSalesforce Certified Field Service Consultant
Salesforce Certified Field Service ConsultantAxelRicardoTrocheRiq
 
Optimizing AI for immediate response in Smart CCTV
Optimizing AI for immediate response in Smart CCTVOptimizing AI for immediate response in Smart CCTV
Optimizing AI for immediate response in Smart CCTVshikhaohhpro
 
Advancing Engineering with AI through the Next Generation of Strategic Projec...
Advancing Engineering with AI through the Next Generation of Strategic Projec...Advancing Engineering with AI through the Next Generation of Strategic Projec...
Advancing Engineering with AI through the Next Generation of Strategic Projec...OnePlan Solutions
 

Recently uploaded (20)

Try MyIntelliAccount Cloud Accounting Software As A Service Solution Risk Fre...
Try MyIntelliAccount Cloud Accounting Software As A Service Solution Risk Fre...Try MyIntelliAccount Cloud Accounting Software As A Service Solution Risk Fre...
Try MyIntelliAccount Cloud Accounting Software As A Service Solution Risk Fre...
 
KnowAPIs-UnknownPerf-jaxMainz-2024 (1).pptx
KnowAPIs-UnknownPerf-jaxMainz-2024 (1).pptxKnowAPIs-UnknownPerf-jaxMainz-2024 (1).pptx
KnowAPIs-UnknownPerf-jaxMainz-2024 (1).pptx
 
Adobe Marketo Engage Deep Dives: Using Webhooks to Transfer Data
Adobe Marketo Engage Deep Dives: Using Webhooks to Transfer DataAdobe Marketo Engage Deep Dives: Using Webhooks to Transfer Data
Adobe Marketo Engage Deep Dives: Using Webhooks to Transfer Data
 
Cloud Management Software Platforms: OpenStack
Cloud Management Software Platforms: OpenStackCloud Management Software Platforms: OpenStack
Cloud Management Software Platforms: OpenStack
 
Call Girls in Naraina Delhi 💯Call Us 🔝8264348440🔝
Call Girls in Naraina Delhi 💯Call Us 🔝8264348440🔝Call Girls in Naraina Delhi 💯Call Us 🔝8264348440🔝
Call Girls in Naraina Delhi 💯Call Us 🔝8264348440🔝
 
Building a General PDE Solving Framework with Symbolic-Numeric Scientific Mac...
Building a General PDE Solving Framework with Symbolic-Numeric Scientific Mac...Building a General PDE Solving Framework with Symbolic-Numeric Scientific Mac...
Building a General PDE Solving Framework with Symbolic-Numeric Scientific Mac...
 
The Essentials of Digital Experience Monitoring_ A Comprehensive Guide.pdf
The Essentials of Digital Experience Monitoring_ A Comprehensive Guide.pdfThe Essentials of Digital Experience Monitoring_ A Comprehensive Guide.pdf
The Essentials of Digital Experience Monitoring_ A Comprehensive Guide.pdf
 
ODSC - Batch to Stream workshop - integration of Apache Spark, Cassandra, Pos...
ODSC - Batch to Stream workshop - integration of Apache Spark, Cassandra, Pos...ODSC - Batch to Stream workshop - integration of Apache Spark, Cassandra, Pos...
ODSC - Batch to Stream workshop - integration of Apache Spark, Cassandra, Pos...
 
Engage Usergroup 2024 - The Good The Bad_The Ugly
Engage Usergroup 2024 - The Good The Bad_The UglyEngage Usergroup 2024 - The Good The Bad_The Ugly
Engage Usergroup 2024 - The Good The Bad_The Ugly
 
Alluxio Monthly Webinar | Cloud-Native Model Training on Distributed Data
Alluxio Monthly Webinar | Cloud-Native Model Training on Distributed DataAlluxio Monthly Webinar | Cloud-Native Model Training on Distributed Data
Alluxio Monthly Webinar | Cloud-Native Model Training on Distributed Data
 
Project Based Learning (A.I).pptx detail explanation
Project Based Learning (A.I).pptx detail explanationProject Based Learning (A.I).pptx detail explanation
Project Based Learning (A.I).pptx detail explanation
 
Call Girls In Mukherjee Nagar 📱 9999965857 🤩 Delhi 🫦 HOT AND SEXY VVIP 🍎 SE...
Call Girls In Mukherjee Nagar 📱  9999965857  🤩 Delhi 🫦 HOT AND SEXY VVIP 🍎 SE...Call Girls In Mukherjee Nagar 📱  9999965857  🤩 Delhi 🫦 HOT AND SEXY VVIP 🍎 SE...
Call Girls In Mukherjee Nagar 📱 9999965857 🤩 Delhi 🫦 HOT AND SEXY VVIP 🍎 SE...
 
Russian Call Girls in Karol Bagh Aasnvi ➡️ 8264348440 💋📞 Independent Escort S...
Russian Call Girls in Karol Bagh Aasnvi ➡️ 8264348440 💋📞 Independent Escort S...Russian Call Girls in Karol Bagh Aasnvi ➡️ 8264348440 💋📞 Independent Escort S...
Russian Call Girls in Karol Bagh Aasnvi ➡️ 8264348440 💋📞 Independent Escort S...
 
Steps To Getting Up And Running Quickly With MyTimeClock Employee Scheduling ...
Steps To Getting Up And Running Quickly With MyTimeClock Employee Scheduling ...Steps To Getting Up And Running Quickly With MyTimeClock Employee Scheduling ...
Steps To Getting Up And Running Quickly With MyTimeClock Employee Scheduling ...
 
Asset Management Software - Infographic
Asset Management Software - InfographicAsset Management Software - Infographic
Asset Management Software - Infographic
 
5 Signs You Need a Fashion PLM Software.pdf
5 Signs You Need a Fashion PLM Software.pdf5 Signs You Need a Fashion PLM Software.pdf
5 Signs You Need a Fashion PLM Software.pdf
 
The Real-World Challenges of Medical Device Cybersecurity- Mitigating Vulnera...
The Real-World Challenges of Medical Device Cybersecurity- Mitigating Vulnera...The Real-World Challenges of Medical Device Cybersecurity- Mitigating Vulnera...
The Real-World Challenges of Medical Device Cybersecurity- Mitigating Vulnera...
 
Salesforce Certified Field Service Consultant
Salesforce Certified Field Service ConsultantSalesforce Certified Field Service Consultant
Salesforce Certified Field Service Consultant
 
Optimizing AI for immediate response in Smart CCTV
Optimizing AI for immediate response in Smart CCTVOptimizing AI for immediate response in Smart CCTV
Optimizing AI for immediate response in Smart CCTV
 
Advancing Engineering with AI through the Next Generation of Strategic Projec...
Advancing Engineering with AI through the Next Generation of Strategic Projec...Advancing Engineering with AI through the Next Generation of Strategic Projec...
Advancing Engineering with AI through the Next Generation of Strategic Projec...
 

Accelerated Linux Core Dump Analysis training public slides

  • 1. Linux Core Dump Analysis Dmitry Vostokov Software Diagnostics Services
  • 2. Prerequisites Basic Linux troubleshooting GDB Commands We use these boxes to introduce GDB commands used in practice exercises © 2015 Software Diagnostics Services
  • 3. Training Goals  Review fundamentals  Learn how to collect core dumps  Learn how to analyze core dumps © 2015 Software Diagnostics Services
  • 4. Training Principles  Talk only about what I can show  Lots of pictures  Lots of examples  Original content © 2015 Software Diagnostics Services
  • 5. Schedule Summary Day 1  Analysis Fundamentals (30 minutes)  Core dump collection methods (10 minutes)  Basic Core Memory Dumps (1 hour 20 minutes) Day 2  Core Memory Dumps (2 hours) © 2015 Software Diagnostics Services
  • 6. Part 1: Fundamentals © 2015 Software Diagnostics Services
  • 7. Memory/Kernel/User Space © 2015 Software Diagnostics Services Kernel Space User Space 0000000000000000 00007FFFFFFFFFFF NULL Pointers 000000000000FFFF 0000000000010000
  • 8. App/Process/Library © 2015 Software Diagnostics Services Kernel Space User Space (PID 9200) 0000000000010000 00007FFFFFFFFFFF App0 App0 libc.so ld.solibc.so ld.so
  • 9. Process Memory Dump GDB Commands info sharedlibrary Lists dynamic libraries maintenance info sections Lists memory regions © 2015 Software Diagnostics Services core Kernel Space 0000000000010000 00007FFFFFFFFFFF User Space (PID 9200) App0 libc.so ld.so
  • 10. Lightweight Processes (Threads) GDB Commands info threads Lists threads thread <n> Switches between threads thread apply all bt Lists stack traces from all threads © 2015 Software Diagnostics Services Kernel Space User Space (PID 9400) App1 LWP 9401LWP 9400 libc.so ld.so libpthread.so
  • 11. Thread Stack Raw Data GDB Commands x/<n>a <address> Prints n addresses with corresponding symbol mappings if any © 2015 Software Diagnostics Services Kernel Space User Space (PID 9400) App1 LWP 9401LWP 9400 libc.so ld.so libpthread.so Stack for LWP 9401 (TID) Stack for LWP 9400 (TID)
  • 12. Thread Stack Trace GDB Commands (gdb) bt #0 0x00007fe9676bf48d in FunctionD () #1 0x00007fe9676bf300 in FunctionC () #2 0x00000000004005ca in FunctionB () #3 0x00000000004005da in FunctionA () © 2015 Software Diagnostics Services User Stack for LWP 10707 FunctionA FunctionB FunctionC Saves return address FunctionA+110 Saves return address FunctionB+220 FunctionD Saves return address FunctionC+130 Resumes from address FunctionA+110 Resumes from address FunctionB+220 Resumes from address FunctionC+130 FunctionA() { ... FunctionB(); ... } FunctionB() { ... FunctionC(); ... } FunctionC() { ... FunctionD(); ... } Return address FunctionC+130 0x00007fe9676bf300 Return address FunctionB+220 0x00000000004005ca Return address FunctionA+110 0x00000000004005da
  • 13. GDB vs. WinDbg WinDbg Commands 0:000> kn 00 00007fe9676bf300 Module!FunctionD+offset 01 00000000004005ca Module!FunctionC+130 02 00000000004005da AppA!FunctionB+220 03 0000000000000000 AppA!FunctionA+110 © 2015 Software Diagnostics Services GDB Commands (gdb) bt #0 0x00007fe9676bf48d in FunctionD () #1 0x00007fe9676bf300 in FunctionC () #2 0x00000000004005ca in FunctionB () #3 0x00000000004005da in FunctionA ()
  • 14. Thread Stack Trace (no symbols) GDB Commands (gdb) bt #0 0x00007fe9676bf48d in FunctionD () #1 0x00007fe9676bf300 in FunctionC () #2 0x00000000004005ca in ?? () #3 0x00000000004005da in ?? () © 2015 Software Diagnostics Services User Stack for LWP 10707 Return address FunctionC+130 0x00007fe9676bf300 Return address 0x00000000004005ca Return address 0x00000000004005da Symbol file App.sym FunctionA 22000 - 23000 FunctionB 32000 - 33000
  • 15. Exceptions (Access Violation) GDB Commands (gdb) x <address> 0x<address>: Cannot access memory at address 0x<address> © 2015 Software Diagnostics Services User Space (PID 3604) App Signal 11 (segmentation fault)M NULL pointer 0x0M libc.so ld.so libpthread.so Stack for LWP 3605 (TID) Stack for LWP 3604 (TID)
  • 16. Exceptions (Runtime) © 2015 Software Diagnostics Services User Space (PID 3714) App libc.so ld.so libpthread.so Stack for LWP 3715 (TID) Stack for LWP 3714 (TID) M throws exception Signal 6 (abort) libstdc++.so
  • 17. Pattern-Oriented Diagnostic Analysis Information Collection (Scripts) Information Extraction (Checklists) Problem Identification (Patterns) Problem Resolution Troubleshooting Suggestions Debugging Strategy Diagnostic Pattern: a common recurrent identifiable problem together with a set of recommendations and possible solutions to apply in a specific context. © 2015 Software Diagnostics Services Diagnostic Analysis Pattern: a common recurrent analysis technique and method of diagnostic pattern identification in a specific context. Diagnostic Problem: a set of indicators (symptoms, signs) describing a problem. Diagnostics Pattern Language: common names of diagnostic and diagnostic analysis patterns. The same language for any operating system: Windows, Mac OS X, Linux, ...
  • 18. Part 2: Core Dump Collection © 2015 Software Diagnostics Services
  • 19. Enabling Collection  Temporary for the current user: $ ulimit -c unlimited  Permanent for every user except root: Edit the file: /etc/security/limits.conf Add or uncomment the line: * soft core unlimited To limit root to 1GB add or uncomment this line: root hard core 1000000 © 2015 Software Diagnostics Services
  • 20. Generation Methods  kill (requires ulimit): $ kill –s SIGQUIT PID $ kill –s SIGABRT PID  gcore: $ gcore PID © 2015 Software Diagnostics Services
  • 21. Part 3: Practice Exercises © 2015 Software Diagnostics Services
  • 22. Links  Memory Dumps: NOT IN THE PUBLIC PREVIEW VERSION  Exercise Transcripts: NOT IN THE PUBLIC PREVIEW VERSION © 2015 Software Diagnostics Services
  • 23. Exercise 0  Goal: Install GDB and check if GDB loads a core dump correctly  Patterns: Incorrect Stack Trace  ALCDA-DumpsExercise-A0.pdf © 2015 Software Diagnostics Services
  • 24. Process Core Dumps Exercises A1-A12 © 2015 Software Diagnostics Services
  • 25. Exercise A1  Goal: Learn how to list stack traces, disassemble functions, check their correctness, dump data, get environment  Patterns: Manual Dump, Stack Trace, Stack Trace Collection, Annotated Disassembly, Paratext, Not My Version, Environment Hint  ALCDA-DumpsExercise-A1.pdf © 2015 Software Diagnostics Services
  • 26. Exercise A2D  Goal: Learn how to identify exceptions, find problem threads and CPU instructions  Patterns: NULL Pointer (data), Active Thread  ALCDA-DumpsExercise-A2D.pdf © 2015 Software Diagnostics Services
  • 27. Exercise A2C  Goal: Learn how to identify exceptions, find problem threads and CPU instructions  Patterns: NULL Pointer (code), Active Thread  ALCDA-DumpsExercise-A2C.pdf © 2015 Software Diagnostics Services
  • 28. Exercise A3  Goal: Learn how to identify spiking threads  Patterns: Spiking Thread  ALCDA-DumpsExercise-A3.pdf © 2015 Software Diagnostics Services
  • 29. Exercise A4  Goal: Learn how to identify heap regions and heap corruption  Patterns: Heap Corruption  ALCDA-DumpsExercise-A4.pdf © 2015 Software Diagnostics Services
  • 30. Exercise A5  Goal: Learn how to identify stack corruption  Patterns: Local Buffer Overflow, Execution Residue  ALCDA-DumpsExercise-A5.pdf © 2015 Software Diagnostics Services
  • 31. Exercise A6  Goal: Learn how to identify stack overflow, stack boundaries, reconstruct stack trace  Patterns: Stack Overflow, Execution Residue  ALCDA-DumpsExercise-A6.pdf © 2015 Software Diagnostics Services
  • 32. Exercise A7  Goal: Learn how to identify active threads  Patterns: Divide by Zero, Active Thread  ALCDA-DumpsExercise-A7.pdf © 2015 Software Diagnostics Services
  • 33. Exercise A8  Goal: Learn how to identify runtime exceptions, past execution residue and stack traces, identify handled exceptions  Patterns: C++ Exception, Execution Residue, Coincidental Symbolic Information, Handled Exception  ALCDA-DumpsExercise-A8.pdf © 2015 Software Diagnostics Services
  • 34. Exercise A9  Goal: Learn how to identify heap leaks  Patterns: Heap Leak, Execution Residue, Module Hint  ALCDA-DumpsExercise-A9.pdf © 2015 Software Diagnostics Services
  • 35. Exercise A10  Goal: Learn how to identify heap contention wait chains, synchronization issues, advanced disassembly, dump arrays  Patterns: Double Free, Heap Contention, Wait Chain, Critical Region, Self-Diagnosis  ALCDA-DumpsExercise-A10.pdf © 2015 Software Diagnostics Services
  • 36. Exercise A11  Goal: Learn how to identify synchronization wait chains, deadlocks, hidden and handled exceptions  Patterns: Wait Chains, Deadlock, Execution Residue, Handled Exception  ALCDA-DumpsExercise-A11.pdf © 2015 Software Diagnostics Services
  • 37. Exercise A12  Goal: Learn how to dump memory for post-processing, get the list of functions and module variables, load symbols, inspect arguments and local variables  Patterns: Module Variable  ALCDA-DumpsExercise-A12.pdf © 2015 Software Diagnostics Services
  • 38. Pattern Links (Linux and GDB) Active Thread Annotated Disassembly C++ Exception Coincidental Symbolic Information Critical Region Deadlock Divide by Zero Environment Hint Execution Residue Handled Exception Heap Contention Heap Corruption Heap Leak Lateral Damage Local Buffer Overflow Manual Dump Module Hint Module Variable Not My Version NULL Pointer (code) NULL Pointer (data) Paratext Self-Diagnosis Spiking Thread Stack Overflow Stack Trace Stack Trace Collection Wait Chain © 2015 Software Diagnostics Services
  • 39. Resources  Software Diagnostics Institute  Pattern-Driven Software Diagnostics  Pattern-Based Software Diagnostics  Debugging TV  Rosetta Stone for Debuggers  Accelerated Mac OS X Core Dump Analysis  GDB Pocket Reference  Memory Dump Analysis Anthology (some articles in volumes 1 and 7 cover GDB) Forthcoming volume 9 will have additional GDB articles © 2015 Software Diagnostics Services
  • 40. Q&A Please send your feedback using the contact form on PatternDiagnostics.com © 2015 Software Diagnostics Services
  • 41. Thank you for attendance! © 2015 Software Diagnostics Services