Utilising production ITNM data in a test environment
When writing stitchers or making AOC changes, it is always preferable to verify your work in a testing area prior to deploying into the production environment. This can be difficult if you do not have a suitable lab environment, or if your test server cannot be connected to the production network.
A way around this is to configure your production ITNM server to run a discovery in failover. This creates a discovery cache in the $NCHOME/var/precision directory which can then be zipped and copied to your test server where it can be used like live data.
The following steps explain this process.
On the Production Server:
- Enable discovery failover (prior to version 3.9)**. This can either be achieved from the advanced configuration options in the ITNM admin GUI, or by editing the DiscoSchema.cfg file in $NCHOME/etc/precision and setting m_UseFailover to 1. In ITNM v3.9 this can either be acheived from the advanced configuration options in the ITNM GUI admin GUI, or by editing the DiscoConfig.cfg file in $NCHOME/etc/precision and setting m_WriteTablesToCache to 1.
- Once discovery has completed, stop ncp_ctrl and zip the contents of $NCHOME/var/precision. If editing the configuration files directly, reset m_UseFailover = 0 on versions prior to 3.9 and m_WriteTablesToCache to 0 on version 3.9 , then restart ncp_ctrl (if using the GUI, wait for the ITNM services to restart, then uncheck the Discovery Failover option in Advanced tab).
On the development server
- Intall ITNM utilising the same domain name as that which is running in production.
- Stop the ncp_ctrl service and untar the cache files into $NCHOME/var/precision.
- Review the cache files and determine which agents have provided discovery data (look for agent returns).
- On versions prior to 3.9 edit the DiscoSchema.cfg file in $NCHOME/etc/precision and set m_UseFailover = 1. On version 3.9 edit the DiscoConfig.cfg file in $NCHOME/etc/precision and set m_WriteTablesToCache = 1.
- Edit the DiscoAgents.cfg file and ensure that only the relevant agents are enables.
- Start ncp_ctrl (and the ncp_disco service if not configured to start under ncp_ctrl) and the discovery cache will be read in.
The disco service will now be running and the discovery database will be populated with your production discovery data. Stitchers can now be run against your production data to verify they are successful prior to them being rolled out.
** Please be aware that running a discovery in failover extends the discovery process considerably, as well as increasing system utilisation. It is not advisable to enable Failover in a production environment except for the purposes of obtaining a cache, so normal operational settings should see discovery failover disabled.
Note – Discovery Failover is entirely independent of ITNM failover. If in any doubt, review the ITNM documentation.