Errmsg: "not authorized on video to execute command..."

Hello,

My first time in this forum, so please, forgive me for any sort of mistakes or misbehaviors…

I have been trying to load “loadReviewsDataset.js” in many different ways, and not being able to do so.

Please notice I am launching mongo shell from the same directory as the .js file is.

I have also tried launching mongo shell this way:

mongo "mongodb://cluster0-shard-00-00-jxeqq.mongodb.net:27017,cluster0-shard-00-01-jxeqq.mongodb.net:27017,cluster0-shard-00-02-jxeqq.mongodb.net:27017/video?replicaSet=Cluster0-shard-0" --authenticationDatabase admin --ssl --username m001-student --password m001-mongodb-basics loadReviewsDataset.js

and also this way:

mongo "mongodb://cluster0-shard-00-00-jxeqq.mongodb.net:27017,cluster0-shard-00-01-jxeqq.mongodb.net:27017,cluster0-shard-00-02-jxeqq.mongodb.net:27017/video?replicaSet=Cluster0-shard-0" --authenticationDatabase admin --ssl --username m001-student --password m001-mongodb-basics

and then, using load(“loadReviewsDataset.js”)

either way, I get this:

> `"errmsg" : "not authorized on video to execute command { drop: \"reviews\", lsid: { id: UUID(\"cc4ef687-fc12-4abc-805a-5d7c5fec1c21\") }, $clusterTime: { clusterTime: Timestamp(1575752857, 1), signature: { hash: BinData(0, A5E0108F9F59DB185E5C79F79F3FABC7D485B189), keyId: 6730992026675838977 } }, $db: \"video\" }",`

I noticed @jchakrad also got the same msg, but the issue hasn’t been fixed :frowning:

Can anyone help me?

Thank you :slight_smile:

Welcome @Mhirley_06993

You can’t load into the class cluster. I believe somewhere in the course it mentioned about creating your own Atlas Cluster and it is in your own private cluster that you’ll load this file into.

@Ramachandra_37567 knows more about this course so he’ll also be able to advise when he’s online.

Mhirley_06993
As 007_jb suggested you have to load that file into your own cluster
Class cluster is a read only DB
Your own Sandbox cluster is R/W
Did you setup your cluster?It would have been covered in your lectures.Please check our forum
You will get your own unique connect string once your setup is complete
Then you can load the data

Oh dear, I did not setup my own cluster, will do that.

Thank you so much for the prompt answer :nerd_face: