You are on page 1of 21

HADR with TSA

using
db2haicu
(A DB2 v9.7 utility)
on AIX/Linux

Date : 04 Apr 2010
Version : 2.0
Author : Neeraj Sharma (neeraj.sharma@in.ibm.com)
Abhishek Iyer (abhishekiyer@in.ibm.com)






Abstract: This is a step by step guide for setting up end to end HADR with TSA using db2haicu
utility.



Audience: The target audience for this document is customer.
Acronyms

Text in kLD kLD kLD kLD indicates user inputs.
Text in 8LuL 8LuL 8LuL 8LuL indicates questions prompted by system/utility.
Text in 8LACk 8LACk 8LACk 8LACk indicates information message by system/utility.

2
Above nomenclature does not apply to 1ssam 1ssam 1ssam 1ssam output in section 11, where-in GkLLN GkLLN GkLLN GkLLN
indicates online node, 8LuL 8LuL 8LuL 8LuL indicates offline node (in warm mode) and kLD kLD kLD kLD indicates failed
node.

3
Table of contents
Part 1 : DB2 configuration.................................................................................................. 4
1. Check/Update /etc/hosts file ....................................................................................... 4
2. Check/Update /etc/services file................................................................................... 4
3. Enable HADR on databases........................................................................................ 5
4. Take database backup ................................................................................................. 5
5. Restore database backup on standby node.................................................................. 6
6. Check database states.................................................................................................. 6
7. Start HADR on databases ........................................................................................... 6
Part 2 : TSA Cluster setup .................................................................................................. 7
8. Prepare cluster nodes first........................................................................................... 7
9. On Standby node (should be executed on standby node first).................................... 7
10. Execute db2haicu on Primary node .......................................................................... 9
11. Check cluster status................................................................................................. 10
Part 3 : Miscellaneous tasks / Diagnostics........................................................................ 11
12. Disable TSA cluster ................................................................................................ 11
13. Enable TSA cluster ................................................................................................. 11
14. db2haicu maintenance mode................................................................................ 12
15. HADR automated failover resource listing using db2pd........................................ 12
16. HADR status using db2pd ...................................................................................... 14
Part 4 : Remove TSA/HADR configuration ..................................................................... 15
17. Remove TSA cluster ............................................................................................... 15
18. Stop HADR............................................................................................................. 15
Part 5 : Automatic client reroute (ACR) ........................................................................... 16
19. Add ACR configuration.......................................................................................... 16
20. Remove ACR configuration ................................................................................... 16
Appendix........................................................................................................................... 17
Why database creation is required on both nodes?....................................................... 17
Quorum device.............................................................................................................. 17
Cluster node name resolution........................................................................................ 17
Cluster Public/Private networks.................................................................................... 17
HADR States................................................................................................................. 18
Peer ........................................................................................................................... 18
LocalCatchup ............................................................................................................ 18
RemoteCatchupPending............................................................................................ 19
RemoteCatchup......................................................................................................... 19
Disconnected............................................................................................................. 19
Manual takeover............................................................................................................ 19
Definite NO NO for HADR setup ................................................................................ 19
DB2_LOAD_COPY_NO_OVERRIDE....................................................................... 20
Application impact........................................................................................................ 20
Upgrading DB2............................................................................................................. 21
References......................................................................................................................... 21
4
Part 1 : DB2 configuration

Overall architecture



Create database on both database servers [yes, creation on both servers is
required, why its required is explained in appendix]

$ db2 ceafe dafabase haddb

Configuration setting on both databases
Create database layout and other database objects on just one database which initially will act as
primary node (say hadrnode01)

1. Check/Update /etc/hosts file
Make sure following entries exits on both the nodes

9.1.2.3 hadnode01
9.1.2.4 hadnode02

2. Check/Update /etc/services file
Make sure following entries exits on both the nodes

D82hADkPOk1 55555/fcp
db2cdb21nsf1 50000/fcp

D82db21nsf1 60000/fcp
D82db21nsf1LND 60003/fcp

5
3. Enable HADR on databases
hadrnode01

Log efa1n fo ecovey enab1ed {LOGkL1AlN} = kLCOvLkY
lndex e-ceaf1on f1me and edo 1ndex bu11d {lNDLXkLC} = kL51Ak1
Log pages du1ng 1ndex bu11d {LOGlNDLX8ulLD} = ON

hADk 1oca1 hosf name {hADkLOCALhO51} = hadnode01
hADk 1oca1 sev1ce name {hADkLOCAL5vC} = D82hADkPOk1
hADk emofe hosf name {hADkkLMO1LhO51} = hadnode02
hADk emofe sev1ce name {hADkkLMO1L5vC} = D82hADkPOk1
hADk 1nsfance name of emofe seve {hADkkLMO1LlN51} = db21nsf1
hADk f1meouf va1ue {hADk1lMLOu1} = 30
hADk 1og W1fe synchon1zaf1on mode {hADk5YNCMODL} = NLAk5YNC
hADk pee W1ndoW duaf1on {seconds} {hADkPLLkWlNDOW} = 60

hadrnode02

Log efa1n fo ecovey enab1ed {LOGkL1AlN} = kLCOvLkY
lndex e-ceaf1on f1me and edo 1ndex bu11d {lNDLXkLC} = kL51Ak1
Log pages du1ng 1ndex bu11d {LOGlNDLX8ulLD} = ON

hADk 1oca1 hosf name {hADkLOCALhO51} = hadnode02
hADk 1oca1 sev1ce name {hADkLOCAL5vC} = D82hADkPOk1
hADk emofe hosf name {hADkkLMO1LhO51} = hadnode01
hADk emofe sev1ce name {hADkkLMO1L5vC} = D82hADkPOk1
hADk 1nsfance name of emofe seve {hADkkLMO1LlN51} = db21nsf1
hADk f1meouf va1ue {hADk1lMLOu1} = 30
hADk 1og W1fe synchon1zaf1on mode {hADk5YNCMODL} = NLAk5YNC
hADk pee W1ndoW duaf1on {seconds} {hADkPLLkWlNDOW} = 60

Values hADk1lMLOu1 and hADkPLLkWlNDOW should be tuned for a particular setup.
Standard recommended values of these paramenters are 120 and 300 respectively.

$ db2 updafe db cfg fo haddb us1ng LOGkL1AlN kLCOvLkY

Once LOGkL1AlN is set to kLCOvLkY, database will move to 8ackup pend1ng state.

hadrnode01

$ db2 gef db cfg fo haddb | gep -1 8ackup pend1ng
8ackup pend1ng = YL5


hadrnode02

$ db2 gef db cfg fo haddb | gep -1 8ackup pend1ng
8ackup pend1ng = YL5
4. Take database backup
hadrnode01

$ db2 8ackup dafabase haddb
8ackup successfu1. 1he f1mesfamp fo fh1s backup 1mage 1s : 2001223202401

This will create a file with name hADkD8.0.D82.NODL0000.CA1N0000.2001223202401.001 in
current directory. Make this file available on hadrnode02 for restoration during step 5.

hadrnode02

$ db2 8ackup dafabase haddb fo /dev/nu11
8ackup successfu1. 1he f1mesfamp fo fh1s backup 1mage 1s : 2001223202501

6

|" backup 1mage of hadnode02 W111 nof be used fheefoe d1ecfed fo /dev/nu11]

The HADR DB CFG parameters mentioned in section 3 (4th to 11th) should be set after
doing the Backup. The first 3 parameters should be set before Backup itself.
5. Restore database backup on standby node

hadrnode02
$db2 esfoe dafabase haddb faken af 2001223202401
5qL2539W Wan1ng! kesfo1ng fo an ex1sf1ng dafabase fhaf 1s fhe same as fhe
backup 1mage dafabase. 1he dafabase f11es W111 be de1efed.
Do you Wanf fo conf1nue ? {y/n} y
D820000l 1he kL51OkL DA1A8A5L command comp1efed successfu11y.

The HADR DB CFG parameters mentioned in section 3 (4th to 11th) should be set after
doing the Restore.

6. Check database states

hadrnode01
$ db2 gef db cfg fo haddb | gep -1 ko11foWad pend1ng
ko11foWad pend1ng = NO

hadrnode02

$ db2 gef db cfg fo haddb | gep -1 ko11foWad pend1ng
ko11foWad pend1ng = YL5

7. Start HADR on databases

hadrnode02
$ db2 sfaf had on db haddb as sfandby
D820000l 1he 51Ak1 hADk ON DA1A8A5L command comp1efed successfu11y.

hadrnode01

$ db2 sfaf had on db haddb as p1may
D820000l 1he 51Ak1 hADk ON DA1A8A5L command comp1efed successfu11y.
7
Part 2 : TSA Cluster setup
RSCT version 2.5.3.3 and TSA version 3.1.0.0 was used for this implementation

8. Prepare cluster nodes first
Execute following commands as oof on both nodes, all other commands should
be executed as instance owner (db21nsf1 in current example).

$ peppnode hadnode01
$ peppnode hadnode02

9. On Standby node (should be executed on standby node first)

bash-3.00$ db2ha1cu
We1come fo fhe D82 h1gh Ava11ab111fy lnsfance Conf1guaf1on uf111fy {db2ha1cu}.

You can f1nd defa11ed d1agnosf1c 1nfomaf1on 1n fhe D82 seve d1agnosf1c 1og f11e ca11ed
db2d1ag.1og. A1so, you can use fhe uf111fy ca11ed db2pd fo quey fhe sfafus of fhe
c1usfe doma1ns you ceafe.

Io moe 1nfomaf1on abouf conf1gu1ng you c1usfeed env1onmenf us1ng db2ha1cu, see fhe
fop1c ca11ed D82 h1gh Ava11ab111fy lnsfance Conf1guaf1on uf111fy {db2ha1cu} 1n fhe D82
lnfomaf1on Cenfe.

db2ha1cu defem1ned fhe cuenf D82 dafabase manage 1nsfance 1s db21nsf1. 1he c1usfe
conf1guaf1on fhaf fo11oWs W111 app1y fo fh1s 1nsfance.

db2ha1cu 1s co11ecf1ng 1nfomaf1on on you cuenf sefup. 1h1s sfep may fake some f1me as
db2ha1cu W111 need fo acf1vafe a11 dafabases fo fhe 1nsfance fo d1scove a11 pafhs ...
When you use db2ha1cu fo conf1gue you c1usfeed env1onmenf, you ceafe c1usfe
doma1ns. Io moe 1nfomaf1on, see fhe fop1c Ceaf1ng a c1usfe doma1n W1fh db2ha1cu 1n
fhe D82 lnfomaf1on Cenfe. db2ha1cu 1s seach1ng fhe cuenf mach1ne fo an ex1sf1ng
acf1ve c1usfe doma1n ...
db2ha1cu d1d nof f1nd a c1usfe doma1n on fh1s mach1ne. db2ha1cu W111 noW quey fhe
sysfem fo 1nfomaf1on abouf c1usfe nodes fo ceafe a neW c1usfe doma1n ...

db2ha1cu d1d nof f1nd a c1usfe doma1n on fh1s mach1ne. 1o conf1nue conf1gu1ng you
c1usfeed env1onmenf fo h1gh ava11ab111fy, you musf ceafe a c1usfe doma1n ofheW1se,
db2ha1cu W111 ex1f.

Ceafe a doma1n and conf1nue? |1]
1. Yes
2. No
1
Ceafe a un1que name fo fhe neW doma1n:
haddoma1n
Nodes musf noW be added fo fhe neW doma1n.
hoW many c1usfe nodes W111 fhe doma1n haddoma1n confa1n?
2
Lnfe fhe hosf name of a mach1ne fo add fo fhe doma1n:
hadnode01
Lnfe fhe hosf name of a mach1ne fo add fo fhe doma1n:
hadnode02
db2ha1cu can noW ceafe a neW doma1n confa1n1ng fhe 2 mach1nes fhaf you spec1f1ed. lf you
choose nof fo ceafe a doma1n noW, db2ha1cu W111 ex1f.

Ceafe fhe doma1n noW? |1]
1. Yes
2. No
1

Ceaf1ng doma1n haddoma1n 1n fhe c1usfe ...
Ceaf1ng doma1n haddoma1n 1n fhe c1usfe Was successfu1.
You can noW conf1gue a quoum dev1ce fo fhe doma1n. Io moe 1nfomaf1on, see fhe fop1c
"quoum dev1ces" 1n fhe D82 lnfomaf1on Cenfe. lf you do nof conf1gue a quoum dev1ce
fo fhe doma1n, fhen a human opeafo W111 have fo manua11y 1nfevene 1f subsefs of
mach1nes 1n fhe c1usfe 1ose connecf1v1fy.
8

Conf1gue a quoum dev1ce fo fhe doma1n ca11ed haddoma1n? |1]
1. Yes
2. No
1

