LinuxQuestions.org
Latest LQ Deal: Complete CCNA, CCNP & Red Hat Certification Training Bundle
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 05-07-2009, 12:56 PM   #1
ericli
LQ Newbie
 
Registered: May 2009
Posts: 14

Rep: Reputation: 0
Running process stopped


I have an running process in Linux and it is supposed to run all the time. But today I found it stopped.

Is there anywhere in the sysytem I can check when and why the process stopped?

Thanks
 
Old 05-07-2009, 12:57 PM   #2
rweaver
Senior Member
 
Registered: Dec 2008
Location: Louisville, OH
Distribution: Debian, CentOS, Slackware, RHEL, Gentoo
Posts: 1,833

Rep: Reputation: 164Reputation: 164
Quote:
Originally Posted by ericli View Post
I have an running process in Linux and it is supposed to run all the time. But today I found it stopped.

Is there anywhere in the sysytem I can check when and why the process stopped?

Thanks
Does it log? What is it? Is it a zombied process? Did it crash and dump a core? Without more information there's not a lot we can tell you.
 
Old 05-07-2009, 01:15 PM   #3
ericli
LQ Newbie
 
Registered: May 2009
Posts: 14

Original Poster
Rep: Reputation: 0
It is a Resin server running on Linux. I looked at the logs nothing's there. So I hope Linux has some history record so I could understand the reason.

btw, for command history, can it display the time stamp of each executed command?

Thanks
 
Old 05-07-2009, 01:32 PM   #4
sundialsvcs
LQ Guru
 
Registered: Feb 2004
Location: SE Tennessee, USA
Distribution: Gentoo, LFS
Posts: 7,158

Rep: Reputation: 2204Reputation: 2204Reputation: 2204Reputation: 2204Reputation: 2204Reputation: 2204Reputation: 2204Reputation: 2204Reputation: 2204Reputation: 2204Reputation: 2204
When you say "stopped," you could have meant any one of several things, and the difference is important:
  1. The process is not there anymore.
  2. The process has frozen in place.
  3. The process is a zombie... dead, but not buried yet.
I'm going to assume "door number 1."

Most of the time, interesting tidbits can be found in log-files which are typically found in /var/log, such as messages. Start by looking there.
 
Old 05-07-2009, 03:46 PM   #5
ericli
LQ Newbie
 
Registered: May 2009
Posts: 14

Original Poster
Rep: Reputation: 0
Thanks, no secret.

Someome just stopped the Resin with "service resin stop".
"history|grep resin" shows that. But don't know when.
 
Old 05-07-2009, 05:22 PM   #6
rweaver
Senior Member
 
Registered: Dec 2008
Location: Louisville, OH
Distribution: Debian, CentOS, Slackware, RHEL, Gentoo
Posts: 1,833

Rep: Reputation: 164Reputation: 164
Quote:
Originally Posted by ericli View Post
Thanks, no secret.

Someome just stopped the Resin with "service resin stop".
"history|grep resin" shows that. But don't know when.
Your best option to get that information is the logs. If you didn't restart it before checking the last modified time on its log files you could probably have told when it last logged something from that. The default for history is to NOT log time stamps, if at the time of the incident it wasn't set to log time stamps then there isn't anything you can do to acquire that information from the history (it wasn't logged.)


Basically to turn it on add this to your login files...
Code:
HISTTIMEFORMAT='%F %T '
export HISTTIMEFORMAT
Keep in mind though anything prior to current sessions is going to have invalid times because it wasn't logged.

Last edited by rweaver; 05-07-2009 at 05:28 PM.
 
  


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
Debian Lenny. Boot process stopped. No error JPG0J Debian 5 05-10-2009 01:44 PM
Get Process size and Thread count for a particular running process haseit Linux - Newbie 2 01-23-2009 12:09 AM
Shell Script : Kill a running process when another process starts ashmew2 Linux - General 3 08-20-2008 04:47 AM
How 2 start a stopped process(CTRL+Z)in command prompt babu198649 Linux - Newbie 4 10-15-2007 03:53 AM
Cron stopped running? willemdebeer Linux - Newbie 1 01-02-2004 02:33 PM


All times are GMT -5. The time now is 11:16 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