heberoxx 发表于 2018-10-26 14:08:13

mongodb 配置文件

  # mongod.conf
  # 追加模式写入log
  logpath=/var/log/mongodb/mongod.log
  logappend=true
  # 后台运行
  fork=true
  # 服务端口号
  port=27013
  # 数据库文件存放目录
  dbpath=/var/lib/mongo
  directoryperdb=true
  # 进程id文件的存放路径
  pidfilepath=/var/run/mongodb/mongod.pid
  # 监听IP地址
  bind_ip=0.0.0.0
  # Disables write-ahead journaling
  # nojournal=true
  # 启用定时记录CPU的利用率和I/O等待
  #cpu=true
  # Turn on/off security.Off is currently the default
  #noauth=true
  #auth=true
  # 详细记录输出
  #verbose=true
  # 用于开发驱动程序时的检查客户端接收数据的有效性
  #objcheck=true
  # 启用数据库配额管理,默认每个db可以有8个文件,可以用quotaFiles参数设置
  #quota=true
  #   设置oplog记录等级
  #   0=off (default)
  #   1=W
  #   2=R
  #   3=both
  #   7=W+some reads
  #diaglog=0
  # 忽略查询提示
  #nohints=true
  # Enable the HTTP interface (Defaults to port 28017).
  #httpinterface=true
  # 关闭服务器端脚本,这将极大的限制功能
  #noscripting=true
  # 关闭扫描表,任何查询将会是扫描失败
  #notablescan=true
  # 关闭数据文件预分配
  #noprealloc=true
  # 为新数据库指定.ns文件的大小,单位:MB
  # nssize=
  # Replication Options
  # in replicated mongo databases, specify the replica set name here
  #replSet=setname

  # maximum>  #oplogSize=1024
  # path to a key file storing authentication info for connections
  # between replica set members
  #keyFile=/path/to/keyfile

页: [1]
查看完整版本: mongodb 配置文件