1he fo11oW1ng 1s a 11sf of suppofed quoum dev1ce fypes:
1. NefWok quoum
Lnfe fhe numbe coespond1ng fo fhe quoum dev1ce fype fo be used: |1]
1
5pec1fy fhe nefWok addess of fhe quoum dev1ce:
9.1.2.1 efe fo append1x fo defa11s on quoum dev1ce
Conf1gu1ng quoum dev1ce fo doma1n haddoma1n ...
Conf1gu1ng quoum dev1ce fo doma1n haddoma1n Was successfu1.
1he c1usfe manage found 4 nefWok 1nfeface cads on fhe mach1nes 1n fhe doma1n. You
can use db2ha1cu fo ceafe nefWoks fo fhese nefWok 1nfeface cads. Io moe
1nfomaf1on, see fhe fop1c Ceaf1ng nefWoks W1fh db2ha1cu 1n fhe D82 lnfomaf1on
Cenfe.

Ceafe nefWoks fo fhese nefWok 1nfeface cads? |1]
1. Yes
2. No
1
Lnfe fhe name of fhe nefWok fo fhe nefWok 1nfeface cad: efh10 on c1usfe node:
hadnode01
1. Ceafe a neW pub11c nefWok fo fh1s nefWok 1nfeface cad.
2. Ceafe a neW p1vafe nefWok fo fh1s nefWok 1nfeface cad.
Lnfe se1ecf1on:
1 efe fo Append1x fo defa11s on fh1s opf1on se1ecf1on {C1usfe Pub11c/P1vafe
nefWoks}
Ae you sue you Wanf fo add fhe nefWok 1nfeface cad efh10 on c1usfe node hadnode01
fo fhe nefWok db2pub11cnefWok0? |1]
1. Yes
2. No
1
Add1ng nefWok 1nfeface cad efh10 on c1usfe node hadnode01 fo fhe nefWok
db2pub11cnefWok0 ...
Add1ng nefWok 1nfeface cad efh10 on c1usfe node hadnode01 fo fhe nefWok
db2pub11cnefWok0 Was successfu1.
Lnfe fhe name of fhe nefWok fo fhe nefWok 1nfeface cad: efh10 on c1usfe node:
hadnode02
1. db2pub11cnefWok0
2. Ceafe a neW pub11c nefWok fo fh1s nefWok 1nfeface cad.
3. Ceafe a neW p1vafe nefWok fo fh1s nefWok 1nfeface cad.
Lnfe se1ecf1on:
1
Ae you sue you Wanf fo add fhe nefWok 1nfeface cad efh10 on c1usfe node hadnode02
fo fhe nefWok db2pub11cnefWok0? |1]
1. Yes
2. No
1
Add1ng nefWok 1nfeface cad efh10 on c1usfe node hadnode02 fo fhe nefWok
db2pub11cnefWok0 ...
Add1ng nefWok 1nfeface cad efh10 on c1usfe node hadnode02 fo fhe nefWok
db2pub11cnefWok0 Was successfu1.
Lnfe fhe name of fhe nefWok fo fhe nefWok 1nfeface cad: efh3 on c1usfe node:
hadnode02
1. db2pub11cnefWok0
2. Ceafe a neW pub11c nefWok fo fh1s nefWok 1nfeface cad.
3. Ceafe a neW p1vafe nefWok fo fh1s nefWok 1nfeface cad.
Lnfe se1ecf1on:
2
Ae you sue you Wanf fo add fhe nefWok 1nfeface cad efh3 on c1usfe node hadnode02
fo fhe nefWok db2pub11cnefWok1? |1]
1. Yes
2. No
1

Add1ng nefWok 1nfeface cad efh3 on c1usfe node hadnode02 fo fhe nefWok
db2pub11cnefWok1 ...
Add1ng nefWok 1nfeface cad efh3 on c1usfe node hadnode02 fo fhe nefWok
db2pub11cnefWok1 Was successfu1.
Lnfe fhe name of fhe nefWok fo fhe nefWok 1nfeface cad: efh3 on c1usfe node:
hadnode01
1. db2pub11cnefWok1
2. db2pub11cnefWok0
3. Ceafe a neW pub11c nefWok fo fh1s nefWok 1nfeface cad.
4. Ceafe a neW p1vafe nefWok fo fh1s nefWok 1nfeface cad.
Lnfe se1ecf1on:
1
9
Ae you sue you Wanf fo add fhe nefWok 1nfeface cad efh3 on c1usfe node hadnode01
fo fhe nefWok db2pub11cnefWok1? |1]
1. Yes
2. No
1
Add1ng nefWok 1nfeface cad efh3 on c1usfe node hadnode01 fo fhe nefWok
db2pub11cnefWok1 ...
Add1ng nefWok 1nfeface cad efh3 on c1usfe node hadnode01 fo fhe nefWok
db2pub11cnefWok1 Was successfu1.
kef1ev1ng h1gh ava11ab111fy conf1guaf1on paamefe fo 1nsfance db21nsf1 ...
kef1ev1ng h1gh ava11ab111fy conf1guaf1on paamefe fo 1nsfance db21nsf1 Was
successfu1.
Add1ng D82 dafabase paf1f1on 0 fo fhe c1usfe ...
Add1ng D82 dafabase paf1f1on 0 fo fhe c1usfe Was successfu1.

kef1ev1ng h1gh ava11ab111fy conf1guaf1on paamefe fo 1nsfance db21nsf1...
1he c1usfe manage conf1guaf1on paamefe {h1gh ava11ab111fy conf1guaf1on paamefe}
1s nof sef. Io moe 1nfomaf1on, see fhe fop1c c1usfemg - C1usfe manage name
conf1guaf1on paamefe 1n fhe D82 lnfomaf1on Cenfe. Do you Wanf fo sef fhe h1gh
ava11ab111fy conf1guaf1on paamefe?
1he fo11oW1ng ae va11d seff1ngs fo fhe h1gh ava11ab111fy conf1guaf1on paamefe:
1.15A
2.vendo
Lnfe a va1ue fo fhe h1gh ava11ab111fy conf1guaf1on paamefe: |1]
1

