Install node.js
It’s easy to install node.js on Windows, just go to node.js official site and download Windows installer, then execute the installer. Congratulations!!! You successfully installed node.js on Windows!!!
Install mongoDB
Go to mongoDB official site to download zip file for Windows, and unzip the contents to anywhere you like. MongoDB will read data at \data\db
by default, but mongoDB won’t create this folder for us, so we must create it by ourself, you can create this folder in Windows Explorer, or type the following command in terminal:
C:\> mkdir \data
C:\> mkdir \data\db
After creating \data\db
, double click mongod.exe
in your_mongodb_path\bin
or type the following command in terminal to turn on mongoDB:
C:\> cd your_mongodb_path\bin
C:\> mongod
Then you can double click mongo.exe
or type the following command in terminal to get into administrative shell:
C:\> cd your_mongodb_path\bin
C:\> mongo
Congratulations!!! You’ve successfully installed node.js and mongoDB on Windows!!!
Update node.js
Go to node.js’s official site and download Windows installer, then execute the installer. Then your node.js is updated.
Update mongoDB
Go to mongoDB official site to download zip file for Windows, and use the files in new zip file, then you can start to use the latest mongoDB. If you have question about installng or using mongoDB, you can check the Windows Quick Start on mongoDB official site :)
Setup a node.js development environment on other OS
If you want to setup a node.js development environment on Mac OSX Lion or Ubuntu 11.04, you can take a look at:
How to setup a node.js development environment on Mac OSX Lion
How to setup a node.js development environment on Ubuntu 11.04.
npm commands and node.js basics
Now you have setup a clean node.js development environment. Let’s have a quick look at how to use npm and learn some basics of javascript and node.js.
Related posts