If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below.

 
Go Back  dBforums > Database Server Software > DB2 > How to tell when a DB2 instance was last Stopped/Started

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1 (permalink)  
Old 08-27-04, 18:05
rvsc36 rvsc36 is offline
Registered User
 
Join Date: Jan 2004
Location: Phoenix, AZ
Posts: 42
How to tell when a DB2 instance was last Stopped/Started

Hello,

Does anyone know of a way to tell when a database instance was last stopped and started?

I thought of ps -ef | grep db2, but I am getting no consistent dates.

Any better ideas?

Thanks!
Reply With Quote
  #2 (permalink)  
Old 08-27-04, 18:52
ARWinner ARWinner is offline
Registered User
 
Join Date: Jan 2003
Posts: 3,575
Look in db2diag.log

Andy
Reply With Quote
  #3 (permalink)  
Old 08-27-04, 19:03
rvsc36 rvsc36 is offline
Registered User
 
Join Date: Jan 2004
Location: Phoenix, AZ
Posts: 42
Thanks Andy, great idea, however,

We keep our diaglevel at a 3, so we trim lines from the log to keep its size down to conserve file system space. So, we have no past record.

Do you know of a way to tell at the OS level (Unix)?
Reply With Quote
  #4 (permalink)  
Old 08-27-04, 19:22
sathyaram_s sathyaram_s is offline
Super Moderator
 
Join Date: Aug 2001
Location: UK
Posts: 4,534
Not sure what you mean by 'no consistent date' ... Do you mean that various processes are started at different times ?? If so, see the time on the process db2gds

This is the 'global daemon spawner' which will be 'managing' other db2 associated threads ...

HTH

Sathyaram
__________________
Visit the new-look IDUG Website , register to gain access to the excellent content.
Reply With Quote
  #5 (permalink)  
Old 08-27-04, 19:36
rvsc36 rvsc36 is offline
Registered User
 
Join Date: Jan 2004
Location: Phoenix, AZ
Posts: 42
Thumbs up

Thanks Sathyaram. That is exactly what I needed.
Reply With Quote
  #6 (permalink)  
Old 08-30-04, 00:26
dollar489 dollar489 is offline
Registered User
 
Join Date: Sep 2002
Posts: 456
To get the time when instance was started, issue the following command for the instance in question:

db2 get dbm cfg

The output of this will show you the instance startup timestamp.

dollar
Reply With Quote
Reply

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

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
Trackbacks are On
Pingbacks are On
Refbacks are On