Here some instructions I worked up after confguring HADR myself:
Add the following to /etc/services on Primary Server:
hadrinstp 18819/tcp
Add the following to /etc/services on Standby Server:
hadrinsts 18819/tcp
Note: Each DB2 database that uses HADR on a given physical server needs its own port for hadr_local_svc.
On Primary Server:
db2 update db cfg using LOGARCHMETH1 DISK:/localhome/db2inst1/archive_logs
Note: This enables log retain, but you can set other config parms to enable log retain. Make sure the directory already exists.
db2 BACKUP DATABASE <db-name> TO "/db_backup" COMPRESS WITHOUT PROMPTING
(backup to whatever directory you want)
On Standby Server:
restore the backup on the secondary server:
db2 RESTORE DATABASE <db-name> FROM "/db_backup/" TAKEN AT 20051101173309 replace history file
Note: do not rollforward. ON Windows, you must copy the entire backup directory path to the standby server to do a restore.
On Primary Server:
db2 update db cfg for <db-name> using HADR_LOCAL_HOST <primary host name>
db2 update db cfg for <db-name> using HADR_REMOTE_HOST <secondary host name>
db2 update db cfg for <db-name> using HADR_LOCAL_SVC 18819
db2 update db cfg for <db-name> using HADR_REMOTE_SVC 18819
db2 update db cfg for <db-name> using HADR_REMOTE_INST db2inst1
db2 update db cfg for <db-name> using HADR_SYNCMODE nearsync
db2 update db cfg for <db-name> using HADR_TIMEOUT 30
db2 update alternate server for database <db-name> using hostname <secondary host name> port 50000
On Standby Server:
db2 update db cfg for <db-name> using HADR_LOCAL_HOST <secondary host name>
db2 update db cfg for <db-name> using HADR_REMOTE_HOST <primary host name>
db2 update db cfg for <db-name> using HADR_LOCAL_SVC 18819
db2 update db cfg for <db-name> using HADR_REMOTE_SVC 18819
db2 update db cfg for <db-name> using HADR_REMOTE_INST db2inst1
db2 update db cfg for <db-name> using HADR_SYNCMODE nearsync
db2 update db cfg for <db-name> using HADR_TIMEOUT 30
db2 update alternate server for database <db-name> using hostname <primary host name> port 50000
On Standby (always start standby first):
db2 start hadr on db <db-name> as standby
On Primary (only after standby is started):
db2 start hadr on db <db-name> as primary
Takeover:
Issue this command on the standby server instance:
db2 TAKEOVER HADR ON DATABASE <db-name> USER db2inst1 BY FORCE
Note: “BY FORCE” is optional and not necessary if both servers are responding).
Wizard:
Or you can use the HADR Wizard to set it up. This is invoked via the Control Center, Database (right click), High Availability.