Do you Wanf fo va11dafe and aufomafe hADk fa11ove fo fhe hADk dafabase hADkD8? |1]
1. Yes
2. No
1
Add1ng hADk dafabase hADkD8 fo fhe doma1n ...
1he hADk dafabase hADkD8 has been defem1ned fo be va11d fo h1gh ava11ab111fy. hoWeve,
fhe dafabase cannof be added fo fhe c1usfe fom fh1s node because db2ha1cu defecfed fh1s
node 1s fhe sfandby fo fhe hADk dafabase hADkD8. kun db2ha1cu on fhe p1may fo fhe
hADk dafabase hADkD8 fo conf1gue fhe dafabase fo aufomafed fa11ove.
A11 c1usfe conf1guaf1ons have been comp1efed successfu11y. db2ha1cu ex1f1ng ...
bash-3.00$

10. Execute db2haicu on Primary node

bash-3.00$ db2ha1cu
We1come fo fhe D82 h1gh Ava11ab111fy lnsfance Conf1guaf1on uf111fy {db2ha1cu}.

You can f1nd defa11ed d1agnosf1c 1nfomaf1on 1n fhe D82 seve d1agnosf1c 1og f11e ca11ed
db2d1ag.1og. A1so, you can use fhe uf111fy ca11ed db2pd fo quey fhe sfafus of fhe
c1usfe doma1ns you ceafe.

Io moe 1nfomaf1on abouf conf1gu1ng you c1usfeed env1onmenf us1ng db2ha1cu, see fhe
fop1c ca11ed D82 h1gh Ava11ab111fy lnsfance Conf1guaf1on uf111fy {db2ha1cu} 1n fhe D82
lnfomaf1on Cenfe.

db2ha1cu defem1ned fhe cuenf D82 dafabase manage 1nsfance 1s db21nsf1. 1he c1usfe
conf1guaf1on fhaf fo11oWs W111 app1y fo fh1s 1nsfance.

db2ha1cu 1s co11ecf1ng 1nfomaf1on on you cuenf sefup. 1h1s sfep may fake some f1me as
db2ha1cu W111 need fo acf1vafe a11 dafabases fo fhe 1nsfance fo d1scove a11 pafhs ...
When you use db2ha1cu fo conf1gue you c1usfeed env1onmenf, you ceafe c1usfe
doma1ns. Io moe 1nfomaf1on, see fhe fop1c Ceaf1ng a c1usfe doma1n W1fh db2ha1cu 1n
fhe D82 lnfomaf1on Cenfe. db2ha1cu 1s seach1ng fhe cuenf mach1ne fo an ex1sf1ng
acf1ve c1usfe doma1n ...
db2ha1cu found a c1usfe doma1n ca11ed haddoma1n on fh1s mach1ne. 1he c1usfe
conf1guaf1on fhaf fo11oWs W111 app1y fo fh1s doma1n.

kef1ev1ng h1gh ava11ab111fy conf1guaf1on paamefe fo 1nsfance db21nsf1 ...
1he c1usfe manage name conf1guaf1on paamefe {h1gh ava11ab111fy conf1guaf1on
paamefe} 1s nof sef. Io moe 1nfomaf1on, see fhe fop1c "c1usfemg - C1usfe manage
name conf1guaf1on paamefe" 1n fhe D82 lnfomaf1on Cenfe. Do you Wanf fo sef fhe h1gh
ava11ab111fy conf1guaf1on paamefe?
1he fo11oW1ng ae va11d seff1ngs fo fhe h1gh ava11ab111fy conf1guaf1on paamefe:
1.15A
2.vendo
Lnfe a va1ue fo fhe h1gh ava11ab111fy conf1guaf1on paamefe: |1]
1
5eff1ng a h1gh ava11ab111fy conf1guaf1on paamefe fo 1nsfance db21nsf1 fo 15A.
Add1ng D82 dafabase paf1f1on 0 fo fhe c1usfe ...
Add1ng D82 dafabase paf1f1on 0 fo fhe c1usfe Was successfu1.
10
Do you Wanf fo va11dafe and aufomafe hADk fa11ove fo fhe hADk dafabase hADkD8? |1]
1. Yes
2. No
1
Add1ng hADk dafabase hADkD8 fo fhe doma1n ...
1he c1usfe node 9.1.2.3 Was nof found 1n fhe doma1n. P1ease e-enfe fhe hosf name.
hadnode02
1he c1usfe node 9.1.2.4 Was nof found 1n fhe doma1n. P1ease e-enfe fhe hosf name.
hadnode01 efe fo Append1x fo moe defa11s on c1usfe node name eso1uf1on
Add1ng hADk dafabase hADkD8 fo fhe doma1n ...
Add1ng hADk dafabase hADkD8 fo fhe doma1n Was successfu1.
Do you Wanf fo conf1gue a v1fua1 lP addess fo fhe hADk dafabase hADkD8? |1]
1. Yes
2. No
1
Lnfe fhe v1fua1 lP addess:
9.1.2.5
Lnfe fhe subnef mask fo fhe v1fua1 lP addess 9.1.2.5: |255.255.255.0]
255.255.255.0
5e1ecf fhe nefWok fo fhe v1fua1 lP 9.1.2.5:
1. db2pub11cnefWok0
2. db2pub11cnefWok1
Lnfe se1ecf1on:
1
Add1ng v1fua1 lP addess 9.1.2.5 fo fhe doma1n ...
Add1ng v1fua1 lP addess 9.1.2.5 fo fhe doma1n Was successfu1.
A11 c1usfe conf1guaf1ons have been comp1efed successfu11y. db2ha1cu ex1f1ng ...
bash-3.00$

11. Check cluster status
On successful completion of commands, cluster domain and nodes status can be checked
by following commands [the command output should same across all nodes in cluster]

bash-3.00$ 1spdoma1n
Name Op5fafe k5C1Acf1veves1on M1xedves1ons 15Pof G5Pof
haddoma1n On11ne 2.5.3.3 No 12347 1234


bash-3.00$ 1spnode
Name Op5fafe k5C1ves1on
hadnode01 On11ne 2.5.3.3
hadnode02 On11ne 2.5.3.3


bash-3.00$ 1ssam
On11ne l8M.kesouceGoup:db2db21nsf1hadnode010-g Nom1na1=On11ne
- On11ne l8M.App11caf1on:db2db21nsf1hadnode010-s
- On11ne l8M.App11caf1on:db2db21nsf1hadnode010-s:hadnode01
On11ne l8M.kesouceGoup:db2db21nsf1hadnode020-g Nom1na1=On11ne
- On11ne l8M.App11caf1on:db2db21nsf1hadnode020-s
- On11ne l8M.App11caf1on:db2db21nsf1hadnode020-s:hadnode02
On11ne l8M.kesouceGoup:db2db21nsf1db21nsf1hADkD8-g Nom1na1=On11ne
|- On11ne l8M.App11caf1on:db2db21nsf1db21nsf1hADkD8-s
|- On11ne l8M.App11caf1on:db2db21nsf1db21nsf1hADkD8-s:hadnode01
- Off11ne l8M.App11caf1on:db2db21nsf1db21nsf1hADkD8-s:hadnode02
- On11ne l8M.5ev1celP: db21p9125-s
|- On11ne l8M.5ev1celP:db21p9125-s:hadnode01
- Off11ne l8M.5ev1celP:db21p9125-s:hadnode02

