j053ph4 / ZenPacks.community.DB2Mon

DB2 Database Monitoring
1 stars 0 forks source link

Will not work on a DB in Roll forward state or not active #3

Open cnoffsin opened 11 years ago

cnoffsin commented 11 years ago

In the modeler, you will not be able to run this statement if the DB is in a roll forward state or not active as in a db that is a slave:

SELECT DB_NAME, DB_STATUS, SERVER_PLATFORM FROM SYSIBMADM.SNAPDB

To get that info you have to take a metrics snapshot of the DB.

So in its current form, the zenpack will not work on a non-active db2 instance

cnoffsin commented 11 years ago

db2 "get db cfg for " | grep "Rollforward pending" | awk '{ print $NF}'

This would get the output to tell if the DB is in Roll Forward state.

"get db cfg" gets config info.