Perhaps I have a complete misunderstanding of how mongodump
is supposed to work, but I can't seem to get it to do anything besides returning a JavaScript execution failed: SyntaxError: Unexpected identifier
error.
Here's what I'm doing:
- Mongod is running
- I want to backup a database called "mydb"
- I'm inside the mongo shell
- I tried the command
mongodump --db mydb
and get the above error - I've tried both
mongodump
andmongoexport
, both have the same issue
What am I doing wrong here?