Now the HADR setup is all set for automatic failover in case of disaster. TSA cluster
starts automatically with absolutely no manual intervention.
11
Part 3 : Miscellaneous tasks / Diagnostics
12. Disable TSA cluster
This option is for scheduled maintenance of setup. It only stops TSA, HADR will
remain active (but failover will not happen). Execute this on primary node as instance
owner.

bash-3.00$ db2ha1cu -d1sab1e
We1come fo fhe D82 h1gh Ava11ab111fy lnsfance Conf1guaf1on uf111fy {db2ha1cu}.

You can f1nd defa11ed d1agnosf1c 1nfomaf1on 1n fhe D82 seve d1agnosf1c 1og f11e ca11ed
db2d1ag.1og. A1so, you can use fhe uf111fy ca11ed db2pd fo quey fhe sfafus of fhe
c1usfe doma1ns you ceafe.

Io moe 1nfomaf1on abouf conf1gu1ng you c1usfeed env1onmenf us1ng db2ha1cu, see fhe
fop1c ca11ed D82 h1gh Ava11ab111fy lnsfance Conf1guaf1on uf111fy {db2ha1cu} 1n fhe D82
lnfomaf1on Cenfe.

db2ha1cu defem1ned fhe cuenf D82 dafabase manage 1nsfance 1s db21nsf1. 1he c1usfe
conf1guaf1on fhaf fo11oWs W111 app1y fo fh1s 1nsfance.

db2ha1cu 1s co11ecf1ng 1nfomaf1on on you cuenf sefup. 1h1s sfep may fake some f1me as
db2ha1cu W111 need fo acf1vafe a11 dafabases fo fhe 1nsfance fo d1scove a11 pafhs ...
Ae you sue you Wanf fo d1sab1e h1gh ava11ab111fy {hA} fo fhe dafabase 1nsfance
db21nsf1. 1h1s W111 1ock a11 fhe esouce goups fo fhe 1nsfance and d1sab1e fhe hA
conf1guaf1on paamefe. 1he 1nsfance W111 nof fa11ove 1f a sysfem oufage occus Wh11e
fhe 1nsfance 1s d1sab1ed. You W111 need fo un db2ha1cu aga1n fo enab1e fhe 1nsfance fo
hA. D1sab1e hA fo fhe 1nsfance db21nsf1? |1]
1. Yes
2. No
1
D1sab11ng h1gh ava11ab111fy fo 1nsfance db21nsf1 ...
Lock1ng fhe esouce goup fo hADk dafabase hADkD8 ...
Lock1ng fhe esouce goup fo hADk dafabase hADkD8 Was successfu1.
Lock1ng fhe esouce goup fo D82 dafabase paf1f1on 0 ...
Lock1ng fhe esouce goup fo D82 dafabase paf1f1on 0 Was successfu1.
Lock1ng fhe esouce goup fo D82 dafabase paf1f1on 0 ...
Lock1ng fhe esouce goup fo D82 dafabase paf1f1on 0 Was successfu1.
D1sab11ng h1gh ava11ab111fy fo 1nsfance db21nsf1 Was successfu1.
A11 c1usfe conf1guaf1ons have been comp1efed successfu11y. db2ha1cu ex1f1ng ...
13. Enable TSA cluster
Launch this command from primary node as instance owner.

bash-3.00$ db2ha1cu
We1come fo fhe D82 h1gh Ava11ab111fy lnsfance Conf1guaf1on uf111fy {db2ha1cu}.

You can f1nd defa11ed d1agnosf1c 1nfomaf1on 1n fhe D82 seve d1agnosf1c 1og f11e ca11ed
db2d1ag.1og. A1so, you can use fhe uf111fy ca11ed db2pd fo quey fhe sfafus of fhe
c1usfe doma1ns you ceafe.

Io moe 1nfomaf1on abouf conf1gu1ng you c1usfeed env1onmenf us1ng db2ha1cu, see fhe
fop1c ca11ed D82 h1gh Ava11ab111fy lnsfance Conf1guaf1on uf111fy {db2ha1cu} 1n fhe D82
lnfomaf1on Cenfe.

db2ha1cu defem1ned fhe cuenf D82 dafabase manage 1nsfance 1s db21nsf1. 1he c1usfe
conf1guaf1on fhaf fo11oWs W111 app1y fo fh1s 1nsfance.

db2ha1cu 1s co11ecf1ng 1nfomaf1on on you cuenf sefup. 1h1s sfep may fake some f1me as
db2ha1cu W111 need fo acf1vafe a11 dafabases fo fhe 1nsfance fo d1scove a11 pafhs ...
When you use db2ha1cu fo conf1gue you c1usfeed env1onmenf, you ceafe c1usfe
doma1ns. Io moe 1nfomaf1on, see fhe fop1c Ceaf1ng a c1usfe doma1n W1fh db2ha1cu 1n
fhe D82 lnfomaf1on Cenfe. db2ha1cu 1s seach1ng fhe cuenf mach1ne fo an ex1sf1ng
acf1ve c1usfe doma1n ...
db2ha1cu found a c1usfe doma1n ca11ed haddoma1n on fh1s mach1ne. 1he c1usfe
conf1guaf1on fhaf fo11oWs W111 app1y fo fh1s doma1n.

