SQL/MP Installation and Management Guide

Moving a Database
HP NonStop SQL/MP Installation and Management Guide523353-004
9-12
Moving the System Catalog
To enable SQLCI to use the licensed SQLCI2 version rather than the normal
SQLCI2 version, you must create the =_SQL_CI2_sys DEFINE pointing to the
licensed version. This command performs this operation:
38> ADD DEFINE =_SQL_CI2_sys, CLASS MAP,
FILE $SYSTEM.SYSTEM.SQLCI2L
In the ADD DEFINE command, sys is the node (system) name without the
backslash.
6. After setting up the licensed SQLCI2L process, delete the catalog entries from the
CATALOGS table (except for the system catalog entry). The CATALOGS table
must be empty before you can drop the existing system catalog; therefore, you
must delete any references to user catalogs without affecting the dependent SQL
catalogs and objects. Enter this statement using the licensed SQLCI2L process to
delete the rows:
>> DELETE FROM catalogs-vol.SQL.CATALOGS
+> WHERE CATALOGCLASS <> "S";
In the DELETE statement, catalogs-vol is the volume on which your
CATALOGS table resides. The subvolume is always SQL.
7. Save a copy of the SQLCI2 program because the DROP SYSTEM CATALOG
command also drops SQLCI2. Enter this FUP DUP command to save a copy of
SQLCI2:
>> VOLUME $SYSTEM.SYSTEM;
>> FUP DUP SQLCI2, ZZSQLCI2, SAVEALL;
8. If you have SQL compiled the licensed SQLCI2L program into your system catalog
to perform Step 5 on page 9-11, drop the program so that the system catalog is
empty. If you are still using the licensed SQLCI2L program from Step 5 on page
9-11, exit from SQLCI and delete the DEFINE. These commands accomplish this
operation:
>> EXIT;
24> DELETE DEFINE =_SQL_CI2_sys
25> SQLCI
>> DROP PROGRAM $SYSTEM.SYSTEM.SQLCI2L;
In the DELETE DEFINE command, sys is the node (system) name without the
backslash.
9. Drop the old system catalog and create the new one in its new location. The
system catalog should be empty, but you can query the catalog to verify that all
references are dropped, except the tables themselves, including the CATALOGS
table.
To drop the system catalog, you must use the DROP SYSTEM CATALOG
command. If you are not running SQLCI, you can drop the catalog from SQLCI by
entering these commands:
>> DROP SYSTEM CATALOG sys-catalog;