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 > Relocating database

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1 (permalink)  
Old 05-10-04, 11:11
dsusendran dsusendran is offline
Registered User
 
Join Date: Apr 2004
Location: Inside Intel
Posts: 165
Thumbs down Relocating database

Hi all,

I am trying to relocate my database from drive d: to e:, using the db2relocatedb command. The configuration file is as below:

relocate.cfg
DB_NAME=TEST,TEST
DB_PATH=D:\DB2,E:\DB2
INSTANCE=DB2,DB2

It says:
DBT1019N Invalid database path specified in the configuration file.

I did create the test database in D drive.

I am running DB2 8.1.5 on Windows 2000 server

Thanks in advance,

Newbie

Last edited by dsusendran; 05-10-04 at 11:13. Reason: additional information
Reply With Quote
  #2 (permalink)  
Old 05-10-04, 11:14
J Petruk J Petruk is offline
Registered User
 
Join Date: Mar 2004
Location: Toronto, ON, Canada
Posts: 513
Quote:
Originally Posted by dsusendran
Hi all,

I am trying to relocate my database from drive d: to e:, using the db2relocatedb command. The configuration file is as below:

relocate.cfg
DB_NAME=TEST,TEST
DB_PATH=D:\DB2,E:\DB2
INSTANCE=DB2,DB2

It says:
DBT1019N Invalid database path specified in the configuration file.

I am running DB2 8.1.5 on Windows 2000 server

Thanks in advance,

Newbie
Try:
DB_PATH=D:,E:
__________________
--
Jonathan Petruk
DB2 Database Consultant
Reply With Quote
  #3 (permalink)  
Old 05-10-04, 11:41
dsusendran dsusendran is offline
Registered User
 
Join Date: Apr 2004
Location: Inside Intel
Posts: 165
Talking Thanks

Thanks. It worked!
Reply With Quote
  #4 (permalink)  
Old 05-10-04, 17:56
rng rng is offline
Registered User
 
Join Date: Mar 2004
Posts: 6
Moving database from instance to another instance

What would be the config file and copy operation that I would need to do if I want to move a database from one instance to another (created instance).

Using db2relocatedb command..
Reply With Quote
  #5 (permalink)  
Old 05-11-04, 08:36
J Petruk J Petruk is offline
Registered User
 
Join Date: Mar 2004
Location: Toronto, ON, Canada
Posts: 513
Quote:
Originally Posted by rng
What would be the config file and copy operation that I would need to do if I want to move a database from one instance to another (created instance).

Using db2relocatedb command..
INSTANCE=DB2,NEWINST
__________________
--
Jonathan Petruk
DB2 Database Consultant
Reply With Quote
  #6 (permalink)  
Old 05-11-04, 09:39
J Petruk J Petruk is offline
Registered User
 
Join Date: Mar 2004
Location: Toronto, ON, Canada
Posts: 513
Here's the most up-to-date docs I could find...

http://publib.boulder.ibm.com/infoce...e/r0004500.htm
__________________
--
Jonathan Petruk
DB2 Database Consultant
Reply With Quote
  #7 (permalink)  
Old 05-11-04, 13:55
dsusendran dsusendran is offline
Registered User
 
Join Date: Apr 2004
Location: Inside Intel
Posts: 165
Talking Here is the syntax

>>-db2relocatedb---f--configFilename---------------------------><

-f configFilename
Specifies the name of the file containing configuration information necessary for relocating the database. This can be a relative or absolute filename. The format of the configuration file is:
DB_NAME=oldName,newName
DB_PATH=oldPath,newPath
INSTANCE=oldInst,newInst
NODENUM=nodeNumber
LOG_DIR=oldDirPath,newDirPath
CONT_PATH=oldContPath1,newContPath1
CONT_PATH=oldContPath2,newContPath2

Name the configFilename as *.CFG

Cheers,
Newbie
Reply With Quote
  #8 (permalink)  
Old 05-11-04, 18:45
rng rng is offline
Registered User
 
Join Date: Mar 2004
Posts: 6
Db2relocate error

I want to move a database from db2inst4 to db2inst2 instance
Here is my config file:
DB_NAME=NEWTEST
DB_PATH=/home/db2inst4,/home/db2inst2
INSTANCE=db2inst4,db2inst2
NODENUM=0

when a execute the command it give this error message
$ db2relocatedb -f relocate.cfg
DBT1025N Neither old nor new database name were found in the database directory.

This is my list database directory in db2inst2 session:

$ db2 "list database directory"

System Database Directory

Number of entries in the directory = 2

Database 1 entry:

Database alias = TEST
Database name = TEST
Local database directory = /home/db2inst2
Database release level = a.00
Comment =
Directory entry type = Indirect
Catalog database partition number = 0

Database 2 entry:

Database alias = NEWTEST
Database name = NEWTEST
Node name = DB2INST4
Database release level = a.00
Comment =
Directory entry type = Remote
Catalog database partition number = -1

And my list directory in db2inst4 session:

db2inst4 pts/1 May 11 10:13 (172.26.252.14)
$ db2 "list database directory"

System Database Directory

Number of entries in the directory = 3

Database 1 entry:

Database alias = ATEST
Database name = ATEST
Local database directory = /home/db2inst4
Database release level = a.00
Comment =
Directory entry type = Indirect
Catalog database partition number = 0

Database 2 entry:

Database alias = TRAAV
Database name = TRAAV
Local database directory = /home/db2inst4
Database release level = a.00
Database release level = a.00
Comment =
Directory entry type = Indirect
Catalog database partition number = 0

Database 3 entry:

Database alias = NEWTEST
Database name = NEWTEST
Local database directory = /home/db2inst4
Database release level = a.00
Comment =
Directory entry type = Indirect
Catalog database partition number = 0

Any advise is welcome to help to solve this problem.

I am using AIX 5 and DB2 version 8.1

Regards
Reply With Quote
  #9 (permalink)  
Old 05-12-04, 08:24
J Petruk J Petruk is offline
Registered User
 
Join Date: Mar 2004
Location: Toronto, ON, Canada
Posts: 513
Quote:
Originally Posted by rng
I want to move a database from db2inst4 to db2inst2 instance
Here is my config file:
DB_NAME=NEWTEST
DB_PATH=/home/db2inst4,/home/db2inst2
INSTANCE=db2inst4,db2inst2
NODENUM=0

when a execute the command it give this error message
$ db2relocatedb -f relocate.cfg
DBT1025N Neither old nor new database name were found in the database directory.

This is my list database directory in db2inst2 session:

$ db2 "list database directory"

System Database Directory

Number of entries in the directory = 2

Database 1 entry:

Database alias = TEST
Database name = TEST
Local database directory = /home/db2inst2
Database release level = a.00
Comment =
Directory entry type = Indirect
Catalog database partition number = 0

Database 2 entry:

Database alias = NEWTEST
Database name = NEWTEST
Node name = DB2INST4
Database release level = a.00
Comment =
Directory entry type = Remote
Catalog database partition number = -1

And my list directory in db2inst4 session:

db2inst4 pts/1 May 11 10:13 (172.26.252.14)
$ db2 "list database directory"

System Database Directory

Number of entries in the directory = 3

Database 1 entry:

Database alias = ATEST
Database name = ATEST
Local database directory = /home/db2inst4
Database release level = a.00
Comment =
Directory entry type = Indirect
Catalog database partition number = 0

Database 2 entry:

Database alias = TRAAV
Database name = TRAAV
Local database directory = /home/db2inst4
Database release level = a.00
Database release level = a.00
Comment =
Directory entry type = Indirect
Catalog database partition number = 0

Database 3 entry:

Database alias = NEWTEST
Database name = NEWTEST
Local database directory = /home/db2inst4
Database release level = a.00
Comment =
Directory entry type = Indirect
Catalog database partition number = 0

Any advise is welcome to help to solve this problem.

I am using AIX 5 and DB2 version 8.1

Regards
Why is NEWTEST already cataloged in both instances?
__________________
--
Jonathan Petruk
DB2 Database Consultant
Reply With Quote
  #10 (permalink)  
Old 05-12-04, 14:34
rng rng is offline
Registered User
 
Join Date: Mar 2004
Posts: 6
Db2relocatedb

If newtest is not cataloged in instance it would give me error
DBT1025N Neither old nor new database
name were found in the database
directory.
Reply With Quote
  #11 (permalink)  
Old 05-12-04, 15:07
dsusendran dsusendran is offline
Registered User
 
Join Date: Apr 2004
Location: Inside Intel
Posts: 165
Try:

DB_NAME=NEWTEST,NEWTEST
DB_PATH=/home/db2inst4,/home/db2inst2
INSTANCE=db2inst4,db2inst2

You did not specify new database name. Nodenum is optional.

Newbie
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