db2ha1cu has defecfed fhaf h1gh ava11ab111fy has been d1sab1ed fo fhe 1nsfance db21nsf1.
Do you Wanf fo enab1e h1gh ava11ab111fy fo fhe 1nsfance db21nsf1? |1]
1. Yes
12
2. No
1
kef1ev1ng h1gh ava11ab111fy conf1guaf1on paamefe fo 1nsfance db21nsf1 ...
1he c1usfe manage name conf1guaf1on paamefe {h1gh ava11ab111fy conf1guaf1on
paamefe} 1s nof sef. Io moe 1nfomaf1on, see fhe fop1c "c1usfemg - C1usfe manage
name conf1guaf1on paamefe" 1n fhe D82 lnfomaf1on Cenfe. Do you Wanf fo sef fhe h1gh
ava11ab111fy conf1guaf1on paamefe?
1he fo11oW1ng ae va11d seff1ngs fo fhe h1gh ava11ab111fy conf1guaf1on paamefe:
1.15A
2.vendo
Lnfe a va1ue fo fhe h1gh ava11ab111fy conf1guaf1on paamefe: |1]
1
5eff1ng a h1gh ava11ab111fy conf1guaf1on paamefe fo 1nsfance db21nsf1 fo 15A.
Lnab11ng h1gh ava11ab111fy fo 1nsfance db21nsf1 ...
Lnab11ng h1gh ava11ab111fy fo 1nsfance db21nsf1 Was successfu1.
A11 c1usfe conf1guaf1ons have been comp1efed successfu11y. db2ha1cu ex1f1ng ...
14. db2haicu maintenance mode
db2haicu will have following output if its already active. This mode is called
maintenance mode. You can add/remove nodes, databases, virtual IPs, network interfaces
and quorum device. This command should be executed from primary database node.

bash-3.00$ db2ha1cu
We1come fo fhe D82 h1gh Ava11ab111fy lnsfance Conf1guaf1on uf111fy {db2ha1cu}.

You can f1nd defa11ed d1agnosf1c 1nfomaf1on 1n fhe D82 seve d1agnosf1c 1og f11e ca11ed
db2d1ag.1og. A1so, you can use fhe uf111fy ca11ed db2pd fo quey fhe sfafus of fhe
c1usfe doma1ns you ceafe.

Io moe 1nfomaf1on abouf conf1gu1ng you c1usfeed env1onmenf us1ng db2ha1cu, see fhe
fop1c ca11ed D82 h1gh Ava11ab111fy lnsfance Conf1guaf1on uf111fy {db2ha1cu} 1n fhe D82
lnfomaf1on Cenfe.

db2ha1cu defem1ned fhe cuenf D82 dafabase manage 1nsfance 1s db21nsf1. 1he c1usfe
conf1guaf1on fhaf fo11oWs W111 app1y fo fh1s 1nsfance.

db2ha1cu 1s co11ecf1ng 1nfomaf1on on you cuenf sefup. 1h1s sfep may fake some f1me as
db2ha1cu W111 need fo acf1vafe a11 dafabases fo fhe 1nsfance fo d1scove a11 pafhs ...
When you use db2ha1cu fo conf1gue you c1usfeed env1onmenf, you ceafe c1usfe
doma1ns. Io moe 1nfomaf1on, see fhe fop1c Ceaf1ng a c1usfe doma1n W1fh db2ha1cu 1n
fhe D82 lnfomaf1on Cenfe. db2ha1cu 1s seach1ng fhe cuenf mach1ne fo an ex1sf1ng
acf1ve c1usfe doma1n ...
db2ha1cu found a c1usfe doma1n ca11ed haddoma1n on fh1s mach1ne. 1he c1usfe
conf1guaf1on fhaf fo11oWs W111 app1y fo fh1s doma1n.

5e1ecf an adm1n1sfaf1ve fask by numbe fom fhe 11sf be1oW:
1. Add o emove c1usfe nodes.
2. Add o emove a nefWok 1nfeface.
3. Add o emove hADk dafabases.
4. Add o emove an lP addess.
5. Move D82 dafabase paf1f1ons and hADk dafabases fo schedu1ed ma1nfenance.
6. Ceafe a neW quoum dev1ce fo fhe doma1n.
7. Desfoy fhe doma1n.
. Lx1f.
Lnfe you se1ecf1on:


15. HADR automated failover resource listing using db2pd
This command can be issued from any of the database nodes.

bash-3.00$ db2pd -ha
D82 hA 5fafus
lnsfance lnfomaf1on:
lnsfance Name = db21nsf1
Numbe Of Doma1ns = 1
Numbe Of kGs fo 1nsfance = 2

Doma1n lnfomaf1on:
Doma1n Name = haddoma1n
C1usfe ves1on = 2.5.3.3
C1usfe 5fafe = On11ne
13
Numbe of nodes = 2

Node lnfomaf1on:
Node Name 5fafe
--------------------- -------------------
hadnode01 On11ne
hadnode02 On11ne

kesouce Goup lnfomaf1on:
kesouce Goup Name = db2db21nsf1db21nsf1hADkD8-g
kesouce Goup Lock5fafe = un1ocked
kesouce Goup Op5fafe = On11ne
kesouce Goup Nom1na1 Op5fafe = On11ne
Numbe of Goup kesouces = 2
Numbe of A11oWed Nodes = 2
A11oWed Nodes
-------------
hadnode02
hadnode01
Membe kesouce lnfomaf1on:
kesouce Name = db2db21nsf1db21nsf1hADkD8-s
kesouce 5fafe = On11ne
kesouce 1ype = hADk
hADk P1may lnsfance = db21nsf1
hADk 5econday lnsfance = db21nsf1
hADk D8 Name = hADkD8
hADk P1may Node = hadnode02
hADk 5econday Node = hadnode01

kesouce Name = db21p9125-s
kesouce 5fafe = On11ne
kesouce 1ype = lP

kesouce Goup Name = db2db21nsf1hadnode020-g
kesouce Goup Lock5fafe = un1ocked
kesouce Goup Op5fafe = On11ne
kesouce Goup Nom1na1 Op5fafe = On11ne
Numbe of Goup kesouces = 1
Numbe of A11oWed Nodes = 1
A11oWed Nodes
-------------
hadnode02
Membe kesouce lnfomaf1on:
kesouce Name = db2db21nsf1hadnode020-s
kesouce 5fafe = On11ne
kesouce 1ype = D82 Paf1f1on
D82 Paf1f1on Numbe = 0
Numbe of A11oWed Nodes = 1
A11oWed Nodes
-------------
hadnode02

NefWok lnfomaf1on:
NefWok Name Numbe of Adapfes
----------------------- ------------------
db2pub11cnefWok1 2
Node Name Adapfe Name
----------------------- ------------------
hadnode02 efh3
hadnode01 efh3

NefWok Name Numbe of Adapfes
----------------------- ------------------
db2pub11cnefWok0 2

Node Name Adapfe Name
----------------------- ------------------
hadnode01 efh10
hadnode02 efh10

quoum lnfomaf1on:
quoum Name quoum 5fafe
------------------------------------ --------------------
db2quoumNefWok9121:1346 On11ne
Opeafo Off11ne
Ia11 Off11ne



14
16. HADR status using db2pd
This command can be issued from any of the database nodes.

