If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below.

 
Go Back  dBforums > Database Server Software > DB2 > Question about restore

Reply
 
LinkBack Thread Tools Display Modes
  #1 (permalink)  
Old 03-15-10, 09:16
mtangshan mtangshan is offline
Registered User
 
Join Date: Feb 2009
Posts: 8
Question about restore

I have a question about db2 restore.

At time point such as 3:00, I had full database backup.
> db2 backup db sample to .
I got a backup image 2010031022000000000

Then I inserted some data into tables test at 3:15
> db2 "insert into test values (1,2)";

Later I inserted some data into tables test at 4:15.

Can i restore db2 to the time point 3:15, if I set db cfg logratain on?

Reply With Quote
  #2 (permalink)  
Old 03-15-10, 09:32
Mathew_paul Mathew_paul is offline
Registered User
 
Join Date: Oct 2007
Posts: 200
u try this
db2 rollforward db dbname to 2010-02-01-03.15.00.000000 using local time

redgs
paul
Reply With Quote
  #3 (permalink)  
Old 03-15-10, 09:33
ARWinner ARWinner is offline
Registered User
 
Join Date: Jan 2003
Posts: 3,473
If you have the logs, you can restore to any point in time that you have in the logs. The only way to insure that you will have the logs is to use log retain or log archiving.

Andy
Reply With Quote
  #4 (permalink)  
Old 03-15-10, 10:45
Cougar8000 Cougar8000 is offline
Registered User
 
Join Date: Nov 2005
Location: IL
Posts: 552
Quote:
Originally Posted by Mathew_paul View Post
u try this
db2 rollforward db dbname to 2010-02-01-03.15.00.000000 using local time

redgs
paul

That is mean
__________________
--
IBM Certified DBA on DB2 for Linux, UNIX, and Windows

DB2 v9.1.0.2 os 5.3.0.0
Reply With Quote
Reply

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On