4. check if directory is changed by command "list database directory"
5. check if container path is changed by command "select * from sysibmadm.dbpaths"
5. restart db2
6. activate test database
Step 1-4 works well as I expected. The Local database directory is shown as E:\TEST.
But the result of step 5 shows everything (db_storage_path, containers, local_db_directory, dbpath) is still at the old path, which I could not understand. After step 5, I found out that I cannot activate or connect to my database anymore. So I have to change the db_path back to D:\TEST and can connect to my database again.
Can anyone please help me where did I go wrong? How should this be done? Many many thanks!!
PS: I am using windows 2008 server, DB2 Enterprise Edition 9.7 Fixpack 8. In my database there are tablespaces with and without automatic storage.
Specifies a change in the location of table space containers. Both the old and new container path must be specified. Multiple CONT_PATH lines can be provided if there are multiple container path changes to be made. This specification is optional if the container paths reside under the database path, in which case the paths are updated automatically. If you are making changes to more than one container where the same old path is being replaced by a common new path, a single CONT_PATH entry can be used. In such a case, an asterisk (*) could be used both in the old and new paths as a wildcard.
All my tablespaces are under D:\test\, so I think the CONT_PATH should update automatically.
I think restore a db from backup is more difficult than just copy the content and relocate the database? E.g. as state in that article, stored procedures have to move separately since they are not included in the backup image.