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

v8 running out of memory when compiling large script

    XMLWordPrintableJSON

Details

    • Icon: Bug Bug
    • Resolution: Done
    • Icon: Major - P3 Major - P3
    • None
    • 2.3.2
    • JavaScript
    • None
    • Fully Compatible
    • ALL

    Description

      I have a 27MB file that basically has variations on this:

      t = db.bulk_test
      t.drop()
      t.ensureIndex({geo:'2dsphere'})
      node12989667 = {type: 'Point', coordinates: [-73.8998916, 40.9339637]}
      t.insert({geo : node12989667})
      // repeat above 2 statements until 27MB is hit, with different names/values etc.:

      If I run this normally, I get this:

      hk@bellona:~$ ./clean/mongo out.js 
      Fri Dec 14 11:42:18.202 In File::open(), ::open for '/etc/lsb-release' failed with errno:1 Operation not permitted
      MongoDB shell version: 2.3.2-pre-
      connecting to: test
       
      #
      # Fatal error in CALL_AND_RETRY_2
      # Allocation failed - process out of memory
      #
       
      Trace/breakpoint trap (core dumped)

      If I compile with --usesm, it works/doesn't crash.

      Attachments

        1. out.js
          26.68 MB

        Activity

          People

            backlog-server-platform DO NOT USE - Backlog - Platform Team
            hari.khalsa@10gen.com hari.khalsa@10gen.com
            Votes:
            0 Vote for this issue
            Watchers:
            5 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: