Using --clean-topology switch for sm_server command to preserve domain settings but remove all monitored devices
book
Article ID: 304134
calendar_today
Updated On:
Products
VMware Smart Assurance
Issue/Introduction
Symptoms:
How to start a server with clean topology How to copy the settings but not topology from an existing domain to a new domain.
How to remove all devices present in the topology but preserve all polling and threshold settings in the domain and discovery filters.
Environment
10.x
Resolution
The "--clean-topology" switch should be used if you no longer want to monitor devices in your topology but would like to preserve settings that have been already configured in it. To use this switch, you will need to:
Confirm that the IP domain is not currently running a discovery process.
Check the stage of discovery progress using the following commands:
./dmctl -s <domain> get ICF_TopologyManager::ICF-TopologyManager::probeInProgress
./dmctl -s <domain> get ICF_TopologyManager::ICF-TopologyManager::InPostProcess
, for both these command FALSE response would indicate that the IP domain is not in discovery mode.
Save the IP domain rps with the following command.
sm_tpmgr -s <IP DomainName> --save
Confirm that the rps save started and finished review the IP domain log file for the following messages and check the timestamp at the time you issued the command above. You may want to tail the log file in a separate screen when you are ready to issue the command above:
Look near the end of the log file for ICF_MSG-*-ICF_SAVESTART-PersistenceManager: save started
Then look for message after that for ICF_SAVEFINISH-PersistenceManager: save finished
Shut down your IP domain
Make a copy of the rps file for the domain. The rps file for all EMC Smarts products is located in the <BASEDIR>/<SUITE>/smarts/local/repos/icf directory.
Rename the copied rps file to the name of your new domain. (ex. Rename from INCHARGE-AM-PM.rps to NEW-INCHARGE-AM-PM.rps)
Modify the sm_service command that starts up the domain to include the --clean-topology option and re-install the service*.
If you do not want to change the Service Start up command as done in Step 6 above, here is an alternative method for Steps 6 through 9 above.
Stop the service using the sm_service stop <service name>. In Windows you want to also disable the Service from starting up automatically changing the Service properties and disabling the service. Apply the changes, then stop the service for the IP domain.
The startup command for the IP domain is found in the sm_service show command line or the in the top 10 lines of the IP domain log. It will look similar to this command:
As root you can run the same command as above from the <IP BASEDIR>/smarts/bin directory.
Once the domain is up and running,
check and confirm that the topology has cleared.
Look near the end of the log file for ICF_MSG-*-ICF_SAVESTART-PersistenceManager: restore started
Then look for message after that for ICF_SAVEFINISH-PersistenceManager: restore finished
Also confirm that a reconfigure has also started and finished in the IP domain log
Shut down the domain and confirm the domain has stopped.
Then use your original sm_service start <service name> to restart your domain as before. Please note in Windows you can use the Services to start your existing domain.
Additional Information
Please note if you are using this process to create a new domain with the same settings you would need to install a new Service with the commands in the first section using this command install the new service command with a new Service Name and domain name.
Another example of the sm_service install command. Remove the notes below in Arial font:
sm_service install --force --unmanaged --startmode=runonce \ '--name=ic-am-pm-server' \ (change this name so that there is not a duplicate service) '--description=EMC Smarts Availability and Performance Manager Server' \ '/opt/Inchargexx/IP/smarts/bin/sm_server' \ '--name=INCHARGE-AM-PM' \ (This name is for the actual domain name. Be sure this is not a duplicate IP domain already on your broker) '--port=0' \ '--config=icf' \ '--bootstrap=bootstrap-am-pm.conf' \ '--subscribe=default' \ '--ignore-restore-errors' \ '--output'