6

I am pretty new for MEAN and just went some round trip (half day install and uninstall MEAN and everything with it?) and do not want to do it again.

The MongoDB I installed on Windows8 is working and already built as a Windows Service. However, then I saw that there is a thing called npm install mongodb. I now do not know what should I do.

Is there a difference of using the default MongoDB installed already as a windows service vs running npm install mongodb?

What should I do if the MongoDB is meant for MEAN stack build up at this point, but I also wants it to open and maybe use for other purpose.

halfer
  • 19,824
  • 17
  • 99
  • 186
ey dee ey em
  • 7,991
  • 14
  • 65
  • 121

2 Answers2

8

When you execute npm install mongodb, it will install node module from npm.js. It is just a driver for node.js to connect to a mongo database, so that is not a database engine itself. For analogy, it's like PDO driver from PHP: if you have pdo_mysql, it doesn't mean you have MySQL Server installed.

garg10may
  • 5,794
  • 11
  • 50
  • 91
vanadium23
  • 3,516
  • 15
  • 27
0

Installing mongodb separately is the actual mongodb server. You run it via the mongod command. Installing mongo from npm installs the node.js driver for communicating with mongodb. It is node.js equivalent to when you run mongo command from the terminal after running the mongod instance.

Mustehssun Iqbal
  • 576
  • 3
  • 19