I\'m trying to import a large data file in JSON format . I\'m using
mongoimport --db verbs --collection de --file \"/Users/marcelbraasch/Downloads/de.json\"
I was struggling with the same issue, adding keyword --authenticationDatabase worked for me.
Found the answer here. This missing keyword was authenticationDatabase
. The command that worked for me was:
mongoimport --db verbs --collection de --authenticationDatabase admin --username user --password password --drop --file /Users/myname/Downloads/de.json
.