IBM Support

In DB2LUW how to restart a vendor archiving mechanism without restarting the whole database

Technical Blog Post


Abstract

In DB2LUW how to restart a vendor archiving mechanism without restarting the whole database

Body

In DB2LUW for some reason we faced some issues with the archive mechanism and we want to restart the archive mechanism ONLY and not the whole database or instance.

So, how to restart the archiving mechanism without restarting a database.

 

There is a way   to restart the archiving mechanism when it uses vendor code.

 

It’s,  db2pd -fvp

 

It’s documented in the Knowledge Center,

https://www.ibm.com/support/knowledgecenter/SSEPGG_10.5.0/com.ibm.db2.luw.admin.cmd.doc/doc/r0011729.html

 

>--+-----------------------------------------------------+------>

   '- -fvp--+-agent_eduid-+--+------+--+---------------+-'   

            +-LAM1--------+  '-term-'  '-file=filename-'     

            +-LAM2--------+                                  

            '-LAM3--------'    

 

As an example,

A database named SAMPLE has logarchmeth1 set to TSM.

At any time run,

db2pd -db sample -fvp lam1

The resulting output is as follows:

-------------------------------------------------------------------------

Fenced Vendor Process State Information:

-------------------------------------------------------------------------

 

Log Manager:

-------------------------------------------------------------------------

LOGARCHMETH1 available.

 

Vendor EDU is available and running.

  startTime: 1155581841  20060814145721

  function: sqluvint

 

This tells us that the fenced vendor process is running in the vendor function sqluvint since August 14, 2006 14:57. Now, if we feel that this has been running too long, or we have determined that this process has hung waiting for TSM resources, we can terminate the fenced vendor process by issuing:

 

db2pd -db sample -fvp lam1 term

The resulting output is as follows:

-------------------------------------------------------------------------

Fenced Vendor Process State Information:

-------------------------------------------------------------------------

 

Log Manager:

-------------------------------------------------------------------------

LOGARCHMETH1 available.

 

Vendor EDU is available and running.

  startTime: 1155581841  20060814145721

  function: sqluvint

This fenced vendor process has been sent a signal to terminate.

This shows us the same information as the previous output, but also let us know that the terminate request has been sent. After waiting a few moments, we should notice that the request has taken affect.

          

             If the fenced vendor process is running, but not running in vendor code, we will see this for a regular display request:

-----------------------------------------------------------------

Fenced Vendor Process State Information:

----------------------------------------------------------------

 

Log Manager:

----------------------------------------------------------------

LOGARCHMETH1 available.

 

Vendor EDU is available and running.

No vendor code being run.

 

 

Once it’s  terminated, any further  archive request will restart the archive mechanism

 

"Note, starting in Db2 Version 11.1.3.3, the archival of log files (LOGARCHMETH1/2) using VENDOR or TSM methods can now be configured with a timeout on Unix environments. If the transmission of log data between Db2 and the TSM or vendor API is unresponsive for the specified timeout period, then Db2 will interrupt the archive log attempt and follow normal log archive failure protocol. For details see "--VENDOR_ARCHIVE_TIMEOUT" in the Configuration parameters for database logging Knowledge Center article.

https://www.ibm.com/support/knowledgecenter/en/SSEPGG_11.1.0/com.ibm.db2.luw.admin.ha.doc/doc/r0006082.html

[{"Business Unit":{"code":"BU058","label":"IBM Infrastructure w\/TPS"},"Product":{"code":"SSEPGG","label":"Db2 for Linux, UNIX and Windows"},"Component":"","Platform":[{"code":"PF025","label":"Platform Independent"}],"Version":"","Edition":"","Line of Business":{"code":"LOB10","label":"Data and AI"}}]

UID

ibm11140214