Il mio problema è simile ad altri input e suggerimenti su questo sito, ma nessuno mi ha aiutato. Dopo aver installato MongoDB, non è stato avviato perché il database non è in esecuzione.MongoDB: Impossibile connettersi a 127.0.0.1:27017, motivo: errno: 61 Connessione rifiutata
Prima si tenta di eseguire mongo e ho risposto questo:
Mac-Pro-de-User: ~ user $ mongo
MongoDB shell version: 2.6.4
connecting to: test
2014-10-28T10: 47: 08713-0700 warning: Failed to connect to 127.0.0.1:27017, reason: errno: 61 Connection refused
2014-10-28T10: 47: 08713-0700 Error: could not connect to server 127.0.0.1:27017 (127.0.0.1) Attempt connection failed at src/mongo/shell/mongo.js: 146
exception: connect failed
Quindi provare a controllare la mongod e ho risposto questo:
Mac-Pro-de-User: ~ user $ mongod
mongod --help for help and startup options
2014-10-28T10: 59: 34485-0700 [initandlisten] MongoDB starting: pid = 926 port = 27017 dbpath =/data/db host = 64-bit Mac-Pro-de-Ernesto.local
2014-10-28T10: 59: 34485-0700 [initandlisten]
2014-10-28T10: 59: 34485-0700 [initandlisten] ** WARNING: soft rlimits too low. Number of files is 256, Should be at Least 1000
2014-10-28T10: 59: 34485-0700 [initandlisten] db version v2.6.4
2014-10-28T10: 59: 34485-0700 [initandlisten] git version: 3a830be0eb92d772aa855ebb711ac91d658ee910
2014-10-28T10: 59: 34485-0700 [initandlisten] Build info: Darwin bs-osx108-4 12.5.0 Darwin Kernel Version 12.5.0: Sun Sep 29 13:33:47 PDT 2013; root: xnu-2050.48.12 ~ 1/x86_64 RELEASE_X86_64 BOOST_LIB_VERSION = 1_49
2014-10-28T10: 59: 34485-0700 [initandlisten] allocator: system
2014-10-28T10: 59: 34485-0700 [initandlisten] options: {}
2014-10-28T10: 59: 34486-0700 [initandlisten] journal dir =/data/db/journal
2014-10-28T10: 59: 34486-0700 [initandlisten] recover: no journal files present, no recovery needed
2014-10-28T10: 59: 34500-0700 [FileAllocator] allocating new datafile /data/db/local.ns, filling zeroes With ...
2014-10-28T10: 59: 34500-0700 [FileAllocator] creating directory/data/db/_tmp
2014-10-28T10: 59: 34512-0700 [FileAllocator] done allocating datafile /data/db/local.ns, size: 16MB, took 0.011 secs
2014-10-28T10: 59: 34726-0700 [FileAllocator] allocating new datafile /data/db/local.0, filling zeroes With ...
2014-10-28T10: 59: 35398-0700 [FileAllocator] done allocating datafile /data/db/local.0, size: 64MB, took 0.671 secs
2014-10-28T10: 59: 35695-0700 [initandlisten] build index on: local.startup_log properties: {v: 1, key: {_id: 1}, name: "_id_" ns "local.startup_log"}
2014-10-28T10: 59: 35695-0700 [initandlisten] index added to empty collection
2014-10-28T10: 59: 35695-0700 [initandlisten] Local command $ cmd command. Create {create: "startup_log" size: 10485760, capped: true} ntoreturn: 1 KeyUpdates: 0 numYields: 0 reslen: 37 1194ms
2014-10-28T10: 59: 35695-0700 [initandlisten] waiting for connections on port 27017
2014-10-28T11: 00: 34516-0700 [clientcursormon] mem (MB) res: 33 virt: 2653
2014-10-28T11: 00: 34516-0700 [clientcursormon] mapped (incl journal view): 160
2014-10-28T11: 00: 34516-0700 [clientcursormon] connections: 0
Quindi provare di nuovo la connessione e passare un po 'di tempo, e di nuovo dice lo stesso:
2014-10-28T11: 05: 34589-0700 [clientcursormon] mem (MB) res: 33 virt: 2653
2014-10-28T11: 05: 34589-0700 [clientcursormon] mapped (incl journal view): 160
2014-10-28T11: 05: 34589-0700 [clientcursormon] connections: 0
E così via. Se puoi aiutare lo apprezzerebbe molto.
PS: C'è già l'/ data/db con 777 permessi, e sto usando OSX Mavericks 10.9.5
Basta metterlo da parte - ho semplicemente acceso il mio computer e spento e ha iniziato a lavorare di nuovo. Questo mi è successo due volte – James111