SlideShare a Scribd company logo
Crash Report Mechanism in Tizen
Yu Yucai, 2013/05/31
2
Agenda
• Crash Client (Tizen 2.1.x)
• Samsung’s crash-work-sdk
• Intel’s corewatcher
• Crash Server
• CrashDB Web
• Crash reason location algrithm
3
Agenda
• Crash Client
• Samsung’s crash-work-sdk
• Intel’s corewatcher(3rd Gen)
• Crash Server
• CrashDB Web
• Crash reason location algrithm
4
Crash Client - Samsung’s crash-work-sdk
• Mechanism
• Crash process flow
• Crash report file: *.cs file

Recommended for you

Cisco IOS shellcode: All-in-one
Cisco IOS shellcode: All-in-oneCisco IOS shellcode: All-in-one
Cisco IOS shellcode: All-in-one

This document discusses Cisco IOS shellcoding and reverse engineering. It covers topics like Cisco IOS shellcodes that are image-independent by disassembling or interrupting hijacking. It also discusses Tcl shellcodes, Cisco IOS reverse engineering challenges including lack of modularity and APIs. The document details subsystems, registries, processes, command parser tree, debugging Cisco IOS, and magic numbers used in Cisco IOS.

shellcodezeronightscisco
Tracer Evaluation
Tracer EvaluationTracer Evaluation
Tracer Evaluation

Performance evaluation of various implementations of off-cpu wakeup path tracers for Linux kernel, using kprobe, ftrace, and ebpf.

performancelinuxprofiling
Solaris Kernel Debugging V1.0
Solaris Kernel Debugging V1.0Solaris Kernel Debugging V1.0
Solaris Kernel Debugging V1.0

This document provides an overview of kernel debugging on Solaris systems using the modular debugger Mdb and dynamic tracing framework DTrace. It discusses debugging live kernels with Mdb, analyzing system crash dumps with Mdb, and using DTrace to monitor the kernel at runtime by enabling probes published by different providers. The document outlines the key tools, techniques, and challenges involved in kernel debugging and crash analysis on Solaris.

mdbsolarisdtrace
5
Crash Client - Samsung’s crash-work-sdk
• Mechanism: force preload libsys-assert.so to overload crash signal
handlers.
sh-4.1# cat /etc/ld.so.preload
/usr/lib/libsys-assert.so
sh-4.1# ldd `which top`
linux-gate.so.1 => (0xb77fd000)
/usr/lib/libsys-assert.so (0xb77f5000)
libproc-3.2.8.so => /lib/libproc-3.2.8.so (0xb77c1000)
libncurses.so.5 => /usr/lib/libncurses.so.5 (0xb7781000)
libc.so.6 => /lib/libc.so.6 (0xb7625000)
libdl.so.2 => /lib/libdl.so.2 (0xb7621000)
/lib/ld-linux.so.2 (0xb77fe000)
6
Crash Client - Samsung’s crash-work-sdk
• Crash process flow
Stage 1: in sys-assert.c (libsys-assert.so)
-> int sig_to_handle[] = { SIGILL, SIGABRT, SIGBUS, SIGFPE, SIGSEGV, };
-> sighandler notify system_server via /opt/share/crash/curbs.log pipeline.
Stage 2: in ss_bs.c (system-server)
-> ecore_file_monitor_add(CRASH_NOTI_PATH,(void *) __crash_file_cb, NULL);
-> __crash_file_cb:
-> launch_crash_worker()
......
launch /usr/bin/crash-worker to generate cs file
launch /usr/apps/org.tizen.crash-popup/bin/crash-popup to popup crash (only 1st)
7
Crash Client - Samsung’s crash-work-sdk
• Crash process flow
Breakpoint 1, launch_app_with_nice (file=0xb46017b0 "/usr/bin/crash-worker", argv=0xbfe52624, pid=0x0, _nice=0)
at /usr/src/debug/system-server-0.1.65/ss_launch.c:140
140 {
(gdb) bt
#0 launch_app_with_nice (file=0xb46017b0 "/usr/bin/crash-worker",
argv=0xbfe52624, pid=0x0, _nice=0)
at /usr/src/debug/system-server-0.1.65/ss_launch.c:140
#1 0x0804d3c9 in launch_app_cmd_with_nice (
cmdline=0xb4601758 "/usr/bin/crash-worker S top 391655492 913 top",
_nice=0) at /usr/src/debug/system-server-0.1.65/ss_launch.c:196
#2 0x0804d744 in ss_launch_evenif_exist (
execpath=0x8060e71 "/usr/bin/crash-worker",
arg=0xbfe53d16 "S top 391655492 913 top")
at /usr/src/debug/system-server-0.1.65/ss_launch.c:289
#3 0x08058b73 in launch_crash_worker (
filename=0xbfe5823c "/opt/share/crash/curbs.log", popup_on=1)
at /usr/src/debug/system-server-0.1.65/ss_bs.c:327
#4 0x08058d47 in __crash_file_cb (data=0x0, em=0x8dabb10,
event=ECORE_FILE_EVENT_MODIFIED,
path=0xbfe5823c "/opt/share/crash/curbs.log")
at /usr/src/debug/system-server-0.1.65/ss_bs.c:374
#5 0xb782f345 in _ecore_file_monitor_inotify_handler ()
from /usr/lib/libecore_file.so.1
#6 0xb7840e5c in _ecore_main_loop_iterate_internal ()
from /usr/lib/libecore.so.1
#7 0xb784141f in ecore_main_loop_begin () from /usr/lib/libecore.so.1
#8 0x0804bd95 in system_main (argc=1, argv=0xbfe59404)
---Type <return> to continue, or q <return> to quit---
at /usr/src/debug/system-server-0.1.65/ss_main.c:102
#9 0x0804bdf1 in elm_main (argc=1, argv=0xbfe59404)
at /usr/src/debug/system-server-0.1.65/ss_main.c:112
#10 0x0804be4e in main (argc=1, argv=0xbfe59404)
at /usr/src/debug/system-server-0.1.65/ss_main.c:119
8
Crash Client - Samsung’s crash-work-sdk
• Crash process flow
Stage 3: crash-worker to generate cs file
sh-4.1# pwd
/opt/usr/share/crash/report
sh-4.1# ls -tlr
total 72
-rwxrw-rw- 1 root app 22248 1982-05-02 18:28 top_19820502182857.cs
-rwxrw-rw- 1 root app 22248 1982-05-02 18:39 top_19820502183647.cs
-rwxrw-rw- 1 root app 22248 1982-05-02 18:49 top_19820502184511.cs

Recommended for you

HackLU 2018 Make ARM Shellcode Great Again
HackLU 2018 Make ARM Shellcode Great AgainHackLU 2018 Make ARM Shellcode Great Again
HackLU 2018 Make ARM Shellcode Great Again

Compared to x86, ARM shellcode has made little progress. The x86 hardware is largely homogenous. ARM, however, has several versions and variants across devices today. There are several constraints and subtleties involved in writing production quality ARM shellcode which works on modern ARM hardware, not just on QEMU emulators. In this talk, we shall explore issues such as overcoming cache coherency, reliable polymorphic shellcode, ARM egghunting and last but not the least, polyglot ARM shellcode. A bonus side effect of this talk will be creating headaches for those who like to defend agaisnt attacks using age old signature based techniques.

hacklu2018arm
W8_2: Inside the UoS Educational Processor
W8_2: Inside the UoS Educational ProcessorW8_2: Inside the UoS Educational Processor
W8_2: Inside the UoS Educational Processor

In this unit we provide more details to the UoS educational, in particular it's implementation in VHDL. Unit duration: 50mn. License: LGPL 2.1

cpuprocessormicroprocessor design
Linux Capabilities - eng - v2.1.5, compact
Linux Capabilities - eng - v2.1.5, compactLinux Capabilities - eng - v2.1.5, compact
Linux Capabilities - eng - v2.1.5, compact

Linux Capabilities: A better root than SUID root Presented at LinuxCon2014, Düsseldorf, Oct. 15th 2014

privilegessuidfedora
9
Crash Client - Samsung’s crash-work-sdk
• What’s *.cs file.
sh-4.1# cat top_19820502184511.cs
S/W Version Information
Model: handset-blackbay
Tizen-Version: 2.1.0
Build-Number: Tizen_handset-blackbay-tizen-2.1-
mobile_20130430.1
Build-Date: 2013.05.01 03:24:28
Crash Information
PID: 1194
Date: 1982-05-02 18:45:11(GMT+0900)
Executable File Path: top
This process is multi-thread process
pid=1194 tid=1194
Signal: 11
(SIGSEGV)
si_code: 0
signal sent by kill (sent by pid 1195, uid 0)
Register Information
gs = 0x00000033, fs = 0x00000000
es = 0x0000007b, ds = 0x0000007b
edi = 0x08057040, esi = 0x00000000
ebp = 0xbfe13b68, esp = 0xbfe13040
eax = 0xfffffffc, ebx = 0x00000001
ecx = 0xbfe1332c, edx = 0x00000000
eip = 0xb7896424
Memory Information
MemTotal: 995664 KB
MemFree: 457540 KB
Buffers: 14768 KB
Cached: 233204 KB
VmPeak: 2748 KB
VmSize: 2748 KB
VmLck: 0 KB
VmHWM: 1336 KB
VmRSS: 1336 KB
VmData: 492 KB
VmStk: 136 KB
10
Crash Client - Samsung’s crash-work-sdk
• What’s *.cs file.
Maps Information
08048000 08056000 r-xp /usr/bin/top
b7683000 b768d000 r-xp /lib/libnss_files-2.13.so
b768f000 b7698000 r-xp /lib/libnss_nis-2.13.so
b769a000 b76ad000 r-xp /lib/libnsl-2.13.so
b76b1000 b76b7000 r-xp /lib/libnss_compat-2.13.so
b76ba000 b76bc000 r-xp /lib/libdl-2.13.so
b76be000 b7814000 r-xp /lib/libc-2.13.so
b781a000 b7857000 r-xp /usr/lib/libncurses.so.5.7
b785a000 b7868000 r-xp /lib/libproc-3.2.8.so
b788e000 b7892000 r-xp /usr/lib/libsys-assert.so
b7896000 b7897000 r-xp [vdso]
b7897000 b78b3000 r-xp /lib/ld-2.13.so
End of Maps Information
Callstack Information (PID:1194)
Call Stack Count: 1
can't open 0: (0x8049a81) [top] + 0x1a81
End of Call Stack
Latest Debug Message Information
--------- beginning of /dev/log_main
05-02 16:31:42.769 E/Tizen::App( 616): void
Tizen::App::_ConditionManagerStub::OnInstallComplete(const
Tizen::App::AppId&)(133) > failed to
GetAppLaunchConditionListN(org.tizen.taskmgr)
…
omPackageManager(const Tizen::Base::String&, const
Tizen::Base::String&, const Tizen::Base::String&)(493) > Cannot
acquire feature list.
05-02 16:31:43.819 E/Tizen::App( 616): void Tizen::App::_
End of latest debug message
11
Agenda
• Crash Client
• Samsung’s crash-work-sdk
• Intel’s corewatcher(3rd Gen)
• Crash Server
• CrashDB Web
• Crash reason location algrithm
12
Crash Client - Intel’s corewatcher
• Mechanism.
• How to upload crashes to server.
• Crash report file: /var/lib/corewatcher/processed/*.txt.

Recommended for you

망고100 보드로 놀아보자 15
망고100 보드로 놀아보자 15망고100 보드로 놀아보자 15
망고100 보드로 놀아보자 15

The document describes how to port and modify drivers for UART, Ethernet, LCD, and keypad on a Mango100 board running Android. It provides instructions on configuring the kernel, modifying driver source code files, and checking that the drivers are functioning properly. Key steps include enabling drivers in the kernel .config file, adding device registration code, and modifying functions to set GPIO pins and timing parameters for devices like the LCD. It also explains how to view input events in logcat and trace the flow of key events through the Android framework.

Creating "Secure" PHP applications, Part 2, Server Hardening
Creating "Secure" PHP applications, Part 2, Server HardeningCreating "Secure" PHP applications, Part 2, Server Hardening
Creating "Secure" PHP applications, Part 2, Server Hardening

The document provides guidance on server hardening techniques. It discusses using netstat to view listening services on a server and using update-rc.d or chkconfig to disable unnecessary services from starting at boot. It also recommends enabling access control lists (ACLs) in file system mounts, using SELinux or AppArmor to enforce mandatory access controls, and setting reasonable PHP memory limits to prevent potential denial of service attacks. The document stresses the importance of only allowing approved applications to execute and knowing the resource limits of the server to avoid potential outages.

Make ARM Shellcode Great Again
Make ARM Shellcode Great AgainMake ARM Shellcode Great Again
Make ARM Shellcode Great Again

Slides from my presentation on ARM Shellcode at #44CON 2018, London. In this talk, we explore ARM egghunting and "Quantum Leap" code - polyglot ARM shellcode. A bonus side effect of this talk will be creating headaches for those who like to defend agaisnt attacks using age old signature based techniques.

therealsaumilarmshellcode
13
Crash Client - Intel’s corewatcher
• Mechanism.
• Corewatcher as daemon
• Listen to /var/lib/corewatcher/
• When crash comes, invoke gdb to analysis
• Upload crashes to CrashDB server
• Environment about corewatcher
• /proc/sys/kernel/core_pattern=/var/lib/corewatcher/core_%e_%t
• core_uses_pid=1
bt full
info shared
14
Crash Client - Intel’s corewatcher
• CrashDB server: https://tz.otcshare.org/crashdb/
• How to upload crash to server
• WWLAN(3G/2G)
• WiFi/SED
• crash_submit: http://otcqa.sh.intel.com/wiki/Crash_Submit
Even though tz.otcshare.org has security restriction(403 forbidden outside of
Intel), crash submit is allowed.
15
Crash Client - Intel’s corewatcher
• Crash report path: /var/lib/corewatcher/processed/*.txt
• Crash report content(without debug info):
cmdline: /usr/bin/mate-calc
version: 2.1.0
backtrace: |
#0 0x00007fd494c2db41 in g_logv () from /usr/lib64/libglib-2.0.so.0
#0 0x00007fd494c2db41 in g_logv () from /usr/lib64/libglib-2.0.so.0
#1 0x00007fd494c2dcfd in g_log () from /usr/lib64/libglib-2.0.so.0
#2 0x00007fd4959a10ee in g_settings_set_property () from /usr/lib64/libgio-2.0.so.0
#3 0x00007fd4956ae098 in g_object_constructor () from /usr/lib64/libgobject-2.0.so.0
#4 0x00007fd4956af562 in g_object_newv () from /usr/lib64/libgobject-2.0.so.0
16
Crash Client - Intel’s corewatcher
• Crash report content(without debug info):
maps: |
0x00007fd4971f5f00 0x00007fd49745ecf0 Yes (*) /usr/lib64/libgtk-x11-2.0.so.0
0x00007fd496ef7420 0x00007fd496f4ccb8 Yes (*) /usr/lib64/libgdk-x11-2.0.so.0
0x00007fd496cc0030 0x00007fd496ccc290 Yes (*) /usr/lib64/libatk-1.0.so.0
0x00007fd496aa8490 0x00007fd496ab05bc Yes (*) /usr/lib64/libpangoft2-1.0.so.0
0x00007fd496898f20 0x00007fd49689dd14 Yes (*) /usr/lib64/libpangocairo-1.0.so.0
0x00007fd49667aa80 0x00007fd49668c018 Yes (*) /usr/lib64/libgdk_pixbuf-2.0.so.0
0x00007fd496377cc0 0x00007fd49643941c Yes (*) /usr/lib64/libcairo.so.2
0x00007fd496127680 0x00007fd496146fe0 Yes (*) /usr/lib64/libpango-1.0.so.0
0x00007fd495e95a90 0x00007fd495ef1fa4 Yes (*) /usr/lib64/libfreetype.so.6
(*): Shared library is missing debugging information.

Recommended for you

iCloud keychain
iCloud keychainiCloud keychain
iCloud keychain

IF YOU ARE CONCERNED ABOUT CLOUD SECURITY PLEASE READ http://blog.hackapp.com/2014/09/what-if-i-was-cloud.html

ios icloid security appleapple
Linux kernel debugging(PDF format)
Linux kernel debugging(PDF format)Linux kernel debugging(PDF format)
Linux kernel debugging(PDF format)

The document discusses kernel debugging techniques. It covers analyzing kernel error logs, debugging memory errors, detecting kernel deadlocks, and troubleshooting login issues. The key debugging steps involve prerequisites like having the kernel source code, reading the error logs and call traces to understand the bug, and tracing from assembly to C code to transactions. Memory debugging tools like AddressSanitizer are also covered.

kerneldebugging
OpenSPARC
OpenSPARCOpenSPARC
OpenSPARC

The document discusses SPARC, an open instruction set architecture developed by Sun Microsystems. It provides an overview of SPARC features such as the 32-bit and 64-bit versions, 128 general purpose registers, and floating-point unit capabilities. It also describes the register window mechanism and how it is used in a "Hello World" program example.

17
Crash Client - Intel’s corewatcher
• Crash report content(with debug info):
backtrace: |
#0 g_logv (log_domain=0x7f3d296fbfe1 "GLib-GIO", log_level=G_LOG_LEVEL_ERROR,
format=<optimized out>, args=args@entry=0x7fff7ea01e58) at gmessages.h:101
#0 g_logv (log_domain=0x7f3d296fbfe1 "GLib-GIO", log_level=G_LOG_LEVEL_ERROR,
format=<optimized out>, args=args@entry=0x7fff7ea01e58) at gmessages.h:101
#1 0x00007f3d28941cfd in g_log (log_domain=log_domain@entry=0x7f3d296fbfe1 "GLib-GIO",
log_level=log_level@entry=G_LOG_LEVEL_ERROR, format=format@entry=0x7f3d29717dc0 "Settings schema '%s'
is not installedn") at gmessages.c:1003
#2 0x00007f3d296b50ee in g_settings_set_property (object=<optimized out>, prop_id=<optimized
out>, value=<optimized out>, pspec=<optimized out>) at gsettings.c:492
#3 0x00007f3d293c2098 in object_set_property (nqueue=0xf90e60, value=0xf96408,
pspec=0xf95ca0, object=0xf95540) at gobject.c:1357
18
Crash Client - Intel’s corewatcher
• Crash report content(with debug info):
maps: |
From To Syms Read Shared Object Library
No linux-vdso.so.1
0x00007f3d2af09f00 0x00007f3d2b172cf0 Yes /usr/lib64/libgtk-x11-2.0.so.0
0x00007f3d2ac0b420 0x00007f3d2ac60cb8 Yes /usr/lib64/libgdk-x11-2.0.so.0
0x00007f3d2a9d4030 0x00007f3d2a9e0290 Yes /usr/lib64/libatk-1.0.so.0
0x00007f3d2a7bc490 0x00007f3d2a7c45bc Yes /usr/lib64/libpangoft2-1.0.so.0
0x00007f3d2a5acf20 0x00007f3d2a5b1d14 Yes /usr/lib64/libpangocairo-1.0.so.0
0x00007f3d2a38ea80 0x00007f3d2a3a0018 Yes /usr/lib64/libgdk_pixbuf-2.0.so.0
(*): Shared library is missing debugging information.
19
Crash Client - Intel’s corewatcher
• Crash report path: /var/lib/corewatcher/processed/*.txt
• Crash report content(without debug info):
cmdline: /usr/bin/mate-calc
version: 2.1.0
backtrace: |
#0 0x00007fd494c2db41 in g_logv () from /usr/lib64/libglib-2.0.so.0
#0 0x00007fd494c2db41 in g_logv () from /usr/lib64/libglib-2.0.so.0
#1 0x00007fd494c2dcfd in g_log () from /usr/lib64/libglib-2.0.so.0
#2 0x00007fd4959a10ee in g_settings_set_property () from /usr/lib64/libgio-2.0.so.0
#3 0x00007fd4956ae098 in g_object_constructor () from /usr/lib64/libgobject-2.0.so.0
#4 0x00007fd4956af562 in g_object_newv () from /usr/lib64/libgobject-2.0.so.0
Quality: 66
20
Crash Client - Intel’s corewatcher
• Crash report content(with debug info):
backtrace: |
#0 g_logv (log_domain=0x7f3d296fbfe1 "GLib-GIO", log_level=G_LOG_LEVEL_ERROR,
format=<optimized out>, args=args@entry=0x7fff7ea01e58) at gmessages.h:101
#0 g_logv (log_domain=0x7f3d296fbfe1 "GLib-GIO", log_level=G_LOG_LEVEL_ERROR,
format=<optimized out>, args=args@entry=0x7fff7ea01e58) at gmessages.h:101
#1 0x00007f3d28941cfd in g_log (log_domain=log_domain@entry=0x7f3d296fbfe1 "GLib-GIO",
log_level=log_level@entry=G_LOG_LEVEL_ERROR, format=format@entry=0x7f3d29717dc0 "Settings schema '%s'
is not installedn") at gmessages.c:1003
#2 0x00007f3d296b50ee in g_settings_set_property (object=<optimized out>, prop_id=<optimized
out>, value=<optimized out>, pspec=<optimized out>) at gsettings.c:492
#3 0x00007f3d293c2098 in object_set_property (nqueue=0xf90e60, value=0xf96408,
pspec=0xf95ca0, object=0xf95540) at gobject.c:1357
Quality 100

Recommended for you

TIP1 - Overview of C/C++ Debugging/Tracing/Profiling Tools
TIP1 - Overview of C/C++ Debugging/Tracing/Profiling ToolsTIP1 - Overview of C/C++ Debugging/Tracing/Profiling Tools
TIP1 - Overview of C/C++ Debugging/Tracing/Profiling Tools

This document provides an overview and comparison of various tools for debugging, profiling, and tracing C/C++ programs on Linux. It discusses concepts and implementations of debugging tools like gdb and Valgrind, profiling tools like gprof and perf, and tracing tools like strace, SystemTap, and LTTng. For each tool, it provides examples of common use cases and highlights strengths and limitations. The document aims to help developers select the appropriate tool based on their specific needs such as debugging memory errors, profiling performance bottlenecks, or tracing system calls.

profilecc++
Honeypots: Visão Geral
Honeypots: Visão GeralHoneypots: Visão Geral
Honeypots: Visão Geral

The document discusses honeypots, which are computer resources dedicated to being probed, attacked, or compromised. Honeypots can be used to detect internal attacks, identify scans and automated attacks, identify trends, keep attackers away from important systems, and collect signatures of attacks and malicious code. They work by emulating known vulnerabilities to collect information about attacks. Honeypots include low and high interaction varieties. Popular honeypot software includes Honeyd, which simulates virtual networks, and Nepenthes, which emulates vulnerabilities to capture binaries and commands executed by worms. Logs from honeypots can be analyzed to identify attack sources and collect malware samples.

securityhackinghoneypots
Spectre(v1%2 fv2%2fv4) v.s. meltdown(v3)
Spectre(v1%2 fv2%2fv4) v.s. meltdown(v3)Spectre(v1%2 fv2%2fv4) v.s. meltdown(v3)
Spectre(v1%2 fv2%2fv4) v.s. meltdown(v3)

Since the emerging of the OpenStack cloud computing platform in the Ubuntu community, increasing number of public/private cloud service providers choose to deploy it all over the world. Recently, Spectre and Meltdown have caused a panic in the world and the Spectre V2 is the only one which can attack the host system from the guest VM. It's vital to know the detailed process of the attack. Gavin Guo will give a detail explanation and an example of how to attack the host system. Besides, v1/v3/v4 are also introduced in the slide.

spectremeltdownssb
21
Crash Client - Intel’s corewatcher
• Example (before submit):
root@xiuhua:~# sdb root on
Switched to 'root' account mode
root@xiuhua:~# sdb shell
sh-4.1# find /var/lib/corewatcher/
/var/lib/corewatcher/
/var/lib/corewatcher/processed
/var/lib/corewatcher/processed/core_top_1398992161.1307.processed
/var/lib/corewatcher/processed/core_top_1398992226.1333.processed
/var/lib/corewatcher/processed/top_1398992226.txt
/var/lib/corewatcher/processed/top_1398992161.txt
22
Crash Client - Intel’s corewatcher
• Example (after submitted):
root@xiuhua:~# sdb root on
Switched to 'root' account mode
root@xiuhua:~# sdb shell
sh-4.1# find /var/lib/corewatcher/
/var/lib/corewatcher/
/var/lib/corewatcher/processed
/var/lib/corewatcher/processed/core_top_1398992161.1307.submitted
/var/lib/corewatcher/processed/core_top_1398992226.1333.submitted
/var/lib/corewatcher/processed/top_1398992226.txt
/var/lib/corewatcher/processed/top_1398992161.txt
23
Agenda
• Crash Client
• Samsung’s crash-work-sdk
• Intel’s corewatcher(3rd Gen)
• Crash Server
• CrashDB Web
• Crash reason location algrithm
24
Crash Server – CrashDB Web
• Production Env: https://tz.otcshare.org/crashdb/
• Demo: http://crashdb-y.sh.intel.com/

Recommended for you

eBPF Trace from Kernel to Userspace
eBPF Trace from Kernel to UserspaceeBPF Trace from Kernel to Userspace
eBPF Trace from Kernel to Userspace

This document discusses eBPF (extended Berkeley Packet Filter), which allows tracing from the Linux kernel to userspace using BPF programs. It provides an overview of eBPF including extended registers, verification, maps, and probes. Examples are given of using eBPF for tracing functions like kfree_skb() and the C library function malloc. The Berkeley Compiler Collection (BCC) makes it easy to write eBPF programs in C and Python.

linuxebpfkernel
bcc/BPF tools - Strategy, current tools, future challenges
bcc/BPF tools - Strategy, current tools, future challengesbcc/BPF tools - Strategy, current tools, future challenges
bcc/BPF tools - Strategy, current tools, future challenges

Brendan Gregg discusses the current state and future potential of BPF and BCC tools for observability in Linux. He outlines 18 areas where BPF support has progressed and 16 areas still needing work. Gregg also discusses challenges like dynamic tracing stability, overhead, ease of coding, and developing visualizations. He proposes finishing ports of his old DTrace tools and links to resources on BPF, BCC, and flame graphs.

io visor summitlinuxlinux foundation
Urqa - Android Crash Report
Urqa - Android Crash ReportUrqa - Android Crash Report
Urqa - Android Crash Report

UrQA is a mobile QA system that collects bug reports from Android apps to provide more detailed information than competitors like BugSense and ACRA. It displays an "event path" for each bug to show the steps to reproduce crashes, while competitors only show basic numbers. UrQA also uses a client-server architecture where the client handles native crashes and sends crash dumps to the server for analysis and storage.

25
Agenda
• Crash Client
• Samsung’s crash-work-sdk
• Intel’s corewatcher(3rd Gen)
• Crash Server
• CrashDB Web
• Crash reason location algrithm
26
Crash Server – Guilty Function Location
https://bugs.tizen.org/jira/browse/TIVI-649
'Security-server has closed unexpectedly' popped up when playing videos or launching clock
(gdb) bt
#0 0xb4e9c999 in vfprintf () from /lib/libc.so.6
#1 0xb4f3e7b4 in __vsnprintf_chk () from /lib/libc.so.6
#2 0xb5560c00 in __dlog_print () from /usr/lib/libdlog.so.0
#3 0x081019fd in process_cookie_request (sockfd=27) at /usr/src/debug/security-server-
0.0.61/src/security-srv/server/security-server-main.c:367
#4 0x08103b7e in security_server_thread (param=0xb451519c) at /usr/src/debug/security-server-
0.0.61/src/security-srv/server/security-server-main.c:923
#5 0xb554be19 in start_thread () from /lib/libpthread.so.0 #6 0xb4f2affe in clone () from
/lib/libc.so.6
27
Crash Server – Guilty Function Location
https://bugs.tizen.org/jira/browse/TIVI-649
'Security-server has closed unexpectedly' popped up when playing videos or launching clock
(gdb) bt
#0 0xb4e9c999 in vfprintf () from /lib/libc.so.6
#1 0xb4f3e7b4 in __vsnprintf_chk () from /lib/libc.so.6
#2 0xb5560c00 in __dlog_print () from /usr/lib/libdlog.so.0
#3 0x081019fd in process_cookie_request (sockfd=27) at /usr/src/debug/security-server-
0.0.61/src/security-srv/server/security-server-main.c:367
#4 0x08103b7e in security_server_thread (param=0xb451519c) at /usr/src/debug/security-server-
0.0.61/src/security-srv/server/security-server-main.c:923
#5 0xb554be19 in start_thread () from /lib/libpthread.so.0 #6 0xb4f2affe in clone () from
/lib/libc.so.6
28
Crash Server – Guilty Function Location
https://bugs.tizen.org/jira/browse/TIVI-649
'Security-server has closed unexpectedly' popped up when playing videos or launching clock
(gdb) bt
#0 0xb4e9c999 in vfprintf () from /lib/libc.so.6
#1 0xb4f3e7b4 in __vsnprintf_chk () from /lib/libc.so.6
#2 0xb5560c00 in __dlog_print () from /usr/lib/libdlog.so.0
#3 0x081019fd in process_cookie_request (sockfd=27) at /usr/src/debug/security-server-
0.0.61/src/security-srv/server/security-server-main.c:367
#4 0x08103b7e in security_server_thread (param=0xb451519c) at /usr/src/debug/security-server-
0.0.61/src/security-srv/server/security-server-main.c:923
#5 0xb554be19 in start_thread () from /lib/libpthread.so.0 #6 0xb4f2affe in clone () from
/lib/libc.so.6
Guilty Function

Recommended for you

PCD - Process control daemon - Presentation
PCD - Process control daemon - PresentationPCD - Process control daemon - Presentation
PCD - Process control daemon - Presentation

PCD – Process Control Daemon is a light-weight system level process manager for Embedded-Linux based projects (consumer electronics, network devices, etc.). PCD starts, stops and monitors all the user space processes in the system, in a synchronized manner, using a textual configuration file. PCD recovers the system in case of errors and provides useful and detailed debug information.

controlstartupcrashes
Devel::NYTProf v5 at YAPC::NA 201406
Devel::NYTProf v5 at YAPC::NA 201406Devel::NYTProf v5 at YAPC::NA 201406
Devel::NYTProf v5 at YAPC::NA 201406

Slides of my talk on Devel::NYTProf and optimizing perl code at YAPC::NA in June 2014. It covers use of NYTProf and outlines a multi-phase approach to optimizing your perl code. A video of the talk and questions is available at https://www.youtube.com/watch?v=T7EK6RZAnEA&list=UU7y4qaRSb5w2O8cCHOsKZDw

nytprofperlperl5
Android Memory , Where is all My RAM
Android Memory , Where is all My RAM Android Memory , Where is all My RAM
Android Memory , Where is all My RAM

This document discusses Android memory management. It explains that Android does not have swap space and relies on garbage collection. It describes the different memory regions in Android including the Java heap, native heap, and ashmem. It provides tips on increasing heap size, viewing heap updates, and how Android manages memory through processes. It also covers topics like memory leaks, references, and tools for analyzing memory usage.

androidleakcanaryram
29
Crash Server – Guilty Function Location
(gdb) f 3
#3 0x081019fd in process_cookie_request (sockfd=27) at /usr/src/debug/security-server-
0.0.61/src/security-srv/server/security-server-main.c:367
367 SEC_SVR_DBG("Server: Cookie created for client PID %d LABEL >%s<",
(gdb) p created_cookie->smack_label
$2 = 0x1777 <Address 0x1777 out of bounds> (gdb) p *created_cookie $4 = {cookie =
"270217{257354063221 e筗Y370230~021024004244", path_len = 49, permission_len = 90, pid =
1562, path = 0x85e0ba8 "/usr/apps/org.tizen.video-player/bin/video-player", permissions = 0x85b6168,
smack_label = 0x1777 <Address 0x1777 out of bounds>, prev = 0x8589190, next = 0x0}
30
Crash Server – Guilty Function Location
https://bugs.tizen.org/jira/browse/TIVI-649
'Security-server has closed unexpectedly' popped up when playing videos or launching clock
(gdb) bt
#0 0xb4e9c999 in vfprintf () from /lib/libc.so.6
#1 0xb4f3e7b4 in __vsnprintf_chk () from /lib/libc.so.6
#2 0xb5560c00 in __dlog_print () from /usr/lib/libdlog.so.0
#3 0x081019fd in process_cookie_request (sockfd=27) at /usr/src/debug/security-server-
0.0.61/src/security-srv/server/security-server-main.c:367
#4 0x08103b7e in security_server_thread (param=0xb451519c) at /usr/src/debug/security-server-
0.0.61/src/security-srv/server/security-server-main.c:923
#5 0xb554be19 in start_thread () from /lib/libpthread.so.0 #6 0xb4f2affe in clone () from
/lib/libc.so.6
White list
• /lib/libc.so.6
• /usr/lib/libdlog.so.0
31
Crash Server – Guilty Function Location
https://bugs.tizen.org/jira/browse/TIVI-649
'Security-server has closed unexpectedly' popped up when playing videos or launching clock
(gdb) bt
#0 0xb4e9c999 in vfprintf () from /lib/libc.so.6
#1 0xb4f3e7b4 in __vsnprintf_chk () from /lib/libc.so.6
#2 0xb5560c00 in __dlog_print () from /usr/lib/libdlog.so.0
#3 0x081019fd in process_cookie_request (sockfd=27) at /usr/src/debug/security-server-
0.0.61/src/security-srv/server/security-server-main.c:367
#4 0x08103b7e in security_server_thread (param=0xb451519c) at /usr/src/debug/security-server-
0.0.61/src/security-srv/server/security-server-main.c:923
#5 0xb554be19 in start_thread () from /lib/libpthread.so.0 #6 0xb4f2affe in clone () from
/lib/libc.so.6
White list
• /lib/libc.so.6
• /usr/lib/libdlog.so.0
Guilty Function
Q & A

Recommended for you

Controlling Memory Footprint at All Layers: Linux Kernel, Applications, Libra...
Controlling Memory Footprint at All Layers: Linux Kernel, Applications, Libra...Controlling Memory Footprint at All Layers: Linux Kernel, Applications, Libra...
Controlling Memory Footprint at All Layers: Linux Kernel, Applications, Libra...

Reducing memory usage is well covered in the history of this conference, yet new tricks still do exist. When optimizing memory footprint for an home gateway device, the author found some unexpected places where small changes can save valuable amount of DRAM or Flash space. This talk will visit different areas including - Kernel: fragmentation threshold, page frame reclamation task and atomic memory. Application level: Memory inefficient shared libraries due to ABI compliance and dynamic loading. Toolchain: Tuning malloc allocator parameters and compiler options. System level: General kernel might be more memory efficient than MMU-less uClinux, and preventing lock up when the system is on the brink of running out of memory.

linuxmemorylinux kernel
Perl Memory Use 201209
Perl Memory Use 201209Perl Memory Use 201209
Perl Memory Use 201209

Slides for my Perl Memory Use talk at YAPC::Asia in Tokyo, September 2012. (This uploaded version includes quite a few slides from the OSCON version that I skipped at YAPC::Asia in order to have more time for a demo.)

yapcasiaperlperl5
Poster_Jan
Poster_JanPoster_Jan
Poster_Jan

This document discusses profiling the AllPaths-LG genome assembler to optimize its performance. It analyzed the CPU and memory usage of each program step on various systems. The profiling identified seven routines that use the most CPU time and I/O. Modules like FindErrors, AlignReads, and CommonPather were prioritized for optimization to reduce assembly time. Future work will involve more detailed profiling and exploring code optimizations for the most resource-intensive modules.

Thanks

More Related Content

What's hot

Linux 系統管理與安全:進階系統管理系統防駭與資訊安全
Linux 系統管理與安全:進階系統管理系統防駭與資訊安全Linux 系統管理與安全:進階系統管理系統防駭與資訊安全
Linux 系統管理與安全:進階系統管理系統防駭與資訊安全
維泰 蔡
 
No instrumentation Golang Logging with eBPF (GoSF talk 11/11/20)
No instrumentation Golang Logging with eBPF (GoSF talk 11/11/20)No instrumentation Golang Logging with eBPF (GoSF talk 11/11/20)
No instrumentation Golang Logging with eBPF (GoSF talk 11/11/20)
Pixie Labs
 
Linux 系統管理與安全:基本 Linux 系統知識
Linux 系統管理與安全:基本 Linux 系統知識Linux 系統管理與安全:基本 Linux 系統知識
Linux 系統管理與安全:基本 Linux 系統知識
維泰 蔡
 
Cisco IOS shellcode: All-in-one
Cisco IOS shellcode: All-in-oneCisco IOS shellcode: All-in-one
Cisco IOS shellcode: All-in-one
DefconRussia
 
Tracer Evaluation
Tracer EvaluationTracer Evaluation
Tracer Evaluation
Qiao Han
 
Solaris Kernel Debugging V1.0
Solaris Kernel Debugging V1.0Solaris Kernel Debugging V1.0
Solaris Kernel Debugging V1.0
Jarod Wang
 
HackLU 2018 Make ARM Shellcode Great Again
HackLU 2018 Make ARM Shellcode Great AgainHackLU 2018 Make ARM Shellcode Great Again
HackLU 2018 Make ARM Shellcode Great Again
Saumil Shah
 
W8_2: Inside the UoS Educational Processor
W8_2: Inside the UoS Educational ProcessorW8_2: Inside the UoS Educational Processor
W8_2: Inside the UoS Educational Processor
Daniel Roggen
 
Linux Capabilities - eng - v2.1.5, compact
Linux Capabilities - eng - v2.1.5, compactLinux Capabilities - eng - v2.1.5, compact
Linux Capabilities - eng - v2.1.5, compact
Alessandro Selli
 
망고100 보드로 놀아보자 15
망고100 보드로 놀아보자 15망고100 보드로 놀아보자 15
망고100 보드로 놀아보자 15
종인 전
 
Creating "Secure" PHP applications, Part 2, Server Hardening
Creating "Secure" PHP applications, Part 2, Server HardeningCreating "Secure" PHP applications, Part 2, Server Hardening
Creating "Secure" PHP applications, Part 2, Server Hardening
archwisp
 
Make ARM Shellcode Great Again
Make ARM Shellcode Great AgainMake ARM Shellcode Great Again
Make ARM Shellcode Great Again
Saumil Shah
 
iCloud keychain
iCloud keychainiCloud keychain
iCloud keychain
Alexey Troshichev
 
Linux kernel debugging(PDF format)
Linux kernel debugging(PDF format)Linux kernel debugging(PDF format)
Linux kernel debugging(PDF format)
yang firo
 
OpenSPARC
OpenSPARCOpenSPARC
OpenSPARC
clairbee
 
TIP1 - Overview of C/C++ Debugging/Tracing/Profiling Tools
TIP1 - Overview of C/C++ Debugging/Tracing/Profiling ToolsTIP1 - Overview of C/C++ Debugging/Tracing/Profiling Tools
TIP1 - Overview of C/C++ Debugging/Tracing/Profiling Tools
Xiaozhe Wang
 
Honeypots: Visão Geral
Honeypots: Visão GeralHoneypots: Visão Geral
Honeypots: Visão Geral
bernardo_mr
 
Spectre(v1%2 fv2%2fv4) v.s. meltdown(v3)
Spectre(v1%2 fv2%2fv4) v.s. meltdown(v3)Spectre(v1%2 fv2%2fv4) v.s. meltdown(v3)
Spectre(v1%2 fv2%2fv4) v.s. meltdown(v3)
Gavin Guo
 
eBPF Trace from Kernel to Userspace
eBPF Trace from Kernel to UserspaceeBPF Trace from Kernel to Userspace
eBPF Trace from Kernel to Userspace
SUSE Labs Taipei
 
bcc/BPF tools - Strategy, current tools, future challenges
bcc/BPF tools - Strategy, current tools, future challengesbcc/BPF tools - Strategy, current tools, future challenges
bcc/BPF tools - Strategy, current tools, future challenges
IO Visor Project
 

What's hot (20)

Linux 系統管理與安全:進階系統管理系統防駭與資訊安全
Linux 系統管理與安全:進階系統管理系統防駭與資訊安全Linux 系統管理與安全:進階系統管理系統防駭與資訊安全
Linux 系統管理與安全:進階系統管理系統防駭與資訊安全
 
No instrumentation Golang Logging with eBPF (GoSF talk 11/11/20)
No instrumentation Golang Logging with eBPF (GoSF talk 11/11/20)No instrumentation Golang Logging with eBPF (GoSF talk 11/11/20)
No instrumentation Golang Logging with eBPF (GoSF talk 11/11/20)
 
Linux 系統管理與安全:基本 Linux 系統知識
Linux 系統管理與安全:基本 Linux 系統知識Linux 系統管理與安全:基本 Linux 系統知識
Linux 系統管理與安全:基本 Linux 系統知識
 
Cisco IOS shellcode: All-in-one
Cisco IOS shellcode: All-in-oneCisco IOS shellcode: All-in-one
Cisco IOS shellcode: All-in-one
 
Tracer Evaluation
Tracer EvaluationTracer Evaluation
Tracer Evaluation
 
Solaris Kernel Debugging V1.0
Solaris Kernel Debugging V1.0Solaris Kernel Debugging V1.0
Solaris Kernel Debugging V1.0
 
HackLU 2018 Make ARM Shellcode Great Again
HackLU 2018 Make ARM Shellcode Great AgainHackLU 2018 Make ARM Shellcode Great Again
HackLU 2018 Make ARM Shellcode Great Again
 
W8_2: Inside the UoS Educational Processor
W8_2: Inside the UoS Educational ProcessorW8_2: Inside the UoS Educational Processor
W8_2: Inside the UoS Educational Processor
 
Linux Capabilities - eng - v2.1.5, compact
Linux Capabilities - eng - v2.1.5, compactLinux Capabilities - eng - v2.1.5, compact
Linux Capabilities - eng - v2.1.5, compact
 
망고100 보드로 놀아보자 15
망고100 보드로 놀아보자 15망고100 보드로 놀아보자 15
망고100 보드로 놀아보자 15
 
Creating "Secure" PHP applications, Part 2, Server Hardening
Creating "Secure" PHP applications, Part 2, Server HardeningCreating "Secure" PHP applications, Part 2, Server Hardening
Creating "Secure" PHP applications, Part 2, Server Hardening
 
Make ARM Shellcode Great Again
Make ARM Shellcode Great AgainMake ARM Shellcode Great Again
Make ARM Shellcode Great Again
 
iCloud keychain
iCloud keychainiCloud keychain
iCloud keychain
 
Linux kernel debugging(PDF format)
Linux kernel debugging(PDF format)Linux kernel debugging(PDF format)
Linux kernel debugging(PDF format)
 
OpenSPARC
OpenSPARCOpenSPARC
OpenSPARC
 
TIP1 - Overview of C/C++ Debugging/Tracing/Profiling Tools
TIP1 - Overview of C/C++ Debugging/Tracing/Profiling ToolsTIP1 - Overview of C/C++ Debugging/Tracing/Profiling Tools
TIP1 - Overview of C/C++ Debugging/Tracing/Profiling Tools
 
Honeypots: Visão Geral
Honeypots: Visão GeralHoneypots: Visão Geral
Honeypots: Visão Geral
 
Spectre(v1%2 fv2%2fv4) v.s. meltdown(v3)
Spectre(v1%2 fv2%2fv4) v.s. meltdown(v3)Spectre(v1%2 fv2%2fv4) v.s. meltdown(v3)
Spectre(v1%2 fv2%2fv4) v.s. meltdown(v3)
 
eBPF Trace from Kernel to Userspace
eBPF Trace from Kernel to UserspaceeBPF Trace from Kernel to Userspace
eBPF Trace from Kernel to Userspace
 
bcc/BPF tools - Strategy, current tools, future challenges
bcc/BPF tools - Strategy, current tools, future challengesbcc/BPF tools - Strategy, current tools, future challenges
bcc/BPF tools - Strategy, current tools, future challenges
 

Viewers also liked

Urqa - Android Crash Report
Urqa - Android Crash ReportUrqa - Android Crash Report
Urqa - Android Crash Report
Hakbeom Hwang
 
PCD - Process control daemon - Presentation
PCD - Process control daemon - PresentationPCD - Process control daemon - Presentation
PCD - Process control daemon - Presentation
haish
 
Devel::NYTProf v5 at YAPC::NA 201406
Devel::NYTProf v5 at YAPC::NA 201406Devel::NYTProf v5 at YAPC::NA 201406
Devel::NYTProf v5 at YAPC::NA 201406
Tim Bunce
 
Android Memory , Where is all My RAM
Android Memory , Where is all My RAM Android Memory , Where is all My RAM
Android Memory , Where is all My RAM
Yossi Elkrief
 
Controlling Memory Footprint at All Layers: Linux Kernel, Applications, Libra...
Controlling Memory Footprint at All Layers: Linux Kernel, Applications, Libra...Controlling Memory Footprint at All Layers: Linux Kernel, Applications, Libra...
Controlling Memory Footprint at All Layers: Linux Kernel, Applications, Libra...
peknap
 
Perl Memory Use 201209
Perl Memory Use 201209Perl Memory Use 201209
Perl Memory Use 201209
Tim Bunce
 
Poster_Jan
Poster_JanPoster_Jan
Poster_Jan
Jan Salomon
 
Process control daemon
Process control daemonProcess control daemon
Process control daemon
haish
 
Workshop - Linux Memory Analysis with Volatility
Workshop - Linux Memory Analysis with VolatilityWorkshop - Linux Memory Analysis with Volatility
Workshop - Linux Memory Analysis with Volatility
Andrew Case
 
Александр Терещук - Memory Analyzer Tool and memory optimization tips in Android
Александр Терещук - Memory Analyzer Tool and memory optimization tips in AndroidАлександр Терещук - Memory Analyzer Tool and memory optimization tips in Android
Александр Терещук - Memory Analyzer Tool and memory optimization tips in Android
UA Mobile
 
Perl Memory Use - LPW2013
Perl Memory Use - LPW2013Perl Memory Use - LPW2013
Perl Memory Use - LPW2013
Tim Bunce
 
Memory in Android
Memory in AndroidMemory in Android
Memory in Android
Sergey Bandysik
 
Linux memory-management-kamal
Linux memory-management-kamalLinux memory-management-kamal
Linux memory-management-kamal
Kamal Maiti
 
Linux memory consumption
Linux memory consumptionLinux memory consumption
Linux memory consumption
haish
 
Memory management in linux
Memory management in linuxMemory management in linux
Memory management in linux
Dr. C.V. Suresh Babu
 
Christo kutrovsky oracle, memory & linux
Christo kutrovsky   oracle, memory & linuxChristo kutrovsky   oracle, memory & linux
Christo kutrovsky oracle, memory & linux
Kyle Hailey
 
Tuning Android for low RAM
Tuning Android for low RAMTuning Android for low RAM
Tuning Android for low RAM
Chris Simmonds
 
Tuning android for low ram devices
Tuning android for low ram devicesTuning android for low ram devices
Tuning android for low ram devices
Droidcon Berlin
 
Как Linux работает с памятью — Вячеслав Бирюков
Как Linux работает с памятью — Вячеслав БирюковКак Linux работает с памятью — Вячеслав Бирюков
Как Linux работает с памятью — Вячеслав Бирюков
Yandex
 
Android Performance Best Practices
Android Performance Best Practices Android Performance Best Practices
Android Performance Best Practices
Amgad Muhammad
 

Viewers also liked (20)

Urqa - Android Crash Report
Urqa - Android Crash ReportUrqa - Android Crash Report
Urqa - Android Crash Report
 
PCD - Process control daemon - Presentation
PCD - Process control daemon - PresentationPCD - Process control daemon - Presentation
PCD - Process control daemon - Presentation
 
Devel::NYTProf v5 at YAPC::NA 201406
Devel::NYTProf v5 at YAPC::NA 201406Devel::NYTProf v5 at YAPC::NA 201406
Devel::NYTProf v5 at YAPC::NA 201406
 
Android Memory , Where is all My RAM
Android Memory , Where is all My RAM Android Memory , Where is all My RAM
Android Memory , Where is all My RAM
 
Controlling Memory Footprint at All Layers: Linux Kernel, Applications, Libra...
Controlling Memory Footprint at All Layers: Linux Kernel, Applications, Libra...Controlling Memory Footprint at All Layers: Linux Kernel, Applications, Libra...
Controlling Memory Footprint at All Layers: Linux Kernel, Applications, Libra...
 
Perl Memory Use 201209
Perl Memory Use 201209Perl Memory Use 201209
Perl Memory Use 201209
 
Poster_Jan
Poster_JanPoster_Jan
Poster_Jan
 
Process control daemon
Process control daemonProcess control daemon
Process control daemon
 
Workshop - Linux Memory Analysis with Volatility
Workshop - Linux Memory Analysis with VolatilityWorkshop - Linux Memory Analysis with Volatility
Workshop - Linux Memory Analysis with Volatility
 
Александр Терещук - Memory Analyzer Tool and memory optimization tips in Android
Александр Терещук - Memory Analyzer Tool and memory optimization tips in AndroidАлександр Терещук - Memory Analyzer Tool and memory optimization tips in Android
Александр Терещук - Memory Analyzer Tool and memory optimization tips in Android
 
Perl Memory Use - LPW2013
Perl Memory Use - LPW2013Perl Memory Use - LPW2013
Perl Memory Use - LPW2013
 
Memory in Android
Memory in AndroidMemory in Android
Memory in Android
 
Linux memory-management-kamal
Linux memory-management-kamalLinux memory-management-kamal
Linux memory-management-kamal
 
Linux memory consumption
Linux memory consumptionLinux memory consumption
Linux memory consumption
 
Memory management in linux
Memory management in linuxMemory management in linux
Memory management in linux
 
Christo kutrovsky oracle, memory & linux
Christo kutrovsky   oracle, memory & linuxChristo kutrovsky   oracle, memory & linux
Christo kutrovsky oracle, memory & linux
 
Tuning Android for low RAM
Tuning Android for low RAMTuning Android for low RAM
Tuning Android for low RAM
 
Tuning android for low ram devices
Tuning android for low ram devicesTuning android for low ram devices
Tuning android for low ram devices
 
Как Linux работает с памятью — Вячеслав Бирюков
Как Linux работает с памятью — Вячеслав БирюковКак Linux работает с памятью — Вячеслав Бирюков
Как Linux работает с памятью — Вячеслав Бирюков
 
Android Performance Best Practices
Android Performance Best Practices Android Performance Best Practices
Android Performance Best Practices
 

Similar to Crash_Report_Mechanism_In_Tizen

A little systemtap
A little systemtapA little systemtap
A little systemtap
yang bingwu
 
A little systemtap
A little systemtapA little systemtap
A little systemtap
yang bingwu
 
Reverse engineering Swisscom's Centro Grande Modem
Reverse engineering Swisscom's Centro Grande ModemReverse engineering Swisscom's Centro Grande Modem
Reverse engineering Swisscom's Centro Grande Modem
Cyber Security Alliance
 
OSSNA 2017 Performance Analysis Superpowers with Linux BPF
OSSNA 2017 Performance Analysis Superpowers with Linux BPFOSSNA 2017 Performance Analysis Superpowers with Linux BPF
OSSNA 2017 Performance Analysis Superpowers with Linux BPF
Brendan Gregg
 
PGCon 2014 - What Do You Mean my Database Server Core Dumped? - How to Inspec...
PGCon 2014 - What Do You Mean my Database Server Core Dumped? - How to Inspec...PGCon 2014 - What Do You Mean my Database Server Core Dumped? - How to Inspec...
PGCon 2014 - What Do You Mean my Database Server Core Dumped? - How to Inspec...
Faisal Akber
 
Debugging Ruby
Debugging RubyDebugging Ruby
Debugging Ruby
Aman Gupta
 
Automated reduction of attack surface using call graph enumeration
Automated reduction of attack surface using call graph enumerationAutomated reduction of attack surface using call graph enumeration
Automated reduction of attack surface using call graph enumeration
Ruo Ando
 
Labs_BT_20221017.pptx
Labs_BT_20221017.pptxLabs_BT_20221017.pptx
Labs_BT_20221017.pptx
ssuserb4d806
 
Linux 4.x Tracing: Performance Analysis with bcc/BPF
Linux 4.x Tracing: Performance Analysis with bcc/BPFLinux 4.x Tracing: Performance Analysis with bcc/BPF
Linux 4.x Tracing: Performance Analysis with bcc/BPF
Brendan Gregg
 
Debugging 2013- Jesper Brouer
Debugging 2013- Jesper BrouerDebugging 2013- Jesper Brouer
Debugging 2013- Jesper Brouer
Mediehuset Ingeniøren Live
 
hacking-embedded-devices.pptx
hacking-embedded-devices.pptxhacking-embedded-devices.pptx
hacking-embedded-devices.pptx
ssuserfcf43f
 
Basic Linux kernel
Basic Linux kernelBasic Linux kernel
Basic Linux kernel
Morteza Nourelahi Alamdari
 
HKG18-TR14 - Postmortem Debugging with Coresight
HKG18-TR14 - Postmortem Debugging with CoresightHKG18-TR14 - Postmortem Debugging with Coresight
HKG18-TR14 - Postmortem Debugging with Coresight
Linaro
 
OSDC 2017 - Werner Fischer - Linux performance profiling and monitoring
OSDC 2017 - Werner Fischer - Linux performance profiling and monitoringOSDC 2017 - Werner Fischer - Linux performance profiling and monitoring
OSDC 2017 - Werner Fischer - Linux performance profiling and monitoring
NETWAYS
 
Kernel Recipes 2017: Performance Analysis with BPF
Kernel Recipes 2017: Performance Analysis with BPFKernel Recipes 2017: Performance Analysis with BPF
Kernel Recipes 2017: Performance Analysis with BPF
Brendan Gregg
 
Kernel Recipes 2017 - Performance analysis Superpowers with Linux BPF - Brend...
Kernel Recipes 2017 - Performance analysis Superpowers with Linux BPF - Brend...Kernel Recipes 2017 - Performance analysis Superpowers with Linux BPF - Brend...
Kernel Recipes 2017 - Performance analysis Superpowers with Linux BPF - Brend...
Anne Nicolas
 
Performance tweaks and tools for Linux (Joe Damato)
Performance tweaks and tools for Linux (Joe Damato)Performance tweaks and tools for Linux (Joe Damato)
Performance tweaks and tools for Linux (Joe Damato)
Ontico
 
USENIX ATC 2017 Performance Superpowers with Enhanced BPF
USENIX ATC 2017 Performance Superpowers with Enhanced BPFUSENIX ATC 2017 Performance Superpowers with Enhanced BPF
USENIX ATC 2017 Performance Superpowers with Enhanced BPF
Brendan Gregg
 
Linux Kernel Crashdump
Linux Kernel CrashdumpLinux Kernel Crashdump
Linux Kernel Crashdump
Marian Marinov
 
Debugging Ruby Systems
Debugging Ruby SystemsDebugging Ruby Systems
Debugging Ruby Systems
Engine Yard
 

Similar to Crash_Report_Mechanism_In_Tizen (20)

A little systemtap
A little systemtapA little systemtap
A little systemtap
 
A little systemtap
A little systemtapA little systemtap
A little systemtap
 
Reverse engineering Swisscom's Centro Grande Modem
Reverse engineering Swisscom's Centro Grande ModemReverse engineering Swisscom's Centro Grande Modem
Reverse engineering Swisscom's Centro Grande Modem
 
OSSNA 2017 Performance Analysis Superpowers with Linux BPF
OSSNA 2017 Performance Analysis Superpowers with Linux BPFOSSNA 2017 Performance Analysis Superpowers with Linux BPF
OSSNA 2017 Performance Analysis Superpowers with Linux BPF
 
PGCon 2014 - What Do You Mean my Database Server Core Dumped? - How to Inspec...
PGCon 2014 - What Do You Mean my Database Server Core Dumped? - How to Inspec...PGCon 2014 - What Do You Mean my Database Server Core Dumped? - How to Inspec...
PGCon 2014 - What Do You Mean my Database Server Core Dumped? - How to Inspec...
 
Debugging Ruby
Debugging RubyDebugging Ruby
Debugging Ruby
 
Automated reduction of attack surface using call graph enumeration
Automated reduction of attack surface using call graph enumerationAutomated reduction of attack surface using call graph enumeration
Automated reduction of attack surface using call graph enumeration
 
Labs_BT_20221017.pptx
Labs_BT_20221017.pptxLabs_BT_20221017.pptx
Labs_BT_20221017.pptx
 
Linux 4.x Tracing: Performance Analysis with bcc/BPF
Linux 4.x Tracing: Performance Analysis with bcc/BPFLinux 4.x Tracing: Performance Analysis with bcc/BPF
Linux 4.x Tracing: Performance Analysis with bcc/BPF
 
Debugging 2013- Jesper Brouer
Debugging 2013- Jesper BrouerDebugging 2013- Jesper Brouer
Debugging 2013- Jesper Brouer
 
hacking-embedded-devices.pptx
hacking-embedded-devices.pptxhacking-embedded-devices.pptx
hacking-embedded-devices.pptx
 
Basic Linux kernel
Basic Linux kernelBasic Linux kernel
Basic Linux kernel
 
HKG18-TR14 - Postmortem Debugging with Coresight
HKG18-TR14 - Postmortem Debugging with CoresightHKG18-TR14 - Postmortem Debugging with Coresight
HKG18-TR14 - Postmortem Debugging with Coresight
 
OSDC 2017 - Werner Fischer - Linux performance profiling and monitoring
OSDC 2017 - Werner Fischer - Linux performance profiling and monitoringOSDC 2017 - Werner Fischer - Linux performance profiling and monitoring
OSDC 2017 - Werner Fischer - Linux performance profiling and monitoring
 
Kernel Recipes 2017: Performance Analysis with BPF
Kernel Recipes 2017: Performance Analysis with BPFKernel Recipes 2017: Performance Analysis with BPF
Kernel Recipes 2017: Performance Analysis with BPF
 
Kernel Recipes 2017 - Performance analysis Superpowers with Linux BPF - Brend...
Kernel Recipes 2017 - Performance analysis Superpowers with Linux BPF - Brend...Kernel Recipes 2017 - Performance analysis Superpowers with Linux BPF - Brend...
Kernel Recipes 2017 - Performance analysis Superpowers with Linux BPF - Brend...
 
Performance tweaks and tools for Linux (Joe Damato)
Performance tweaks and tools for Linux (Joe Damato)Performance tweaks and tools for Linux (Joe Damato)
Performance tweaks and tools for Linux (Joe Damato)
 
USENIX ATC 2017 Performance Superpowers with Enhanced BPF
USENIX ATC 2017 Performance Superpowers with Enhanced BPFUSENIX ATC 2017 Performance Superpowers with Enhanced BPF
USENIX ATC 2017 Performance Superpowers with Enhanced BPF
 
Linux Kernel Crashdump
Linux Kernel CrashdumpLinux Kernel Crashdump
Linux Kernel Crashdump
 
Debugging Ruby Systems
Debugging Ruby SystemsDebugging Ruby Systems
Debugging Ruby Systems
 

Crash_Report_Mechanism_In_Tizen

  • 1. Crash Report Mechanism in Tizen Yu Yucai, 2013/05/31
  • 2. 2 Agenda • Crash Client (Tizen 2.1.x) • Samsung’s crash-work-sdk • Intel’s corewatcher • Crash Server • CrashDB Web • Crash reason location algrithm
  • 3. 3 Agenda • Crash Client • Samsung’s crash-work-sdk • Intel’s corewatcher(3rd Gen) • Crash Server • CrashDB Web • Crash reason location algrithm
  • 4. 4 Crash Client - Samsung’s crash-work-sdk • Mechanism • Crash process flow • Crash report file: *.cs file
  • 5. 5 Crash Client - Samsung’s crash-work-sdk • Mechanism: force preload libsys-assert.so to overload crash signal handlers. sh-4.1# cat /etc/ld.so.preload /usr/lib/libsys-assert.so sh-4.1# ldd `which top` linux-gate.so.1 => (0xb77fd000) /usr/lib/libsys-assert.so (0xb77f5000) libproc-3.2.8.so => /lib/libproc-3.2.8.so (0xb77c1000) libncurses.so.5 => /usr/lib/libncurses.so.5 (0xb7781000) libc.so.6 => /lib/libc.so.6 (0xb7625000) libdl.so.2 => /lib/libdl.so.2 (0xb7621000) /lib/ld-linux.so.2 (0xb77fe000)
  • 6. 6 Crash Client - Samsung’s crash-work-sdk • Crash process flow Stage 1: in sys-assert.c (libsys-assert.so) -> int sig_to_handle[] = { SIGILL, SIGABRT, SIGBUS, SIGFPE, SIGSEGV, }; -> sighandler notify system_server via /opt/share/crash/curbs.log pipeline. Stage 2: in ss_bs.c (system-server) -> ecore_file_monitor_add(CRASH_NOTI_PATH,(void *) __crash_file_cb, NULL); -> __crash_file_cb: -> launch_crash_worker() ...... launch /usr/bin/crash-worker to generate cs file launch /usr/apps/org.tizen.crash-popup/bin/crash-popup to popup crash (only 1st)
  • 7. 7 Crash Client - Samsung’s crash-work-sdk • Crash process flow Breakpoint 1, launch_app_with_nice (file=0xb46017b0 "/usr/bin/crash-worker", argv=0xbfe52624, pid=0x0, _nice=0) at /usr/src/debug/system-server-0.1.65/ss_launch.c:140 140 { (gdb) bt #0 launch_app_with_nice (file=0xb46017b0 "/usr/bin/crash-worker", argv=0xbfe52624, pid=0x0, _nice=0) at /usr/src/debug/system-server-0.1.65/ss_launch.c:140 #1 0x0804d3c9 in launch_app_cmd_with_nice ( cmdline=0xb4601758 "/usr/bin/crash-worker S top 391655492 913 top", _nice=0) at /usr/src/debug/system-server-0.1.65/ss_launch.c:196 #2 0x0804d744 in ss_launch_evenif_exist ( execpath=0x8060e71 "/usr/bin/crash-worker", arg=0xbfe53d16 "S top 391655492 913 top") at /usr/src/debug/system-server-0.1.65/ss_launch.c:289 #3 0x08058b73 in launch_crash_worker ( filename=0xbfe5823c "/opt/share/crash/curbs.log", popup_on=1) at /usr/src/debug/system-server-0.1.65/ss_bs.c:327 #4 0x08058d47 in __crash_file_cb (data=0x0, em=0x8dabb10, event=ECORE_FILE_EVENT_MODIFIED, path=0xbfe5823c "/opt/share/crash/curbs.log") at /usr/src/debug/system-server-0.1.65/ss_bs.c:374 #5 0xb782f345 in _ecore_file_monitor_inotify_handler () from /usr/lib/libecore_file.so.1 #6 0xb7840e5c in _ecore_main_loop_iterate_internal () from /usr/lib/libecore.so.1 #7 0xb784141f in ecore_main_loop_begin () from /usr/lib/libecore.so.1 #8 0x0804bd95 in system_main (argc=1, argv=0xbfe59404) ---Type <return> to continue, or q <return> to quit--- at /usr/src/debug/system-server-0.1.65/ss_main.c:102 #9 0x0804bdf1 in elm_main (argc=1, argv=0xbfe59404) at /usr/src/debug/system-server-0.1.65/ss_main.c:112 #10 0x0804be4e in main (argc=1, argv=0xbfe59404) at /usr/src/debug/system-server-0.1.65/ss_main.c:119
  • 8. 8 Crash Client - Samsung’s crash-work-sdk • Crash process flow Stage 3: crash-worker to generate cs file sh-4.1# pwd /opt/usr/share/crash/report sh-4.1# ls -tlr total 72 -rwxrw-rw- 1 root app 22248 1982-05-02 18:28 top_19820502182857.cs -rwxrw-rw- 1 root app 22248 1982-05-02 18:39 top_19820502183647.cs -rwxrw-rw- 1 root app 22248 1982-05-02 18:49 top_19820502184511.cs
  • 9. 9 Crash Client - Samsung’s crash-work-sdk • What’s *.cs file. sh-4.1# cat top_19820502184511.cs S/W Version Information Model: handset-blackbay Tizen-Version: 2.1.0 Build-Number: Tizen_handset-blackbay-tizen-2.1- mobile_20130430.1 Build-Date: 2013.05.01 03:24:28 Crash Information PID: 1194 Date: 1982-05-02 18:45:11(GMT+0900) Executable File Path: top This process is multi-thread process pid=1194 tid=1194 Signal: 11 (SIGSEGV) si_code: 0 signal sent by kill (sent by pid 1195, uid 0) Register Information gs = 0x00000033, fs = 0x00000000 es = 0x0000007b, ds = 0x0000007b edi = 0x08057040, esi = 0x00000000 ebp = 0xbfe13b68, esp = 0xbfe13040 eax = 0xfffffffc, ebx = 0x00000001 ecx = 0xbfe1332c, edx = 0x00000000 eip = 0xb7896424 Memory Information MemTotal: 995664 KB MemFree: 457540 KB Buffers: 14768 KB Cached: 233204 KB VmPeak: 2748 KB VmSize: 2748 KB VmLck: 0 KB VmHWM: 1336 KB VmRSS: 1336 KB VmData: 492 KB VmStk: 136 KB
  • 10. 10 Crash Client - Samsung’s crash-work-sdk • What’s *.cs file. Maps Information 08048000 08056000 r-xp /usr/bin/top b7683000 b768d000 r-xp /lib/libnss_files-2.13.so b768f000 b7698000 r-xp /lib/libnss_nis-2.13.so b769a000 b76ad000 r-xp /lib/libnsl-2.13.so b76b1000 b76b7000 r-xp /lib/libnss_compat-2.13.so b76ba000 b76bc000 r-xp /lib/libdl-2.13.so b76be000 b7814000 r-xp /lib/libc-2.13.so b781a000 b7857000 r-xp /usr/lib/libncurses.so.5.7 b785a000 b7868000 r-xp /lib/libproc-3.2.8.so b788e000 b7892000 r-xp /usr/lib/libsys-assert.so b7896000 b7897000 r-xp [vdso] b7897000 b78b3000 r-xp /lib/ld-2.13.so End of Maps Information Callstack Information (PID:1194) Call Stack Count: 1 can't open 0: (0x8049a81) [top] + 0x1a81 End of Call Stack Latest Debug Message Information --------- beginning of /dev/log_main 05-02 16:31:42.769 E/Tizen::App( 616): void Tizen::App::_ConditionManagerStub::OnInstallComplete(const Tizen::App::AppId&)(133) > failed to GetAppLaunchConditionListN(org.tizen.taskmgr) … omPackageManager(const Tizen::Base::String&, const Tizen::Base::String&, const Tizen::Base::String&)(493) > Cannot acquire feature list. 05-02 16:31:43.819 E/Tizen::App( 616): void Tizen::App::_ End of latest debug message
  • 11. 11 Agenda • Crash Client • Samsung’s crash-work-sdk • Intel’s corewatcher(3rd Gen) • Crash Server • CrashDB Web • Crash reason location algrithm
  • 12. 12 Crash Client - Intel’s corewatcher • Mechanism. • How to upload crashes to server. • Crash report file: /var/lib/corewatcher/processed/*.txt.
  • 13. 13 Crash Client - Intel’s corewatcher • Mechanism. • Corewatcher as daemon • Listen to /var/lib/corewatcher/ • When crash comes, invoke gdb to analysis • Upload crashes to CrashDB server • Environment about corewatcher • /proc/sys/kernel/core_pattern=/var/lib/corewatcher/core_%e_%t • core_uses_pid=1 bt full info shared
  • 14. 14 Crash Client - Intel’s corewatcher • CrashDB server: https://tz.otcshare.org/crashdb/ • How to upload crash to server • WWLAN(3G/2G) • WiFi/SED • crash_submit: http://otcqa.sh.intel.com/wiki/Crash_Submit Even though tz.otcshare.org has security restriction(403 forbidden outside of Intel), crash submit is allowed.
  • 15. 15 Crash Client - Intel’s corewatcher • Crash report path: /var/lib/corewatcher/processed/*.txt • Crash report content(without debug info): cmdline: /usr/bin/mate-calc version: 2.1.0 backtrace: | #0 0x00007fd494c2db41 in g_logv () from /usr/lib64/libglib-2.0.so.0 #0 0x00007fd494c2db41 in g_logv () from /usr/lib64/libglib-2.0.so.0 #1 0x00007fd494c2dcfd in g_log () from /usr/lib64/libglib-2.0.so.0 #2 0x00007fd4959a10ee in g_settings_set_property () from /usr/lib64/libgio-2.0.so.0 #3 0x00007fd4956ae098 in g_object_constructor () from /usr/lib64/libgobject-2.0.so.0 #4 0x00007fd4956af562 in g_object_newv () from /usr/lib64/libgobject-2.0.so.0
  • 16. 16 Crash Client - Intel’s corewatcher • Crash report content(without debug info): maps: | 0x00007fd4971f5f00 0x00007fd49745ecf0 Yes (*) /usr/lib64/libgtk-x11-2.0.so.0 0x00007fd496ef7420 0x00007fd496f4ccb8 Yes (*) /usr/lib64/libgdk-x11-2.0.so.0 0x00007fd496cc0030 0x00007fd496ccc290 Yes (*) /usr/lib64/libatk-1.0.so.0 0x00007fd496aa8490 0x00007fd496ab05bc Yes (*) /usr/lib64/libpangoft2-1.0.so.0 0x00007fd496898f20 0x00007fd49689dd14 Yes (*) /usr/lib64/libpangocairo-1.0.so.0 0x00007fd49667aa80 0x00007fd49668c018 Yes (*) /usr/lib64/libgdk_pixbuf-2.0.so.0 0x00007fd496377cc0 0x00007fd49643941c Yes (*) /usr/lib64/libcairo.so.2 0x00007fd496127680 0x00007fd496146fe0 Yes (*) /usr/lib64/libpango-1.0.so.0 0x00007fd495e95a90 0x00007fd495ef1fa4 Yes (*) /usr/lib64/libfreetype.so.6 (*): Shared library is missing debugging information.
  • 17. 17 Crash Client - Intel’s corewatcher • Crash report content(with debug info): backtrace: | #0 g_logv (log_domain=0x7f3d296fbfe1 "GLib-GIO", log_level=G_LOG_LEVEL_ERROR, format=<optimized out>, args=args@entry=0x7fff7ea01e58) at gmessages.h:101 #0 g_logv (log_domain=0x7f3d296fbfe1 "GLib-GIO", log_level=G_LOG_LEVEL_ERROR, format=<optimized out>, args=args@entry=0x7fff7ea01e58) at gmessages.h:101 #1 0x00007f3d28941cfd in g_log (log_domain=log_domain@entry=0x7f3d296fbfe1 "GLib-GIO", log_level=log_level@entry=G_LOG_LEVEL_ERROR, format=format@entry=0x7f3d29717dc0 "Settings schema '%s' is not installedn") at gmessages.c:1003 #2 0x00007f3d296b50ee in g_settings_set_property (object=<optimized out>, prop_id=<optimized out>, value=<optimized out>, pspec=<optimized out>) at gsettings.c:492 #3 0x00007f3d293c2098 in object_set_property (nqueue=0xf90e60, value=0xf96408, pspec=0xf95ca0, object=0xf95540) at gobject.c:1357
  • 18. 18 Crash Client - Intel’s corewatcher • Crash report content(with debug info): maps: | From To Syms Read Shared Object Library No linux-vdso.so.1 0x00007f3d2af09f00 0x00007f3d2b172cf0 Yes /usr/lib64/libgtk-x11-2.0.so.0 0x00007f3d2ac0b420 0x00007f3d2ac60cb8 Yes /usr/lib64/libgdk-x11-2.0.so.0 0x00007f3d2a9d4030 0x00007f3d2a9e0290 Yes /usr/lib64/libatk-1.0.so.0 0x00007f3d2a7bc490 0x00007f3d2a7c45bc Yes /usr/lib64/libpangoft2-1.0.so.0 0x00007f3d2a5acf20 0x00007f3d2a5b1d14 Yes /usr/lib64/libpangocairo-1.0.so.0 0x00007f3d2a38ea80 0x00007f3d2a3a0018 Yes /usr/lib64/libgdk_pixbuf-2.0.so.0 (*): Shared library is missing debugging information.
  • 19. 19 Crash Client - Intel’s corewatcher • Crash report path: /var/lib/corewatcher/processed/*.txt • Crash report content(without debug info): cmdline: /usr/bin/mate-calc version: 2.1.0 backtrace: | #0 0x00007fd494c2db41 in g_logv () from /usr/lib64/libglib-2.0.so.0 #0 0x00007fd494c2db41 in g_logv () from /usr/lib64/libglib-2.0.so.0 #1 0x00007fd494c2dcfd in g_log () from /usr/lib64/libglib-2.0.so.0 #2 0x00007fd4959a10ee in g_settings_set_property () from /usr/lib64/libgio-2.0.so.0 #3 0x00007fd4956ae098 in g_object_constructor () from /usr/lib64/libgobject-2.0.so.0 #4 0x00007fd4956af562 in g_object_newv () from /usr/lib64/libgobject-2.0.so.0 Quality: 66
  • 20. 20 Crash Client - Intel’s corewatcher • Crash report content(with debug info): backtrace: | #0 g_logv (log_domain=0x7f3d296fbfe1 "GLib-GIO", log_level=G_LOG_LEVEL_ERROR, format=<optimized out>, args=args@entry=0x7fff7ea01e58) at gmessages.h:101 #0 g_logv (log_domain=0x7f3d296fbfe1 "GLib-GIO", log_level=G_LOG_LEVEL_ERROR, format=<optimized out>, args=args@entry=0x7fff7ea01e58) at gmessages.h:101 #1 0x00007f3d28941cfd in g_log (log_domain=log_domain@entry=0x7f3d296fbfe1 "GLib-GIO", log_level=log_level@entry=G_LOG_LEVEL_ERROR, format=format@entry=0x7f3d29717dc0 "Settings schema '%s' is not installedn") at gmessages.c:1003 #2 0x00007f3d296b50ee in g_settings_set_property (object=<optimized out>, prop_id=<optimized out>, value=<optimized out>, pspec=<optimized out>) at gsettings.c:492 #3 0x00007f3d293c2098 in object_set_property (nqueue=0xf90e60, value=0xf96408, pspec=0xf95ca0, object=0xf95540) at gobject.c:1357 Quality 100
  • 21. 21 Crash Client - Intel’s corewatcher • Example (before submit): root@xiuhua:~# sdb root on Switched to 'root' account mode root@xiuhua:~# sdb shell sh-4.1# find /var/lib/corewatcher/ /var/lib/corewatcher/ /var/lib/corewatcher/processed /var/lib/corewatcher/processed/core_top_1398992161.1307.processed /var/lib/corewatcher/processed/core_top_1398992226.1333.processed /var/lib/corewatcher/processed/top_1398992226.txt /var/lib/corewatcher/processed/top_1398992161.txt
  • 22. 22 Crash Client - Intel’s corewatcher • Example (after submitted): root@xiuhua:~# sdb root on Switched to 'root' account mode root@xiuhua:~# sdb shell sh-4.1# find /var/lib/corewatcher/ /var/lib/corewatcher/ /var/lib/corewatcher/processed /var/lib/corewatcher/processed/core_top_1398992161.1307.submitted /var/lib/corewatcher/processed/core_top_1398992226.1333.submitted /var/lib/corewatcher/processed/top_1398992226.txt /var/lib/corewatcher/processed/top_1398992161.txt
  • 23. 23 Agenda • Crash Client • Samsung’s crash-work-sdk • Intel’s corewatcher(3rd Gen) • Crash Server • CrashDB Web • Crash reason location algrithm
  • 24. 24 Crash Server – CrashDB Web • Production Env: https://tz.otcshare.org/crashdb/ • Demo: http://crashdb-y.sh.intel.com/
  • 25. 25 Agenda • Crash Client • Samsung’s crash-work-sdk • Intel’s corewatcher(3rd Gen) • Crash Server • CrashDB Web • Crash reason location algrithm
  • 26. 26 Crash Server – Guilty Function Location https://bugs.tizen.org/jira/browse/TIVI-649 'Security-server has closed unexpectedly' popped up when playing videos or launching clock (gdb) bt #0 0xb4e9c999 in vfprintf () from /lib/libc.so.6 #1 0xb4f3e7b4 in __vsnprintf_chk () from /lib/libc.so.6 #2 0xb5560c00 in __dlog_print () from /usr/lib/libdlog.so.0 #3 0x081019fd in process_cookie_request (sockfd=27) at /usr/src/debug/security-server- 0.0.61/src/security-srv/server/security-server-main.c:367 #4 0x08103b7e in security_server_thread (param=0xb451519c) at /usr/src/debug/security-server- 0.0.61/src/security-srv/server/security-server-main.c:923 #5 0xb554be19 in start_thread () from /lib/libpthread.so.0 #6 0xb4f2affe in clone () from /lib/libc.so.6
  • 27. 27 Crash Server – Guilty Function Location https://bugs.tizen.org/jira/browse/TIVI-649 'Security-server has closed unexpectedly' popped up when playing videos or launching clock (gdb) bt #0 0xb4e9c999 in vfprintf () from /lib/libc.so.6 #1 0xb4f3e7b4 in __vsnprintf_chk () from /lib/libc.so.6 #2 0xb5560c00 in __dlog_print () from /usr/lib/libdlog.so.0 #3 0x081019fd in process_cookie_request (sockfd=27) at /usr/src/debug/security-server- 0.0.61/src/security-srv/server/security-server-main.c:367 #4 0x08103b7e in security_server_thread (param=0xb451519c) at /usr/src/debug/security-server- 0.0.61/src/security-srv/server/security-server-main.c:923 #5 0xb554be19 in start_thread () from /lib/libpthread.so.0 #6 0xb4f2affe in clone () from /lib/libc.so.6
  • 28. 28 Crash Server – Guilty Function Location https://bugs.tizen.org/jira/browse/TIVI-649 'Security-server has closed unexpectedly' popped up when playing videos or launching clock (gdb) bt #0 0xb4e9c999 in vfprintf () from /lib/libc.so.6 #1 0xb4f3e7b4 in __vsnprintf_chk () from /lib/libc.so.6 #2 0xb5560c00 in __dlog_print () from /usr/lib/libdlog.so.0 #3 0x081019fd in process_cookie_request (sockfd=27) at /usr/src/debug/security-server- 0.0.61/src/security-srv/server/security-server-main.c:367 #4 0x08103b7e in security_server_thread (param=0xb451519c) at /usr/src/debug/security-server- 0.0.61/src/security-srv/server/security-server-main.c:923 #5 0xb554be19 in start_thread () from /lib/libpthread.so.0 #6 0xb4f2affe in clone () from /lib/libc.so.6 Guilty Function
  • 29. 29 Crash Server – Guilty Function Location (gdb) f 3 #3 0x081019fd in process_cookie_request (sockfd=27) at /usr/src/debug/security-server- 0.0.61/src/security-srv/server/security-server-main.c:367 367 SEC_SVR_DBG("Server: Cookie created for client PID %d LABEL >%s<", (gdb) p created_cookie->smack_label $2 = 0x1777 <Address 0x1777 out of bounds> (gdb) p *created_cookie $4 = {cookie = "270217{257354063221 e筗Y370230~021024004244", path_len = 49, permission_len = 90, pid = 1562, path = 0x85e0ba8 "/usr/apps/org.tizen.video-player/bin/video-player", permissions = 0x85b6168, smack_label = 0x1777 <Address 0x1777 out of bounds>, prev = 0x8589190, next = 0x0}
  • 30. 30 Crash Server – Guilty Function Location https://bugs.tizen.org/jira/browse/TIVI-649 'Security-server has closed unexpectedly' popped up when playing videos or launching clock (gdb) bt #0 0xb4e9c999 in vfprintf () from /lib/libc.so.6 #1 0xb4f3e7b4 in __vsnprintf_chk () from /lib/libc.so.6 #2 0xb5560c00 in __dlog_print () from /usr/lib/libdlog.so.0 #3 0x081019fd in process_cookie_request (sockfd=27) at /usr/src/debug/security-server- 0.0.61/src/security-srv/server/security-server-main.c:367 #4 0x08103b7e in security_server_thread (param=0xb451519c) at /usr/src/debug/security-server- 0.0.61/src/security-srv/server/security-server-main.c:923 #5 0xb554be19 in start_thread () from /lib/libpthread.so.0 #6 0xb4f2affe in clone () from /lib/libc.so.6 White list • /lib/libc.so.6 • /usr/lib/libdlog.so.0
  • 31. 31 Crash Server – Guilty Function Location https://bugs.tizen.org/jira/browse/TIVI-649 'Security-server has closed unexpectedly' popped up when playing videos or launching clock (gdb) bt #0 0xb4e9c999 in vfprintf () from /lib/libc.so.6 #1 0xb4f3e7b4 in __vsnprintf_chk () from /lib/libc.so.6 #2 0xb5560c00 in __dlog_print () from /usr/lib/libdlog.so.0 #3 0x081019fd in process_cookie_request (sockfd=27) at /usr/src/debug/security-server- 0.0.61/src/security-srv/server/security-server-main.c:367 #4 0x08103b7e in security_server_thread (param=0xb451519c) at /usr/src/debug/security-server- 0.0.61/src/security-srv/server/security-server-main.c:923 #5 0xb554be19 in start_thread () from /lib/libpthread.so.0 #6 0xb4f2affe in clone () from /lib/libc.so.6 White list • /lib/libc.so.6 • /usr/lib/libdlog.so.0 Guilty Function
  • 32. Q & A