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 / March 2008

Tip: Looking for answers? Try searching our database.

move a tablespace (sms containers) to different location

Thread view: 
Enable EMail Alerts  Start New Thread
Thread rating: 
stefan.albert - 18 Mar 2008 10:26 GMT
Hi folks,
we have 3 instances where a table space (good old SMS) lives in the
wrong directory.
Normally I simply would create a new one and do a INSERT ... SELECT
for all tables (or a load ... from cursor). But we have different
tables in the table space and I want to use the same "script" for all
instances.
So I had a look at db2relocate, which should do the trick. I have the
following plan to do this:
0) backup -- always good
1) quiesce tablespace for table ONE.OF_THEM exclusive
2) cp -p OLD_CONT_DIRs NEW_CONT_DIRs
3) rename OLD_CONT_DIRs
4) db2relocate -f reloc.cfg
5) quiesce tablespace for table ONE.OF_THEM reset

Does anybody have any experience with this? Or any further
suggestions?
Thanks in advance,
Stefan
stefan.albert - 25 Mar 2008 18:25 GMT
> Hi folks,
> we have 3 instances where a table space (good old SMS) lives in the
[quoted text clipped - 16 lines]
> Thanks in advance,
> Stefan

Here my results :

Step 2) failed - because DB2 holds a lock on the files.
Step 1) db2stop (force)
Step 5) db2start

The file reloc.cfg defines the old and new locations.

It worked fine for me.
 
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.