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

Server aborts when querying against 2dsphere index with coarsestIndexedLevel:0

    • Type: Icon: Bug Bug
    • Resolution: Done
    • Priority: Icon: Major - P3 Major - P3
    • 2.6.5, 2.7.6
    • Affects Version/s: None
    • Component/s: Geo
    • ALL
    • Hide
      var t = db.geo_s2_params;
      t.ensureIndex({loc: '2dsphere'}, {coarsestIndexedLevel: 0});
      
      db.runCommand({geoNear: t.getName(), near: {type: 'Point', coordinates: [0, 0]}, spherical: true});
      
      Show
      var t = db.geo_s2_params; t.ensureIndex({loc: '2dsphere'}, {coarsestIndexedLevel: 0}); db.runCommand({geoNear: t.getName(), near: {type: 'Point', coordinates: [0, 0]}, spherical: true});

      The server aborts when querying against a 2dsphere index with the (mostly-undocumented) 'coarsestIndexedLevel' parameter set to 0.

      Backtrace:

      2014-08-20T19:29:42.210-0400 F          [conn1] src/third_party/s2/s2cellid.h:423:  Check failed: !is_face()
      2014-08-20T19:29:42.210-0400 I          [conn1] Fatal Assertion 0
      2014-08-20T19:29:42.214-0400 I          [conn1] 
       0x100802caa 0x1007ac5bb 0x10079aeff 0x100895c96 0x100895c79 0x1002b552d 0x10040fc1e 0x10023122d 0x1002405ed 0x100240379 0x100245fe8 0x100445b86 0x100172052 0x1001f953a 0x1001fa442 0x1001fb7a3 0x10042e456 0x1002e68a9 0x100008d09 0x1007bd7c0
      ----- BEGIN BACKTRACE -----
      {"backtrace":[{"b":"100000000","o":"802CAA"},{"b":"100000000","o":"7AC5BB"},{"b":"100000000","o":"79AEFF"},{"b":"100000000","o":"895C96"},{"b":"100000000","o":"895C79"},{"b":"100000000","o":"2B552D"},{"b":"100000000","o":"40FC1E"},{"b":"100000000","o":"23122D"},{"b":"100000000","o":"2405ED"},{"b":"100000000","o":"240379"},{"b":"100000000","o":"245FE8"},{"b":"100000000","o":"445B86"},{"b":"100000000","o":"172052"},{"b":"100000000","o":"1F953A"},{"b":"100000000","o":"1FA442"},{"b":"100000000","o":"1FB7A3"},{"b":"100000000","o":"42E456"},{"b":"100000000","o":"2E68A9"},{"b":"100000000","o":"8D09"},{"b":"100000000","o":"7BD7C0"}],"processInfo":{ "mongodbVersion" : "2.7.6-pre-", "gitVersion" : "8f9c2e19ae3131e1aebb64d8ab46ac9bb4a5eae3", "uname" : { "sysname" : "Darwin", "release" : "13.2.0", "version" : "Darwin Kernel Version 13.2.0: Thu Apr 17 23:03:13 PDT 2014; root:xnu-2422.100.13~1/RELEASE_X86_64", "machine" : "x86_64" }, "somap" : [ { "path" : "/Users/kk/code/mongo/mongo/./mongod", "machType" : 2, "b" : "100000000", "buildId" : "ACF2AC0CEDCF3B4989689C5F8982CA64" }, { "path" : "/usr/lib/libSystem.B.dylib", "machType" : 6, "b" : "7FFF8713E000", "buildId" : "E303F2F8A8CF3DF384B3F2D0EE41CCF6" }, { "path" : "/usr/lib/libstdc++.6.dylib", "machType" : 6, "b" : "7FFF8721D000", "buildId" : "0241E6A4136833BE950BD0A175C41F54" }, { "path" : "/usr/lib/system/libcache.dylib", "machType" : 6, "b" : "7FFF8FA81000", "buildId" : "BDC1E65B72A13DA3A57CB23159CAAD0B" }, { "path" : "/usr/lib/system/libcommonCrypto.dylib", "machType" : 6, "b" : "7FFF93890000", "buildId" : "8C4F0CA0389C3EDCB155E62DD2187E1D" }, { "path" : "/usr/lib/system/libcompiler_rt.dylib", "machType" : 6, "b" : "7FFF878E5000", "buildId" : "4CD916B21B17362AB403EF24A1DAC141" }, { "path" : "/usr/lib/system/libcopyfile.dylib", "machType" : 6, "b" : "7FFF8C30A000", "buildId" : "5A881779D0D63029B371E3021C2DDA5E" }, { "path" : "/usr/lib/system/libcorecrypto.dylib", "machType" : 6, "b" : "7FFF8E2F8000", "buildId" : "F3973C2814B63006BB2B00DD7F09ABC7" }, { "path" : "/usr/lib/system/libdispatch.dylib", "machType" : 6, "b" : "7FFF9102C000", "buildId" : "C4E4A18D3C3B3C9C8709A4270D998DE7" }, { "path" : "/usr/lib/system/libdyld.dylib", "machType" : 6, "b" : "7FFF9246B000", "buildId" : "7C9EC3B7DDE333FF953F4067C743951D" }, { "path" : "/usr/lib/system/libkeymgr.dylib", "machType" : 6, "b" : "7FFF93063000", "buildId" : "3AA8D85DCF003BD3A5A0E28E1A32A6D8" }, { "path" : "/usr/lib/system/liblaunch.dylib", "machType" : 6, "b" : "7FFF8A8B5000", "buildId" : "38D1AB2CA476385F8EA87AB604CA1F89" }, { "path" : "/usr/lib/system/libmacho.dylib", "machType" : 6, "b" : "7FFF878DF000", "buildId" : "1D2910DFC0363A82A3FD44FF73B5FF9B" }, { "path" : "/usr/lib/system/libquarantine.dylib", "machType" : 6, "b" : "7FFF88265000", "buildId" : "7A1A2BCBC03D3A25BFA43E569B2D2C38" }, { "path" : "/usr/lib/system/libremovefile.dylib", "machType" : 6, "b" : "7FFF92853000", "buildId" : "3543F917928E3DB2A2F47AB73B4970EF" }, { "path" : "/usr/lib/system/libsystem_asl.dylib", "machType" : 6, "b" : "7FFF93D3E000", "buildId" : "655FB34352CF3E2FB14DBEBF5AAEF94D" }, { "path" : "/usr/lib/system/libsystem_blocks.dylib", "machType" : 6, "b" : "7FFF8C2A6000", "buildId" : "FB856CD12AEA39078E9B1E54B6827F82" }, { "path" : "/usr/lib/system/libsystem_c.dylib", "machType" : 6, "b" : "7FFF9246F000", "buildId" : "6FD3A4004BB23B95B90CBE6E9D0D78FA" }, { "path" : "/usr/lib/system/libsystem_configuration.dylib", "machType" : 6, "b" : "7FFF876AA000", "buildId" : "4998CB6A9D54390A9F575D1AC53C135C" }, { "path" : "/usr/lib/system/libsystem_dnssd.dylib", "machType" : 6, "b" : "7FFF92079000", "buildId" : "A0B7CF19D9F233D48107A62184C9066E" }, { "path" : "/usr/lib/system/libsystem_info.dylib", "machType" : 6, "b" : "7FFF878B7000", "buildId" : "7D41A156D2853849A2C3C04ADE797D98" }, { "path" : "/usr/lib/system/libsystem_kernel.dylib", "machType" : 6, "b" : "7FFF885A6000", "buildId" : "498AEBD741943CF2AA16D5D03FFBD8C0" }, { "path" : "/usr/lib/system/libsystem_m.dylib", "machType" : 6, "b" : "7FFF8D028000", "buildId" : "B7F0E2E4277733FCA787D6430B630D54" }, { "path" : "/usr/lib/system/libsystem_malloc.dylib", "machType" : 6, "b" : "7FFF93874000", "buildId" : "A695B4E438E9332EA77229D31E3F1385" }, { "path" : "/usr/lib/system/libsystem_network.dylib", "machType" : 6, "b" : "7FFF91BF7000", "buildId" : "8B1E1F1DA5CC3BAE8B1EABC84337A364" }, { "path" : "/usr/lib/system/libsystem_notify.dylib", "machType" : 6, "b" : "7FFF8C2A8000", "buildId" : "52571EC3689437E4946E064B021ED44E" }, { "path" : "/usr/lib/system/libsystem_platform.dylib", "machType" : 6, "b" : "7FFF9386D000", "buildId" : "3C3D3DA832B9324398ECD89B9A1670B3" }, { "path" : "/usr/lib/system/libsystem_pthread.dylib", "machType" : 6, "b" : "7FFF8D020000", "buildId" : "AB498556B555310E9041F67EC9E00E2C" }, { "path" : "/usr/lib/system/libsystem_sandbox.dylib", "machType" : 6, "b" : "7FFF88417000", "buildId" : "B46E4040A8C63EBC91F8F1CB01106614" }, { "path" : "/usr/lib/system/libsystem_stats.dylib", "machType" : 6, "b" : "7FFF8A1F6000", "buildId" : "4E51D5B092A03D0DB90E495A1ED3E391" }, { "path" : "/usr/lib/system/libunc.dylib", "machType" : 6, "b" : "7FFF8BB62000", "buildId" : "62682455186236FE8A047A6B91256438" }, { "path" : "/usr/lib/system/libunwind.dylib", "machType" : 6, "b" : "7FFF92823000", "buildId" : "78DCC3582FC1302EB3950155B47CB547" }, { "path" : "/usr/lib/system/libxpc.dylib", "machType" : 6, "b" : "7FFF88581000", "buildId" : "AB40CD57F4543FD4B41563B3C0D5C624" }, { "path" : "/usr/lib/libobjc.A.dylib", "machType" : 6, "b" : "7FFF87D2A000", "buildId" : "AD7FD984271E30F4A3616B20319EC73B" }, { "path" : "/usr/lib/libauto.dylib", "machType" : 6, "b" : "7FFF914DA000", "buildId" : "F45C36E8B6063886B5B1B6745E757CA8" }, { "path" : "/usr/lib/libc++abi.dylib", "machType" : 6, "b" : "7FFF87869000", "buildId" : "21A807D367323455B77F743E9F916DF0" }, { "path" : "/usr/lib/libc++.1.dylib", "machType" : 6, "b" : "7FFF8E20D000", "buildId" : "4F68DFC5207739A8A449CAC5FDEE7BDE" }, { "path" : "/usr/lib/libDiagnosticMessagesClient.dylib", "machType" : 6, "b" : "7FFF8FFA7000", "buildId" : "4CDB0F7BC0AF3424BC39495696F0DB1E" } ] }}
       mongod(_ZN5mongo15printStackTraceERSo+0x3A) [0x100802caa]
       mongod(_ZN5mongo10logContextEPKc+0xDB) [0x1007ac5bb]
       mongod(_ZN5mongo13fassertFailedEi+0xAF) [0x10079aeff]
       mongod(_ZN15LogMessageFatalD2Ev+0x16) [0x100895c96]
       mongod(_ZN15LogMessageFatalD1Ev+0x9) [0x100895c79]
       mongod(_ZNK8S2CellId6parentEv+0xDD) [0x1002b552d]
       mongod(_ZN5mongo17ExpressionMapping13cover2dsphereERK8S2RegionRKNS_7BSONObjEPNS_19OrderedIntervalListE+0x35E) [0x10040fc1e]
       mongod(_ZN5mongo20GeoNear2DSphereStage12nextIntervalEPNS_16OperationContextEPNS_10WorkingSetEPNS_10CollectionE+0x78D) [0x10023122d]
       mongod(_ZN5mongo9NearStage10bufferNextEPNS_6StatusE+0x3D) [0x1002405ed]
       mongod(_ZN5mongo9NearStage4workEPm+0x69) [0x100240379]
       mongod(_ZN5mongo15ProjectionStage4workEPm+0x48) [0x100245fe8]
       mongod(_ZN5mongo12PlanExecutor7getNextEPNS_7BSONObjEPNS_7DiskLocE+0x56) [0x100445b86]
       mongod(_ZN5mongo16Geo2dFindNearCmd3runEPNS_16OperationContextERKSsRNS_7BSONObjEiRSsRNS_14BSONObjBuilderEb+0x14C2) [0x100172052]
       mongod(_ZN5mongo12_execCommandEPNS_16OperationContextEPNS_7CommandERKSsRNS_7BSONObjEiRSsRNS_14BSONObjBuilderEb+0x3A) [0x1001f953a]
       mongod(_ZN5mongo7Command11execCommandEPNS_16OperationContextEPS0_RNS_6ClientEiPKcRNS_7BSONObjERNS_14BSONObjBuilderEb+0x992) [0x1001fa442]
       mongod(_ZN5mongo12_runCommandsEPNS_16OperationContextEPKcRNS_7BSONObjERNS_11_BufBuilderINS_16TrivialAllocatorEEERNS_14BSONObjBuilderEbi+0x4E3) [0x1001fb7a3]
       mongod(_ZN5mongo11newRunQueryEPNS_16OperationContextERNS_7MessageERNS_12QueryMessageERNS_5CurOpES3_+0x306) [0x10042e456]
       mongod(_ZN5mongo16assembleResponseEPNS_16OperationContextERNS_7MessageERNS_10DbResponseERKNS_11HostAndPortE+0x8D9) [0x1002e68a9]
       mongod(_ZN5mongo16MyMessageHandler7processERNS_7MessageEPNS_21AbstractMessagingPortEPNS_9LastErrorE+0xB9) [0x100008d09]
       mongod(_ZN5mongo17PortMessageServer17handleIncomingMsgEPv+0x360) [0x1007bd7c0]
      -----  END BACKTRACE  -----
      2014-08-20T19:29:42.214-0400 I          [conn1] 
      
      ***aborting after fassert() failure
      
      
      2014-08-20T19:29:42.217-0400 F          [conn1] Got signal: 6 (Abort trap: 6).
      

            Assignee:
            greg_10gen Greg Studer
            Reporter:
            kamran.khan Kamran K.
            Votes:
            0 Vote for this issue
            Watchers:
            5 Start watching this issue

              Created:
              Updated:
              Resolved: