LinuxQuestions.org
Visit Jeremy's Blog.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Enterprise Linux Forums > Linux - Enterprise
User Name
Password
Linux - Enterprise This forum is for all items relating to using Linux in the Enterprise.

Notices


Reply
  Search this Thread
Old 08-12-2009, 06:31 AM   #1
asimba
Member
 
Registered: Mar 2005
Location: 127.0.0.0
Distribution: Red Hat / Fedora
Posts: 355

Rep: Reputation: 42
Service Start Date and Time - Red Hat Enterprise Linux 5.x


Hi,

Does anybody know if there is some command to check what date and time a given service was started or stopped.

(PS : I do not want to check logs - I did dig logs and did not find anything significant there)

Regards,

A
 
Old 08-12-2009, 07:30 AM   #2
MensaWater
LQ Guru
 
Registered: May 2005
Location: Atlanta Georgia USA
Distribution: Redhat (RHEL), CentOS, Fedora, CoreOS, Debian, FreeBSD, HP-UX, Solaris, SCO
Posts: 7,831
Blog Entries: 15

Rep: Reputation: 1669Reputation: 1669Reputation: 1669Reputation: 1669Reputation: 1669Reputation: 1669Reputation: 1669Reputation: 1669Reputation: 1669Reputation: 1669Reputation: 1669
Don't know of any log off the top of my head.

However, for start of running services usually there is a pid file with same name as service in /var/run. The date/time stamp on those files should give you a good idea on when the running services were started.

/var/run/sendmail.pid would be a good example.

Also some things in /var/run you can figure out - for example there is a cups directory that contains a socket file. The time on that socket is when cups last started.

The above files get deleted when the service stops.

Of course you could always create your own logging by adding syntax to each of the scripts in /etc/init.d that start/stop the services.
 
1 members found this post helpful.
Old 08-12-2009, 07:37 AM   #3
asimba
Member
 
Registered: Mar 2005
Location: 127.0.0.0
Distribution: Red Hat / Fedora
Posts: 355

Original Poster
Rep: Reputation: 42
I will give it a try ... As for time being - I am into kinda forensics - checking a few servers in cluster. I cannot make any changes due some reasons.

But sure, I will give it a try.

Thank you jlightner!
 
  


Reply



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
how to start ftp service in Red Hat Linux release 7.1 (Seawolf) nirmit Linux - Newbie 4 06-23-2008 05:25 AM
File Creation date & time in Red Hat cjagdish69 Linux - Newbie 1 04-23-2007 01:23 AM
LXer: Preview Time for Red Hat Enterprise Linux 4.5 LXer Syndicated Linux News 0 03-04-2007 01:46 AM
Red Hat Enterprise Linux 5 Release Date? keysorsoze Red Hat 5 03-01-2007 08:15 PM
red hat 8 and date,time ronss Linux - Distributions 2 12-04-2002 01:20 AM

LinuxQuestions.org > Forums > Enterprise Linux Forums > Linux - Enterprise

All times are GMT -5. The time now is 07:21 PM.

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
Open Source Consulting | Domain Registration