The ServiceNow clone process does not include the text index data and after each clone a regenerate text index process is executed on the target instance (Post-clone cleanup scripts).

This is done post-clone and the instance is available; but, there may not be searchable text data for hours to days for some customers until the regenerate text index process as completed.

This can be made better by setting/creating two properties in the target instance and add these properties to the data preservers.

Additionally, since the TASK table generally is the largest table and the longest to index; we might consider re-ordering the text indexes to index TASKS last; so that, at least, all other tables will be processed sooner.

Making these changes can reduce the regenerate text index process by 10% to 30%.


1) In the target instance, update or add these two properties.

  • Name: glide.ts.index.parallelism | Type: integer | Value: 12
  • Name: glide.ts.nibble_pause | Type: integer | Value: 5000

2) Create a data preserver so these properties will remain post clone.

3) In the source instance, modify the cleanup script that regenerates the text indexes to first reorder the text indexes to set the order of the TASK table to last.

  • Navigate to the System Clone > Clone Definition > Cleanup Scripts module.
  • Find the cleanup script named "Regenerate all text indexes" and open the form.
  • Modify the script as folllows:
var gr = new GlideRecord('ts_index_name');
gr.addQuery('table', 'task');
if ( {
gr.number = 999;

new GlideTextIndexEvent().indexAllNoPurge();

Additional Information

Warning: Setting the property glide.ts.index.parallelism over 12 has lead to memory issues, this property should not be change from the default 8 in a production instance.

Also, take a look at the following KB article on how to identify slow "lookup" variables that can contribute to slow text index regeneration for the task table:

KB0727199 - How to Identify Slow Lookup Variables in the Service Catalog

Article Information

Last Updated:2020-02-13 01:08:12