LinuxQuestions.org
Download your favorite Linux distribution at LQ ISO.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie
User Name
Password
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!

Notices


Reply
  Search this Thread
Old 11-05-2012, 08:14 PM   #1
jyotir.roy
LQ Newbie
 
Registered: Nov 2012
Posts: 12

Rep: Reputation: Disabled
Backgorund process died after long run


Hi,

I have a process that I am running as below.

c2cd r &

r is a argument
& is used to run it as background process.

c2cd is nothing but a application which creates 3 individual thread.

Simple example of c2cd.c
int main(int argc, char ** argv)
{
pthread_create(&g_mngr_threads[C2C_MNGR_APP], NULL, c2cApp_Manager, NULL);
pthread_create(&g_mngr_threads[C2C_MNGR_SEND], NULL, c2cSend_Manager, NULL);
pthread_create(&g_mngr_threads[C2C_MNGR_RECV], NULL, c2cRecv_Manager, NULL);
}

this 3 thread communicate to each other using sockets. And all the internal message passing is ok but after long run of more than 8 hours c2cd died.

Can you help me on 2 things
1> how can I monitor this thread?
2> How can I stop this thread getting unwanted signal?
 
Old 11-05-2012, 09:29 PM   #2
sundialsvcs
LQ Guru
 
Registered: Feb 2004
Location: SE Tennessee, USA
Distribution: Gentoo, LFS
Posts: 8,323
Blog Entries: 4

Rep: Reputation: 2837Reputation: 2837Reputation: 2837Reputation: 2837Reputation: 2837Reputation: 2837Reputation: 2837Reputation: 2837Reputation: 2837Reputation: 2837Reputation: 2837
Well, by reading this post, I really don't understand what the problem is. Do you have any idea why the process died?

You certainly can trap some (but not all ...) signals to divert attention to some handler, but it is actually pretty rare to want to do that. You might want to, say, use a signal to produce a status-message without stopping the entire process, or something like that, but you should ponder carefully.
 
Old 11-05-2012, 10:19 PM   #3
jyotir.roy
LQ Newbie
 
Registered: Nov 2012
Posts: 12

Original Poster
Rep: Reputation: Disabled
Quote:
Originally Posted by sundialsvcs View Post
Well, by reading this post, I really don't understand what the problem is. Do you have any idea why the process died?

You certainly can trap some (but not all ...) signals to divert attention to some handler, but it is actually pretty rare to want to do that. You might want to, say, use a signal to produce a status-message without stopping the entire process, or something like that, but you should ponder carefully.
Hi,
I don't know why this process died?

Output of ps in my system
1587 root 5364 S c2cd r
1592 root 1980 S < udevd -d
1593 root 6348 S wmond

Now do you know how can I monitor c2cd?
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
the process for the smb://10.0.12.2 protocol died unexpectedly twwwater Slackware 4 07-10-2010 12:27 AM
KlamAV - Update Process died unexpectedly! lazylogic Debian 2 10-10-2007 06:33 AM
OpenSuse10.2 -The process for the sysinfo protocol died unexpectedly pajoe SUSE / openSUSE 1 12-24-2006 11:53 PM
Backgorund for the splash-screen safrout Linux - Newbie 2 12-01-2003 06:41 PM
Konqueror: The process for the http:// ... protocol died unexpectedly SparceMatrix Linux - Software 2 08-30-2002 05:15 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie

All times are GMT -5. The time now is 01:05 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration