473,776 Members | 1,665 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

Couple of HADR questions

Hi,

I'm working with a customer that is trying to find a solution to
provide geographical redundancy. Our application is currently using
IBM DB2 v8.2. I have a couple of questions with regards to HADR:

1. DB2 HADR (Can it be used to support geographical redundancy in a
nested fashion (ie. Synchronous HADR at a site, and ASYNCRONOUS
between sites using the same instances/databases). If so how would we
set it up?

2. DB2 HADR (Is the JDBC configuration any different then when a
single DB2 instance is used?) How is the JDBC driver configured (using
the jdbc connection string) to point to all the DB2 HADR nodes?
Thanks,
Marc

Jan 24 '06 #1
7 5067

HADR itself does not presently support multiple standby sites for one
database. However, the kind of configuration you discuss can be
supported by a combination of traditional failover (i.e.,
shared/multi-ported disk plus cluster manager) locally and HADR across
the distance.

That is, you can configure the HADR primary on a cluster that supports
in-cluster failover for the DB2 server, while the HADR standby is
configured at a remote site (either w/ or w/o local failover for the
standby, but of course we prefer to see analogous configuration of the
standby).

Regarding JDBC configuration, I think you are probably asking about how
to set up Automatic Client Reroute for that client. ACR can be set up
on the server for all clients, but the universal driver also provides
the ability to set it up at the client itself (helpful in some cases,
as the server-side support doesn't kick in until a first successful
connection is made by the client whereas the driver can reroute if the
very first connection attempt itself fails).

Here are a few references for ACR, including some driver specific setup
info:

JDBC driver side:
* http://www-1.ibm.com/support/docview...id=swg21177732
* Search for string "Rerouting DB2 Universal JDBC driver clients" in
the right-hand panel here:
http://publib.boulder.ibm.com/infoce...e/r0012130.htm

Server side:
http://publib.boulder.ibm.com/infoce...n/c0011423.htm

New (general) developerWorks article on ACR:
http://www-128.ibm.com/developerwork...512zikopoulos/

Regards,
- Steve P.
--------------------------
Steve Pearson
IBM DB2 UDB for LUW Development
Portland, OR, USA

Jan 24 '06 #2
Steve thanks for the quick response.

Additional comments to my original questions:

1. How would we setup a DB2 cluster with in-cluster failover if we're
not using HADR?

2. You're correct. I was looking for specifics on how the client would
connect when the very first connection attemps itself fails. Can the
driver use DNS with multiple A records (one pointing to the primary and
the other to the alternate location?).

Much appreciated,
Thanks,
Marc

Jan 24 '06 #3
"Marc" <mb****@magma.c a> wrote in message
news:11******** **************@ g43g2000cwa.goo glegroups.com.. .
Steve thanks for the quick response.

Additional comments to my original questions:

1. How would we setup a DB2 cluster with in-cluster failover if we're
not using HADR?

2. You're correct. I was looking for specifics on how the client would
connect when the very first connection attemps itself fails. Can the
driver use DNS with multiple A records (one pointing to the primary and
the other to the alternate location?).

Much appreciated,
Thanks,
Marc


The type 2 driver does automatic client reroute without any coding changes.
The type 4 driver requires coding changes to persist the alternate server
location. Automatic client reroute works independent of HADR for any
database where you want alternate server connection information.

With both the type 2 and type 4 drivers, if a HADR takeover has occurred,
the application will receive a specific SQL error message that indicates
that the application has automatically reconnected and the last SQL
statement has rolled back, so the application has to retry the failed SQL
statement again, which will work on the standby database (which has now been
switched to primary).
Jan 24 '06 #4
1. How would we setup a DB2 cluster with in-cluster failover if we're
not using HADR?
I'm afraid I'd be beyond my depth to try and give details of this.
Some info and further references here:
http://publib.boulder.ibm.com/infoce...n/c0006354.htm
Can the driver use DNS with multiple A records (one pointing to the primary and
the other to the alternate location?).


Not sure about that either, but I can try to find out. My speculation
is that one would not want to use DNS to try and access one or the
other because you may have to deal with unexpected errors such as
"sorry, can't connect to an HADR standby" because DNS doesn't have a
clue that it shouldn't route you to the standby.

Also, if the name shown in DNS is associated with multiple IP addresses
(if that's what you're referring to), and is also used in the HADR
configuration (HADR_*_HOST) it may cause trouble, since HADR requires
that the given host NOT be multi-homed and that its name is resolved to
match the configuration at both ends.

If you want I could pass your question on to someone who works on ACR
itself to see if they can better answer it.

Regards,
- Steve P.
--------------------------
Steve Pearson
IBM DB2 UDB for LUW Development
Portland, OR, USA

Jan 25 '06 #5
Hi Steve,

Please forward the question to someone who works on ACR.

The issue we're trying to resolve is the case where the first JDBC
client connection failed, how does the client know how to connect to
the 2nd HADR node?
From what I understand, if the first attempt to connect succeeds, then

the information on the 2nd HADR node is sent back to the client, so in
the event of a failure it will know where it needs to reroute for
failover. The issue has to do when trying to establish connectivity on
the first attempt (either the Node is unavailable, network issues,
etc).

Thanks,
Marc

Feb 7 '06 #6
Hi, Marc.

I think the question is changing underfoot. It originally had to do
with DNS.

Regarding rerouting with JDBC on first connection attempts, please see
the links I posted earlier. The JDBC universal driver can be
configured with alternate server information *at the client* which
allows reroute on a first connection attempt. If the server also has
an ACR alternate server configured (which applies to all client types),
then after a successful connection, the server configured info will be
sent back to the client (per usual) and will replace the client's
initial rerouting info.

Regards,
- Steve P.
--------------------------
Steve Pearson
IBM DB2 UDB for LUW Development
Portland, OR, USA

Feb 8 '06 #7
Thanks Steve.

I found the information I was looking for (configuring the client for
rerouting on a first connection attempt). I was hoping this would have
been possible without having to do any code changes (i.e. using Java
system properties or in the JDBC connection string somehow). It seems
the only way of doing this is by using JNDI and creating a serializable
Java Bean with the following 2 properties:
- alternateServer Name
- alternatePortNu mber..

Thanks,
Marc

Feb 22 '06 #8

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

1
3107
by: Bruce M | last post by:
Is there a way to run the db2-generated HADR-create script outside of DB2CC beyond the obvious? My DB2CC generates the HADR script and then abends because of a java error meaning I can't finish my HADR creation. In looking at the script it isn't necessarily obvious which commands should run on the primary server and which should be run on the standby server.
1
3723
by: shindle | last post by:
Hello - I am in the process of testing out the new HADR feature of DB2 UDB V8.2 and I have some questions that I was hoping that someone could answer please. I have a HADR test set-up with two DB2 instances on the same machine with the sample database on each set up as an HADR pair in near-synch mode. I have noticed that when I perform any logged operation on the primary (such as a mass INSERT SQL) that there is a substantial lag in
3
5228
by: bwmiller16 | last post by:
Why are 2 ports required for a HADR Pair? Environment: RH Linux AS3 UDB Express 8.2 with HADR Option Folks - Working with HADR and getting this setup to work right.
7
10620
by: Mark A | last post by:
If server 01 running HADR in the primary role crashes, and the DBA does a HADR takeover by force on the 02 server to switch roles, then the 02 server is now the primary. What happens when the Server 01 is brought back up? It still thinks it is the primary because that was its role when it crashed and it does not know about the takeover by force command that was issued. Does the 01 server check the 02 server to see what role they are in...
0
505
by: Marc | last post by:
Hi, I'm working with a customer that is trying to find a solution to provide geographical redundancy. Our application is currently using IBM DB2 v8.2. I have a couple of questions with regards to HADR: 1. DB2 HADR (Can it be used to support geographical redundancy in a nested fashion (ie. Synchronous HADR at a site, and ASYNCRONOUS between sites using the same instances/databases). If so how
4
4649
by: Joachim Klassen | last post by:
DB2 V8.2 FP10 on Windows I tested the following HADR scenario: - a new tablespace on a new filesytem is created on the primary System - the replay on standby fails because of lacking permissions - the tablespace is backed up on the primary system - tables are created in the new tablespace and data is inserted (and a couple of logs are archived) - Takeover is done by the standby
16
21804
by: gumby | last post by:
I'm having trouble getting HADR to work with the sample databases on two HS20 xSeries blades, Red Hat ES4 up3, DB2 8.2.4, getting the following error. SQL1768N Unable to start HADR. Reason code = "7" - The primary database failed to establish a connection to its standby database within the HADR timeout interval. What things should I check besides the remote host and remote service parameters on the standby database, which seem to be...
8
23477
by: Challenge | last post by:
Hi, I got error, SQL1768N Unable to start HADR. Reason code = "7", when I tried to start hadr primary database. Here are the hadr configuration of my primary db: HADR database role = STANDARD HADR local host name (HADR_LOCAL_HOST) = testserver HADR local service name (HADR_LOCAL_SVC) = 56000 HADR remote host name (HADR_REMOTE_HOST) = testserver
0
2441
by: deshaipet | last post by:
Hi - We have primary and standby databases on different servers. Here is my /etc/service entry for HADR pair : On Primary : "vi /etc/services
0
4049
DB2 Warlord
by: DB2 Warlord | last post by:
After countless time I was unabl to find the answer to my HADR questions and getting HADR to work in 9.5 via the Control Center. Please see my fix that seem strange but works. My error was as follows. When setting up HADR via the CCenter at the last step in a full setup called "START HADR" it would fail with reason 7. Now trying to solve the port issue that is listed gets you no where. In fact on my db2diag.log it listed a comm error. ...
0
9464
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can effortlessly switch the default language on Windows 10 without reinstalling. I'll walk you through it. First, let's disable language synchronization. With a Microsoft account, language settings sync across devices. To prevent any complications,...
0
10122
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven tapestry of website design and digital marketing. It's not merely about having a website; it's about crafting an immersive digital experience that captivates audiences and drives business growth. The Art of Business Website Design Your website is...
1
10061
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For most users, this new feature is actually very convenient. If you want to control the update process,...
1
7471
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules. He will explain when you may want to use classes instead of User Defined Types (UDT). For example, to manage the data in unbound forms. Adolph will...
0
5368
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The last exercise I practiced was to create a LAN-to-LAN VPN between two Pfsense firewalls, by using IPSEC protocols. I succeeded, with both firewalls in the same network. But I'm wondering if it's possible to do the same thing, with 2 Pfsense firewalls...
0
5497
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
1
4031
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated we have to send another system
2
3627
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.
3
2860
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence can significantly impact your brand's success. BSMN Consultancy, a leader in Website Development in Toronto offers valuable insights into creating effective websites that not only look great but also perform exceptionally well. In this comprehensive...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.