I've got a set of redundant marts that I'm trying to catalog on the
client side to allow us to do two things:
1. manually recatalog to point at either of the two fast marts
2. automatically failover to a third slow mart
The data marts are on db2 8.2.1, the client on db2 8.2.?
But I'm hitting a few roadblocks here - all suggestions are
appreciated. So, I've given our portal team (runs actuate) a pair of
scripts to switch the catalog entries between the two fast marts:
recatalog_to_primary.ksh:
#!/bin/ksh
db2 terminate
db2 catalog tcpip node server1 remote server1 server 60000
db2 uncatalog database rptmart
db2 catalog database rptmart as rptmart at node server1
db2 terminate
exit 0
recatalog_to_secondary.ksh:
#!/bin/ksh
db2 terminate
db2 catalog tcpip node server2 remote server2 server 60000
db2 uncatalog database rptmart
db2 catalog database rptmart as rptmart at node server2
db2 terminate
exit 0
Additionally, on the server side I've updated each server to point at
the other as an alternate (via client rerouting). These will
eventually point to the slow mart, but for right now they are pointing
to each other.
Database 1 entry for server1:
Database alias = RPTMART
Database name = RPTMART
Local database directory = /db2i2_home/db2i2
Database release level = a.00
Comment =
Directory entry type = Indirect
Catalog database partition number = 0
Alternate server hostname = server2
Alternate server port number = 60000
Database 1 entry for server2:
Database alias = RPTMART
Database name = RPTMART
Local database directory = /db2i2_home/db2i2
Database release level = a.00
Comment =
Directory entry type = Indirect
Catalog database partition number = 0
Alternate server hostname = server1
Alternate server port number = 60000
So, here's what I've seen regarding the manual recataloging:
1. when i've experimented with the recatalog scripts on one of our
other servers, it continued to connect to the wrong server. Bouncing
the instance helped - but I can't rely on that in production. Any
suggestions?
And here's what I've seen regarding the automatic client rerouting:
2. after connecting to one of these servers from the portal server its
local database directory does not show the alternate server. Should
it?
3. after I force a portal query on one server (resulting in a
SQL30081N) the actuate query fails, returning the SQL30081N, instead of
reconnecting to the alternate. Do I need to do anything else to get
the server alternates used by the client?
4. i'd prefer to configure client rerouting on the client side rather
than the server - so that I could have different clients reroute to
different failover servers (the clients have differing availability
requirements). It looks like the clients should support this, but the
online documentation seemed to indicate that rerouting info on the
client side was ignored. Is this true?
Thanks!
Ken