mongodump给出了分段错误

时间:2017-12-25 00:59:35

标签: mongodb mongodump

我的mac macOs High Sierra v10.13.1上安装了MongoDB v3.2.6,我在升级之前尝试进行备份。

我有一个$ mongod实例在一个窗口中使用defaut db location和default port运行。

这是我的本地数据库,它不受密码保护,也不需要ssl conncetions。

我可以使用$ mongo或Robomongo访问我的数据库,但是当我运行$ mongodump$ mongodump --db mydatabase时,我收到以下错误

[1] 1815 segmentation fault mongodump

更新:我试图运行mongostat,现在我收到以下错误:

[1] 2404 bus error mongodump

以下是使用$ mongod启动数据库时获得的日志:

2017-12-25T12:36:26.642+0000 I CONTROL  [initandlisten] MongoDB starting : pid=3216 port=27017 dbpath=/data/db 64-bit host=MBP-de-Kevin.home
2017-12-25T12:36:26.643+0000 I CONTROL  [initandlisten] db version v3.2.6
2017-12-25T12:36:26.643+0000 I CONTROL  [initandlisten] git version: 05552b562c7a0b3143a729aaa0838e558dc49b25
2017-12-25T12:36:26.643+0000 I CONTROL  [initandlisten] OpenSSL version: OpenSSL 1.0.2m  2 Nov 2017
2017-12-25T12:36:26.643+0000 I CONTROL  [initandlisten] allocator: system
2017-12-25T12:36:26.643+0000 I CONTROL  [initandlisten] modules: none
2017-12-25T12:36:26.643+0000 I CONTROL  [initandlisten] build environment:
2017-12-25T12:36:26.643+0000 I CONTROL  [initandlisten]     distarch: x86_64
2017-12-25T12:36:26.643+0000 I CONTROL  [initandlisten]     target_arch: x86_64
2017-12-25T12:36:26.643+0000 I CONTROL  [initandlisten] options: {}
2017-12-25T12:36:26.644+0000 I -        [initandlisten] Detected data files in /data/db created by the 'mmapv1' storage engine, so setting the active storage engine to 'mmapv1'.
2017-12-25T12:36:26.653+0000 I JOURNAL  [initandlisten] journal dir=/data/db/journal
2017-12-25T12:36:26.654+0000 I JOURNAL  [initandlisten] recover : no journal files present, no recovery needed
2017-12-25T12:36:26.674+0000 I JOURNAL  [durability] Durability thread started
2017-12-25T12:36:26.675+0000 I JOURNAL  [journal writer] Journal writer thread started
2017-12-25T12:36:26.894+0000 I FTDC     [initandlisten] Initializing full-time diagnostic data capture with directory '/data/db/diagnostic.data'
2017-12-25T12:36:26.894+0000 I NETWORK  [HostnameCanonicalizationWorker] Starting hostname canonicalization worker
2017-12-25T12:36:26.894+0000 I NETWORK  [initandlisten] waiting for connections on port 27017

我做错了什么,如何调试?

2 个答案:

答案 0 :(得分:6)

我使用brew upgrade mongodb修正了错误。仍然不知道是什么问题。

据说最好按照其中一条指南upgrade mongodb来避免其他问题。

答案 1 :(得分:6)

我遇到了同样的问题。我在macOS High Sierra 10.13.3上。我的mongo版本是mongodb 3.2.7。我在documentation of mongodump

中读到了这个
MAC OSX SIERRA AND GO 1.6 INCOMPATIBILITY
Users running on Mac OSX Sierra require the 3.2.10 or newer version of mongodump.

我已升级到mongodb 3.6.2,我的问题已解决。