In DB2, how to know date/time a particular Database was put to RO?

RDBMS from IBM and IBM's Hierarchical DBMS and Transaction Manager (IMS DC).
Post Reply
User avatar
saurabhgaur
New Member
Posts: 1
Joined: Tue Feb 27, 2024 11:59 am

In DB2, how to know date/time a particular Database was put to RO?

Post by saurabhgaur »

Is there any place where one can find at what date/time a particular Database was put to RO? Or got any change in status ? Is that available to see somewhere in the subsystem catalog or BSDS?
User avatar
Anuj Dhawan
Founder
Posts: 2802
Joined: Sun Apr 21, 2013 7:40 pm
Location: Mumbai, India
Contact:
India

Re: In DB2, how to know date/time a particular Database was put to RO?

Post by Anuj Dhawan »

Hi SaurabhGaur,

Welcome to the forums!I've created a new post for your question to help you get the best possible attention. It's generally recommended to start new threads for new questions, and then link to any relevant previous discussions within your post, which you've looked at. This helps others searching for similar information find your question more easily.

If you had added your question to an older thread, it might have been harder for others to notice and respond.

Please feel free to ask your question here, and I'm sure the community will be happy to help!
Thanks,
Anuj

Disclaimer: My comments on this website are my own and do not represent the opinions or suggestions of any other person or business entity, in any way.
User avatar
DB2 Guy
Forum Moderator
Forum Moderator
Posts: 120
Joined: Sun Apr 21, 2013 8:25 pm
India

Re: In DB2, how to know date/time a particular Database was put to RO?

Post by DB2 Guy »

As far as I know, there isn't a single, definitive way to pinpoint the exact moment a DB2 database was switched to read-only (RO) status. However, there are several methods that can help you narrow down the timeframe:1. DB2 Logs:
  • Check the DB2 diagnostic log files (db2diag.log and others) for relevant entries. These logs may contain timestamps and messages indicating the database being placed in RO mode. Look for keywords like "READONLY" or "STOP DATABASE".
  • The timeframe covered by the logs will depend on your log rotation settings.
2. System Operations Staff:
  • If the RO switch was due to a planned maintenance activity, system administrators or operations staff likely have records of the specific time window.
3. Monitoring Tools:
  • If your organization uses database monitoring tools, they might have logged events related to the database status change. These tools can provide a more precise timestamp for the RO transition.
4. DB2 Commands: While not necessarily revealing the exact time, you can use the

Code: Select all

DISPLAY DATABASE
command to check the current status of the database, including whether it's read-only or read-write. This might help confirm if it's currently in RO mode. By combining information from these sources, you can get a clearer picture of when the database was switched to RO status.
Post Reply

Create an account or sign in to join the discussion

You need to be a member in order to post a reply

Create an account

Not a member? register to join our community
Members can start their own topics & subscribe to topics
It’s free and only takes a minute

Register

Sign in

Return to “IBM DB2 and IMS DB/DC”