Help Center/ Data Replication Service/ Troubleshooting/ Solutions to Failed Check Items/ Database Parameters/ Checking Whether the Source Database Collections Contain TTL Indexes
Updated on 2024-09-25 GMT+08:00

Checking Whether the Source Database Collections Contain TTL Indexes

During MongoDB migration, due to inconsistency of time zones and clocks between source and destination databases, migrating TTL indexes will cause data inconsistency. DRS checks whether the source database contains collections with TTL indexes. If yes, delete the TTL indexes or do not migrate the collections with TTL indexes.

Item to Be Confirmed

If the objects to be migrated contain TTL indexes, due to inconsistency of time zones and clocks between source and destination databases, migrating TTL indexes will cause data inconsistency.

Handling Suggestion

If data consistency is required, delete TTL indexes. Alternatively, do not migrate the collections containing TTL indexes.

Run the following command to delete an index:

run the db.Collection name.dropIndex(Index name)