Unable to do mongodump or mongoexport from AWS DocumentDB instance

0

When i try to do mongodump, I am getting the below error: Failed: error creating intents to dump: error creating intents for database <db>: error counting <db>.<col>: Aggregation stage not supported: '$collStats'

According to https://docs.aws.amazon.com/documentdb/latest/developerguide/backup_restore-dump_restore_import_export_data.html - versions less than 100.6.1 should be fine, but still no success.

I downgraded both mongo and mongodump versions to the below ones: mongodump version: 100.4.0 mongod version v4.4.25

Gowtham
已提問 7 個月前檢視次數 364 次
1 個回答
-1

Kindly note that, the "$collStats" Stage Operator is not supported in any DocumentDB version currently. This is also mentioned in the document below[1].

[1] https://docs.aws.amazon.com/documentdb/latest/developerguide/mongo-apis.html#mongo-apis-aggregation-pipeline-stage

Having said that, currently there is no alternative for passing aggregated functions or combining outputs of two stages in aggregate query in DocDB. Please be aware, you will have to use separate queries and re-structure the same to mitigate this issue.

Going forward, you can keep an eye on AWS announcements [2], as all new releases in DocumentDB would be posted here.

[2] AWS updates: https://aws.amazon.com/about-aws/whats-new/2023/

AWS
支援工程師
Ruchi_P
已回答 7 個月前
  • Hi Ruchi, Issue is I am not able to do mongodump or mongoexport as per the guide I have linked in the question. I am not trying to use the $collStats operator, rather mongodump/mongoexport is throwing the said error.

您尚未登入。 登入 去張貼答案。

一個好的回答可以清楚地回答問題並提供建設性的意見回饋,同時有助於提問者的專業成長。

回答問題指南