System copy related: SAP prod. nodes appearing after refresh


Symptoms

License is not valid. Reason: Licensed value for "Monitored server count" is '3' but required is >= '13'

or 

License is not valid. Reason: Licensed value for "System ID" is 'LRP' but required is = 'LRQ'

Reason and prerequisites

"System refresh" is a process of copying one system to another, typically from production to development. It is often called "system copy".
If you don't follow the steps from documentation (https://docs.appdynamics.com/sap/en/upgrade-or-uninstall-the-solution#UpgradeorUninstalltheSolution-SystemRefreshSteps), the monitoring configuration of the source system (including application servers) is applied to the target system, and on top, the application server of the target system are added. It causes exceeding the number of used servers in the license.

Solution 

1.In case integration is activated:

-  Execute /DVD/APPD_CUST and deactivate integration

2.Execute t-code /DVD/MON:

- Stop all collector jobs under ‘Collector Jobs’ tab

- Press Edit ->Select * system -> Delete system definition and confirm all pop-ups

3.Execute t-code /DVD/APPD_STATUS and stop all HTTP SDK instances

4.Execute t-code /DVD/APPD_CUST:

- Edit mode ->Settings->Rebuild Node List - please make sure that all ports in node settings are unique and not in use

5.Execute /DVD/APPD_CUST activate the integration

6.Execute t-code /DVD/APPD_STATUS and start all HTTP SDK instances

7.Execute transaction /DVD/APPD_DI_CON (system will correctly re register) and start the jobs


Note:  

The point #2 and 7# will correct the incorrect nodes under the /DVD/MON - System landscape.

The point #4 will correct the incorrect nodes under the /DVD/APPD_CUST under the node list. 


You can use the simplified version in case you need to fix only the nodes incorrectly added in /DVD/MON

1. Stop all running collector jobs in /DVD/APPD_DI_CON.
2. In /DVD/MON, select the system PRD in left tree pane "System landscape".
3. Select menu item Edit->Delete system. Deleting may take some time depending on the amount of already collected data.
4. In /DVD/APPD_DI_CON, start one of the collector jobs, it invokes system registration process with correct number of the servers.