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

Shell exits with "out of memory" when command returns large array of documents

    • Type: Icon: Bug Bug
    • Resolution: Duplicate
    • Priority: Icon: Major - P3 Major - P3
    • None
    • Affects Version/s: 2.4.1
    • Component/s: Shell
    • None
    • Environment:
      Mac OS
    • OS X
    • Hide

      Load the data, do some searches. Search criteria is not relevant, it will just crash after a couple of searches.

      Show
      Load the data, do some searches. Search criteria is not relevant, it will just crash after a couple of searches.

      I have a small database (see attachment) with some large texts in it. There are only 10 entries in the collection of (gutenberg) books, but whenever I run a query like this:

      db.books.runCommand ( "text",

      {search: "hello" }

      )

      I get the following stacktrace:

      > db.books.runCommand ( "text", {search: "posted" })
      
      #
      # Fatal error in CALL_AND_RETRY_2
      # Allocation failed - process out of memory
      #
      
      Mon Jun 17 21:02:01.813 mongo got signal 6 (Abort trap: 6), stack trace:
      
      Mon Jun 17 21:02:01.815 0x10016fc9b 0x100001c0d 0x7fff90cd094a 0 0x7fff90d27dce 0x100416df9 0x10024c756 0x1001fca40 0x1001fe138 0x1003d3843 0x100446eed 0x100349835 0x28df0d06362
       0   mongo                               0x000000010016fc9b _ZN5mongo15printStackTraceERSo + 43
       1   mongo                               0x0000000100001c0d _Z12quitAbruptlyi + 925
       2   libsystem_c.dylib                   0x00007fff90cd094a _sigtramp + 26
       3   ???                                 0x0000000000000000 0x0 + 0
       4   libsystem_c.dylib                   0x00007fff90d27dce abort + 143
       5   mongo                               0x0000000100416df9 _ZN2v88internal2OS5AbortEv + 9
       6   mongo                               0x000000010024c756 _Z9API_FatalPKcS0_z + 198
       7   mongo                               0x00000001001fca40 _ZN2v8L24DefaultFatalErrorHandlerEPKcS1_ + 112
       8   mongo                               0x00000001001fe138 _ZN2v88internal2V823FatalProcessOutOfMemoryEPKcb + 488
       9   mongo                               0x00000001003d3843 _ZN2v88internal8JSObject10SetElementENS0_6HandleIS1_EEjNS2_INS0_6ObjectEEE18PropertyAttributesNS0_14StrictModeFlagENS0_15SetPropertyModeE + 707
       10  mongo                               0x0000000100446eed _ZN2v88internal7Runtime17SetObjectPropertyEPNS0_7IsolateENS0_6HandleINS0_6ObjectEEES6_S6_18PropertyAttributesNS0_14StrictModeFlagE + 445
       11  mongo                               0x0000000100349835 _ZN2v88internal17KeyedStoreIC_SlowENS0_9ArgumentsEPNS0_7IsolateE + 213
       12  ???                                 0x0000028df0d06362 0x0 + 2808653833058
      

      This doesn't happen always, but after searching for 4-5 times, the console crashes.

            Assignee:
            Unassigned Unassigned
            Reporter:
            bodiam Erik Pragt
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

              Created:
              Updated:
              Resolved: