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 > Having problem restoring database!!!

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1 (permalink)  
Old 02-23-10, 17:57
amira1344 amira1344 is offline
Registered User
 
Join Date: Feb 2010
Posts: 11
Having problem restoring database!!!

Hi,
I am new with DB2 and having problem restoring db. When I try it from Control Centre, I get " SQL2542N No match for a database image file was found based on the source database alias "db..." and timestamp "20100214010004" provided.
I get the same message whether I choose one of the existing images or one of the backup files I have on the folder directory.
If i do it from Command Window, I would get the same error message. can someone help me for this procedure and tell me how do I get the exact time stamp from backup file?

Thanks a lot!!!
Reply With Quote
  #2 (permalink)  
Old 02-23-10, 19:49
db2girl db2girl is offline
∞∞∞∞∞∞
 
Join Date: Aug 2008
Location: Toronto, Canada
Posts: 1,816
Can you see a backup image with this timestamp on disk? Please include dir output and db2 version.

You need to issue the restore command from the root dir (dir where you see <DB_NAME>.0)
Reply With Quote
  #3 (permalink)  
Old 02-24-10, 11:06
amira1344 amira1344 is offline
Registered User
 
Join Date: Feb 2010
Posts: 11
Hi Bella,
Thanks for replying. No I don't see the time stamp however I looked at date/time on windows explorer and manually typed in the command line. What command should I issue to see the time stamp on command window?
I have my db2 installed on C:\ and containers are on D:\ drive. Can you give syntax and step by step in command line?
I also attached the screen shot of directory where my backup file is restored for you to see. Note, I copied file from another location. The folder name is "20100223".

Thanks a lot and appreciated for your help.
Reply With Quote
  #4 (permalink)  
Old 02-24-10, 11:10
amira1344 amira1344 is offline
Registered User
 
Join Date: Feb 2010
Posts: 11
Screenshot

Sorry I forgot to attach.
Here we go...
Attached Thumbnails
Having problem restoring database!!!-db21.gif  
Reply With Quote
  #5 (permalink)  
Old 02-24-10, 12:14
Stealth_DBA Stealth_DBA is offline
Registered User
 
Join Date: May 2009
Posts: 472
amira1344, your attachment shows the problem. In DB2 V8.2 and earlier on Windows, the backup has to be in a very specific set of folders. It is composed of:

DatabaseAlias.Type\InstanceName\NodeNumber\Catalog NodeNumber\yyyymmdd

with the actual backup being: hhmmss.001

Your backup is just in folder

Backups\20100223

You need to create a folder structure like (You will have to supply the Database Alias and Instance name):

DatabaseAlias.0\InstanceName\NODE0000\CATN0000\201 00223

and put your backup, 010004.001 in the last folder.

NOTE 0 is for a Full backup and the NODE0000 and CATN0000 are the normal names for non-partitioned databases.

After this, the DB2 Restore should be able to find it.
Reply With Quote
Reply

Thread Tools Search this Thread
Search this Thread:

Advanced Search
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