Results 1 to 5 of 5
  1. #1
    Join Date
    Apr 2015
    Posts
    3

    Question Answered: DB2 HADR - server restart sequences

    Hi

    I am trying to understand the different scenarios and sequences for DB2 HADR - please can you confirm or correct me if I am wrong

    Scenarios:
    1. Secondary Server reboots
    2. Primary Server reboots (without HADR takeover on the secondary)
    3. Both Servers reboot at same time


    1. When secondary starts up again, I need to run 'start HADR on database _____ as standby' - then all will work ok?
    2. When Primary comes back up, it will automatically restart HADR as primary - no action required?
    3. When both come back up - I need to start HADR on standby *before* db2start on the primary?


    (I have left out the scenarios where primary starts up after standby has taken over, as in this case, the old primary will automatically start up as standby)


    Thank you

    Regards,
    Jason

  2. Best Answer
    Posted by mark.b

    "
    Quote Originally Posted by jason__99 View Post
    When the Primary tries to connect to the standby, will this activate the standby?
    Hi Jason,

    No, HADR Standby can be activated by START HADR AS STANDBY / ACTIVATE DATABASE commands only.
    Client connections / HADR Primary are not able to activate it."


  3. #2
    Join Date
    Jul 2013
    Location
    Moscow, Russia
    Posts
    666
    Provided Answers: 55
    Hi Jason,

    DB2 databases are not activated automatically upon their instance start up. You have to do it explicitly or implicitly (when, for example, some user application is trying to connect to the database). DB2 database "remembers" it's previous HADR role upon activation. So, if you issue ACTIVATE DATABASE command (or your application tries to connect), the database tries to take it's previous role.
    HADR Primary is not activated until it connects to Standby. It returns an error if it's not able to connect in HADR_TIMEOUT seconds.
    This is why you should activate (via ACTIVATED DATABASE or START HADR AS STANDBY) Standby before trying to activate Primary.
    Regards,
    Mark.

  4. #3
    Join Date
    Apr 2015
    Posts
    3
    <reposted comment as reply to Mark..>
    Last edited by jason__99; 04-04-15 at 07:39. Reason: Meant to reply to Mark, not post new comment

  5. #4
    Join Date
    Apr 2015
    Posts
    3
    Hi Mark,

    When the Primary tries to connect to the standby, will this activate the standby?



    Quote Originally Posted by mark.b View Post
    Hi Jason,

    DB2 databases are not activated automatically upon their instance start up. You have to do it explicitly or implicitly (when, for example, some user application is trying to connect to the database). DB2 database "remembers" it's previous HADR role upon activation. So, if you issue ACTIVATE DATABASE command (or your application tries to connect), the database tries to take it's previous role.
    HADR Primary is not activated until it connects to Standby. It returns an error if it's not able to connect in HADR_TIMEOUT seconds.
    This is why you should activate (via ACTIVATED DATABASE or START HADR AS STANDBY) Standby before trying to activate Primary.

  6. #5
    Join Date
    Jul 2013
    Location
    Moscow, Russia
    Posts
    666
    Provided Answers: 55
    Quote Originally Posted by jason__99 View Post
    When the Primary tries to connect to the standby, will this activate the standby?
    Hi Jason,

    No, HADR Standby can be activated by START HADR AS STANDBY / ACTIVATE DATABASE commands only.
    Client connections / HADR Primary are not able to activate it.
    Regards,
    Mark.

Posting Permissions

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