bash-3.00$ db2pd -had -db haddb

Dafabase Paf1f1on 0 -- Dafabase hADkD8 -- Acf1ve -- up 0 days 03:33:33

hADk lnfomaf1on:
ko1e 5fafe 5yncMode heaf8eafsM1ssed LogGapkunAvg {byfes}
P1may Pee Neasync 0 0

Connecf5fafus Connecf11me 11meouf
Connecfed Mon Dec 22 20:15:14 200 {1229955314} 30

PeeW1ndoWLnd PeeW1ndoW
Mon Dec 22 23:36:21 200 {122996731} 60

Loca1hosf Loca15ev1ce
hadnode01 D82hADkPOk1

kemofehosf kemofe5ev1ce kemofelnsfance
hadnode02 D82hADkPOk1 db21nsf1

P1mayI11e P1mayPg P1mayL5N
50037993.LOG 1406 0x0000018LL25065ID

5fand8yI11e 5fand8yPg 5fand8yL5N
50037993.LOG 1406 0x0000018LL25065ID
db2pd-had.ouf: LND

15
Part 4 : Remove TSA/HADR configuration

In order to remove TSA configuration settings (cluster and resource groups) completely
from the cluster,
17. Remove TSA cluster

bash-3.00$ db2ha1cu -de1efe
We1come fo fhe D82 h1gh Ava11ab111fy lnsfance Conf1guaf1on uf111fy {db2ha1cu}.

You can f1nd defa11ed d1agnosf1c 1nfomaf1on 1n fhe D82 seve d1agnosf1c 1og f11e ca11ed
db2d1ag.1og. A1so, you can use fhe uf111fy ca11ed db2pd fo quey fhe sfafus of fhe
c1usfe doma1ns you ceafe.

Io moe 1nfomaf1on abouf conf1gu1ng you c1usfeed env1onmenf us1ng db2ha1cu, see fhe
fop1c ca11ed D82 h1gh Ava11ab111fy lnsfance Conf1guaf1on uf111fy {db2ha1cu} 1n fhe D82
lnfomaf1on Cenfe.

db2ha1cu defem1ned fhe cuenf D82 dafabase manage 1nsfance 1s db21nsf1. 1he c1usfe
conf1guaf1on fhaf fo11oWs W111 app1y fo fh1s 1nsfance.

When you use db2ha1cu fo conf1gue you c1usfeed env1onmenf, you ceafe c1usfe
doma1ns. Io moe 1nfomaf1on, see fhe fop1c Ceaf1ng a c1usfe doma1n W1fh db2ha1cu 1n
fhe D82 lnfomaf1on Cenfe. db2ha1cu 1s seach1ng fhe cuenf mach1ne fo an ex1sf1ng
acf1ve c1usfe doma1n ...
db2ha1cu found a c1usfe doma1n ca11ed haddoma1n on fh1s mach1ne. 1he c1usfe
conf1guaf1on fhaf fo11oWs W111 app1y fo fh1s doma1n.

kemov1ng hADk dafabase hADkD8 fom fhe doma1n ...
kemov1ng hADk dafabase hADkD8 fom fhe doma1n Was successfu1.
kemov1ng D82 dafabase paf1f1on 0 fom fhe c1usfe ...
kemov1ng D82 dafabase paf1f1on 0 fom fhe c1usfe Was successfu1.
kemov1ng D82 dafabase paf1f1on 0 fom fhe c1usfe ...
kemov1ng D82 dafabase paf1f1on 0 fom fhe c1usfe Was successfu1.
De1ef1ng fhe doma1n haddoma1n fom fhe c1usfe ...
De1ef1ng fhe doma1n haddoma1n fom fhe c1usfe Was successfu1.
A11 c1usfe conf1guaf1ons have been comp1efed successfu11y. db2ha1cu ex1f1ng ...


18. Stop HADR

hadrnode02
$ db2 sfop had on db haddb
D820000l 1he 51OP hADk ON DA1A8A5L command comp1efed successfu11y.

hadrnode01
$ db2 deacf1vafe dafabase haddb
D820000l 1he DLAC1lvA1L DA1A8A5L command comp1efed successfu11y.
$ db2 sfop had on db haddb
D820000l 1he 51OP hADk ON DA1A8A5L command comp1efed successfu11y.


16
Part 5 : Automatic client reroute (ACR)
Automatic client reroute is a DB2 Database for Linux, UNIX, and Windows feature that
allows client applications to recover from a loss of communication with the server so that
the application can continue its work with minimal interruption. Automatic client reroute
can be accomplished only if an alternate server has been specified prior to the loss of
communication. Client should atleast connect to server once in order to be able to use
ACR feature. No configuration changes on the client side are required.
19. Add ACR configuration
hadrnode01

$ db2 updafe a1fenafe seve fo dafabase haddb us1ng hosfname hadnode02 pof 50000
D820000l 1he uPDA1L AL1LkNA1L 5LkvLk IOk DA1A8A5L command comp1efed
successfu11y.
D821056W D1ecfoy changes may nof be effecf1ve unf11 fhe d1ecfoy cache 1s
efeshed.

hadrnode02

$ db2 updafe a1fenafe seve fo dafabase haddb us1ng hosfname hadnode01 pof 50000
D820000l 1he uPDA1L AL1LkNA1L 5LkvLk IOk DA1A8A5L command comp1efed
successfu11y.
D821056W D1ecfoy changes may nof be effecf1ve unf11 fhe d1ecfoy cache 1s
efeshed.


20. Remove ACR configuration

hadrnode01

$ db2 updafe a1fenafe seve fo dafabase haddb us1ng hosfname NuLL pof NuLL
D820000l 1he uPDA1L AL1LkNA1L 5LkvLk IOk DA1A8A5L command comp1efed
successfu11y.
D821056W D1ecfoy changes may nof be effecf1ve unf11 fhe d1ecfoy cache 1s
efeshed.

hadrnode02

$ db2 updafe a1fenafe seve fo dafabase haddb us1ng hosfname NuLL pof NuLL
D820000l 1he uPDA1L AL1LkNA1L 5LkvLk IOk DA1A8A5L command comp1efed
successfu11y.
D821056W D1ecfoy changes may nof be effecf1ve unf11 fhe d1ecfoy cache 1s
efeshed.
17
Appendix
Why database creation is required on both nodes?

