zoukankan      html  css  js  c++  java
  • mongoDB

    1. Run mongoDB in Windows,

    In command prompt, go to folder which include mongod.exe, then type: 

            mongod.exe --dbpath D:/mongoDB/db, and click enter.

    If you can see

    [initandlisten] MongoDB starting : pid=xxxx port=xxxxx dbpath=xxxxxxxx 32-bit.

    That means mongoDB is running now. Then open a new command prompt , and type mongo.exe, you should see:

    MongoDB shell version: x.x.x

    connecting to: test 

    MongoDB running successful. 

    2.  mongoDB closed unexpectedly,

      If mongoDB close unexpected, when you want to run it again, you will see message like:

      ************

       old lock file: D:/mongoDB/db/mongod.lock. probably means unclean shutdown recommend removing file and running --repair

      ************

      We can repair this problem as message write. Remove file mongod.lock from D:/mongoDB/ and D:/mongoDB/db/, then run

      mongod.exe --repair

      OK, problem resloved.

  • 相关阅读:
    HTTP协议
    django-两种方式对单表的操作
    模态框对话
    django
    web框架原理
    DNS详解
    jQuery
    初识web框架
    练习:简单主页搭建
    多表查询
  • 原文地址:https://www.cnblogs.com/jiajinyi/p/mongoDB.html
Copyright © 2011-2022 走看看