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

Drop database caused collections in other DB's to dropped

    • ALL

      Problem:

      As reported in Google Groups

      http://groups.google.com/group/mongodb-user/browse_thread/thread/34cda5dac73edff7

      Database names called

      • buy
      • buy_201107
      • buy_201108

      User did
      > use buy
      > db.dropdatabse()

      From the logs it can be seen

      Sat Jul 23 23:49:38 [conn663642] DROP DATABASE: buy
      Sat Jul 23 23:49:38 [conn663642] DBConfig::dropDatabase: buy
      Sat Jul 23 23:49:39 [conn663642] about to log metadata event: { _id:
      "mg03-2011-07-23T15:49:38-0", server: "mg03", clientAddr: "N/A", time:
      new Date(1311436179027), what: "dropDatabase.start", ns: "buy",
      details: {} }

      Look good, but next message it looks like the NS changed

      Sat Jul 23 23:49:39 [conn663642] about to log metadata event: { _id:
      "mg03-2011-07-23T15:49:39-1", server: "mg03", clientAddr: "N/A", time:
      new Date(1311436179091), what: "dropCollection.start", ns:
      "buy_201107.data", details: {} }

      This message comes from chunk.cpp:775, however, the code path to here looks reasombale.

            Assignee:
            greg_10gen Greg Studer
            Reporter:
            alvin Alvin Richards (Inactive)
            Votes:
            2 Vote for this issue
            Watchers:
            3 Start watching this issue

              Created:
              Updated:
              Resolved: