# Calling Backend Services-Installing MongoDB

**URL:** <https://forum.codewithmosh.com/t/calling-backend-services-installing-mongodb/4550>\
**Category:** React\
**Created:** [April 30, 2021, 8:53pm UTC](https://forum.codewithmosh.com/t/calling-backend-services-installing-mongodb/4550 "2021-04-30T20:53:46Z")\
**Posts on this page:** 6\
**Page:** 1

<div class="post-metadata">

**Author:** ![a14743535](https://avatars.discourse-cdn.com/v4/letter/a/8c91f0/32.png) [@a14743535](https://forum.codewithmosh.com/u/a14743535)\
**Post date:** [April 30, 2021, 8:53pm UTC](https://forum.codewithmosh.com/t/calling-backend-services-installing-mongodb/4550/1 "2021-04-30T20:53:46Z")

</div>

Hello everyone, I’m having a hard time following through with React course from this lecture. Everything has changed dramatically. I have no idea how to continue with the rest of the course.  
I followed the way Mosh showed in the video to install mongoDB. However, I failed…  
Does anyone know how to successfully install mongoDB now?

---

<div class="post-metadata">

**Author:** ![sh2021](https://avatars.discourse-cdn.com/v4/letter/s/dc4da7/32.png) [@sh2021](https://forum.codewithmosh.com/u/sh2021)\
**Post date:** [May 20, 2021, 10:09am UTC](https://forum.codewithmosh.com/t/calling-backend-services-installing-mongodb/4550/2 "2021-05-20T10:09:00Z")

</div>

can you be more specific about your problem, if u really want some help?

---

<div class="post-metadata">

**Author:** ![elener](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.codewithmosh.com/elener/32/1756_2.png) [@elener](https://forum.codewithmosh.com/u/elener)\
**Post date:** [June 10, 2021, 11:38am UTC](https://forum.codewithmosh.com/t/calling-backend-services-installing-mongodb/4550/3 "2021-06-10T11:38:36Z")

</div>

Hi. I don’t know about your problem. But I will describe my situation.  
On Windows. After ``' **npm i** there was an _error_.  
I’ve found that **bcrypt** wasn’t installed. Probably cause my **Node.js** is version **14.15.5.** and bcrypt needs to be a compatible version with it. So I installed ````` **$ npm i bcrypt@5.0.0*`\* , then run** $ npm rebuild **and then** $ node index.js** again. And it is working now, however my Compas shows only “admin, config, local, vidly {genres, movies}”. So no “vidly-tests” nor “users”. Hope this helps 🙂  
EDIT: oh and I also didn’t have walker **$ npm i walker** , so I could run tests for the first time **$ npm test** and this will populate DB with what was missing.  
Don’t forget to **reload** your database 😉

---

<div class="post-metadata">

**Author:** ![UniqueNospaceShort](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.codewithmosh.com/uniquenospaceshort/32/1814_2.png) [@UniqueNospaceShort](https://forum.codewithmosh.com/u/UniqueNospaceShort)\
**Post date:** [June 24, 2021, 11:31am UTC](https://forum.codewithmosh.com/t/calling-backend-services-installing-mongodb/4550/4 "2021-06-24T11:31:32Z")

</div>

Should you follow the instructions on the GitHub repo (and also video).

You need to  
node seed.js  
and  
npm test

Those will create the DBs and collections (tables).

Also test fails alot because of authentication.

I found out the course had authentication enabled by default in the course and README.md of the repo, yet the config.json file actually disabled that option.  
For tests, enable authentication anew to make them pass.  
I don’t think this DB is anyhow useful. Moreover they are empty after the test.

Users collection is empty which is fine. You will create users later on. I was there a few hours ago.

---

<div class="post-metadata">

**Author:** ![UniqueNospaceShort](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.codewithmosh.com/uniquenospaceshort/32/1814_2.png) [@UniqueNospaceShort](https://forum.codewithmosh.com/u/UniqueNospaceShort)\
**Post date:** [June 24, 2021, 11:32am UTC](https://forum.codewithmosh.com/t/calling-backend-services-installing-mongodb/4550/5 "2021-06-24T11:32:41Z")

</div>

I had no specific problems related to MongoDB while installing the latest versions on Windows.

What platform ?  
What errors ?

---

<div class="post-metadata">

**Author:** ![avitlele](https://avatars.discourse-cdn.com/v4/letter/a/e19b73/32.png) [@avitlele](https://forum.codewithmosh.com/u/avitlele)\
**Post date:** [August 4, 2021, 9:13pm UTC](https://forum.codewithmosh.com/t/calling-backend-services-installing-mongodb/4550/6 "2021-08-04T21:13:52Z")

</div>

Elener, you’re right. The issue is because of the version of **bcrypt**. I got the same your problem and here were steps I fixed.

1. Open package.json and find **bcrypt** and change its version to **3.0.6** (My node version is 16.3.0). Save what you changed.
2. run npm rebuild
3. run npm i
4. No error 🙂
5. Good luck!!!
