Not able to start mongodb using dbpath

Hello,

I recently downloaded a backup of my production database. I was hoping to be able to connect to this downloaded (and extracted) backup data using mongod --dbpath. But I am not able to connect to these local files. I tried it using 2 different mongod versions, 4.0.3 and 4.4.21. Both gave me different errors. My production db shows its running on version 4.4.23 as per Atlas.

Here are the details of errors on both versions.

mongod version 4.0.3

mongod --dbpath ~/Downloads/restore-64caaf6f53157227c9123456/
2023-08-02T18:43:53.776-0400 I CONTROL  [main] Automatically disabling TLS 1.0, to force-enable TLS 1.0 specify --sslDisabledProtocols 'none'
2023-08-02T18:43:53.804-0400 I CONTROL  [initandlisten] MongoDB starting : pid=92287 port=27017 dbpath=/Users/username/Downloads/restore-64caaf6f53157227c9123456/ 64-bit host=Adminstrators-MacBook-Pro.local
2023-08-02T18:43:53.804-0400 I CONTROL  [initandlisten] db version v4.0.3
2023-08-02T18:43:53.804-0400 I CONTROL  [initandlisten] git version: 7ea530946fa7880364d88c8d8b6026bbc9ffa48c
2023-08-02T18:43:53.804-0400 I CONTROL  [initandlisten] allocator: system
2023-08-02T18:43:53.804-0400 I CONTROL  [initandlisten] modules: none
2023-08-02T18:43:53.804-0400 I CONTROL  [initandlisten] build environment:
2023-08-02T18:43:53.804-0400 I CONTROL  [initandlisten]     distarch: x86_64
2023-08-02T18:43:53.804-0400 I CONTROL  [initandlisten]     target_arch: x86_64
2023-08-02T18:43:53.805-0400 I CONTROL  [initandlisten] options: { storage: { dbPath: "/Users/username/Downloads/restore-64caaf6f53157227c9123456/" } }
2023-08-02T18:43:53.807-0400 I CONTROL  [initandlisten] machdep.cpu.extfeatures unavailable
2023-08-02T18:43:53.807-0400 I STORAGE  [initandlisten] wiredtiger_open config: create,cache_size=7680M,session_max=20000,eviction=(threads_min=4,threads_max=4),config_base=false,statistics=(fast),log=(enabled=true,archive=true,path=journal,compressor=snappy),file_manager=(close_idle_time=100000),statistics_log=(wait=0),verbose=(recovery_progress),
2023-08-02T18:43:53.911-0400 E STORAGE  [initandlisten] WiredTiger error (-31802) [1691016233:911251][92287:0x206e0d600], connection: __log_open_verify, 1015: unsupported WiredTiger file version: this build only supports versions up to 3, and the file is version 5: WT_ERROR: non-specific WiredTiger error Raw: [1691016233:911251][92287:0x206e0d600], connection: __log_open_verify, 1015: unsupported WiredTiger file version: this build only supports versions up to 3, and the file is version 5: WT_ERROR: non-specific WiredTiger error
2023-08-02T18:43:53.946-0400 E STORAGE  [initandlisten] WiredTiger error (-31802) [1691016233:946039][92287:0x206e0d600], connection: __log_open_verify, 1015: unsupported WiredTiger file version: this build only supports versions up to 3, and the file is version 5: WT_ERROR: non-specific WiredTiger error Raw: [1691016233:946039][92287:0x206e0d600], connection: __log_open_verify, 1015: unsupported WiredTiger file version: this build only supports versions up to 3, and the file is version 5: WT_ERROR: non-specific WiredTiger error
2023-08-02T18:43:53.966-0400 E STORAGE  [initandlisten] WiredTiger error (-31802) [1691016233:966886][92287:0x206e0d600], connection: __log_open_verify, 1015: unsupported WiredTiger file version: this build only supports versions up to 3, and the file is version 5: WT_ERROR: non-specific WiredTiger error Raw: [1691016233:966886][92287:0x206e0d600], connection: __log_open_verify, 1015: unsupported WiredTiger file version: this build only supports versions up to 3, and the file is version 5: WT_ERROR: non-specific WiredTiger error
2023-08-02T18:43:53.987-0400 W STORAGE  [initandlisten] Failed to start up WiredTiger under any compatibility version.
2023-08-02T18:43:53.987-0400 F STORAGE  [initandlisten] Reason: -31802: WT_ERROR: non-specific WiredTiger error
2023-08-02T18:43:53.987-0400 F -        [initandlisten] Fatal Assertion 28595 at src/mongo/db/storage/wiredtiger/wiredtiger_kv_engine.cpp 645
2023-08-02T18:43:53.987-0400 F -        [initandlisten] 

