Results 1 to 6 of 6
  1. #1
    Join Date
    Jul 2012
    Posts
    5

    Unanswered: DB2 HADR archiving log file ?

    We are implementing HADR in our company and am able to succuesfully implement it. However i have a question for you. We use the following configurations

    Path to log files = /logs/preinstc/dblogs/DOCUMENT/NODE0000/
    First log archive method (LOGARCHMETH1) = DISK:/dbarch/dblogs/

    and we have auto pruning and have setup a backup retention on our Primary

    Number of database backups to retain (NUM_DB_BACKUPS) = 3
    Recovery history retention (days) (REC_HIS_RETENTN) = 2
    Auto deletion of recovery objects (AUTO_DEL_REC_OBJ) = ON

    The above is setup on the Primary, Now as DB2's standard process is we take a backup and restore on standby an hence the above cfg's will be restored on the standby as well, based on how i restore.
    So what i have read in other threads is that we use 1 DBarch folder for our archive path.
    so my question is when we restore to the standby will it be succuesfully able to point to that dbarch or not? considering that while restoring LOGARCHMETH1 is already pointing to disk:dbarch from the primary will three be any conflict when i do a restore to the standby as the DBARCH drive will be shared? I know Primary is the only 1 where the logs will be archived and if in any circumstance standby becomes primary it will use the above dbarch folder for the archive logs if needed ?

    Does anyone has any inputs ?

    Thanks


    Kohli

  2. #2
    Join Date
    Apr 2006
    Location
    Belgium
    Posts
    2,514
    Provided Answers: 11
    when we restore db on standby (we use tsm) I always change logarchmeth1 to NULL
    so the standby will only request logfiles from primary and primary will copy logfiles from archpath to active path and cleanup when finished
    when db in sync I change logarchmeth1 back to tsm on standby (needed when becomes primary after takeover)
    Best Regards, Guy Przytula
    Database Software Consultant
    Good DBAs are not formed in a week or a month. They are created little by little, day by day. Protracted and patient effort is needed to develop good DBAs.
    Spoon feeding : To treat (another) in a way that discourages independent thought or action, as by overindulgence.
    DB2 UDB LUW Certified V7-V8-V9-V9.7-V10.1-V10.5 DB Admin - Advanced DBA -Dprop..
    Information Server Datastage Certified
    http://www.infocura.be

  3. #3
    Join Date
    Jul 2012
    Posts
    5
    Thanks for your reply
    So you are saying after restoring to the standby you do the follwoing
    1) on standby change Logarchmet1 to null.( you dont need a backup when you do that ?)
    2) Standby request logfiles from primary active path. Primary will copy all the logs from arch path to its new logpath and sync it with standby.
    3) later when Standby needs to be primary you change the archpath on the new primary to the same TSM solution ?

    Kohli
    Db2's got talent Winner 2012

  4. #4
    Join Date
    Apr 2006
    Location
    Belgium
    Posts
    2,514
    Provided Answers: 11
    yes, we update the db cfg on stdby whenever the state is peer after restore of standby and hadr was started.... and db in sync
    Best Regards, Guy Przytula
    Database Software Consultant
    Good DBAs are not formed in a week or a month. They are created little by little, day by day. Protracted and patient effort is needed to develop good DBAs.
    Spoon feeding : To treat (another) in a way that discourages independent thought or action, as by overindulgence.
    DB2 UDB LUW Certified V7-V8-V9-V9.7-V10.1-V10.5 DB Admin - Advanced DBA -Dprop..
    Information Server Datastage Certified
    http://www.infocura.be

  5. #5
    Join Date
    Jul 2012
    Posts
    5
    so you are saying is
    you change logarchmeth 1 to null which is changing it to circular logging.
    Wehn you make the standby as primary you change logarchmet1 to TSM which is archivable logging and then you will need to take a backup of the standby, and then wouldn't the log files not be in sync ?

  6. #6
    Join Date
    Aug 2008
    Location
    Toronto, Canada
    Posts
    2,368
    Quote Originally Posted by przytula_guy View Post
    when we restore db on standby (we use tsm) I always change logarchmeth1 to NULL
    so the standby will only request logfiles from primary and primary will copy logfiles from archpath to active path and cleanup when finished
    when db in sync I change logarchmeth1 back to tsm on standby (needed when becomes primary after takeover)

    I'm not sure I understand why you need to change logarchmeth1 from TSM to NULL. Can you please clarify?

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •