Read Concern and Preferences

I am trying to drop the database and get the new one in but when I exit the mongo shell on my primary and run the command I get an error. This is what I get:

2018-10-29T08:35:57.822+0000 error validating settings: only one positional argument is allowed
2018-10-29T08:35:57.822+0000 try ‘mongoimport --help’ for more information

This is the command I am running:

vagrant@m103:~$ mongoimport --drop \ --host m103-repl/192.168.103.100:27002,192.168.103.100:27001,192.168.103.100:27003 \ -u “m103-admin” -p “m103-pass” --authenticationDatabase “admin” \ --db applicationData --collection products /dataset/products.json

What am I doing wrong? and what is meant about the one positional argument is allowed? Do I need to run this command on all three machines? Shouldn’t since I have the replication set up and running. if I write to the primary, won’t it replicate to the secondaries>?

The backslashes are not part of the command. They are used only when you enter a command on multiple lines to indicate that the command continues on the next line.

1 Like