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
preguntada hace 7 meses366 visualizaciones
1 Respuesta
-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
INGENIERO DE SOPORTE
Ruchi_P
respondido hace 7 meses
  • 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.

No has iniciado sesión. Iniciar sesión para publicar una respuesta.

Una buena respuesta responde claramente a la pregunta, proporciona comentarios constructivos y fomenta el crecimiento profesional en la persona que hace la pregunta.

Pautas para responder preguntas