473,796 Members | 2,728 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

standby db on windows

got: DB2 v8.2 ESE
WinXP in machine A
Windows Server 2003 in machine B

I have a db server on machine 'A' and I want to create a standby db on
machine 'B' via log shipping.

standby db on B was created with a backup online imagine and then
restore it and rollforward it to end of logs but NOT complete so I can
apply the logs from A.

1)I maded a full online backup that include logs

*db2 => backup database bd online to c:\backups include logs
Backup successful. The timestamp for this backup image is :
20050414113540

2)Copy the image to machine 'B'

*C:\WINDOWS>net use z: \\192.168.0.83\ c
Se ha completado el comando correctamente.
*C:\WINDOWS>XCO PY C:\BACKUPS\BD.0 Z:\BACKUPS\BD.0 \*.* /S /E
C:\BACKUPS\BD.0 \DB2\NODE0000\C ATN0000\2005041 4\113540.001
1 archivos copiados

3)Restore the backup image on 'B'
*db2 => RESTORE DATABASE BD FROM C:\BACKUPS TO C: INTO BD
DB20000I The RESTORE DATABASE command completed successfully.

4)See if in state is the db
*db2 => rollforward database bd query status

Rollforward Status

Input database alias = bd
Number of nodes have returned status = 1

Node number = 0
Rollforward status = DB pending
Next log file to be read = S0018130.LOG
Log files processed = -
Last committed transaction = 2004-10-28-08.38.49.000000

5)Perfert now, it is supose that I can send daily copies of the A's
logs to B
*C:\WINDOWS>XCO PY C:\DB2\NODE0000 \SQL00003\SQLOG DIR\*.*
z:\DB2\NODE0000 \SQL00001\
SQLOGDIR\*.* /S /E
C:\DB2\NODE0000 \SQL00003\SQLOG DIR\S0018111.LO G
C:\DB2\NODE0000 \SQL00003\SQLOG DIR\S0018112.LO G
C:\DB2\NODE0000 \SQL00003\SQLOG DIR\S0018113.LO G
C:\DB2\NODE0000 \SQL00003\SQLOG DIR\S0018114.LO G
C:\DB2\NODE0000 \SQL00003\SQLOG DIR\S0018115.LO G
C:\DB2\NODE0000 \SQL00003\SQLOG DIR\S0018116.LO G
C:\DB2\NODE0000 \SQL00003\SQLOG DIR\S0018117.LO G
C:\DB2\NODE0000 \SQL00003\SQLOG DIR\S0018118.LO G
C:\DB2\NODE0000 \SQL00003\SQLOG DIR\S0018119.LO G
C:\DB2\NODE0000 \SQL00003\SQLOG DIR\S0018120.LO G
C:\DB2\NODE0000 \SQL00003\SQLOG DIR\S0018121.LO G
C:\DB2\NODE0000 \SQL00003\SQLOG DIR\S0018122.LO G
C:\DB2\NODE0000 \SQL00003\SQLOG DIR\S0018123.LO G
C:\DB2\NODE0000 \SQL00003\SQLOG DIR\S0018124.LO G
C:\DB2\NODE0000 \SQL00003\SQLOG DIR\S0018125.LO G
C:\DB2\NODE0000 \SQL00003\SQLOG DIR\S0018126.LO G
C:\DB2\NODE0000 \SQL00003\SQLOG DIR\S0018127.LO G
C:\DB2\NODE0000 \SQL00003\SQLOG DIR\S0018128.LO G
C:\DB2\NODE0000 \SQL00003\SQLOG DIR\S0018129.LO G
C:\DB2\NODE0000 \SQL00003\SQLOG DIR\S0018130.LO G
C:\DB2\NODE0000 \SQL00003\SQLOG DIR\S0018131.LO G
C:\DB2\NODE0000 \SQL00003\SQLOG DIR\S0018132.LO G
C:\DB2\NODE0000 \SQL00003\SQLOG DIR\S0018133.LO G
23 archivos copiados

6)Apply new logs to B
*db2 => rollforward database bd to end of logs

Rollforward Status

Input database alias = bd
Number of nodes have returned status = 1

Node number = 0
Rollforward status = DB working
Next log file to be read = S0018132.LOG
Log files processed = S0018130.LOG - S0018131.LOG
Last committed transaction = 2005-04-14-11.33.27.000000

