This is a discussion on system directory and local directory doesn't match for a DB within the DB2 forums, part of the Database Server Software category; --> Dear Group, I recently installed DB2 and created an db "TOOLSDB" for the tools catalog. during installation, the DB ...
| |||||||
| Register | FAQ | Members List | Calendar | Search | Today's Posts | Mark Forums Read |
| ||||
| Dear Group, I recently installed DB2 and created an db "TOOLSDB" for the tools catalog. during installation, the DB was created at the default location. But I moved the DB to another location using "db2relocatedb". Somehow I messed up during the relocate and undid the relocate. Now, I have the following situation. I can do certain tasks on the DB. but when I try to create a tools catalog on the toolsdb, I get the following error message. % db2 create tools catalog toolscat USE EXISTING database toolsdb SQL1031N The database directory cannot be found on the indicated file system. SQLSTATE=58031 Note: I probably can drop and recreate the DB. But I want to try other alternatives first. % db2 list db directory System Database Directory Number of entries in the directory = 2 Database 1 entry: Database alias = TOOLSDB Database name = TOOLSDB Local database directory = /db2home/db2inst1 Database release level = a.00 Comment = Cataloged by db2relocatedb Directory entry type = Indirect Catalog database partition number = 0 Database 2 entry: .... % db2 list db directory on path /db2home/db2inst1 Database 1 entry: Database alias = TOOLSDB Database name = TOOLSDB Database directory = SQL00001 Database release level = a.00 Comment = Directory entry type = Home Catalog database partition number = 0 Database partition number = 0 |
| |||
| I'd try to uncatalog the TOOLSDB first. I think DB2 is confused at the system and local database directories. Uncatalog, catalog should fix it. Then catalog the TOOLSDB on the path indicated. Then try to create it again. Worse comes to worst, uncatalog, catalog, drop and recreate even if you say you don't want to do this. HTH, Pierre. Prince Kumar wrote: > Dear Group, > > I recently installed DB2 and created an db "TOOLSDB" for the tools > catalog. during installation, the DB was created at the default > location. But I moved the DB to another location using > "db2relocatedb". Somehow I messed up during the relocate and undid the > relocate. > > Now, I have the following situation. > > I can do certain tasks on the DB. but when I try to create a tools > catalog on the toolsdb, I get the following error message. > > % db2 create tools catalog toolscat USE EXISTING database toolsdb > SQL1031N The database directory cannot be found on the indicated file > system. > SQLSTATE=58031 > > Note: I probably can drop and recreate the DB. But I want to try other > alternatives first. > > % db2 list db directory > > System Database Directory > > Number of entries in the directory = 2 > > Database 1 entry: > > Database alias = TOOLSDB > Database name = TOOLSDB > Local database directory = /db2home/db2inst1 > Database release level = a.00 > Comment = Cataloged by db2relocatedb > Directory entry type = Indirect > Catalog database partition number = 0 > > Database 2 entry: > ... > > > % db2 list db directory on path /db2home/db2inst1 > > Database 1 entry: > > Database alias = TOOLSDB > Database name = TOOLSDB > Database directory = SQL00001 > Database release level = a.00 > Comment = > Directory entry type = Home > Catalog database partition number = 0 > Database partition number = 0 -- Pierre Saint-Jacques IBM DB2 Cerified Solutions Expert - Administration SES Consultants Inc. |
| |||
| Thanks for your Response. I tried you suggestion. But for somereason, it is not cataoging the DB, now. $ db2 uncatalog db toolsdb DB20000I The UNCATALOG DATABASE command completed successfully. DB21056W Directory changes may not be effective until the directory cache is refreshed. $ db2 list db directory on /db2home/db2inst1 Local Database Directory on /db2home/db2inst1 Number of entries in the directory = 1 Database 1 entry: Database alias = TOOLSDB Database name = TOOLSDB Database directory = SQL00001 Database release level = a.00 Comment = Directory entry type = Home Catalog database partition number = 0 Database partition number = 0 $ db2 catalog db toolsdb on /db2home/db2inst1 SQL6028N Catalog database failed because database "toolsdb" was not found in the local database directory. $ db2 catalog db toolsdb SQL6028N Catalog database failed because database "toolsdb" was not found in the local database directory. How do I get rid of this db? Thanks, Prince. "P. Saint-Jacques" <sescons@attglobal.net> wrote in message news:<3F834DD1.4080807@attglobal.net>... > I'd try to uncatalog the TOOLSDB first. I think DB2 is confused at the > system and local database directories. Uncatalog, catalog should fix it. > Then catalog the TOOLSDB on the path indicated. > Then try to create it again. > > Worse comes to worst, uncatalog, catalog, drop and recreate even if you > say you don't want to do this. > HTH, Pierre. > > Prince Kumar wrote: > > Dear Group, > > > > I recently installed DB2 and created an db "TOOLSDB" for the tools > > catalog. during installation, the DB was created at the default > > location. But I moved the DB to another location using > > "db2relocatedb". Somehow I messed up during the relocate and undid the > > relocate. > > > > Now, I have the following situation. > > > > I can do certain tasks on the DB. but when I try to create a tools > > catalog on the toolsdb, I get the following error message. > > > > % db2 create tools catalog toolscat USE EXISTING database toolsdb > > SQL1031N The database directory cannot be found on the indicated file > > system. > > SQLSTATE=58031 > > > > Note: I probably can drop and recreate the DB. But I want to try other > > alternatives first. > > > > % db2 list db directory > > > > System Database Directory > > > > Number of entries in the directory = 2 > > > > Database 1 entry: > > > > Database alias = TOOLSDB > > Database name = TOOLSDB > > Local database directory = /db2home/db2inst1 > > Database release level = a.00 > > Comment = Cataloged by db2relocatedb > > Directory entry type = Indirect > > Catalog database partition number = 0 > > > > Database 2 entry: > > ... > > > > > > % db2 list db directory on path /db2home/db2inst1 > > > > Database 1 entry: > > > > Database alias = TOOLSDB > > Database name = TOOLSDB > > Database directory = SQL00001 > > Database release level = a.00 > > Comment = > > Directory entry type = Home > > Catalog database partition number = 0 > > Database partition number = 0 |
| |||
| Hi Prince, Something seems wrong -- and it is not you ;-). I would try "db2 catalog db TOOLSDB". I do not think that will make any difference, but worth a try. If that is not successful, then I would suggest opening a PMR with DB2 Support -- they will likely what to know the exact steps of your aborted/failed db move, and request that you try db2trc'ing the catalog statement. If that does not interest you, to manually clean up the files, that db must be the only "local" db. You can then remove all the files under /db2home/db2inst1/db2inst1/ HTH, Lloyd |
| ||||
| DB21056W Directory changes may not be effective until the directory cache is refreshed. = db2 terminate Try it after your catalog operations. PM "Prince Kumar" <gspk@yahoo.com> a écrit dans le message de news:629275ba.0310081006.33c8c2e5@posting.google.c om... > Thanks for your Response. > > I tried you suggestion. But for somereason, it is not cataoging the DB, now. > > $ db2 uncatalog db toolsdb > DB20000I The UNCATALOG DATABASE command completed successfully. > DB21056W Directory changes may not be effective until the directory cache is > refreshed. > > > $ db2 list db directory on /db2home/db2inst1 > > Local Database Directory on /db2home/db2inst1 > > Number of entries in the directory = 1 > > Database 1 entry: > > Database alias = TOOLSDB > Database name = TOOLSDB > Database directory = SQL00001 > Database release level = a.00 > Comment = > Directory entry type = Home > Catalog database partition number = 0 > Database partition number = 0 > > > $ db2 catalog db toolsdb on /db2home/db2inst1 > SQL6028N Catalog database failed because database "toolsdb" was not found in > the local database directory. > > > $ db2 catalog db toolsdb > SQL6028N Catalog database failed because database "toolsdb" was not found in > the local database directory. > > How do I get rid of this db? > > Thanks, > Prince. > > "P. Saint-Jacques" <sescons@attglobal.net> wrote in message news:<3F834DD1.4080807@attglobal.net>... > > I'd try to uncatalog the TOOLSDB first. I think DB2 is confused at the > > system and local database directories. Uncatalog, catalog should fix it. > > Then catalog the TOOLSDB on the path indicated. > > Then try to create it again. > > > > Worse comes to worst, uncatalog, catalog, drop and recreate even if you > > say you don't want to do this. > > HTH, Pierre. > > > > Prince Kumar wrote: > > > Dear Group, > > > > > > I recently installed DB2 and created an db "TOOLSDB" for the tools > > > catalog. during installation, the DB was created at the default > > > location. But I moved the DB to another location using > > > "db2relocatedb". Somehow I messed up during the relocate and undid the > > > relocate. > > > > > > Now, I have the following situation. > > > > > > I can do certain tasks on the DB. but when I try to create a tools > > > catalog on the toolsdb, I get the following error message. > > > > > > % db2 create tools catalog toolscat USE EXISTING database toolsdb > > > SQL1031N The database directory cannot be found on the indicated file > > > system. > > > SQLSTATE=58031 > > > > > > Note: I probably can drop and recreate the DB. But I want to try other > > > alternatives first. > > > > > > % db2 list db directory > > > > > > System Database Directory > > > > > > Number of entries in the directory = 2 > > > > > > Database 1 entry: > > > > > > Database alias = TOOLSDB > > > Database name = TOOLSDB > > > Local database directory = /db2home/db2inst1 > > > Database release level = a.00 > > > Comment = Cataloged by db2relocatedb > > > Directory entry type = Indirect > > > Catalog database partition number = 0 > > > > > > Database 2 entry: > > > ... > > > > > > > > > % db2 list db directory on path /db2home/db2inst1 > > > > > > Database 1 entry: > > > > > > Database alias = TOOLSDB > > > Database name = TOOLSDB > > > Database directory = SQL00001 > > > Database release level = a.00 > > > Comment = > > > Directory entry type = Home > > > Catalog database partition number = 0 > > > Database partition number = 0 |