Results 1 to 6 of 6
  1. #1
    Join Date
    Aug 2008
    Posts
    76

    Arrow Unanswered: Questions with Archival logging for HADR Setup

    As only primary database does archival logging -

    1) How should I setup archival logging(LOGARCHMETH1 and LOGARCHMETH2 for Primary and Standby databases in HADR setup ?

    2) Should I only use one NFS mount(separate NFS mounts for LOGARCHAMETH1&2) for archival logging which is created on Primary database server and mounted onto standby database server ?

    3) Please suggest me any other better options for the HADR setup.


    Thanks
    Pandit

  2. #2
    Join Date
    May 2003
    Location
    USA
    Posts
    5,737
    1. Archive logging does not occur on the standby database (when in HADR standby mode). But you should define LOGARCHMETH1 and LOGARCHMETH2 (if you use log mirror) in case you have to do a takeover and switch roles sot the standby becomes the primary HADR database. You can run a cron job to clean out the log path on the standby (only when in standby mode) to move the active logs to the archive path that are older than x number of days, and then delete them from archive path when x + n days old (or when archive path is getting full).

    2. For maximum availability, the HADR pirmary and standby servers should not share any disk mounts for DB2 instance, database path, tablespaces, or logs. You might want to have an NFS mount for a work area for misc files that could be shared between the servers.
    M. A. Feldman
    IBM Certified DBA on DB2 for Linux, UNIX, and Windows
    IBM Certified DBA on DB2 for z/OS and OS/390

  3. #3
    Join Date
    Aug 2008
    Posts
    76
    Thanks a lot Marcus-

    But an IBM article on HADR says the following:

    Shared log archive device between HADR primary and standby databases is preferred. The standbydatabase does not archive log files. If the archive device is not shared, after a few role switches, some files will be on one device and some on the other. Another advantage of shared device is that the standby can retrieve log files directly from the archive device during local catchup state, relieving the primary from reading the files and sending them over the network to the standby.

    So, Iam real confused how to setup LOGARCHMETH1 and LOGARCHMETH2 on primary and standby.

  4. #4
    Join Date
    May 2003
    Location
    USA
    Posts
    5,737
    Could you provide a link to the IBM article? Not everyone at IBM has the same opinion on things (I worked for IBM for 10 years).

    There may be advantages to using a shared device for archive logs, but it would reduce the amount of redundancy, and therefore provide less disaster recovery capability. Maybe you could share the files used for LOGARCHMETH2 since those are redundant with LOGARCHMETH1 archived logs.
    M. A. Feldman
    IBM Certified DBA on DB2 for Linux, UNIX, and Windows
    IBM Certified DBA on DB2 for z/OS and OS/390

  5. #5
    Join Date
    Aug 2008
    Posts
    76
    Hi -

    Here is the link for the IBM article.

    IBM developerWorks: Wikis - IBM Database Wiki - HADR_tune.

    Under the sub heading "Log Archive Device" the statements I quoted are mentioned.

  6. #6
    Join Date
    May 2003
    Location
    USA
    Posts
    5,737
    That site is a wiki, which means any member can contribute and edit articles. I don' know if Zhuge is actually an IBM employee, although she is probably fairly knowledgeable. Based on a google search, she may an academic, or maybe she is an IBM employee in a research lab near San Jose (note that the DB2 LUW lab is in Toronto).

    But I would bet that (like many people who are IBM employees) that she is not a "real" DBA and has not experienced the kinds of failures that HADR protects against in a production environment. It may be good idea to put the archive mirrors on a shared disk, but at least the primary archive logs should be independent to make sure they are not overly dependent on network file systems that might be unavailable in a real disaster.
    M. A. Feldman
    IBM Certified DBA on DB2 for Linux, UNIX, and Windows
    IBM Certified DBA on DB2 for z/OS and OS/390

Posting Permissions

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