- Login to NCM Application server from which you want to backup database, and then set the VOYENCE_HOME environment variable.
For example, in Linux, execute the following command:
source /etc/voyence.conf
- Stop the tomcat service running on the remote RA server.
- Take the backup of database by using the backup.pl script under the <VOYENCE_HOME>/tools directory.
The script creates a “backup-image-.*.tgz” file under the VOYENCE_HOME>/data-image directory.
Note:- If you have Smarts Adapter configured with SMARTS IP and SAM, the backup.pl script will also backup the Smarts Adapter data.
- If you are taking backup from lower version of NCM (10.1.3 and below) then before taking the backup run the database-changes.pl script present under Utils directory of 10.1.13 installer.
- Copy the “backup-image-.*.tgz” file to a host where a new NCM Application server is installed. The backup file can be copied under any directory.
- Login to the new NCM Application server setup, and then execute the following command:
source /etc/voyence.conf
- Execute the following command from the <VOYENCE_HOME>/tools directory if you are restoring database across same NCM version:
perl restore.pl <Absolute path to backup image file /backup-image-.*.tgz>
- Execute the following command from the <VOYENCE_HOME>/tools directory if you are restoring database on higher NCM version:
perl restore.pl <Absolute path to backup image file /backup-image-.*.tgz> --force
Note: This step is required for the backups taken from NCM 9.6 version onwards. - Update the InfraDB entry with Device server host names and IP addresses. To update the InfraDB entry, perform the following steps:
- From the <VOYENCE_HOME>, execute the following command:
\cgi-bin\cflist.cgi > cflist.txt
- Edit the cflist.txt to change all Device server FQDN and IP address to the new Device server FQDN and IP address.
For example, POP 1000 "<HOSTNAME>" NetList= RsrcList= DevList=1001,1002 EmsList= : ADDR="<IPADDRESS"
- Execute the following command. It must return 'Status: 200 Success'.
\cgi-bin\cfwrite.cgi < cflist.txt
- From the <VOYENCE_HOME>, execute the following command:
- On the new Application server, go to the <VOYENCE_HOME>/bin directory, and then add all distributed Device servers to the lockbox using cstdriver utility:
- cstdriver -lockbox <VOYENCE_HOME>/data/lockb.clb -passphrase <passphrase> -addHost <FQDN of Device server>
- cstdriver -lockbox <VOYENCE_HOME>/data/lockb.clb -passphrase <passphrase> -addHost <FQDN>
- Change the ownership of <VOYENCE_HOME>/data directory to ncm:voyence using the command:
chown -R ncm:voyence <VOYENCE_HOME>/data
- Change the ownership of <VOYENCE_HOME>/conf/key and <VOYENCE_HOME>/conf/iv files to ncm:voyence using the command:
chown -R ncm:voyence <VOYENCE_HOME>/conf/key chown -R ncm:voyence <VOYENCE_HOME>/conf/iv
- Restart the vcmaster service in the Application server host.
- Copy and replace the <VOYENCE_HOME>/data/lockb.clb file from Application server host to all Device server host under <VOYENCE_HOME>/data/lockb.clb.
- Change the ownership of the lockb.clb file to ncm:voyence using the command:
chown ncm:voyence lockb.clb
- Change the file permissions of the lockb.clb file to 640 using the command:
chmod 640 lockb.clb
- Copy and replace the following from the old Device server to new Device server:
- <VOYENCE_HOME>/data/devserver/configuration/ad_nextIdx
- <VOYENCE_HOME>/data/devserver/configuration/ad_numIdxIHavefiles
- <VOYENCE_HOME>/data/devserver/configuration/ad_nextIdx
- Change the ownership of both the files to ncm:voyence using the commands:
chown ncm:voyence ad_nextIdx chown ncm:voyence ad_numIdxIHavefiles
- Change the file permissions of both the files to 660 using the commands:
chmod 660 ad_nextIdx chmod 660 ad_numIdxIHavefiles
- Restart the vcmaster service in all distributed Device server hosts.
- To update all Device server FQDN in cm_device_server table in the database, do the following:
- Login to NCM UI, and then navigate to Tools > System Administration > Global > Access > Device Servers.
- Select each Device server, and then click Edit.
- In the Edit Device Server window, click OK.
Or,
Run the following command from [Product directory]\db\controldb\bin:
psql.exe -h -d voyencedb -U pgdba -p 5435 -c "update cm_device_server set device_server_name='Device_Server_name';"
- If you have Smarts Adapter configured in your previous NCM setup, follow these steps:
On Linux
- Stop the NCM Smarts Adapter service.
systemctl stop ncmsmartsadapter
- Change the directory to $VOYENCE_HOME/NCMSmartsAdapter/.
- Open and edit the prodDb.script file, so that VOYENCE_CONFIGURATION table is populated with actual AS host name, as follows:
- Search for
INSERT INTO VOYENCE_CONFIGURATION VALUES (1,4,TRUE,'auth.conf','2','10000','linbgh125.lss.vmware.com','jUpFF0M5HQuOdJUqIYKo0w==','sysadmin')
- Replace the old Application server host name with new Application server host name.
For example, replace 'linbgh125.lss.vmware.com' with '<new Application server host name>'.
- Start the NCM Smarts Adapter service.
systemctl start ncmsmartsadapter
- Stop the NCM Smarts Adapter service.