Home | Contact Us | FAQ | Search & Site Map | Link to Us
Sign In | Join | Other 45 Sites in Network
Home
Discussion Groups
Database Servers
DB2InformixIngresMS SQLOraclePervasive.SQLPostgreSQLProgressSybase
Desktop Databases
FileMakerFoxProMS AccessParadox
General
General DB TopicsDatabase Theory
Related Topics
Java Development.NET DevelopmentVB DevelopmentMore Topics ...

Database Forum / DB2 Topics / December 2006

Tip: Looking for answers? Try searching our database.

Rollforward to a particular log

Thread view: 
Enable EMail Alerts  Start New Thread
Thread rating: 
EC - 22 Dec 2006 17:45 GMT
We have two DB2 servers are supposed to be a replicate of each other
with a database of the same name.  I want to do a 'db2 db backup
online... include logs' on the first server, and do a 'db2 restore db
to ... logtarget...' on the second server, and then rollforward ONLY
those logs that were included in the backup image.  Both databases may
have the same DB id because of previous restores.  However, the second
server might have additional transaction logs since the time of the
backup was taken in the first server.  How do I make sure the
restore/rollforward to only rollforward the logs that were included in
the first backup image?  Will "rollforward...to end of logs..." try to
rollforward the addtional transaction logs?
Thx...Eddie
Pierre Saint-Jacques - 23 Dec 2006 02:47 GMT
What you'll need to do on the receiving server:
Deactivate the db
Move and delete all the log files in that db's current log path to anoher
path.
When path is empty,
Restore your source image on the target and specify, in the command, that
the logs in the image are to go to: current logpath of the receiving db.

Roll the restored image to the end of the logs and stop.
This will give you, on the target, a db that is at the same point of
consistency that the image you took from the source.

Please note that from now on the receiving db will have its own log chain
and it will "not" be compatible with the existing one that was there before
the you moved and deleted the logs.

I'd highly recommend for you to take a backup of the receiving db and store
it with the logs you moved in order to come back to there if you ever need
to.

Regards,  Pierre.

Signature

Pierre Saint-Jacques
SES Consultants Inc.
514-737-4515

> We have two DB2 servers are supposed to be a replicate of each other
> with a database of the same name.  I want to do a 'db2 db backup
[quoted text clipped - 8 lines]
> rollforward the addtional transaction logs?
> Thx...Eddie
EC - 23 Dec 2006 15:48 GMT
Thanks, Pierre.  How about rollforward to the 'End time' timestamp of
the db backup? Would that ensure me that only the logs included in the
backup would be use? Or would this may potentially rollforward other
logs as well?  Thx.
> What you'll need to do on the receiving server:
> Deactivate the db
[quoted text clipped - 34 lines]
> > rollforward the addtional transaction logs?
> > Thx...Eddie
Pierre Saint-Jacques - 23 Dec 2006 19:46 GMT
If you deactivated the source db before the backup then rolling forward to
end of logs is the end of the backup time stamp .

If the backup was taken online, then the end of backup timestamp will be in
the history file of that db and you need to roll forward to at leas tha
timestamp.
Note that INCLUDE logs option in the backup will force the current log at
end of backup to be clodsed at that timestamp and that will force that
shortened log to be copied to the backup image target and again you'll have
the logs required. In that case, put only the logs up to and including that
last one shortened one and you'll be fine.
Regards,  Pierre.

Signature

Pierre Saint-Jacques
SES Consultants Inc.
514-737-4515

Thanks, Pierre.  How about rollforward to the 'End time' timestamp of
the db backup? Would that ensure me that only the logs included in the
backup would be use? Or would this may potentially rollforward other
logs as well?  Thx.
Pierre Saint-Jacques wrote:
> What you'll need to do on the receiving server:
> Deactivate the db
[quoted text clipped - 38 lines]
> > rollforward the addtional transaction logs?
> > Thx...Eddie
 
Sign In
Join
My Latest Posts
My Monitored Threads
My Blog
My Photo Gallery
My Profile
My Homepage

Start New Thread
Enable EMail Alerts
Rate this Thread



©2008 Advenet LLC   Privacy Policy - Terms of Use
This website includes both content owned or controlled by Advenet as well as content owned or controlled by third parties.