This chapter describes how to check the validity of Oracle Communications IP Service Activator Oracle Database using the Database Integrity Checker and run clean-up datascripts.
This chapter also describes the following cleanup utilities associated with provisioning MPLS LSP based tunnels. Provisioning with the MPLS LSP module is described in IP Service Activator VPN User's Guide.
You can check the validity of IP Service Activator database using the Database Integrity Checker.
Note:
It is a best practice to run the Database Integrity Checker nightly as part of a regular system health check.Checking the database is particularly important if the database has been shut down in an emergency.
The Database Integrity Checker is a command-line tool that writes diagnostic information about the database to a human readable output file in Service_Activator_Home. By default, diagnostic information is written to the file icheck_Day_Mon_dd.bin but you can specify an alternative output file.
Different versions of the tool are available for different versions of IP Service Activator. You should ensure that the version of tool you use matches the version of IP Service Activator you are checking. You can do this by running the Database Integrity Checker tool and noting the version number in the first line of the output. For example:
Oracle Communications IP Service Activator v7.x.x.x component: Database Integrity Checker ...
The tool must be run on one database at a time, and the database must not be in use.
Note:
Oracle recommends that you run the tool on a back-up version of the database. For information about backing up an Oracle database, see the applicable Oracle Backup and Recovery guide.The Database Integrity Checker (UNIX version) is installed on the Policy Server during IP Service Activator installation.
Before running the Database Integrity Checker make sure that there are no IP Service Activator components running and accessing the database.
To run the Database Integrity Checker (UNIX version):
Run the script integrity_checker.sh from the <ServiceActivatorHome> folder. You are prompted to enter the <DSN_Name>, <database_user_id>, and <database_password>.
Enter the following commands:
cd Service_Activator_Home
./bin/integrity_checker.sh
OR
integrity_checker -ConnectString <connect_string> [-SerialNumber <serial_number>] [-FileName <file_name>] [-Summary <file_name>]
These parameters are described in the table "Database Integrity Checker Parameters".
The Database Integrity Checker runs to completion and displays a report similar to the following sample:
Oracle Communications IP Service Activator v7.x.x.x component: Database Integrity Checker Copyright C 20xx Oracle. All rights reserved. Reading database..... Object model initialised: 10801 objects discovered Checking object model..... Tue 07/08/07 09:31:55 No faults were found in the database. Finished.
Other reports that may be returned are listed in "Report Information".
The Database Integrity Checker runs on Windows but communicates with the Oracle Database on Solaris/Linux. The tool is installed to ServiceActivatorHome\Program but must be run from ServiceActivatorHome specifying the relative path to the program: Program\integrity_checker.exe
Run the Database Integrity Checker from the ServiceActivatorHome directory.
Before running the Database Integrity Checker make sure that there are no IP Service Activator components running and accessing the database.
To run the Database Integrity Checker (Windows version):
Open a Command Prompt window.
Change to the Service_Activator_Home directory.
Run the tool (including the path):
Program\integrity_checker.exe -ConnectString <connect_string>; [-SerialNumber <serial_number>] [-FileName <file_name>] [-Summary <file_name>] [+debugFile -debugFileName <file_name>]
For example:
cd C:\Program files\Oracle Communications\Service Activator Program\integrity_checker.exe -ConnectString OCI;DSN=mydsn;UID=userid;PWD=password -SerialNumber 123456789 -FileName DIC_Diag.out -Summary DIC_Summ.out +debugFile -debugFileName DICdebug.log
The Database Integrity Checker runs to completion and displays a report similar to the following sample:
Oracle Communications IP Service Activator v7.x.x.xx component: Database Integrity Checker Copyright C 2008 Oracle. All rights reserved. Reading database..... Object model initialised: 10801 objects discovered Checking object model..... Tue 07/08/07 09:31:55 No faults were found in the database. Finished.
Other reports that may be returned are listed on "Report Information".
Table 8-1 lists and describes the integrity checker parameters.
Table 8-1 Integrity Checker Parameter Definitions
Parameter | Description |
---|---|
-ConnectString |
Mandatory parameter. Connects the tool to the database to be checked, where connect_string is the database connect string. The connect string for an Oracle database is: -ConnectString OCI;DSN=<local net service name from tnsnames.ora>;UID=<user identity>;PWD=<password> In the database connection string, the value of UID and PWD should be entered in the correct case. |
-SerialNumber |
If you were assigned and entered a serial number during IP Service Activator installation, you must enter the same 9-digit serial number here. |
-FileName |
Optional parameter. Specifies the pathname of the file to which diagnostic information is sent. If the specified file already exists, a message asks if you want to create a new file or overwrite the existing file. If you do not enter the -FileName parameter, an output file named icheck_Day_Mon_dd.bin is created in the directory from which the tool was launched (for example: icheck_Mon_Apr_15.bin). Note: If there are no issues with your database the icheck file is not generated. |
-Summary |
Optional parameter. Specifies the pathname of the file to which summary information is written. This file is appended to if it already exists. If no -Summary parameter is specified, summary output is displayed on the screen. Maintaining a summary file provides a useful record of when the tool was run and the results of each run. |
Note:
If you want to use the UNIX version of the tool (integrity_checker.sh), do not enter the ConnectString parameter, but you can specify the remaining parameters if needed.After completing the check, the Database Integrity Checker writes one of the following report messages to the screen or to a summary file, if specified:
No faults were found in the database.
Finished.
A minor fault was found in the database. Please contact Oracle Global Customer Support customer support for assistance.
A major fault was found in the database. Please contact Oracle Global Customer Support for assistance.
The database integrity checker has encountered an unknown fault. Please update your software with the latest version of the checker.
This message may mean that the version of the tool is incompatible with the version of IP Service Activator it has been run against.
This section describes administration and maintenance of the Network Processor portion of the Oracle database. The Network Processor use of the Oracle database complements the Policy Server's storage of the Object Model in the Oracle database.
Features of the Network Processor that use the Oracle database include:
Device model and Service model persistency
npAdmin tools
Log file read processes: LogReader
npSnapshot and npUpgrade scripts (For more information about these scripts, see the Upgrades chapter in IP Service Activator Installation Guide.)
Configuration Management
Network Processor database-related files include:
Network Processor database-related configuration files
Network Processor database-related log files
The Oracle database provides the repository for IP Service Activator device configuration data. For each device managed by an IP Service Activator cartridge, there is a database record containing the device ID, the Service Model version, and the Device Model version. The record stores the last configuration successfully pushed to the device - the Last Device State (LDS).
The database record replaces the DeviceModel_smVersion_dmVersion_componentID.xml file for each device that was formerly maintained on disk in the directory Service_Activator_Home/WorkingData/cacheDD.
The npAdmin shell script provides a set of tools for managing LDS records (containing deviceID, device model, and service model data) in the Network Processor database table. The default Connection String for this script is: OCI;DSN=IPServiceActivatorDb;UID=admin;PWD=admin
The following tasks can be performed on the LDS schema in the Oracle database.
To retrieve from the database the Last Device State for a specific device:
Usage: npAdmin.sh get_last_lds <deviceObjid> <cartridgeObjid> Example: npAdmin.sh get_last_lds 123 256
To delete one or all of the Last Device States or service models for a specific device:
Usage: npAdmin.sh delete_lds <deviceObjid>|all <cartridgeObjid>|all <smVersion>|all <dmVersion>|all Example: npAdmin.sh delete_lds 123 all all
The deletion of a device state is supported only in a lab environment.
To list one or all Last Device States based on device object ID or device IP address:
Usage: list_lds <deviceObjid>|all <cartridgeObjid>|all <deviceIp>|all Example: npAdmin.sh list_lds 39432 all all
To split a device model file containing a service model into two files, a device model file and a service model file:
Usage: npAdmin.sh split_lds <cacheddFilename> <smFilename> <dmFilename> <aiFilename> <directory> Example: npAdmin.sh split_lds cachedd_123.xml sm_123_2.0.1_2.1.4.xml dm_123_2.0.1_2.1.4.xml
The device model file to be split is in the current working directory, and the resulting split files are placed in the same directory.
To import a specific device model file from the specified directory into a database record:
Usage: npAdmin.sh import_lds <deviceObjid> <cartridgeObjid> <smVersion> <dmVersion> <directory> Example: npAdmin.sh import_lds 123 2.0.1 2.1.4 /opt/lds_files
Do not use spaces in the <directory> argument.
The files on which this command acts must have this service model filename format: sm_<deviceObjid>_<smVersion>_<dmVersion>.xml
and this device model filename format: dm_<deviceObjid>_<smVersion>_<dmVersion>.xml
To export a specific device record from the database to a file in the specified directory:
Usage: npAdmin.sh export_lds <deviceObjid> [<cartridgeObjid> <smVersion> <dmVersion>] <directory> Example: npAdmin.sh export_lds 39432 ’pwd'
Do not use spaces in the <directory> argument.
The files which this command creates have this service model filename format: sm_<deviceObjid>_<smVersion>_<dmVersion>.xml
and this device model filename format: dm_<deviceObjid>_<smVersion>_<dmVersion>.xml
To save in the specified directory the obsolete Last Device States for a specific device or all devices:
Usage: npAdmin.sh save_old_lds <deviceObjid>|all <cartridgeObjid>|all <deviceIp>|all <directory> Example: npAdmin.sh save_old_lds all all /opt/lds_files
Do not use spaces in the <directory> argument.
The files which this command creates have this service model filename format: sm_<deviceObjid>_<smVersion>_<dmVersion>.xml
and this device model filename format: dm_<deviceObjid>_<smVersion>_<dmVersion>.xml
To delete from the database the obsolete Last Device States for a specific device or all devices:
Usage: npAdmin.sh purge_old_lds <deviceObjid>|all <cartridgeObjid>|all <deviceIp>|all [commit] Example: npAdmin.sh purge_old_lds all all commit
Use the 'commit' option if you do not want a confirmation prompt. Perform this task only when the schema has been changed and if you want to purge the old LDS after an upgrade from 5.2.4 or 7.x.
To delete associations from the service and device models for a specified device:
When a service (or an instance of a service) is deleted in IP Service Activator, the Network Processor may fail to successfully remove the configuration associated with that service. This can result in repeated attempts by the network processor to remove the affected configuration.
The configured association can be removed manually or can be removed with a special purge_association command in npAdmin.
This command should only be used in the situation described above and at no other time. There is no ’undo' option after using this command.
To execute this command in npAdmin, the association IDs and device IP must be determined. The following log pattern in the network processor log for the cartridge provides this information:
<date-time>|<msecs>|WARN|<thread-name>|<device-ip>|<cartridge-name>|<association-list>|proxy_np|<hostname>|Error occurred while attempting to configure the device: '<command-and-router-response>'. Rollback will be attempted. The following explains the syntax required to execute the command. Usage: npAdmin.sh purge_associations [deviceIp | deviceObjid] [associations] Example: npAdmin.sh purge_associations 10.156.68.228 25856
If more than one association is specified, they should be separated by a space.
To purge deleted devices and to reduce the footprint in the database:
Usage: npAdmin.sh purge_deleted_devices Example: -bash-4.1$ ./npAdmin.sh purge_deleted_devices
When you have deleted a number of devices from IPSA. Use with caution.
The IP Service Activator administrator should be aware of the following Network Processor database-related files.
The IP Service Activator administrator should be aware of the following Network Processor/database-related files.
Service_Activator_Home/Config/cman.cfg
The entries for system_log, policy_server and event_handler include a ConnectString parameter for the OM database.
The network_processor entry includes a ConnectString parameter for the Network Processor schema.
The logreader entry includes DatabaseServer, DatabasePort, DatabaseSid, DatabaseUserid and DatabasePassword parameters for the LW schema.
Service_Activator_Home/Config/networkProcessor/com/Oracle/serviceactivator/networkprocessor/default.properties
The following tables list attributes in the network processor default.properties file.
Network Processor default.properties attribute | Type/Values | Description |
---|---|---|
connectionTimeoutSeconds |
integer |
Connection timeout value once connection is established |
showConfigTimeoutSeconds |
integer |
Timeout value once "show configuration" established |
minSecondsBetweenIndividualConnectAttempts |
integer |
Minimum time between connection retries |
overallConnectAttemptSeconds |
integer |
Total time to allow to attempt to connect to the device |
Network Processor default.properties attribute | Type/Values | Description |
---|---|---|
warnInOfflineMaintenanceMode |
boolean (true, false) |
Determines whether or not to raise warning faults in Offline Maintenance (FileInterface) command delivery mode |
suppressAuditFeedback |
boolean (true, false) |
When set to 'true', audit feedback is suppressed. When set to 'false', device and concrete audit states are updated as a result of a device audit, and faults are raised against concretes reporting audit failures. |
suppressManualConfigInPerServiceAudit |
boolean (true, false) |
When set to 'true', manual configuration is suppressed in Per Service Audits. When set to 'false', manual configuration is displayed in Per Service Audits. Default is 'true'. |
lossOfSyncSeverity |
One of: Critical, Error, Warning, Notice, Info, Suppress |
Configures the severity of a loss of synchronization detected between the last device state and the device |
Table 8-4 Cartridge-centric Parameters
Network Processor default.properties attribute | Type/Values | Description |
---|---|---|
saveRunningConfig |
boolean (true, false) |
Configures whether or not the running configuration is saved to the startup configuration after each running configuration change (for applicable devices). |
vrfRebuildRetries |
integer |
Maximum number of retries to configure a VRF routing table. This applies to cartridges that support retries to configure a VRF routing table. |
vrfRebuildWaitTime |
integer |
Wait time in milliseconds between retries to configure a VRF routing table. This applies to cartridges which support retries to configure a VRF routing table. |
manualVrfProtection |
boolean (true, false) |
When set to 'true', VRF routing tables are not deleted. This applies to cartridges which implement manual VRF protection. Note: If this value is set to 'true', then the Cisco "preCheckVrf" precheck must be disabled in the standard.properties file. Otherwise, it would prevent the reuse of any VRF names that had previously been preserved since the precheck would always fail. |
reconcileFailureIsCritical |
boolean (true, false) |
Set the severity of fault message 3510: 'Re-issue commands operation failed' When set to 'true', the severity level is set to Critical. When set to 'false', the severity level is set to Error. |
Network Processor default.properties attribute | Type/Values | Description |
---|---|---|
groupName |
text |
Specifies the group name to use when issuing commands on Juniper routers. |
juniperConnectionRetryWaitIntervalSeconds |
integer |
The number of seconds to wait between retries to connect to a Juniper device after the connections were lost. |
juniperJunosConfigurationMode |
one of: configure,configure private,configure exclusive |
Sets the configuration mode command for Juniper JUNOS CLI devices. |
Table 8-6 Juniper JUNOS L VPN Cartridge Parameters
Network Processor default.properties attribute | Type/Values | Description |
---|---|---|
junosConfigureBroadcastMessages |
boolean (true,false) |
When set to ”true,” broadcast message commands are configured by JUNOS SDK cartridges. |
junosAutoGeneratedVrfNamePrefix |
text |
Specifies the prefix for auto-generated VRF Names to be used when configuring VPN using JUNOS SDK cartridges. By default it is set to ”IPSA.” |
Table 8-7 CISCO IOS XR Parameters
Network Processor default.properties attribute | Type/Values | Description |
---|---|---|
ciscoIosXrConfigurationMode |
one of: configure, configure exclusive |
Sets the configuration mode command for Cisco IOS XR devices. |
Network Processor default.properties attribute | Type/Values | Description |
---|---|---|
ciscoPrefixListMinSequence |
integer |
The minimum ID number that can be assigned to Cisco prefix lists. |
ciscoPrefixListMaxSequence |
integer |
The maximum ID number that can be assigned to Cisco prefix lists. |
ciscoDisableDampening |
boolean (true, false) |
When set to 'false', the Cisco EBGP dampening configuration is generated. |
ciscoSooRouteMapSequenceNum |
integer |
The default number used in Cisco route map order configuration. |
ciscoPhbGeneratedACLType |
One of: autoNamed, autoNumbered |
This property is used by PHB and MQC classifications to indicated whether to create named or numbered ACL when user selects auto generate option. Note: Specification of a value other than ’autoNamed' or ’autoNumbered' causes the cartridge to raise a fault. |
VrfAliasesDisabled |
boolean (true, false) |
When set to 'false', the Cisco VRF aliases configuration are generated. |
Table 8-9 Database Connection Pool Settings
Network Processor default.properties attribute | Type/Values | Description |
---|---|---|
dbConnectionPoolMin |
integer |
Minimum number of physical connections that can be maintained by the pool. |
dbConnectionPoolMax |
integer |
Maximum number of physical connections that can be maintained by the pool. |
dbConnectionPoolConnectionUses |
integer |
Number of times a connection is retrieved/returned from/to the pool before it is closed and re-opened. This number should not be more than 1/3 of your Oracle Database "open_cursors" system parameter value or you may encounter "ORA-01000: maximum open cursors exceeded" exceptions. Note: See IP Service Activator Installation Guide for information about setting the value of open_cursors. |
dbConnectionPoolConnectionTimeout |
integer |
Number of seconds which must pass before an idle physical connection is disconnected. |
dbConnectionPoolWaitTimeout |
integer |
If dbConnectionPoolNoWait is false, number of seconds that must pass before a thread waiting for a connection times out. |
dbConnectionPoolNoWait |
boolean (true, false) |
If true, this attribute specifies that an error is returned if a call requires a physical connection while the maximum number of connections in the pool are busy. |
dbConnectionPoolTafEnabled |
boolean (true, false) |
Set to true if the Oracle Database Transaction Application Failover (TAF) feature is enabled. |
dbConnectionPoolRetryAttempts |
integer |
Number of attempts to create a connection pool after the connections were lost. |
dbConnectionPoolRetryIntervalSeconds |
integer |
Number of seconds to wait between retries to create a connection pool after the connections were lost. |
cmDbConnectionPoolMin |
integer |
Minimum number of physical connections that can be maintained by the pool. |
cmDbConnectionPoolMax |
integer |
Maximum number of physical connections that can be maintained by the pool. |
cmDbConnectionPoolConnectionUses |
integer |
Number of times a connection is retrieved and returned to or from the pool before it is closed and reopened. Note: This number should not exceed a third of your Oracle "open_cursors" system parameter value. Exceeding this value may result in the exception:
|
cmDbConnectionPoolConnectionTimeout |
integer |
Number of seconds before an idle physical connection is disconnected. |
cmDbConnectionPoolWaitTimeout |
integer |
The number of seconds before a thread waiting for a connection times out. Applies only when:
|
cmDbConnectionPoolNoWait |
boolean (true, false) |
If true, returns an error when a call requires a physical connection and when the maximum number of connections in the pool are busy. |
cmDbConnectionPoolTafEnabled |
boolean (true, false) |
Set to true only if the Oracle Transaction Application Failover (TAF) feature is enabled. |
cmDbConnectionPoolRetryAttempts |
integer |
Number of attempts to create a connection pool after the connections were lost. |
cmDbConnectionPoolRetryIntervalSeconds |
integer |
Number of seconds to wait between retries when creating a connection pool after the connections were lost. |
Table 8-10 Miscellaneous Settings
Network Processor default.properties attribute | Type/Values | Description |
---|---|---|
maxthreads |
integer |
Maximum number of processing threads |
maxSchedulerThreads |
integer |
Maximum number of scheduler threads that can run concurrently. |
SnapShotFileLocation |
text |
Filename and directory for the snapshot file, for the CM tftp server to pick up. |
RestoreFileLocation |
text |
Directory location of the restore file, for the tftp server to pick up. |
restoreCommandTimeoutSeconds |
integer |
Command timeout default if not specified in the restore template |
useOfflineCommitOptions |
boolean (true, false) |
When set to 'true', changes the command delivery mode display string in the audit log from "file-interface" and "no-command-delivery" to "offline-maintenance" and "offline-test", respectively. |
optimizeFirstCommit |
boolean (true, false) |
When set to 'true', optimize the first commit on a device after re-manage or network processor startup such that the service model to device model transformation only executes if the service model has changed. |
queuePriority |
One of: auto, low, high |
Commit queue prioritization. This setting affects how the first commit for a device after re-manage or network processor startup is queued. auto: determine queue priority based on service model changes. This may involve database operations. low (default): all initial commit operations are given low priority without retrieving service model data from the database. high: all initial commit operations are given high priority without retrieving service model data from the database |
archiveOnChangeDelay |
integer |
Delay in minutes, used by ConfigManagement scheduler's Archive on Change functionality. |
disableEnvCheck |
boolean (true, false) |
If false, checks that the correct version of Saxon is found. If true, skips the check. |
deleteTransientCmdReissueFiles |
boolean (true, false) |
Delete Command Reissue Files on startup. |
tftpDeviceVisibleNICIpAddr |
One of: ”none”, IP address |
In case the host has multiple NIC cards, specifies which IP to use. Default is ”none”, meaning there is only one NIC. This affects the restore functionality, and should specify the NIC that has access to the device. |
cmdExecutorDelay |
integer |
Specifies command delivery delay in milliseconds between commands sent to the device |
cmdReissueDirectory |
text |
Directory used to store the preview of the command re-issue requests. |
quarantineDelay |
integer |
Specifies the delay in seconds between quarantine invocations. |
cacheCapacity |
integer |
Size of the memory cache, in bytes. |
maximumCommitQueueSize |
integer |
Used to throttle the commit queue. |
Service_Activator_Home/Config/networkProcessor/upgradeTool/default.properties
# Full path name of the home directory that will hold the "upgrade" sub-directories. upgradeHome = /opt/OracleCommunications/ServiceActivator/upgradeHome # deviceList retrieval method = 'database' or explicit list (use one or the other). Explicit list: oid,name,ipa:oid,name,ipa:oid,name,ipa:oid,name,ipa:oid,name,ipadeviceList = database # Location of last device models to be upgraded: 'files' (if stored in cacheDD directory), 'database' (if stored in np_lds table) or 'np_ldm' (if stored in np_ldm table). npModelSource = database # Checks that saxon is the correct version as is hardcoded in the network processor. disableEnvCheck = false # Number of concurrent processes (should be less than the number of processors) processes = 2 # The total amount of memory (in MB ) to be used by all children processes (it will be divided among them) totalMemory = 2048
The npSnapshot and npUpgrade read the db.properties file in the Service_Activator_Home/Config for database details.
Service_Activator_Home/Config/java/com/Oracle/serviceactivator/logreader/logCollector.properties
The following entries are used for configuring the LW schema:
dbDriver = oracle.jdbc.driver.OracleDriver dbConnect = jdbc:oracle:thin:@SERVER:PORT:SID maintenanceInterval = 3600000 logLifetime = 7 listenSocketPort = 4446 fileRollCheckInterval = 60000 # By default, use the enterprise edition features for efficiency dbInitializeProperties=dbInit.properties # For Oracle standard edition, the above line must be commented out and the following uncommented. #dbInitializeProperties=dbInitSe.properties
Service_Activator_Home/odbc/network/admin/tnsnames.ora
This file contains entries similar to the following sample, which the applications in the cman.cfg file use to connect to the appropriate database with their ConnectString parameter:
IPServiceActivatorDb = (DESCRIPTION = (ADDRESS = (PROTOCOL = TCP)(HOST = 10.13.4.113)(PORT = 1521)) (CONNECT_DATA = (SERVER = DEDICATED) (SERVICE_NAME = IPSA.WORLD) ) )