When a process is down - how to get a coredump in arm board?


 
Thread Tools Search this Thread
Top Forums Programming When a process is down - how to get a coredump in arm board?
# 8  
Old 03-06-2010
Quote:
Originally Posted by Loic Domaigne
Perhaps no enough space available on the flash to write the core dump?
Smilie
# 9  
Old 03-09-2010
Actually . I test , the collapse has nothing to do with the signal SIGSEGV or whether it has enough space .

I use signal function . but can't catch SIGSEGV when it's down .


I really have no idea!
# 10  
Old 03-09-2010
Quote:
Originally Posted by aobai
I use signal function . but can't catch SIGSEGV when it's down.
I don't think that quite translated, try again?
# 11  
Old 03-09-2010
The result of an unhandled signal and the value (name sometimes, too) for each flavor of unix varies. Here is a list, your system may vary
Quote:
SIGNAL ID DEFAULT DESCRIPTION
======================================================================
SIGHUP 1 Termin. Hang up on controlling terminal
SIGINT 2 Termin. Interrupt. Generated when we enter CNRTL-C
and it is delivered to all processes/threads
associated to the current terminal. If
generated with kill, it is delivered to only
one process/thread.
SIGQUIT 3 Core Generated when at terminal we enter CNRTL-\
SIGILL 4 Core Generated when we executed an illegal instruction
SIGTRAP 5 Core Trace trap (not reset when caught)
SIGABRT 6 Core Generated by the abort function
SIGFPE 8 Core Floating Point error
SIGKILL 9 Termin. Termination (can't catch, block, ignore)
SIGBUS 10 Core Generated in case of hardware fault
SIGSEGV 11 Core Generated in case of illegal address
SIGSYS 12 Core Generated when we use a bad argument in a
system service call
SIGPIPE 13 Termin. Generated when writing to a pipe or a socket
while no process is reading at other end
SIGALRM 14 Termin. Generated by clock when alarm expires
SIGTERM 15 Termin. Software termination signal
SIGURG 16 Ignore Urgent condition on IO channel
SIGCHLD 20 Ignore A child process has terminated or stopped
SIGTTIN 21 Stop Generated when a backgorund process reads
from terminal
SIGTTOUT 22 Stop Generated when a background process writes
to terminal
SIGXCPU 24 Discard CPU time has expired
SIGUSR1 30 Termin. User defiled signal 1
SIGUSR2 31 Termin. User defined signal 2
Notice: several signals result in Termin. == termination with no core. Example SIGUSR2. Especially note SIGKILL.
It cannot be blocked. It does not cause a core dump either. This is true for all the UNIX flavors I know about. I believe ARM is a linux port.
# 12  
Old 03-18-2010
Program terminated with signal 13, Broken pipe.
#0 0x4011ceb8 in select () from /lib/libc.so.0
(gdb) bt 6
#0 0x4011ceb8 in select () from /lib/libc.so.0
#1 0x00015298 in NSvrCtrl::GetEvent (this=0x5ff08, timeout=1000)
at nsvrctrl.cpp:187
#2 0x0004ada8 in SKYCAST::NATThreadProc (pParam=0x5feb0) at NatThread.cpp:147
#3 0x40013ac4 in pthread_start_thread () from /lib/libpthread.so.0
#4 0x40013ac4 in pthread_start_thread () from /lib/libpthread.so.0
#5 0x40013ac4 in pthread_start_thread () from /lib/libpthread.so.0
(More stack frames follow...)
# 13  
Old 03-18-2010
Hi Aobai,

There you are: SIGPIPE doesn't generate any core. But you have a pretty good backtrace where the problem lies apparently.

Are you using TCP socket? In this case, you should perhaps blocks SIGPIPE so that you get synchronously informed during the write()/send() (that will return -1 with errno set to EPIPE), instead of getting SIGPIPE.

Cheers,
Loïc.
# 14  
Old 03-24-2010
Hi Loic,
my process is a multi-threaded ,I use the following code at the beginning of the thread(not the main thread) as you suggested
Code:
         struct sigaction act;
          act.sa_handler=SIG_IGN;
          sigemptyset(&act.sa_mask);
          act.sa_flags=0;
          sigaction(SIGPIPE, &act, NULL);

and run it with the gdb about one day or more . the process don't terminate (before It did). but it stopped(no breakpoint or something else ). which I means use c or r , the process will run again .

if I use bt to see the frame . the result is the same as above .

thanks!

Last edited by aobai; 03-24-2010 at 06:11 AM..
Login or Register to Ask a Question

Previous Thread | Next Thread

9 More Discussions You Might Find Interesting

1. Programming

IDE's for the ARM processor on Linux

Hello everyone. I am running Debian on an ARM7 Device (aka my android phone). Everything is great. Works well. I would love to use it for Development. Mainly my interests are in Web Development, and Java development. So far the only useful IDE for debian arm is Netbeans. Which is pretty... (0 Replies)
Discussion started by: CDevelop
0 Replies

2. Hardware

Xenomai On ARM board EXYNOS 4210 ODROID-PC

Hi I am trying to port xenomai on exynos 4210 arm board. With some research I have found a way to port the board on the exynos board but the problem is that on the exynos-4210 website they have provided a patched version of linux-3.0.15 kernel for implementing on the board. On this kernel I am... (1 Reply)
Discussion started by: mohitjandwani
1 Replies

3. Programming

Running c code in ARM QEMU

I created and Compiled a C program to run in QEMU for ARM. When I run the program using the command #qemu-arm -L /home/arm-2010.09/arm-none-linux-gnueabi/libc ./test it gives me the following error: If 'qemu-arm' is not a typo you can use command-not-found to lookup the package that contains... (0 Replies)
Discussion started by: rupeshkp728
0 Replies

4. UNIX for Dummies Questions & Answers

setserial not working on linux running on Beagleboard (ARM development board)

Hi, I'm trying to develop an application to work with serial infra-red module, but I'm having difficulties to even get my module started. My HW is Beagleboard, which has 1 UART serial port, normally used for console, which I have disabled (I re-created the boot.scr, without the console... (0 Replies)
Discussion started by: julumme
0 Replies

5. UNIX for Advanced & Expert Users

Trace "free(): invalid next size (normal)" error on arm-linux board

Hi guys, i'm running a program on samsumg 6410 arm cpu board. it caused an "free(): invalid next size (normal)" fail. i try to use gdb for remote debugging: 1, start gdb server on board: gdbserver 192.168.1.20:1234 ./HostAP Process ./HostAP created; pid = 499 Listening on port... (8 Replies)
Discussion started by: ss1969
8 Replies

6. Programming

gcc for arm process

hi, correct me if am wrong, as per gcc doc gcc is able to compile code for different target systems such as ARM, ARC etc. I tried for compiling ARM but failed to do so. getting below error: gcc -mcpu=arm920t -c avg.c -o agv_arm `-mcpu=' is deprecated. Use `-mtune=' or '-march=' instead.... (6 Replies)
Discussion started by: zing_foru
6 Replies

7. Fedora

gcc arm compiler

think only compile is required I wish to compile a sample code int main() { int a=5,b=8,c; c=a+b; } compile using gcc -Wall -g -march=arm922t main.c -o hello I got an error :bad value(arm922t) for -march=switch instead of using march i used mcpu options ,the same... (1 Reply)
Discussion started by: sujith4u87
1 Replies

8. UNIX for Advanced & Expert Users

gcc arm compiler

I want to find the ARM assembly language for my sample C code using gcc .I had gcc compiler ,whether it is enough for it or i need to download gcc arm cross compiler.If necessary ,how it configured?I am using fedora (0 Replies)
Discussion started by: sujith4u87
0 Replies

9. Linux

Kernel internals for ARM

Hi, Does anybody have a good pointer on Linux kernel internals for ARM architecture? I can locate plenty for x86 but since ARM is RISC I think there would be subtle changes. So if somebody has a knowledge of good document on Linux Kernel internals for ARM or even a comparative study of kernel on... (0 Replies)
Discussion started by: Rakesh Ranjan
0 Replies
Login or Register to Ask a Question