Additional NMS Configuration
Read Only Mode
Read Only mode disables buttons and menu items in the Java Application which save data. This is used as part of Failover Patching to prevent users from saving data that will be lost. This is controlled by the FLG_READ_ONLY status flag in JBot configuration. Custom buttons and menu items added to JBot configuration should use the FLG_READ_ONLY status flag to control whether they are enabled.
Example
<Enabled when= "!FLG_READ_ONLY "/>
Applications which have a status bar (Web Workspace, Model Management, Web Callbacks, and Storm Management) display a read only mode icon in the status bar. This is configured in the LBL_READ_ONLY label in each application’s status bar.
In addition, the title bar of each Java application changes while in Read Only mode. The title is configured with the [Application].readOnlyTitle property in each application. The default configuration adds “(Read Only mode)” to the original application’s title.
Read Only mode can be turned on by running the following command:
nms-read-only 1
And turned off with the following command:
nms-read-only 0
When Read Only mode is turned on or off, a system alarm is generated using the text configured for the READ_ONLY_ON and READ_ONLY_OFF message codes in the MESSAGE_CODE_LOOKUP table for MESSAGE_TOPIC ‘DDS’.
Example
INSERT INTO message_code_lookup (message_topic, message_code,
message_string)
VALUES ('DDS', 'READ_ONLY_ON', 'Read Only mode turned on');
INSERT INTO message_code_lookup (message_topic, message_code,
message_string)
VALUES ('DDS', 'READ_ONLY_OFF', 'Read Only mode turned off');
Syncing Operations Model
In order for the Operations Model to be up to date when a switchover or failover is performed, the $OPERATIONS_MODELS directory is synced to the standby site. However, this can involve a lot of data and in the case of a failover, the original primary site might not be reachable. The nms‑sync‑site script should be used to keep standby sites in sync with the primary site. Create the file $NMS_HOME/etc/standby_sites.txt on each NMS environment with a list of the hostnames where NMS services run at each of the other sites (one per line).
In the [project]-postbuild script, add the following line after all updates to $OPERATIONS_MODELS are finished:
nms-sync-site -f model-build @$NMS_HOME/etc/standby_sites.txt
In addition, it is recommended to create a cron table entry on each environment to run the following script:
#!/bin/ksh
if [[ ! -r "$NMS_HOME/etc/standby_sites.txt" ]]
then
exit 0
fi
 
cnt=$(ISQL -silent 2>/dev/null << sqlend
set pagesize 0
set feedback off
select count(1) from nms_current_site
where site='$NMS_SITE_NAME';
exit;
sqlend
)
 
if [[ $cnt -gt 0 ]] && nms-version --is-active
then
nms-sync-site -q -f model-build @"$NMS_HOME/etc/standby_sites.txt"
fi
nms-update-site
This script updates the NMS_CURRENT_SITE database table to the current site in the NMS_SITE_NAME environment variable. This makes it so that the NMS_PARAMETERS_VIEW database view only includes parameters that apply to this site. This script is run by nms‑ha‑switchover, nms‑ha‑failover, and nms‑post‑setup.