Error importing data to my cluster

When im trying to import the data to my cluster i have this error

error parsing command line options: error parsing uri (mongodb+srv://m220student:m220password@cluster0-x38xe.mongodb.net): lookup cluster0-x38xe.mongodb.net on 127.0.0.53:53: cannot unmarshal DNS message
2019-04-13T17:52:12.949-0300 try ‘mongorestore --help’ for more information

i executed this line on this directory “mflix-java/mflix”
mongorestore --drop --gzip --uri mongodb+srv://m220student:m220password@cluster0-x38xe.mongodb.net data

Hello Leandro,

Try using
“mongorestore --drop --gzip --uri mongodb+srv//m220student:m220password@cluster0-x38xe.mongodb.net data”

Thanks,
Adit.

1 Like

didnt work neither. :frowning_face:

No don’t use the “”… Those were just to say copy this string…

Now, did you try replacing the cluster name in atlas to mflix as in step4 in readme file?

Try that and let me know.

1 Like

yes, i tried that too, but didnt work neither, im gonna try changing the name

paste the connect string after you have replaced the name.

I mean… What is the new connect string?

1 Like

Leandro… I am able to connect to your cluster and restore… You haven’t changed the cluster name…

use this…

mongorestore --drop --gzip --uri mongodb+srv://m220student:m220password@cluster0-x38xe.mongodb.net data

1 Like

Check if there is a data folder in mflix folder.

1 Like

Screenshot%20from%202019-04-13%2019-31-13 as you can see there is a data folder but still happening the same error

Sorry Leandro… I don’t know what “cannot unmarshal DNS message” means… Looks like a network issue…

I am able to connect to you cluster… Try connecting from a different internet connection…

Do you have any Starbucks close by… You should be able to connect from there.

1 Like

Hello Leandro. I have the same problem.
Look this is the right query:
mongorestore --drop --gzip --uri mongodb+srv://m220student:m220password@mflix-*****.mongodb.net data

And i have notebook with Ubuntu 18.04 just like you. But our query DO NOT work. I did it from Windows on my wife’s notebook and continue work on Ubuntu.

If you wanna we can load data for you. and you can start work on Ubuntu

1 Like

Guys any luck… Did you know why you got the network issue?

I have the same issue with Ubuntu 18.04

Mkkhail,

I have the same issue: could you please load the data for me? This would be much appreciated. This is my mongorestore command:

mongorestore --host Cluster0-shard-0/cluster0-shard-00-00-7x6u7.mongodb.net:27017,cluster0-shard-00-01-7x6u7.mongodb.net:27017,cluster0-shard-00-02-7x6u7.mongodb.net:27017 --ssl --username m220student --password m220password --authenticationDatabase admin

The regular connection string is:

mongodb+srv://m220student:m220password@cluster0-7x6u7.mongodb.net/test?retryWrites=true

I had a working database but then encountered some issues that I think are related to corrupted data, hence I tried restoring the data. I changed nothing from the setup that had worked before and used the mongorestore command I had succeeded previously.

Many thanks for any assistance

@Leandro_08545,

try this:

mongorestore --drop --gzip --uri "mongodb+srv://m220student:m220password@cluster0-x38xe.mongodb.net" data

Place quotes around your uri string value.

N.

I figured it out: got the restore command from the cluster (command line utilities) and prefaced it with --gzip.

Thanks for your earlier posts.