7)Maded some changes to the db on 'A' so copy again the logs to B
*C:\WINDOWS>XCO PY C:\DB2\NODE0000 \SQL00003\SQLOG DIR\*.*
z:\DB2\NODE0000 \SQL00001\
SQLOGDIR\*.* /S /E /Y
C:\DB2\NODE0000 \SQL00003\SQLOG DIR\S0018111.LO G
C:\DB2\NODE0000 \SQL00003\SQLOG DIR\S0018112.LO G
C:\DB2\NODE0000 \SQL00003\SQLOG DIR\S0018113.LO G
C:\DB2\NODE0000 \SQL00003\SQLOG DIR\S0018114.LO G
C:\DB2\NODE0000 \SQL00003\SQLOG DIR\S0018115.LO G
C:\DB2\NODE0000 \SQL00003\SQLOG DIR\S0018116.LO G
C:\DB2\NODE0000 \SQL00003\SQLOG DIR\S0018117.LO G
C:\DB2\NODE0000 \SQL00003\SQLOG DIR\S0018118.LO G
C:\DB2\NODE0000 \SQL00003\SQLOG DIR\S0018119.LO G
C:\DB2\NODE0000 \SQL00003\SQLOG DIR\S0018120.LO G
C:\DB2\NODE0000 \SQL00003\SQLOG DIR\S0018121.LO G
C:\DB2\NODE0000 \SQL00003\SQLOG DIR\S0018122.LO G
C:\DB2\NODE0000 \SQL00003\SQLOG DIR\S0018123.LO G
C:\DB2\NODE0000 \SQL00003\SQLOG DIR\S0018124.LO G
C:\DB2\NODE0000 \SQL00003\SQLOG DIR\S0018125.LO G
C:\DB2\NODE0000 \SQL00003\SQLOG DIR\S0018126.LO G
C:\DB2\NODE0000 \SQL00003\SQLOG DIR\S0018127.LO G
C:\DB2\NODE0000 \SQL00003\SQLOG DIR\S0018128.LO G
C:\DB2\NODE0000 \SQL00003\SQLOG DIR\S0018129.LO G
C:\DB2\NODE0000 \SQL00003\SQLOG DIR\S0018130.LO G
C:\DB2\NODE0000 \SQL00003\SQLOG DIR\S0018131.LO G
C:\DB2\NODE0000 \SQL00003\SQLOG DIR\S0018132.LO G
C:\DB2\NODE0000 \SQL00003\SQLOG DIR\S0018133.LO G
C:\DB2\NODE0000 \SQL00003\SQLOG DIR\S0018134.LO G
24 archivos copiados

8)Apply the logs on B
db2 => rollforward database bd to end of logs

Rollforward Status

Input database alias = bd
Number of nodes have returned status = 1

Node number = 0
Rollforward status = DB working
Next log file to be read = S0018132.LOG
Log files processed = S0018130.LOG - S0018131.LOG
Last committed transaction = 2005-04-14-11.44.02.000000

DB20000I The ROLLFORWARD command completed successfully.

9)Aparentely everything when well,is this a correct way to do a
standby?
10)Can I copy A's logs once the B is rollforward to complete? (back to
pending state)
11)Where I can find stuff about DB2 configurations files? Because to
find where the logs are and tablespace are is kind of magic!!

Many Thanks
Nov 12 '05 #1
7 2666
Juan,

Are you aware of HADR? Espcially since I'm reasonably sure that its'
part of the ESE licence. So you seem to be re-inventing the weheel here.
http://publib.boulder.ibm.com/infoce...n/c0011267.htm

Cheers
Serge

--
Serge Rielau
DB2 SQL Compiler Development
IBM Toronto Lab
Nov 12 '05 #2
Hi,
Are you aware of HADR? Espcially since I'm reasonably sure that its'
part of the ESE licence. So you seem to be re-inventing the weheel here.


yep, it is, and it's working perfectly for me on two W2K3 boxes.

But it needs identical systems and I don't know if Juan's setup with
W2K3 and XP would work (and I'm close to sure that it's unsupported).

Regards,
Bernd
Nov 12 '05 #3
Bernd Giegerich wrote:
Hi,
Are you aware of HADR? Espcially since I'm reasonably sure that its'
part of the ESE licence. So you seem to be re-inventing the weheel here.

yep, it is, and it's working perfectly for me on two W2K3 boxes.

But it needs identical systems and I don't know if Juan's setup with
W2K3 and XP would work (and I'm close to sure that it's unsupported).

Regards,
Bernd

Didn't catch that in the original post. FWIW I wouldn't see why HADR
woudl not work. One of the good things about HADR is that you can do
upgrades on one system at a time. I'd expect no problems within the
Windows family, but formal support is a different issue....

--
Serge Rielau
DB2 SQL Compiler Development
IBM Toronto Lab
Nov 12 '05 #4
Hi,
FWIW I wouldn't see why HADR woudl not work.
I don't know, if DB2 checks for OS versions or such things during the
HADR initialisation - I never tried to set it up with different
operating systems on primary and standby...
One of the good things about HADR is that you can do
upgrades on one system at a time. I'd expect no problems within the
Windows family, but formal support is a different issue....


yep, even different patch levels are only supported for the short time
of rolling upgrades, according to the documentation.

Regards,
Bernd
Nov 12 '05 #5
I mess up typing the db2 version. I got Workgroup unlimited Edition
(WUE)and that one doesn't have HADR.

I also read about HADR, and sound pretty good solution, but
unfortunatelly the project doesn't have any budget.

I know are many ways of upgrading logs to the standby, last thing I
tryed was this:

db2 => RESTORE DATABASE BD FROM C:\BACKUPS
DB20000I The RESTORE DATABASE command completed successfully.

--archive log for datbase BD on machine A

db2 => ROLLFORWARD DB BD TO END OF LOGS

Rollforward Status