Database creation is required on both db nodes so that LOGRETAIN can be set to
recovery successfully. If backup from hadrnode01 is restored on hadrnode01 before
enabling LOGRETAIN, database will have Backup pending and Rollforward
pending flags ON. In this state database can not be backed up because its in
Rollforward pending state and HADR standby can not be started on this database because
database is in Backup pending state.

Quorum device

A quorum device helps a cluster manager make cluster management decisions when the
cluster manager's normal decision process does not produce a clear choice. When a
cluster manager has to choose between multiple potential actions, the cluster manager
counts how many cluster domain nodes support each of the potential actions; and then
cluster manager chooses the action that is supported by the majority of cluster domain
nodes. If exactly the same number of cluster domain nodes supports more than one
choice, then the cluster manager refers to a quorum device to make the choice.

A network quorum device is an IP address to which every cluster domain node can
connect (ping) at all times.

In current implementation network route IP is used assuming that as long as network
segment is UP and RUNNING, router will always be available. No special software is
required to be installed in this quorum device. It should be reachable (ping-able) to both
the nodes all the time. During the disaster/node crash event, this device should be
reachable to other node which is working fine (either as primary/standby).
Cluster node name resolution

This resolution is required only when IP address are using during HADR configuration
instead of hostname. Automatic name resolution will not happen using /etc/hosts file.
Right hostname should be provided at this prompt. Names provided at this prompt should
match the ones provided to db2haicu while configuration in step 9.
This prompt will not appear if HADR configuration uses hostname instead of IP
addresses.
Cluster Public/Private networks
Typically servers will have multiple network interfaces. In current implementation we
have 2 network interfaces on each node [eth3 and eth10]. Public network on both nodes
are using eth3 network adapter and private network uses eth10 network adapter. Network
18
interfaces with compatible IP address should be grouped together. In current
implementation eth3 on both nodes are in db2pub11cnefWok1 and eth10 are in
db2pub11cnefWok0.

HADR States

Peer
This state indicates that primary and standby nodes are in sync and standby is
ready to takeover as primary database.


LocalCatchup
This state indicates that database has just started and is reading local log files
from log paths, archive paths. Immediately after this state, node will enter into
RemoteCatchupPending state.


19
RemoteCatchupPending
This state indicates standby node is waiting for Primary to come up in order to
receive any log updates. Node can enter into this state if during a RemoteCatchup
connection between Primary and standby breaks.


RemoteCatchup
This state indicates standby is applying the log gap between Primary and standby
onto standby node.


Disconnected
This state indicates standby node is not available




Manual takeover
To make standby node as primary manually, issue following command at standby node

$ db2 fakeove had on db haddb
D820000l 1he 1AkLOvLk hADk ON DA1A8A5L command comp1efed successfu11y.

If for some reason, automatic failover fails, issue following command to force manual
takeover.

$ db2 fakeove had on db haddb by foce
D820000l 1he 1AkLOvLk hADk ON DA1A8A5L command comp1efed successfu11y.


Definite NO NO for HADR setup

Never use nonrecoverable load on HADR setup. It will stop log shipping to standby
and the only option left to make HADR work again is to backup Primary (full backup)
node and restore it onto standby node. This might not be an option at all if database size
is of the order of terabytes; because backup and restore will take several hours to
complete.

20
DB2_LOAD_COPY_NO_OVERRIDE
HADR replicates load with certain restrictions. Because load data is not embedded in the
log stream, the standby can only get the data from a load copy. Thus load is replicated
only if there is a load copy. The copy must be available to the standby when it replays the
load. The standby may attempt to access the copy any time after the primary completes
the load. It is recommended that a shared copy device such as NFS is used. If you transfer
the copy by means like physically transferring a tape, it is recommended that the standby
be stopped ("db2 deactivated database") before the primary starts the load. Once the
primary finishes the load and the copy is available to the standby, restart the standby
("db2 activate database"). The standby will then reconnect to the primary and replay the
load.
When the primary does a load with COPY NO option, by default the load is
automatically converted to NONRECOVERABLE. When standby replays the load, the
table is marked as invalid. COPY NO loads can be optionally converted to COPY YES
via the DB2_LOAD_COPY_NO_OVERRIDE registry variable.


Application impact
In the even of failover from hadrnode01 to hadrnode02 (either due to disaster or manual
takeover), application will receive following message once after successful takeover.

5qL3010N A connecf1on fa11ed buf has been e-esfab11shed. 1he hosfname o lP
addess 1s "hadnode02" and fhe sev1ce name o pof numbe 1s "50003".
5pec1a1 eg1sfes may o may nof be e-affempfed {keason code = "1"}.
5qL51A1L=0506

In order to make this failover look transparent to users, application need to catch and
handle above SQL code and retry internally or request user to try after few minutes.
Here is one sample code

fy {
// fansacf1on code
} cafch {5qLLxcepf1on sq1Lx} {
1f{sq1Lx.gefCause{}.gefLoCode{} == 3010} {
// execufe fhe fansacf1on aga1n.
}e1se{
fhoW sq1Lx // e1ease unhand1ed excepf1ons fo ofhe hand1es
}
}
}



21
Upgrading DB2

In case of Rolling Upgrade (DB2 patch application), both the nodes should be brought on
to the same DB2 patch level as soon as possible. In other words, it is not possible to apply
patch on one node and then after few days apply the patch onto the second node. As soon
as primary node will know that standby is on a different db2 level, HADR state will
become Disconnected.




References
1. http://www.ibm.com/developerworks/wikis/display/data/HADR_home
2. http://www.ibm.com/developerworks/db2/bestpractices/
3. http://publib.boulder.ibm.com/infocenter/db2luw/v8/topic/com.ibm.db2.udb.doc/c
ore/c0011585.htm
4. http://www.demos.ibm.com/on_demand/Demo/IBM_Demo_DB2_HADR-
Jan05.html
5. ftp://ftp.software.ibm.com/ps/products/db2/info/vr97/pdf/en_US/DB2RecoveryA
ndHA-db2hae971.pdf



Rolling Upgrade for DB2 fix pack, OS
HADR connection
HADR connection
HADR connection
HADR connection
HADR connection
P
fpN+1
S
fpN fpN
P
S
S
S
S
P
P
P
fpN
fpN
fpN+1
fpN+1
fpN+1
fpN+1
fpN+1
Both P and S on fpN
Optional 2
nd
takeover
Both on fpN+1
Shutdown S. Upgrade S, Restart S,
S on fpN+1
Takeover.
P on fpN+1
Connection is closed at end of takeover
Shutdown S. Upgrade S, Restart S,
Both on fpN+1
0
3
2
1
4

You might also like