MongoDB Manual
  • 3.4 (current)
  • 3.2
  • 3.0
  • 2.6
  • 2.4
  • 2.2

  • Introduction
    • 数据库和集合
      • Views
      • 限制集
    • 文档
    • BSON 类型
    • Comparison/Sort Order
    • MongoDB Extended JSON
  • Installation
    • Install MongoDB Community Edition
      • Install on Linux
        • Install on Red Hat
        • Install on SUSE
        • Install on Amazon
        • Install on Ubuntu
        • Install on Debian
        • Install From Tarball
      • Install on OS X
      • Install on Windows
    • Install MongoDB Enterprise
      • Install on Linux
        • Install on Red Hat
        • Install on Ubuntu
        • Install on Debian
        • Install on SUSE
        • Install on Amazon
        • Install From Tarball
      • Install on OS X
      • Install on Windows
    • Verify Integrity of MongoDB Packages
  • mongo shell
    • 配置 mongo Shell
    • 获取``mongo`` Shell的帮助
    • Write Scripts for the mongo Shell
    • Data Types in the mongo Shell
    • mongo Shell Quick Reference
  • MongoDB CRUD 操作
    • 插入文档
    • 查询文档
      • 返回查询的映射字段
      • 查询值为Null或不存在的字段
      • 在 mongo 命令行里迭代游标
    • 更新文档
    • 删除文档
    • Bulk Write Operations
    • SQL到MongoDB映射表
    • Read Isolation (Read Concern)
    • Write Acknowlegement (Write Concern)
    • MongoDB CRUD 概念
      • 原子性和事务处理
      • 读隔离、一致性和时近性
      • 分布式查询
      • 分布式写操作
      • 执行两个阶段的提交
      • Linearizable Reads via findAndModify
      • 查询计划
      • Query Optimization
        • 评估当前操作的性能
        • 优化查询性能
        • 写操作性能
        • Explain Results
      • 分析查询性能
      • Tailable Cursors
  • 聚合
    • 聚合管道
      • 聚合管道的优化
      • 聚合管道的限制
      • 聚合管道和分片集合
      • Example with ZIP Code Data
      • Example with User Preference Data
    • 映射化简
      • Map-Reduce和分片集合
      • Map Reduce并发
      • Map-Reduce 例子
      • 对增量数据做Map-Reduce
      • 验证Map函数
      • 验证Reduce函数
    • 聚合指南
      • 聚合管道快速指南
      • Aggregation Commands
      • Aggregation Commands Comparison
      • Variables in Aggregation Expressions
      • SQL to Aggregation Mapping Chart
  • 文本索引
    • 文本检索
    • 文本检索操作符
    • 在聚合管道中使用文本搜索
    • 使用基本技术Rosette语义平台的文本索引
    • 文本搜索语言
  • 数据模型
    • 数据模型设计介绍
    • Document Validation
    • 数据建模理论
      • 数据模型设计
      • MongoDB特性和数据模型的关系
    • 数据模型例子与范式
      • 文档关系建模
        • 一对一关系建模:内嵌文档模型
        • 一对多关系建模: 内嵌文档模型
        • 一对多关系建模: 文档引用模式
      • 树结构建模
        • 树结构建模:父文档引用
        • 树结构建模: 子文档引用
        • 树结构建模: 祖先数组
        • 树结构建模: 物化路径
        • 树结构建模: 嵌套集合
      • 具体应用建模举例
        • 原子性事务建模
        • 关键词搜索建模
        • 货币数据建模
        • Model Time Data
    • Data Model Reference
      • Database References
  • Administration
    • 生产环境指南
    • Operations Checklist
    • Development Checklist
    • Performance
      • Database Profiler
        • 数据库 Profiler输出
      • Disable Transparent Huge Pages (THP)
      • UNIX系统下 ulimit 的设置
    • Configuration and Maintenance
      • Run-time Database Configuration
      • Upgrade to the Latest Revision of MongoDB
      • 管理 mongod 进程
      • Terminate Running Operations
      • Rotate Log Files
    • 数据中心意识
      • MongoDB部署中的分离操作
      • 区域
        • Manage Shard Zones
        • Segmenting Data by Location
        • Tiered Hardware for Varying SLA or SLO
        • Segmenting Data by Application or Customer
        • Distributed Local Writes for Insert Only Workloads
      • Manage Shard Zones
    • MongoDB备份方案
      • Back Up and Restore with Filesystem Snapshots
      • Back Up and Restore with MongoDB Tools
      • Restore a Replica Set from MongoDB Backups
      • 备份和恢复集群
        • Back Up a Sharded Cluster with File System Snapshots
        • Back Up a Sharded Cluster with Database Dumps
        • 集群的备份时间安排
        • 恢复集群
      • Recover a Standalone after an Unexpected Shutdown
    • MongoDB监控
      • Monitor MongoDB With SNMP on Linux
      • Monitor MongoDB Windows with SNMP
      • Troubleshoot SNMP
  • Indexes
    • 单键索引
    • 复合索引
    • 多键索引
      • Multikey Index Bounds
    • 文本索引
      • 指定文本索引的语言
      • 为 文本 索引指定名称
      • 通过权重控制搜索结果
      • 限制被扫描项的数量
    • 2dsphere 索引
      • Find Restaurants with Geospatial Queries
      • 查询 2dsphere 索引
      • GeoJSON Objects
    • 2d 索引
      • 创建一个 2d 索引
      • 查询 2d 索引
      • 2d 索引原理
      • 使用球面几何计算距离
    • Hashed Indexes
    • 索引属性
      • TTL索引
        • 通过设置TTL使集合中的数据过期
      • 唯一索引
      • Partial Indexes
      • Case Insensitive Indexes
      • 稀疏索引
    • Index Build
      • 在复制集上创建索引
    • 索引交集
    • Manage Indexes
    • 衡量索引的使用情况
    • 索引策略
      • 创建索引以支持查询
      • 使用索引来排序查询结果
      • 确保索引与内存相适应
      • 创建能确保选择力的查询
    • 索引参考
  • 存储
    • Storage Engines
      • WiredTiger Storage Engine
        • 将单机模式下的 MongoDB 存储引擎切换到WiredTiger
        • 将复制集模式下的 MongoDB 存储引擎切换到 WiredTiger
        • Change Sharded Cluster to WiredTiger
          • Change Config Servers to WiredTiger
      • MMAPv1 Storage Engine
      • 内存存储引擎
    • Journaling
      • Manage Journaling
    • GridFS
    • FAQ: MongoDB存储
  • 安全
    • Security Checklist
    • 认证
      • Users
        • Add Users
      • Authentication Mechanisms
        • SCRAM-SHA-1
        • MONGODB-CR
        • x.509
          • Use x.509 Certificates to Authenticate Clients
      • Enterprise Authentication Mechanisms
        • Kerberos Authentication
          • Configure MongoDB with Kerberos Authentication on Linux
          • Configure MongoDB with Kerberos Authentication on Windows
          • Troubleshoot Kerberos Authentication
          • Configure MongoDB with Kerberos Authentication and Active Directory Authorization
        • LDAP Proxy Authentication
          • Authenticate Using SASL and LDAP with ActiveDirectory
          • Authenticate Using SASL and LDAP with OpenLDAP
          • Authenticate and Authorize Users Using Active Directory via Native LDAP
        • LDAP Authorization
      • Internal Authentication
        • Enforce Keyfile Access Control in a Replica Set
        • Enforce Keyfile Access Control in a Replica Set without Downtime
        • 使用Keyfile存取控制部署复制集
        • Enforce Keyfile Access Control in Sharded Cluster
        • Deploy Sharded Cluster with Keyfile Access Control
        • Use x.509 Certificate for Membership Authentication
        • Upgrade from Keyfile Authentication to x.509 Authentication
    • Enable Auth
      • Manage Users and Roles
      • Change Your Password and Custom Data
    • Role-Based Access Control
      • Built-In Roles
      • User-Defined Roles
      • 集合层访问控制
    • Encryption
      • Transport Encryption
        • Configure mongod and mongos for TLS/SSL
        • TLS/SSL Configuration for Clients
        • Upgrade a Cluster to Use TLS/SSL
        • Configure MongoDB for FIPS
      • Encryption at Rest
        • Configure Encryption
        • Rotate Encryption Keys
    • Auditing
      • Configure Auditing
      • Configure Audit Filters
    • Security Hardening
      • MongoDB Configuration Hardening
      • Hardening Network Infrastructure
        • Configure Linux iptables Firewall for MongoDB
        • Configure Windows netsh Firewall for MongoDB
    • Implement Field Level Redaction
    • 安全参考文献
      • 内置角色
      • system.roles Collection
      • system.users集合
      • Resource Document
      • Privilege Actions
      • 系统事件审计信息
    • Create a Vulnerability Report
  • 复制
    • 复制集成员
      • 复制集主节点
      • 复制集从节点
        • 优先级为0的复制集成员
        • 隐藏节点
        • 延时节点
      • 投票节点
    • 复制集Oplog
    • 复制集的数据同步
    • 复制集架构
      • 三个节点的复制集
      • Replica Sets Distributed Across Two or More Data Centers
    • 复制集的高可用
      • 复制集选举
      • 故障切换时的回滚
    • 主从复制
    • 复制集的读与写
      • 复制集的安全写级别
      • 复制集读选项
      • Server Selection Algorithm
    • 复制集指南
      • 复制集部署指南
        • 部署复制集
        • 部署一个用于测试和开发的复制集
        • 异地分布式复制集的部署
        • 为复制集添加投票节点
        • 将单节点转为复制集
        • 为复制集新增节点
        • 移除复制集的节点
        • 更换复制集节点
      • 节点配置指南
        • 修改复制集节点的优先级
        • 禁止从节点升职为主节点
        • 配置一个隐藏节点
        • 配置一个延时复制节点
        • 配置一个不参与投票的节点
        • 将从节点转换为投票节点
      • 复制集维护教程
        • 修改Oplog大小
        • 对复制集节点进行维护
        • 强制指定某个节点为主节点
        • 复制集成员的重新同步
        • 配置复制集标签设置
        • 为有不可用节点的复制集重设复制集配置
        • 管理链式复制
        • 为复制集节点修改主机名
        • 配置从节点的同步来源
      • 复制集故障排除
    • 复制集参考
      • Replica Set Configuration
      • The local Database
      • Replica Set Member States
      • Read Preference Reference
  • 分片
    • 集群组件
      • 分片
      • Config Servers (metadata)
      • Router (mongos)
    • 片键
    • Hashed Sharding
      • Deploy Sharded Cluster using Hashed Sharding
    • Ranged Sharding
      • Deploy Sharded Cluster using Ranged Sharding
    • 区域
      • Manage Shard Zones
      • Segmenting Data by Location
      • Tiered Hardware for Varying SLA or SLO
      • Segmenting Data by Application or Customer
      • Distributed Local Writes for Insert Only Workloads
    • Administration
      • Data Partitioning with Chunks
        • 在集群中创建数据块
        • 在集群中分裂数据块
        • 在集群中合并数据块
        • 修改集群中数据块的大小
      • Config Server Administration
        • Replace a Config Server
        • Upgrade Config Servers to Replica Set
        • Upgrade Config Servers to Replica Set (Downtime)
      • Balancer Administration
        • 管理集群均衡过程
        • 在集群中迁移数据块
      • 查看集群配置
      • 迁移集群到新的硬件系统中
      • 向集群中添加分片
      • 从集群中删除分片
      • Clear jumbo Flag
      • Back Up Cluster Metadata
      • 将一个集群转化为复制集
      • Convert a Replica Set to a Sharded Cluster
    • 分片参考文献
      • Operational Restrictions
      • 排除集群故障
      • Config Database
  • 常见问题
    • FAQ: MongoDB基础知识
    • FAQ:索引
    • FAQ: 并发
    • FAQ:MongoDB 分片
    • FAQ:复制和复制集
    • FAQ: MongoDB存储
    • FAQ:MogoDB 诊断
  • Reference
    • Operators
      • Query and Projection Operators
        • Comparison Query Operators
          • $eq
          • $gt
          • $gte
          • $lt
          • $lte
          • $ne
          • $in
          • $nin
        • Logical Query Operators
          • $or
          • $and
          • $not
          • $nor
        • Element Query Operators
          • $exists
          • $type
        • Evaluation Query Operators
          • $mod
          • $regex
          • $text
          • $where
        • Geospatial Query Operators
          • $geoWithin
          • $geoIntersects
          • $near
          • $nearSphere
          • $geometry
          • $minDistance
          • $maxDistance
          • $center
          • $centerSphere
          • $box
          • $polygon
          • $uniqueDocs
        • Query Operator Array
          • $all
          • $elemMatch (query)
          • $size
        • Bitwise Query Operators
          • $bitsAllSet
          • $bitsAnySet
          • $bitsAllClear
          • $bitsAnyClear
        • $comment
        • Projection Operators
          • $ (projection)
          • $elemMatch (projection)
          • $meta
          • $slice (projection)
      • Update Operators
        • Field Update Operators
          • $inc
          • $mul
          • $rename
          • $setOnInsert
          • $set
          • $unset
          • $min
          • $max
          • $currentDate
        • Array Update Operators
          • $ (update)
          • $addToSet
          • $pop
          • $pullAll
          • $pull
          • $pushAll
          • $push
          • $each
          • $slice
          • $sort
          • $position
        • Bitwise Update Operator
          • $bit
        • Isolation Update Operator
          • $isolated
      • Aggregation Pipeline Operators
        • Pipeline Aggregation Stages
          • $collStats (aggregation)
          • $project (aggregation)
          • $match (aggregation)
          • $redact (aggregation)
          • $limit (aggregation)
          • $skip (aggregation)
          • $unwind (aggregation)
          • $group (aggregation)
          • $sample (aggregation)
          • $sort (aggregation)
          • $geoNear (aggregation)
          • $lookup (aggregation)
          • $out (aggregation)
          • $indexStats (aggregation)
          • $facet (aggregation)
          • $bucket (aggregation)
          • $bucketAuto (aggregation)
          • $sortByCount (aggregation)
          • $addFields (aggregation)
          • $replaceRoot (aggregation)
          • $count (aggregation)
          • $graphLookup (aggregation)
        • Boolean Aggregation Operators
          • $and (aggregation)
          • $or (aggregation)
          • $not (aggregation)
        • Set Operators (Aggregation)
          • $setEquals (aggregation)
          • $setIntersection (aggregation)
          • $setUnion (aggregation)
          • $setDifference (aggregation)
          • $setIsSubset (aggregation)
          • $anyElementTrue (aggregation)
          • $allElementsTrue (aggregation)
        • Comparison Aggregation Operators
          • $cmp (aggregation)
          • $eq (aggregation)
          • $gt (aggregation)
          • $gte (aggregation)
          • $lt (aggregation)
          • $lte (aggregation)
          • $ne (aggregation)
        • Arithmetic Aggregation Operators
          • $abs (aggregation)
          • $add (aggregation)
          • $ceil (aggregation)
          • $divide (aggregation)
          • $exp (aggregation)
          • $floor (aggregation)
          • $ln (aggregation)
          • $log (aggregation)
          • $log10 (aggregation)
          • $mod (aggregation)
          • $multiply (aggregation)
          • $pow (aggregation)
          • $sqrt (aggregation)
          • $subtract (aggregation)
          • $trunc (aggregation)
        • String Aggregation Operators
          • $concat (aggregation)
          • $indexOfBytes (aggregation)
          • $indexOfCP (aggregation)
          • $split (aggregation)
          • $strcasecmp (aggregation)
          • $strLenBytes (aggregation)
          • $strLenCP (aggregation)
          • $strcasecmp (aggregation)
          • $substr (aggregation)
          • $substrBytes (aggregation)
          • $substrCP (aggregation)
          • $toLower (aggregation)
          • $toUpper (aggregation)
        • Text Search Aggregation Operators
          • $meta (aggregation)
        • Array Aggregation Operators
          • $arrayElemAt (aggregation)
          • $concatArrays (aggregation)
          • $filter (aggregation)
          • $indexOfArray (aggregation)
          • $isArray (aggregation)
          • $range (aggregation)
          • $reverseArray (aggregation)
          • $reduce (aggregation)
          • $size (aggregation)
          • $slice (aggregation)
          • $zip (aggregation)
          • $in (aggregation)
        • Aggregation Variable Operators
          • $map (aggregation)
          • $let (aggregation)
        • Aggregation Literal Operators
          • $literal (aggregation)
        • Date Aggregation Operators
          • $dayOfYear (aggregation)
          • $dayOfMonth (aggregation)
          • $dayOfWeek (aggregation)
          • $year (aggregation)
          • $month (aggregation)
          • $week (aggregation)
          • $hour (aggregation)
          • $minute (aggregation)
          • $second (aggregation)
          • $millisecond (aggregation)
          • $dateToString (aggregation)
          • $isoDayOfWeek (aggregation)
          • $isoWeek (aggregation)
          • $isoWeekYear (aggregation)
        • Conditional Aggregation Operators
          • $cond (aggregation)
          • $ifNull (aggregation)
          • $switch (aggregation)
        • Data Type Aggregation Operators
          • $type (aggregation)
        • Group Accumulator Operators
          • $sum (aggregation)
          • $avg (aggregation)
          • $first (aggregation)
          • $last (aggregation)
          • $max (aggregation)
          • $min (aggregation)
          • $push (aggregation)
          • $addToSet (aggregation)
          • $stdDevPop (aggregation)
          • $stdDevSamp (aggregation)
      • Query Modifiers
        • $comment
        • $explain
        • $hint
        • $maxScan
        • $maxTimeMS
        • $max
        • $min
        • $orderby
        • $returnKey
        • $showDiskLoc
        • $snapshot
        • $query
        • $natural
    • Database Commands
      • Aggregation Commands
        • aggregate
        • count
        • distinct
        • group
        • mapReduce
      • Geospatial Commands
        • geoNear
        • geoSearch
      • Query and Write Operation Commands
        • find
        • insert
        • update
        • delete
        • findAndModify
        • getMore
        • getLastError
        • getPrevError
        • resetError
        • eval
        • parallelCollectionScan
      • Query Plan Cache Commands
        • planCacheListFilters
        • planCacheSetFilter
        • planCacheClearFilters
        • planCacheListQueryShapes
        • planCacheListPlans
        • planCacheClear
      • Authentication Commands
        • logout
        • authenticate
        • copydbgetnonce
        • getnonce
        • authSchemaUpgrade
      • User Management Commands
        • createUser
        • updateUser
        • dropUser
        • dropAllUsersFromDatabase
        • grantRolesToUser
        • revokeRolesFromUser
        • usersInfo
      • Role Management Commands
        • createRole
        • updateRole
        • dropRole
        • dropAllRolesFromDatabase
        • grantPrivilegesToRole
        • revokePrivilegesFromRole
        • grantRolesToRole
        • revokeRolesFromRole
        • rolesInfo
        • invalidateUserCache
      • Replication Commands
        • replSetFreeze
        • replSetGetStatus
        • replSetInitiate
        • replSetMaintenance
        • replSetReconfig
        • replSetStepDown
        • replSetSyncFrom
        • resync
        • applyOps
        • isMaster
        • replSetGetConfig
      • 分片命令
        • flushRouterConfig
        • addShard
        • balancerStart
        • balancerStatus
        • balancerStop
        • cleanupOrphaned
        • checkShardingIndex
        • enableSharding
        • listShards
        • removeShard
        • getShardMap
        • getShardVersion
        • mergeChunks
        • setShardVersion
        • 分片集合
        • 分片状态
        • unsetSharding
        • split
        • splitChunk
        • splitVector
        • medianKey
        • moveChunk
        • movePrimary
        • isdbgrid
        • addShardToZone
        • removeShardFromZone
        • updateZoneKeyRange
      • Administration Commands
        • renameCollection
        • copydb
        • dropDatabase
        • listCollections
        • drop
        • create
        • clone
        • cloneCollection
        • cloneCollectionAsCapped
        • convertToCapped
        • filemd5
        • createIndexes
        • listIndexes
        • dropIndexes
        • fsync
        • clean
        • connPoolSync
        • connectionStatus
        • compact
        • collMod
        • reIndex
        • setParameter
        • getParameter
        • repairDatabase
        • repairCursor
        • touch
        • shutdown
        • logRotate
        • killOp
        • setFeatureCompatibilityVersion
      • Diagnostic Commands
        • availableQueryOptions
        • buildInfo
        • collStats
        • connPoolStats
        • cursorInfo
        • dataSize
        • dbHash
        • dbStats
        • diagLogging
        • driverOIDTest
        • explain
        • features
        • getCmdLineOpts
        • getLog
        • hostInfo
        • isSelf
        • listCommands
        • listDatabases
        • netstat
        • ping
        • profile
        • serverStatus
        • 集群连接池状态
        • top
        • validate
        • whatsmyuri
      • Internal Commands
        • handshake
        • recvChunkAbort
        • recvChunkCommit
        • recvChunkStart
        • recvChunkStatus
        • replSetFresh
        • mapreduce.shardedfinish
        • transferMods
        • replSetHeartbeat
        • replSetGetRBID
        • migrateClone
        • replSetElect
        • writeBacksQueued
        • writebacklisten
      • System Events Auditing Commands
        • logApplicationMessage
    • mongo Shell Methods
      • Collection Methods
        • db.collection.aggregate()
        • db.collection.bulkWrite()
        • db.collection.count()
        • db.collection.copyTo()
        • db.collection.createIndex()
        • db.collection.dataSize()
        • db.collection.deleteOne()
        • db.collection.deleteMany()
        • db.collection.distinct()
        • db.collection.drop()
        • db.collection.dropIndex()
        • db.collection.dropIndexes()
        • db.collection.ensureIndex()
        • db.collection.explain()
        • db.collection.find()
        • db.collection.findAndModify()
        • db.collection.findOne()
        • db.collection.findOneAndDelete()
        • db.collection.findOneAndReplace()
        • db.collection.findOneAndUpdate()
        • db.collection.getIndexes()
        • db.collection.getShardDistribution()
        • db.collection.getShardVersion()
        • db.collection.group()
        • db.collection.insert()
        • db.collection.insertOne()
        • db.collection.insertMany()
        • db.collection.isCapped()
        • db.collection.latencyStats()
        • db.collection.mapReduce()
        • db.collection.reIndex()
        • db.collection.replaceOne()
        • db.collection.remove()
        • db.collection.renameCollection()
        • db.collection.save()
        • db.collection.stats()
        • db.collection.storageSize()
        • db.collection.totalSize()
        • db.collection.totalIndexSize()
        • db.collection.update()
        • db.collection.updateOne()
        • db.collection.updateMany()
        • db.collection.validate()
      • Cursor Methods
        • cursor.addOption()
        • cursor.batchSize()
        • cursor.close()
        • cursor.collation()
        • cursor.comment()
        • cursor.count()
        • cursor.explain()
        • cursor.forEach()
        • cursor.hasNext()
        • cursor.hint()
        • cursor.itcount()
        • cursor.limit()
        • cursor.map()
        • cursor.maxScan()
        • cursor.maxTimeMS()
        • cursor.max()
        • cursor.min()
        • cursor.next()
        • cursor.noCursorTimeout()
        • cursor.objsLeftInBatch()
        • cursor.pretty()
        • cursor.readConcern()
        • cursor.readPref()
        • cursor.returnKey()
        • cursor.showRecordId()
        • cursor.size()
        • cursor.skip()
        • cursor.snapshot()
        • cursor.sort()
        • cursor.tailable()
        • cursor.toArray()
      • 数据库相关方法
        • db.cloneCollection()
        • db.cloneDatabase()
        • db.commandHelp()
        • db.copyDatabase()
        • db.createCollection()
        • db.createView()
        • db.currentOp()
        • db.dropDatabase()
        • db.eval()
        • db.fsyncLock()
        • db.fsyncUnlock()
        • db.getCollection()
        • db.getCollectionInfos()
        • db.getCollectionNames()
        • db.getLastError()
        • db.getLastErrorObj()
        • db.getLogComponents()
        • db.getMongo()
        • db.getName()
        • db.getPrevError()
        • db.getProfilingLevel()
        • db.getProfilingStatus()
        • db.getReplicationInfo()
        • db.getSiblingDB()
        • db.help()
        • db.hostInfo()
        • db.isMaster()
        • db.killOp()
        • db.listCommands()
        • db.loadServerScripts()
        • db.logout()
        • db.printCollectionStats()
        • db.printReplicationInfo()
        • db.printShardingStatus()
        • db.printSlaveReplicationInfo()
        • db.repairDatabase()
        • db.resetError()
        • db.runCommand()
        • db.serverBuildInfo()
        • db.serverCmdLineOpts()
        • db.serverStatus()
        • db.setLogLevel()
        • db.setProfilingLevel()
        • db.shutdownServer()
        • db.stats()
        • db.version()
        • db.upgradeCheck()
        • db.upgradeCheckAllDBs()
      • Query Plan Cache Methods
        • db.collection.getPlanCache()
        • PlanCache.help()
        • PlanCache.listQueryShapes()
        • PlanCache.getPlansByQuery()
        • PlanCache.clearPlansByQuery()
        • PlanCache.clear()
      • Bulk Operation Methods
        • Bulk()
        • db.collection.initializeOrderedBulkOp()
        • db.collection.initializeUnorderedBulkOp()
        • Bulk.insert()
        • Bulk.find()
        • Bulk.find.collation()
        • Bulk.find.removeOne()
        • Bulk.find.remove()
        • Bulk.find.replaceOne()
        • Bulk.find.updateOne()
        • Bulk.find.update()
        • Bulk.find.upsert()
        • Bulk.execute()
        • Bulk.getOperations()
        • Bulk.tojson()
        • Bulk.toString()
      • User Management Methods
        • db.auth()
        • db.createUser()
        • db.updateUser()
        • db.changeUserPassword()
        • db.removeUser()
        • db.dropAllUsers()
        • db.dropUser()
        • db.grantRolesToUser()
        • db.revokeRolesFromUser()
        • db.getUser()
        • db.getUsers()
      • Role Management Methods
        • db.createRole()
        • db.updateRole()
        • db.dropRole()
        • db.dropAllRoles()
        • db.grantPrivilegesToRole()
        • db.revokePrivilegesFromRole()
        • db.grantRolesToRole()
        • db.revokeRolesFromRole()
        • db.getRole()
        • db.getRoles()
      • Replication Methods
        • rs.add()
        • rs.addArb()
        • rs.conf()
        • rs.freeze()
        • rs.help()
        • rs.initiate()
        • rs.printReplicationInfo()
        • rs.printSlaveReplicationInfo()
        • rs.reconfig()
        • rs.remove()
        • rs.slaveOk()
        • rs.status()
        • rs.stepDown()
        • rs.syncFrom()
      • 分片方法
        • sh._adminCommand()
        • sh.getBalancerLockDetails()
        • sh._checkFullName()
        • sh._checkMongos()
        • sh._lastMigration()
        • sh.addShard()
        • sh.addShardTag()
        • sh.addShardToZone()
        • sh.addTagRange()
        • sh.updateZoneKeyRange()
        • sh.removeTagRange()
        • sh.removeRangeFromZone()
        • sh.disableBalancing()
        • sh.enableBalancing()
        • sh.enableSharding()
        • sh.getBalancerHost()
        • sh.getBalancerState()
        • sh.help()
        • sh.isBalancerRunning()
        • sh.moveChunk()
        • sh.removeShardTag()
        • sh.removeShardFromZone()
        • sh.setBalancerState()
        • sh.shardCollection()
        • sh.splitAt()
        • sh.splitFind()
        • sh.startBalancer()
        • sh.status()
        • sh.stopBalancer()
        • sh.waitForBalancer()
        • sh.waitForBalancerOff()
        • sh.waitForDLock()
        • sh.waitForPingChange()
      • Subprocess Methods
        • clearRawMongoProgramOutput()
        • rawMongoProgramOutput()
        • run()
        • runMongoProgram()
        • runProgram()
        • startMongoProgram()
        • stopMongoProgram()
        • stopMongoProgramByPid()
        • stopMongod()
        • waitMongoProgramOnPort()
        • waitProgram()
      • Object Constructors and Methods
        • Date()
        • UUID()
        • ObjectId
        • ObjectId.getTimestamp()
        • ObjectId.toString()
        • ObjectId.valueOf()
        • WriteResult()
        • WriteResult.hasWriteError()
        • WriteResult.hasWriteConcernError()
        • BulkWriteResult()
      • Connection Methods
        • Mongo.getDB()
        • Mongo.getReadPrefMode()
        • Mongo.getReadPrefTagSet()
        • Mongo.setReadPref()
        • Mongo.setSlaveOk()
        • Mongo()
        • connect()
      • Native Methods
        • cat()
        • version()
        • cd()
        • sleep()
        • copyDbpath()
        • resetDbpath()
        • fuzzFile()
        • getHostName()
        • getMemInfo()
        • hostname()
        • _isWindows()
        • listFiles()
        • load()
        • ls()
        • md5sumFile()
        • mkdir()
        • pwd()
        • quit()
        • _rand()
        • removeFile()
        • setVerboseShell()
        • _srand()
    • MongoDB Package Components
      • mongod
      • mongos
      • mongo
      • mongod.exe
      • mongos.exe
      • mongodump
      • mongorestore
      • bsondump
      • mongooplog
      • mongoimport
      • mongoexport
      • mongostat
      • mongotop
      • mongoperf
      • mongoreplay
      • mongoldap
      • mongofiles
    • 配置文件选项
    • MongoDB Server Parameters
    • MongoDB Limits and Thresholds
    • Explain Results
    • 系统集合
    • Connection String URI Format
    • Collation
      • Collation Locales and Default Parameters
    • MongoDB Wire Protocol
    • Log Messages
    • Exit Codes and Statuses
    • Glossary
    • MongoDB 默认端口
  • 发布笔记
    • MongoDB 3.4 发布笔记
      • MongoDB 3.4 中的兼容性变化
      • 升级单机到 3.4
      • 升级复制集到 3.4
      • 升级分片集群到 3.4
      • 降级 MongoDB 3.4 到 3.2
        • 降级 3.4 单机 到 3.2
        • 降级MongoDB 3.4 复制集到 3.2
        • 降级 3.4 分片集群到 3.2
    • Release Notes for MongoDB 3.2
      • 3.2 Changelog
      • Compatibility Changes in MongoDB 3.2
        • JavaScript Changes in MongoDB 3.2
      • 将MongoDB升级到3.2
      • Downgrade MongoDB from 3.2
    • MongoDB 3.0 发布笔记
      • 3.0 Changelog
      • Compatibility Changes in MongoDB 3.0
      • 将MongoDB升级到3.0
      • Upgrade to SCRAM-SHA-1
      • Downgrade MongoDB from 3.0
    • MongoDB 2.6 发布笔记
      • 2.6 Changelog
      • Compatibility Changes in MongoDB 2.6
      • Upgrade MongoDB to 2.6
      • Upgrade User Authorization Data to 2.6 Format
      • Downgrade MongoDB from 2.6
    • Release Notes for MongoDB 2.4
      • 2.4 Changelog
      • JavaScript Changes in MongoDB 2.4
      • 将MongoDB升级到2.4
      • Compatibility and Index Type Changes in MongoDB 2.4
    • Release Notes for MongoDB 2.2
    • Release Notes for MongoDB 2.0
    • MongoDB 1.8 发布笔记
    • MongoDB 1.6发布笔记
    • MongoDB 1.4发布笔记
    • MongoDB 1.2.x发布笔记
  • Documentation

  • 中文社区首页
  • 博客
  • 讨论区
  • Try it Out
  • Drivers
  • Server
  • Drivers

