Uploaded image for project: 'Core Server'
  1. Core Server
  2. SERVER-1216

ensureIndex on "system.indexes" crashed server

    • Type: Icon: Bug Bug
    • Resolution: Done
    • Priority: Icon: Major - P3 Major - P3
    • 1.5.2
    • Affects Version/s: 1.4.3
    • Component/s: Index Maintenance
    • None
    • Environment:
      Linux 2.6.33.5-112.fc13.i686 #1 SMP (Fedora 13)
    • Linux

      > use test
      > db.users.insert(

      {name: "xrfang"}

      )
      > db.getCollectionNames()
      [ "system.indexes", "users" ]
      > db.system.indexes.ensureIndex(

      {"name":1}

      )
      Fri Jun 11 17:39:21 MessagingPort recv() errno:104 Connection reset by peer 127.0.0.1:27017
      Fri Jun 11 17:39:21 query failed : xrfang.$cmd

      { getlasterror: 1.0 }

      to: 127.0.0.1
      Fri Jun 11 17:39:21 JS Error: Error: error doing query: failed (anon):1284
      Fri Jun 11 17:39:21 trying reconnect to 127.0.0.1
      Fri Jun 11 17:39:21 reconnect 127.0.0.1 ok
      Fri Jun 11 17:39:21 query failed : xrfang.$cmd

      { getlasterror: 1.0 }

      to: 127.0.0.1
      Fri Jun 11 17:39:21 JS Error: Error: error doing query: failed (anon):1284

      In the above session I incorrectly called the ensureIndex on "system.Indexes" collection, and crashed the server. if I restart the server and try to do the same thing on the same collection, this bug disappear. But if I created a new db, do the same thing, it still crashes server.

        1. mongo-bug.txt
          4 kB
          Shannon Fang

            Assignee:
            eliot Eliot Horowitz (Inactive)
            Reporter:
            xrfang Shannon Fang
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

              Created:
              Updated:
              Resolved: