If you did not enable partitioning for one or more storable classes when you installed Oracle Communications Billing and Revenue Management (BRM), follow the procedures in this chapter to convert specified nonpartitioned storable classes to partitioned storable classes in the BRM database.
Before partitioning your storable classes, read the following:
If you did not enable partitioning for one or more storable classes when you installed BRM, you can do so after installation.
The partitioning conversion feature splits the table of a specified storable class in the BRM database into the following partitions:
partition_migrate: Holds all objects created before the nonpartitioned storable classes were converted to partitioned storable classes. The BRM purge utility, partition_utils, cannot purge objects in this partition. To purge them, you must develop your own tools based on sound Oracle database management principles.
partition_historic: Holds nonpurgeable events created after the nonpartitioned storable classes were converted to partitioned storable classes. Nonpurgeable events should not be purged from the database. See "Event and Item Objects Stored in partition_historic".
partition_last: A spillover partition that is not intended to store objects you want to purge or preserve. If you do not add purgeable partitions to your tables before BRM resumes generating objects, purgeable objects created after the upgrade are stored in this partition.
Note:For information on how partitioning is enabled when you install BRM, see "Overview of Enabling Partitioning during Installation".
To convert nonpartitioned storable classes to partitioned storable classes, perform these tasks:
Before adding partitions to your tables, increase the disk space allocated for the tables and indexes in your BRM database.
Tip:Oracle recommends that you add enough space for 6 to 12 months of data.
Note:If you already installed the partitioning package, features in that package cannot be reinstalled without first being uninstalled. To reinstall a feature, uninstall it, and then install it again.
To install the partitioning package:
Download the software to a temporary directory (temp_dir).
If you download to a Windows workstation, use FTP to copy the .bin file to a temporary directory on your UNIX server.
You must increase the heap size used by the Java Virtual Machine (JVM) before running the installation program to avoid ”Out of Memory” error messages in the log file. See "Increasing Heap Size to Avoid 'Out of Memory' Error Messages" in BRM Installation Guide.
Make sure no users are logged in to BRM.
Go to the directory where the Third-Party package is installed and source the source.me file.
Caution:You must source the source.me file to proceed with installation. Otherwise, ”suitable JVM not found” and other error messages appear.
Go to temp_dir and run the following command:
where platform is solaris, linux, aix_32, or hpux_ia64.
Note:You can use the -console parameter to run the installation in command-line mode. To use the graphical user interface (GUI) installation, install a GUI application such as X Windows and set the DISPLAY environment variable before you install the software.
Follow the instructions displayed during installation. The default installation directory for the partitioning package is opt/portal/7.5.
Note:The installation program does not prompt you for the installation directory if BRM or the partitioning package is already installed on the machine and automatically installs the package in the directory in which BRM is installed (BRM_Home).
Go to the directory where you installed the partitioning package and source the source.me file:
The partitioning conversion configuration file, partition.cfg, controls the parameters of your conversion. If necessary, change the parameters to meet your business requirements.
To reconfigure the parameters:
Log in as user pin.
Open the BRM_Home/upgrade/partition/partition.cfg file in a text editor such as vi.
Change the default parameters as necessary. For information on each parameter, see the comments in the partition.cfg file.
Save and close the file.
Copy any customizations from your backed-up pin_setup.values file into the BRM_Home/setup/pin_setup.values file.
Make a complete offline backup of your BRM database, and make sure the backup is completely valid and usable. For more information on performing full database backups, see your database software documentation.
In addition to the backup, use the Oracle export utility to export all BRM tables. This helps you restore individual tables if necessary.
Converting from a nonpartitioned storable class to a partitioned storable class should take about 30 minutes. The size of your tables does not affect the speed of this conversion.
To run the partitioning conversion scripts:
Go to BRM_Home/upgrade/partitioning.
Run the following command:
This runs a series of scripts that perform the conversion.
Check the log and pinlog files in the directory specified by the UPGRADE_LOG_DIR parameter in your partition.cfg file (by default, BRM_Home/upgrade/partition/sqllog). These log files show how long each script took to run and list any errors that occurred.
Important:If errors are reported, fix them, and rerun the script.
Before your BRM system resumes generating data, use the partition_utils script to add purgeable partitions to your newly partitionable tables. See "Adding Partitions".
Start all BRM processes. See "Starting and Stopping the BRM System".
Note:The object IDs of objects generated in your newly partitioned tables will be larger than the object IDs of objects generated in your old, nonpartitioned tables. (Depending on the table, object IDs are stored in either the POID_ID0 field or the OBJ_ID0 field.)
Table 26-1 lists the scripts and files used to convert your nonpartitioned storable classes to partitioned storable classes. These scripts and files are in the BRM_Home/upgrade/partition folder.
Important:To convert custom storable classes, you might need to create additional SQL scripts. To use custom scripts in the conversion, add appropriate SQL file entries to the nonpartitioning-to-partitioning conversion configuration file, partition.cfg. See "(Optional) Reconfiguring the Parameters".
|Script or File||Description|
SQL script that creates the pinlog files.
Configuration file in which you must enter details about the Oracle database configuration before you run the conversion scripts. All the conversion Perl scripts parse this file to get the database connection parameters.
Master Perl script for the conversion process. This script calls other SQL scripts to perform the conversion.
SQL script that creates the common routines needed for the conversion.
Custom SQL scripts that implement partitioning for the specified storable class (storable_class_name).
SQL scripts that implement partitioning.
Perl script that performs many miscellaneous conversion tasks related to the BRM database.
By default, the partitioning conversion feature enables you to convert the event, bill, invoice, item, and journal storable classes.
To convert additional nonpartitioned storable classes to partitioned storable classes:
Create a SQL script named storable_class_name_tables_tobe_partitioned.sql, where storable_class_name is the name of the object type whose table you want to partition.
For samples, see the following files in the BRM_Home/upgrade/partition/ directory, where BRM_Home is the directory in which BRM components are installed:
Add the new SQL script to the @SQL_PARTITION_TABLES parameter in the BRM_Home/upgrade/partition/partition.cfg file.
Run the partitioning.pl script, which converts the specified storable class from nonpartitioned to partitioned.
Run the partition_utils.pl script, which adds purgeable partitions.