Try It Now

  • MongoDB 3.2
  • Download Center
  • Cloud Manager
  • Ops Manager
  • Compass
  • BI Connector
  • Documentation

  • 中文社区首页
  • 博客
  • 讨论区
  • Try it Out
  • Drivers
  • Server
  • Drivers

Try It Now

  • MongoDB 3.2
  • Download Center
  • Cloud Manager
  • Ops Manager
  • Compass
  • BI Connector
翻译或纠错本页面

MongoDB 2.0中的修改¶

  • Release Notes for MongoDB 2.0
    • 升级
      • Preparation
      • Upgrading a Standalone mongod
      • Upgrading a Replica Set
      • Upgrading a Sharded Cluster
    • Changes
      • Compact Command
      • Concurrency Improvements
      • Default Stack Size
      • Index Performance Enhancements
      • Sharding Authentication
      • Replica Sets
        • Hidden Nodes in Sharded Clusters
        • Priorities
        • Data-Center Awareness
        • w : majority
        • Reconfiguration with a Minority Up
        • Primary Checks for a Caught up Secondary before Stepping Down
        • Extended Shutdown on the Primary to Minimize Interruption
        • Maintenance Mode
      • Geospatial Features
        • Multi-Location Documents
        • Polygon searches
      • Journaling Enhancements
      • New ContinueOnError Option for Bulk Insert
      • Map Reduce
        • Output to a Sharded Collection
        • Performance Improvements
      • New Querying Features
        • Additional regex options: s
        • $and
      • Command Output Changes
      • Shell Features
        • Custom Prompt
        • Default Shell Init Script
      • Most Commands Require Authentication
    • Resources

© MongoDB, Inc 2008-2017. MongoDB, Mongo, and the leaf logo are registered trademarks of MongoDB, Inc.

Report a Problem