Input database alias = BD
Number of nodes have returned status = 1

Node number = 0
Rollforward status = DB working
Next log file to be read = S0018146.LOG
Log files processed = -
Last committed transaction = 2005-04-15-08.32.05.000000

DB20000I The ROLLFORWARD command completed successfully.

--Made some change on db B and also call archive log command

db2 => ROLLFORWARD DB BD TO END OF LOGS
SQL1265N The archive log file "S0018147.L OG" is not associated with
the
current log sequence for database "BD" on node "0".

Any sugestions or manuals to do a stuff like this?

Thanks
Nov 12 '05 #6

HADR is available with your version of DB2 as an add-on license. That
should be more economical than an upgrade to ESE. However, I did
notice you said you have "no budget" so I understand this may not be an
available option. Don't forget however that while you have "no budget"
you may still spend more implementing a less manageable solution due to
your time investment and other hidden costs.

Here is one reference that may be helpful for planning and implementing
a hand-rolled log shipping solution:

http://www-106.ibm.com/developerwork...04mcinnis.html

Btw, I found that with a Google query. It was the top hit with default
search on "db2 log shipping disaster recovery". IBM has arranged for
much DB2 documentation to be searchable via Google; don't forget to
take advantage of this when you don't know where to look.

There is also some discussion (but looks like it might be briefer than
the above) in Chapter 5 of the DB2 Data Recovery and High Availability
Guide and Reference. Since the V8.2 one was revised to focus more on
HADR in this area, there is probably more on the hand-rolled approach
in an earlier version, such as that for V8.1:

ftp://ftp.software.ibm.com/ps/produc...r/db2hae80.pdf

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

Nov 12 '05 #7
Thanks Steve, I'll write the stuff to have a better idea, and then try
to make them work!

If I have any problem, I'll post again.

Regards

Juan
Nov 12 '05 #8

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

Similar topics

0
3926
by: Cherrish Vaidiyan | last post by:
hello, Thanx for the suggestions on my Listener query. Now i am performing a simple work.. STANDBY DATABASE creation. I have followed the instraction from Oracle 9i Release 1 documentation but have some doubts. here are the basic stpes i followed. 1 Either make a new backup of the primary database datafiles or access
0
3341
by: Cherrish Vaidiyan | last post by:
sir, The following are the steps that i followed in setting up standby database on Red hat Linux 9. i am using Oracle 9i. i have followed the steps in this site : http://download-west.oracle.com/docs/cd/B10501_01/server.920/a96653/create_ps.htm#66206 Still i give the steps i followed. Preparing the Primary Database for Standby Database Creation
5
1980
by: Phyxius | last post by:
I just had a new computer built. My previous computer was also a custom and I was using Windows XP home. I purchased a new XP Home edition from Microsoft and installed it into the new computer-not an upgrade, then transferred the necessary data from my old hardrive to my new one. All drivers are the same and are all the latest updates. With my previous computer I was able to utilize both Standby and Hibernate modes. I now can't access...
6
21974
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 down hill from there. Though the Standby machine seemed to know it was a standby it would not connect to the primary. I could not even do a db2 get snapshot to view the hadr status on the machine. I was wanting to do a few HADR tests before I...
2
5196
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 database in standby mode i can't but it's not in rollforward pending state. How can i put this database in rollffoward pending state without backup/restore from the new primary dabatase ?
4
4205
by: Mark A | last post by:
I would like to make a split mirror copy of a HADR standby database. Please note that I do not want to create a standby with a split mirror of the primary, but I want to make a split mirror of the standby (for a reporting database). I know that I cannot do a write suspend on the standby because it does not allow any connections. But what if I just did a split mirror of the standby, do a db2inidb, then ship the logs over to the split...
6
2273
by: JT | last post by:
Hi, I've realized that my good fortune of not having my computer go into standby mode was the result of my application accessing a file on a shared network drive. Not going into standby is a very good thing for my application, but I don't want users to be required to share a drive and file just to accomplish this. I've read in old posts in various places stating that by importing kernel32.dll I could access a function called
7
3510
by: Volkan Senguel | last post by:
Hi i'm searching a solution to avoid that the user can go in the standby mode while a app is runing. i have searched and readed a lot in the web and have not found a working solution... for the moment i use "away mode" under vista to get simiar results but with other handycaps like screen off etc. :-( i have get this code from a other dev but it doesnt work with vista, the pc
0
1203
by: questionit | last post by:
Hi My Windows XP does not go on complete standby even though it has been set to go to standby in Power Options. Only the HDD goes on to standby and the monitor but the rest of the peripherals (including processor) does not go on standby. Anyone has an idea what the problem is? Qi
0
10467
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, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed. This is as boiled down as I can make it. Here is my compilation command: g++-12 -std=c++20 -Wnarrowing bit_field.cpp Here is the code in...
0
10244
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
10201
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,...
0
10021
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 protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the choice of these technologies. I'm particularly interested in Zigbee because I've heard it does some...
0
9061
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, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then launch it, all on its own.... Now, this would greatly impact the work of software developers. The idea...
0
5454
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...
1
4130
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
3744
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.
3
2931
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.