#Is this error because of mongoDB 3.2.21 or something other issue?

4 messages · Page 1 of 1 (latest)

round terrace
#

C:\Program Files\MongoDB\Server\3.2\bin>mongoimport --host cluster0.******.mong
odb.net --port 27017 --username gofood --password **** --authenticationData
base admin --db ******** --collection food_items --file C:\Users\xyz\Downl
oads\foodData2.json
2024-02-15T19:47:51.769+0530 [........................] gofoodmern.food_items
0B/6.12KB (0.0%)
2024-02-15T19:47:52.279+0530 [........................] gofoodmern.food_items
0B/6.12KB (0.0%)
2024-02-15T19:47:52.279+0530 Failed: error connecting to db server: no reacha
ble servers
2024-02-15T19:47:52.280+0530 imported 0 documents

round terrace
#

No mongodb experts here?

blissful beacon
#

I also found an article about the --host flag. Apparently you need to tell mongo that your machine is the host.

--host=127.0.0.1 seems to solve it in some cases. Other than that, I'm out of ideas. Hope you find what you need.