1.count统计结果错误 这是由于分布式集群正在迁移数据,它导致count结果值错误,需要使用aggregate pipeline来得到正确统计结果,例如: db.collection.aggregate([{$group: {_id: null, count: {$sum: 1}}}]) 引用:“On a sharded cluster, count can result in an inaccurate count if orphaned documents exist or if a c…