473,473 Members | 1,477 Online
Bytes | Software Development & Data Engineering Community
Create Post

Home Posts Topics Members FAQ

DB2 HADR state for DB2 v9.1

Hi folks,

Anyone knows what do these mean?

Primary log position(file, page, LSN) = S0000009.LOG, 0,
00000000036B0000
Standby log position(file, page, LSN) = S0000008.LOG, 357,
000000000342D073
Log gap running average(bytes) = 2633608

Is HADR state real peer when the HADR state is peer but the above
primary/standby log position are not the same? May I takeover the HADR
at that time, or shall wait the primary/standby log position are the
same?
Thanks in advance~

Jan 11 '07 #1
3 3777

Laurence wrote:
Hi folks,

Anyone knows what do these mean?

Primary log position(file, page, LSN) = S0000009.LOG, 0,
00000000036B0000
Standby log position(file, page, LSN) = S0000008.LOG, 357,
000000000342D073
Log gap running average(bytes) = 2633608

Is HADR state real peer when the HADR state is peer but the above
primary/standby log position are not the same? May I takeover the HADR
at that time, or shall wait the primary/standby log position are the
same?
Thanks in advance~
I always see this log mis-match when I do an online backup, and no
subsequent changes to the database have occured since the backup. I
include the logs with the backup, but I don't know if that is reason
for the mis-match. If you were to do an insert, update, or delete, I
think you would see them in synch right after that.

I have never tried to do a takeover in that state, but I assume it
would not be a problem.

Jan 11 '07 #2
Whenever DB2 "truncates" a log file, there may be a relatively large
apparent log gap shown for this HADR snapshot monitor element. This is
mentioned in HADR documentation, for example here:
http://publib.boulder.ibm.com/infoce...c/r0011478.htm

What happens is that DB2 effectively jumps over a range of unused LSNs
(log sequence numbers), which fools HADR into thinking the distance
between the primary and standby is greater than it really is. The
extra gap vanishes once the standby moves to the next log file; that
occurs once there is some operation on the primary subsequent to the
operation that cause the log file truncation. Online backup is a
typical "culprit"; the ARCHIVE LOG command also has this effect. The
artificial log gap may trigger a related health monitor alert as well.

We anticipate making some changes in a future release to help with log
gap accuracy in the presence of a truncated log file.

Regards,
- Steve P.
--
Steve Pearson, IBM DB2 for Linux, UNIX, and Windows, IBM Software Group
DB2 "Portland" Development Team, IBM Beaverton Lab, Beaverton, OR, USA

Jan 16 '07 #3
Anyone knows what do these mean?
See other posts.
Is HADR state real peer when the HADR state is peer but the above
primary/standby log position are not the same? May I takeover the HADR
at that time, or shall wait the primary/standby log position are the
same?
The difference in log position (LSN) and apparent log gap do not affect
the HADR state nor the HADR takeover semantics. If you are running in
SYNC or NEARSYNC mode, then the standby should be able to fail over
with no transaction loss assuming the usual fine print (e.g., in
NEARSYNC, the standby didn't also fail). If you are running in ASYNC
mode, it is possible that there is some real lag between the primary
and standby in addition to the artificial lag described in my other
post. More often someone performed an online backup while things were
otherwise idle on the primary, resulting in the primary log position
being the LSN of the start of log file N+1 while the standby log
position is the LSN of the end of log file N, in which case all log
records of file N already made it to the standby.

Regards,
- Steve P.
--
Steve Pearson, IBM DB2 for Linux, UNIX, and Windows, IBM Software Group
DB2 "Portland" Development Team, IBM Beaverton Lab, Beaverton, OR, USA

Jan 16 '07 #4

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

Similar topics

2
by: bwmiller16 | last post by:
Folks - OpSys: RH Linux, AS3 DB: UDB 8.2.0 (FP7 Stinger) HW: 2 X-series We setup a HADR pair and they went into PEER state (after we backed-up the DB on primary and restored the DB on the...
7
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...
4
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...
16
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...
3
by: Joachim Klassen | last post by:
Hi all, if I accidentally use a TAKEOVER command with BY FORCE clause while primary and standby are in peer state I'll end up with two primary's (at least with FP10 and Windows). Is this works ...
6
by: shorti | last post by:
db2 8.1 fix pack 12 on AIX 5.3 This is a newly configured HADR machine. The HADR was up and running. I was 'playing' around some on the standby and did a db2 deactivate and things sort of went...
6
by: shorti | last post by:
I have two questions about HADR recovery. I am running db2 v8 fp12. 1) If the primary suddenly crashes would you always want to switch the standby to the primary by force...or would there be...
2
by: paul | last post by:
Hi, I have two databases in hadr, this morning i issued a "takeover ... by force" because the normal takeover didn't worked. Now i have two standard databases, and if i try to put the old primary...
2
by: agentlease | last post by:
Hi, If the HADR state is 'Disconnected' and commit transactions to the Primary database, in the event of a Failover to the Standby database, how do we determine if it is safe i.e. how do we know...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
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...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...
0
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...
1
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...
0
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and...
0
muto222
php
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.

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.