============================= Release Notes for MongoDB 2.4 ============================= *March 19, 2013* .. default-domain:: mongodb .. contents:: On this page :local: :backlinks: none :depth: 1 :class: singlecol MongoDB 2.4 includes enhanced geospatial support, switch to V8 JavaScript engine, security enhancements, and text search (beta) and hashed index. Minor Releases -------------- .. class:: hidden .. toctree:: /release-notes/2.4-changelog 2.4.14 -- April 28, 2015 ~~~~~~~~~~~~~~~~~~~~~~~~ - Init script sets process ulimit to different value compared to documentation :issue:`SERVER-17780` - Compute BinData length in v8 :issue:`SERVER-17647` - Upgrade PCRE Version from 8.30 to Latest :issue:`SERVER-17252` - :ref:`2.4.14 Changelog <2.4.14-changelog>`. - `All 2.4.14 improvements `_. 2.4.13 -- February 25, 2015 ~~~~~~~~~~~~~~~~~~~~~~~~~~~ - Enforce BSON BinData length validation :issue:`SERVER-17278` - Disable SSLv3 ciphers :issue:`SERVER-15673` - Improve BSON validation :issue:`SERVER-17264` - :ref:`2.4.13 Changelog <2.4.13-changelog>`. - `All 2.4.13 improvements `_. 2.4.12 -- October 16, 2014 ~~~~~~~~~~~~~~~~~~~~~~~~~~ - Partially written journal last section causes recovery to fail :issue:`SERVER-15111`. - Explicitly zero ``.ns`` files on creation :issue:`SERVER-15369`. - :ref:`2.4.12 Changelog <2.4.12-changelog>`. - `All 2.4.12 improvements `_. 2.4.11 -- August 18, 2014 ~~~~~~~~~~~~~~~~~~~~~~~~~ - Fixed potential information leak: :issue:`SERVER-14268`. - Resolved issue were an ``_id`` with a ``$prefix`` field caused replication failure due to unvalidated insert :issue:`SERVER-12209`. - Addressed issue where updates to documents with text-indexed fields could lead to incorrect entries :issue:`SERVER-14738`. - Resolved issue where creating descending index on ``_id`` could corrupt namespace :issue:`SERVER-14833`. - :ref:`2.4.11 Changelog <2.4.11-changelog>`. - `All 2.4.11 improvements `_. 2.4.10 -- April 4, 2014 ~~~~~~~~~~~~~~~~~~~~~~~ - Performs fast file allocation on Windows when available :issue:`SERVER-8480`. - Start elections if more than one primary is detected :issue:`SERVER-10793`. - Changes to allow safe downgrading from v2.6 to v2.4 :issue:`SERVER-12914`, :issue:`SERVER-12175`. - Fixes for edge cases in index creation :issue:`SERVER-12481`, :issue:`SERVER-12956`. - :ref:`2.4.10 Changelog <2.4.10-changelog>`. - `All 2.4.10 improvements `_. 2.4.9 -- January 10, 2014 ~~~~~~~~~~~~~~~~~~~~~~~~~ - Fix for instances where :binary:`~bin.mongos` incorrectly reports a successful write :issue:`SERVER-12146`. - Make non-primary read preferences consistent with ``slaveOK`` versioning logic :issue:`SERVER-11971`. - Allow new sharded cluster connections to read from secondaries when primary is down :issue:`SERVER-7246`. - `All 2.4.9 improvements `_. 2.4.8 -- November 1, 2013 ~~~~~~~~~~~~~~~~~~~~~~~~~ - Increase future compatibility for 2.6 authorization features :issue:`SERVER-11478`. - Fix :dbcommand:`dbhash` cache issue for config servers :issue:`SERVER-11421`. - `All 2.4.8 improvements `_. 2.4.7 -- October 21, 2013 ~~~~~~~~~~~~~~~~~~~~~~~~~ - Fixed over-aggressive caching of V8 Isolates :issue:`SERVER-10596`. - Removed extraneous initial count during mapReduce :issue:`SERVER-9907`. - Cache results of dbhash command :issue:`SERVER-11021`. - Fixed memory leak in aggregation :issue:`SERVER-10554`. - `All 2.4.7 improvements `_. 2.4.6 -- August 20, 2013 ~~~~~~~~~~~~~~~~~~~~~~~~ - Fix for possible loss of documents during the chunk migration process if a document in the chunk is very large :issue:`SERVER-10478`. - Fix for C++ client shutdown issues :issue:`SERVER-8891`. - Improved replication robustness in presence of high network latency :issue:`SERVER-10085`. - Improved Solaris support :issue:`SERVER-9832`, :issue:`SERVER-9786`, and :issue:`SERVER-7080`. - `All 2.4.6 improvements `_. 2.4.5 -- July 3, 2013 ~~~~~~~~~~~~~~~~~~~~~ - Fix for CVE-2013-4650 Improperly grant user system privileges on databases other than local :issue:`SERVER-9983`. - Fix for CVE-2013-3969 Remotely triggered segmentation fault in Javascript engine :issue:`SERVER-9878`. - Fix to prevent identical background indexes from being built :issue:`SERVER-9856`. - Config server performance improvements :issue:`SERVER-9864` and :issue:`SERVER-5442`. - Improved initial sync resilience to network failure :issue:`SERVER-9853`. - `All 2.4.5 improvements `_. 2.4.4 -- June 4, 2013 ~~~~~~~~~~~~~~~~~~~~~ - Performance fix for Windows version :issue:`SERVER-9721` - Fix for config upgrade failure :issue:`SERVER-9661`. - Migration to Cyrus SASL library for MongoDB Enterprise :issue:`SERVER-8813`. - `All 2.4.4 improvements `_. 2.4.3 -- April 23, 2013 ~~~~~~~~~~~~~~~~~~~~~~~ - Fix for ``mongo`` shell ignoring modified object's ``_id`` field :issue:`SERVER-9385`. - Fix for race condition in log rotation :issue:`SERVER-4739`. - Fix for ``copydb`` command with authorization in a sharded cluster :issue:`SERVER-9093`. - `All 2.4.3 improvements `_. 2.4.2 -- April 17, 2013 ~~~~~~~~~~~~~~~~~~~~~~~ - Several V8 memory leak and performance fixes :issue:`SERVER-9267` and :issue:`SERVER-9230`. - Fix for upgrading sharded clusters :issue:`SERVER-9125`. - Fix for high volume connection crash :issue:`SERVER-9014`. - `All 2.4.2 improvements `_ 2.4.1 -- April 17, 2013 ~~~~~~~~~~~~~~~~~~~~~~~ - Fix for losing index changes during initial sync :issue:`SERVER-9087` - `All 2.4.1 improvements `_. Major New Features ------------------ The following changes in MongoDB affect both standard and Enterprise editions: .. _2.4-release-text-indexes: Text Search ~~~~~~~~~~~ Add support for text search of content in MongoDB databases as a *beta* feature. See :doc:`/core/index-text` for more information. .. _2.4-release-geospatial: Geospatial Support Enhancements ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ - Add new :doc:`2dsphere index `. The new index supports `GeoJSON `_ objects ``Point``, ``LineString``, and ``Polygon``. See :doc:`/core/2dsphere` and :doc:`/applications/geospatial-indexes`. - Introduce operators :query:`$geometry`, :query:`$geoWithin` and :query:`$geoIntersects` to work with the GeoJSON data. .. _2.4-release-hashed-indexes: Hashed Index ~~~~~~~~~~~~ Add new :ref:`hashed index ` to index documents using hashes of field values. When used to index a shard key, the hashed index ensures an evenly distributed shard key. See also :ref:`sharding-hashed-sharding`. .. DOCS-752 Improvements to the Aggregation Framework ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ - Improve support for geospatial queries. See the :query:`$geoWithin` operator and the :pipeline:`$geoNear` pipeline stage. - Improve sort efficiency when the :pipeline:`$sort` stage immediately precedes a :pipeline:`$limit` in the pipeline. - Add new operators :expression:`$millisecond` and :expression:`$concat` and modify how :group:`$min` operator processes ``null`` values. .. _2.4-fixed-size-arrays: Changes to Update Operators ~~~~~~~~~~~~~~~~~~~~~~~~~~~ - Add new :update:`$setOnInsert` operator for use with :method:`upsert ` . - Enhance functionality of the :update:`$push` operator, supporting its use with the :update:`$each`, the :update:`$sort`, and the :update:`$slice` modifiers. Additional Limitations for Map-Reduce and ``$where`` Operations ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ The :dbcommand:`mapReduce` command, :dbcommand:`group` command, and the :query:`$where` operator expressions cannot access certain global functions or properties, such as ``db``, that are available in the :binary:`~bin.mongo` shell. See the individual command or operator for details. .. _2.4-release-server-status: Improvements to ``serverStatus`` Command ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ Provide additional metrics and customization for the :dbcommand:`serverStatus` command. See :method:`db.serverStatus()` and :dbcommand:`serverStatus` for more information. .. _2.4-privilege-documents: .. _2.4-unique-users: Security Enhancements --------------------- - Introduce a role-based access control system :doc:`/reference/user-privileges` using new :doc:`/reference/privilege-documents`. - Enforce uniqueness of the user in user privilege documents per database. Previous versions of MongoDB did not enforce this requirement, and existing databases may have duplicates. - Support encrypted connections using SSL certificates signed by a Certificate Authority. See :doc:`/tutorial/configure-ssl`. For more information on security and risk management strategies, see :doc:`MongoDB Security Practices and Procedures `. Performance Improvements ------------------------ .. _2.4-release-javascript-change: V8 JavaScript Engine ~~~~~~~~~~~~~~~~~~~~ .. class:: hidden .. toctree:: /release-notes/2.4-javascript Change default JavaScript engine from SpiderMonkey to V8. The change provides improved concurrency for JavaScript operations, modernized JavaScript implementation, and the removal of non-standard SpiderMonkey features, and affects all JavaScript behavior including the commands :dbcommand:`mapReduce`, :dbcommand:`group`, and :dbcommand:`eval` and the query operator :query:`$where`. See :doc:`/release-notes/2.4-javascript` for more information about all changes . BSON Document Validation Enabled by Default for ``mongod`` and ``mongorestore`` ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ Enable basic :term:`BSON` object validation for :binary:`~bin.mongod` and :binary:`~bin.mongorestore` when writing to MongoDB data files. See :setting:`objcheck` for details. Index Build Enhancements ~~~~~~~~~~~~~~~~~~~~~~~~ - Add support for multiple concurrent index builds in the background by a single :binary:`~bin.mongod` instance. See :ref:`building indexes in the background ` for more information on background index builds. - Allow the :method:`db.killOp()` method to terminate a foreground index build. - Improve index validation during index creation. See :doc:`/release-notes/2.4-index-types` for more information. Set Parameters as Command Line Options ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ Provide ``--setParameter`` as a command line option for :binary:`~bin.mongos` and :binary:`~bin.mongod`. See :binary:`~bin.mongod` and :binary:`~bin.mongos` for list of available options for :setting:`setParameter`. Increased Chunk Migration Write Concern ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ The default write concern for insert and delete operations that occur as part of a :term:`chunk` migration in a :term:`sharded cluster` now ensures that at least one secondary acknowledges each insert and deletion operation. See :ref:`chunk-migration-write-concern`. Improved Chunk Migration Queue Behavior ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ Increase performance for moving multiple chunks off an overloaded shard. The balancer no longer waits for the current migration's delete phase to complete before starting the next chunk migration. See :ref:`chunk-migration-queuing` for details. .. _mongodb-enterprise: Enterprise ---------- The following changes are specific to MongoDB Enterprise Editions: .. _2.4.4-sasl-change: SASL Library Change ~~~~~~~~~~~~~~~~~~~ In 2.4.4, MongoDB Enterprise uses Cyrus SASL. Earlier 2.4 Enterprise versions use GNU SASL (``libgsasl``). To upgrade to 2.4.4 MongoDB Enterprise or greater, you **must** install all package dependencies related to this change, including the appropriate Cyrus SASL ``GSSAPI`` library. See :doc:`/tutorial/install-mongodb-enterprise` for details of the dependencies. .. _kerberos-authentication: New Modular Authentication System with Support for Kerberos ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ In 2.4, the MongoDB Enterprise now supports authentication via a Kerberos mechanism. See :doc:`/tutorial/control-access-to-mongodb-with-kerberos-authentication` for more information. For drivers that provide support for Kerberos authentication to MongoDB, refer to :ref:`kerberos-and-drivers`. For more information on security and risk management strategies, see :doc:`MongoDB Security Practices and Procedures `. Additional Information ---------------------- Platform Notes ~~~~~~~~~~~~~~ For OS X, MongoDB 2.4 only supports OS X versions 10.6 (Snow Leopard) and later. There are no other platform support changes in MongoDB 2.4. See the `downloads page `_ for more information on platform support. Upgrade Process ~~~~~~~~~~~~~~~ .. class:: hidden .. toctree:: /release-notes/2.4-upgrade /release-notes/2.4-index-types See :doc:`/release-notes/2.4-upgrade` for full upgrade instructions. Other Resources ~~~~~~~~~~~~~~~ - `MongoDB Downloads `_. - `All JIRA issues resolved in 2.4 `_. - `All Backwards incompatible changes `_. - `All Third Party License Notices `_.