***aborting after fassert() failure

mongod version 4.4.21

mongod --dbpath ~/Downloads/restore-64caaf6f53157227c9123456/
{"t":{"$date":"2023-08-02T19:07:59.657-04:00"},"s":"I",  "c":"CONTROL",  "id":23285,   "ctx":"main","msg":"Automatically disabling TLS 1.0, to force-enable TLS 1.0 specify --sslDisabledProtocols 'none'"}
{"t":{"$date":"2023-08-02T19:07:59.659-04:00"},"s":"I",  "c":"NETWORK",  "id":4648602, "ctx":"main","msg":"Implicit TCP FastOpen in use."}
{"t":{"$date":"2023-08-02T19:07:59.660-04:00"},"s":"I",  "c":"STORAGE",  "id":4615611, "ctx":"initandlisten","msg":"MongoDB starting","attr":{"pid":93877,"port":27017,"dbPath":"/Users/username/Downloads/restore-64caaf6f53157227c9123456/","architecture":"64-bit","host":"Adminstrators-MacBook-Pro.local"}}
{"t":{"$date":"2023-08-02T19:07:59.660-04:00"},"s":"I",  "c":"CONTROL",  "id":23403,   "ctx":"initandlisten","msg":"Build Info","attr":{"buildInfo":{"version":"4.4.21","gitVersion":"07fb62484a27e3e464ecdd6c746de64e53e19e56","modules":[],"allocator":"system","environment":{"distarch":"x86_64","target_arch":"x86_64"}}}}
{"t":{"$date":"2023-08-02T19:07:59.660-04:00"},"s":"I",  "c":"CONTROL",  "id":51765,   "ctx":"initandlisten","msg":"Operating System","attr":{"os":{"name":"Mac OS X","version":"21.6.0"}}}
{"t":{"$date":"2023-08-02T19:07:59.660-04:00"},"s":"I",  "c":"CONTROL",  "id":21951,   "ctx":"initandlisten","msg":"Options set by command line","attr":{"options":{"storage":{"dbPath":"/Users/username/Downloads/restore-64caaf6f53157227c9123456/"}}}}
{"t":{"$date":"2023-08-02T19:07:59.661-04:00"},"s":"I",  "c":"STORAGE",  "id":22315,   "ctx":"initandlisten","msg":"Opening WiredTiger","attr":{"config":"create,cache_size=7680M,session_max=33000,eviction=(threads_min=4,threads_max=4),config_base=false,statistics=(fast),log=(enabled=true,archive=true,path=journal,compressor=snappy),file_manager=(close_idle_time=100000,close_scan_interval=10,close_handle_minimum=250),statistics_log=(wait=0),verbose=[recovery_progress,checkpoint_progress,compact_progress],"}}
{"t":{"$date":"2023-08-02T19:07:59.765-04:00"},"s":"F",  "c":"STORAGE",  "id":4671205, "ctx":"initandlisten","msg":"This version of MongoDB is too recent to start up on the existing data files. Try MongoDB 4.2 or earlier."}
{"t":{"$date":"2023-08-02T19:07:59.766-04:00"},"s":"F",  "c":"-",        "id":23089,   "ctx":"initandlisten","msg":"Fatal assertion","attr":{"msgid":4671205,"file":"src/mongo/db/storage/wiredtiger/wiredtiger_kv_engine.cpp","line":923}}
{"t":{"$date":"2023-08-02T19:07:59.766-04:00"},"s":"F",  "c":"-",        "id":23090,   "ctx":"initandlisten","msg":"\n\n***aborting after fassert() failure\n\n"}
{"t":{"$date":"2023-08-02T19:07:59.766-04:00"},"s":"F",  "c":"CONTROL",  "id":4757800, "ctx":"initandlisten","msg":"Writing fatal message","attr":{"message":"Got signal: 6 (Abort trap: 6).\n"}}
{"t":{"$date":"2023-08-02T19:07:59.769-04:00"},"s":"I",  "c":"CONTROL",  "id":31431,   "ctx":"initandlisten","msg":"BACKTRACE: {bt}","attr":{"bt":{"backtrace":[{"a":"10662336C","b":"10442B000","o":"21F836C","s":"_ZN5mongo18stack_trace_detail12_GLOBAL__N_119printStackTraceImplERKNS1_7OptionsEPNS_14StackTraceSinkE","s+":"10C"},{"a":"106624A68","b":"10442B000","o":"21F9A68","s":"_ZN5mongo15printStackTraceEv","s+":"28"},{"a":"1066225AB","b":"10442B000","o":"21F75AB","s":"_ZN5mongo12_GLOBAL__N_116abruptQuitActionEiP9__siginfoPv","s+":"BB"},{"a":"7FF8008B6DFD","b":"7FF8008B3000","o":"3DFD","s":"_sigtramp","s+":"1D"},{"a":"4"},{"a":"7FF8007ECD24","b":"7FF80076B000","o":"81D24","s":"abort","s+":"7B"},{"a":"106605CE7","b":"10442B000","o":"21DACE7","s":"_ZN5mongo25fassertFailedWithLocationEiPKcj","s+":"197"},{"a":"1044AE3B6","b":"10442B000","o":"833B6","s":"_ZN5mongo18WiredTigerKVEngine15_openWiredTigerERKNSt3__112basic_stringIcNS1_11char_traitsIcEENS1_9allocatorIcEEEES9_","s+":"7D6"},{"a":"1044AB8A8","b":"10442B000","o":"808A8","s":"_ZN5mongo18WiredTigerKVEngineC2ERKNSt3__112basic_stringIcNS1_11char_traitsIcEENS1_9allocatorIcEEEES9_PNS_11ClockSourceES9_mmbbbb","s+":"15D8"},{"a":"1044B0188","b":"10442B000","o":"85188","s":"_ZN5mongo18WiredTigerKVEngineC1ERKNSt3__112basic_stringIcNS1_11char_traitsIcEENS1_9allocatorIcEEEES9_PNS_11ClockSourceES9_mmbbbb","s+":"38"},{"a":"104488327","b":"10442B000","o":"5D327","s":"_ZNK5mongo12_GLOBAL__N_117WiredTigerFactory6createERKNS_19StorageGlobalParamsEPKNS_21StorageEngineLockFileE","s+":"337"},{"a":"104F4741A","b":"10442B000","o":"B1C41A","s":"_ZN5mongo23initializeStorageEngineEPNS_14ServiceContextENS_22StorageEngineInitFlagsE","s+":"77A"},{"a":"104438283","b":"10442B000","o":"D283","s":"_ZN5mongo12_GLOBAL__N_114_initAndListenEPNS_14ServiceContextEi","s+":"463"},{"a":"10442DDBA","b":"10442B000","o":"2DBA","s":"_ZN5mongo12_GLOBAL__N_111mongoDbMainEiPPc","s+":"161A"},{"a":"10442C799","b":"10442B000","o":"1799","s":"main","s+":"9"},{"a":"208A4252E"},{"a":"5"}],"processInfo":{"mongodbVersion":"4.4.21","gitVersion":"07fb62484a27e3e464ecdd6c746de64e53e19e56","compiledModules":[],"uname":{"sysname":"Darwin","release":"21.6.0","version":"Darwin Kernel Version 21.6.0: Mon Aug 22 20:20:05 PDT 2022; root:xnu-8020.140.49~2/RELEASE_ARM64_T8101","machine":"x86_64"},"somap":[{"path":"/usr/local/Cellar/mongodb-community@4.4/4.4.21/bin/mongod","machType":2,"b":"10442B000","vmaddr":"100000000","buildId":"D2F1B69B6822388890FAD35A3CF5B151"},{"path":"/usr/lib/system/libsystem_c.dylib","machType":6,"b":"7FF80076B000","vmaddr":"7FF8001EB000","buildId":"E42E9D7A03B4340BB61EDCD45FD4ACC0"},{"path":"/usr/lib/system/libsystem_platform.dylib","machType":6,"b":"7FF8008B3000","vmaddr":"7FF800333000","buildId":"A8A337746D4435E9AD2ABAD9E4D5192A"}]}}}}
{"t":{"$date":"2023-08-02T19:07:59.769-04:00"},"s":"I",  "c":"CONTROL",  "id":31427,   "ctx":"initandlisten","msg":"  Frame: {frame}","attr":{"frame":{"a":"10662336C","b":"10442B000","o":"21F836C","s":"_ZN5mongo18stack_trace_detail12_GLOBAL__N_119printStackTraceImplERKNS1_7OptionsEPNS_14StackTraceSinkE","s+":"10C"}}}
{"t":{"$date":"2023-08-02T19:07:59.769-04:00"},"s":"I",  "c":"CONTROL",  "id":31427,   "ctx":"initandlisten","msg":"  Frame: {frame}","attr":{"frame":{"a":"106624A68","b":"10442B000","o":"21F9A68","s":"_ZN5mongo15printStackTraceEv","s+":"28"}}}
{"t":{"$date":"2023-08-02T19:07:59.769-04:00"},"s":"I",  "c":"CONTROL",  "id":31427,   "ctx":"initandlisten","msg":"  Frame: {frame}","attr":{"frame":{"a":"1066225AB","b":"10442B000","o":"21F75AB","s":"_ZN5mongo12_GLOBAL__N_116abruptQuitActionEiP9__siginfoPv","s+":"BB"}}}
{"t":{"$date":"2023-08-02T19:07:59.769-04:00"},"s":"I",  "c":"CONTROL",  "id":31427,   "ctx":"initandlisten","msg":"  Frame: {frame}","attr":{"frame":{"a":"7FF8008B6DFD","b":"7FF8008B3000","o":"3DFD","s":"_sigtramp","s+":"1D"}}}
{"t":{"$date":"2023-08-02T19:07:59.769-04:00"},"s":"I",  "c":"CONTROL",  "id":31427,   "ctx":"initandlisten","msg":"  Frame: {frame}","attr":{"frame":{"a":"4"}}}
{"t":{"$date":"2023-08-02T19:07:59.769-04:00"},"s":"I",  "c":"CONTROL",  "id":31427,   "ctx":"initandlisten","msg":"  Frame: {frame}","attr":{"frame":{"a":"7FF8007ECD24","b":"7FF80076B000","o":"81D24","s":"abort","s+":"7B"}}}
{"t":{"$date":"2023-08-02T19:07:59.769-04:00"},"s":"I",  "c":"CONTROL",  "id":31427,   "ctx":"initandlisten","msg":"  Frame: {frame}","attr":{"frame":{"a":"106605CE7","b":"10442B000","o":"21DACE7","s":"_ZN5mongo25fassertFailedWithLocationEiPKcj","s+":"197"}}}
{"t":{"$date":"2023-08-02T19:07:59.769-04:00"},"s":"I",  "c":"CONTROL",  "id":31427,   "ctx":"initandlisten","msg":"  Frame: {frame}","attr":{"frame":{"a":"1044AE3B6","b":"10442B000","o":"833B6","s":"_ZN5mongo18WiredTigerKVEngine15_openWiredTigerERKNSt3__112basic_stringIcNS1_11char_traitsIcEENS1_9allocatorIcEEEES9_","s+":"7D6"}}}
{"t":{"$date":"2023-08-02T19:07:59.769-04:00"},"s":"I",  "c":"CONTROL",  "id":31427,   "ctx":"initandlisten","msg":"  Frame: {frame}","attr":{"frame":{"a":"1044AB8A8","b":"10442B000","o":"808A8","s":"_ZN5mongo18WiredTigerKVEngineC2ERKNSt3__112basic_stringIcNS1_11char_traitsIcEENS1_9allocatorIcEEEES9_PNS_11ClockSourceES9_mmbbbb","s+":"15D8"}}}
{"t":{"$date":"2023-08-02T19:07:59.769-04:00"},"s":"I",  "c":"CONTROL",  "id":31427,   "ctx":"initandlisten","msg":"  Frame: {frame}","attr":{"frame":{"a":"1044B0188","b":"10442B000","o":"85188","s":"_ZN5mongo18WiredTigerKVEngineC1ERKNSt3__112basic_stringIcNS1_11char_traitsIcEENS1_9allocatorIcEEEES9_PNS_11ClockSourceES9_mmbbbb","s+":"38"}}}
{"t":{"$date":"2023-08-02T19:07:59.769-04:00"},"s":"I",  "c":"CONTROL",  "id":31427,   "ctx":"initandlisten","msg":"  Frame: {frame}","attr":{"frame":{"a":"104488327","b":"10442B000","o":"5D327","s":"_ZNK5mongo12_GLOBAL__N_117WiredTigerFactory6createERKNS_19StorageGlobalParamsEPKNS_21StorageEngineLockFileE","s+":"337"}}}
{"t":{"$date":"2023-08-02T19:07:59.769-04:00"},"s":"I",  "c":"CONTROL",  "id":31427,   "ctx":"initandlisten","msg":"  Frame: {frame}","attr":{"frame":{"a":"104F4741A","b":"10442B000","o":"B1C41A","s":"_ZN5mongo23initializeStorageEngineEPNS_14ServiceContextENS_22StorageEngineInitFlagsE","s+":"77A"}}}
{"t":{"$date":"2023-08-02T19:07:59.769-04:00"},"s":"I",  "c":"CONTROL",  "id":31427,   "ctx":"initandlisten","msg":"  Frame: {frame}","attr":{"frame":{"a":"104438283","b":"10442B000","o":"D283","s":"_ZN5mongo12_GLOBAL__N_114_initAndListenEPNS_14ServiceContextEi","s+":"463"}}}
{"t":{"$date":"2023-08-02T19:07:59.769-04:00"},"s":"I",  "c":"CONTROL",  "id":31427,   "ctx":"initandlisten","msg":"  Frame: {frame}","attr":{"frame":{"a":"10442DDBA","b":"10442B000","o":"2DBA","s":"_ZN5mongo12_GLOBAL__N_111mongoDbMainEiPPc","s+":"161A"}}}
{"t":{"$date":"2023-08-02T19:07:59.769-04:00"},"s":"I",  "c":"CONTROL",  "id":31427,   "ctx":"initandlisten","msg":"  Frame: {frame}","attr":{"frame":{"a":"10442C799","b":"10442B000","o":"1799","s":"main","s+":"9"}}}
{"t":{"$date":"2023-08-02T19:07:59.769-04:00"},"s":"I",  "c":"CONTROL",  "id":31427,   "ctx":"initandlisten","msg":"  Frame: {frame}","attr":{"frame":{"a":"208A4252E"}}}
{"t":{"$date":"2023-08-02T19:07:59.769-04:00"},"s":"I",  "c":"CONTROL",  "id":31427,   "ctx":"initandlisten","msg":"  Frame: {frame}","attr":{"frame":{"a":"5"}}}
Abort trap: 6

Any help here is highly appreciated. I need to fix some production documents and restoring from backup is not an option for me (will result in too much data loss).

regards

Hi @Vinit_Acharekar, welcome to the forums.

Try 4.2., 4.0 is reporting the file version is newer than it supports and 4.4 is too new.

Here is an old post that helps find the last version that sucessfully started the DB the backup was taken from.

1 Like