Description of Issue
In the event that a ServiceNow instance has been renamed and there are already existing clone target records created for that instance from another source instance, the clone request may fail as the clone target record contains a URL and other connection information that ho longer references a valid ServiceNow instance.
The error message received when attempting to submit the clone will usually indicate "Unknown host" and the clone request will not be submitted.
Attempting to create a new clone target for the renamed instance will fail, because the target instance still retains the same sys_id regardless of the instance name.
Furthermore, attempting to delete the previous clone target record from the source will usually generate a message such as the following and prohibit the deletion:
The current record cannot be deleted until all XX instance clone records referencing it are deleted.
This is because this record references some number of previously completed or requested clone requests (corresponding to the XX number of records) on the source instance. Attempting to delete these related clone request records will also usually be unsuccessful.
In order to allow a clone from the renamed instance to be submitted without errors in this case is to rename various fields of the clone target record.
To perform this rename, follow these steps:
- Log into the clone source instance with an account having admin rights to that instance.
- Browse to the following location on that instance: System Clone -> Administration -> Clone Targets.
- A list should appear displaying all the clone targets configured on this instance. Ensure that the list shows the Name field and the Instance URL field columns.
- Locate the row containing the previous name of the instance you want to clone to.
- Double click the Name field of that record.
- This should cause an edit dialog box to appear. Replace the previous name of that instance with the newly renamed instance name for that instance. Click the Save button in the dialog box.
- Double click the Instance URL field for that record. Replace the previous instance name with the new name for the instance, ensuring to leave the reminder of the URL unchanged. Click the Save button on the dialog box.
- Open the record and verify that that the current Username field is correct. If not, correct the Username and Password fields with the account on the target instance which will be used for the clone request and Update the record.
- Resubmit the clone request using the newly renamed clone target record.
Updating the Name or URL field of the clone target request will automatically cause the other necessary fields of the record to be updated as well (i.e. database_url, database_user, etc).