Please note we will close your issue without comment if you delete, do not read or do not fill out the issue checklist below and provide ALL the requested information. If you repeatedly fail to use the issue template, we will block you from ever submitting issues to Homebrew again.
brew installing one, specific Homebrew/homebrew-core formula (not cask or tap) and not every time you run brew? If it's a general brew problem please file this issue at https://github.com/Homebrew/brew/issues/new. If it's a brew cask problem please file this issue at https://github.com/caskroom/homebrew-cask/issues/new. If it's a tap (e.g. Homebrew/homebrew-php) problem please file this issue at the tap.brew update and retried your prior step?brew doctor, fixed all issues and retried your prior step?brew gist-logs <formula> (where <formula> is the name of the formula that failed) and included the output link?brew gist-logs didn't work: ran brew config and brew doctor and included their output with your issue?To help us debug your issue please explain:
brew install commands)To get formulae added or changed in Homebrew please file a Pull Request
We will close issues requesting formulae changes.
When I start mongo CLI client I get the error:
MongoDB shell version v3.6.2
connecting to: mongodb://127.0.0.1:27017
2018-01-16T14:45:03.364+0300 W NETWORK [thread1] Failed to connect to 127.0.0.1:27017, in(checking socket for error after poll), reason: Connection refused
2018-01-16T14:45:03.364+0300 E QUERY [thread1] Error: couldn't connect to server 127.0.0.1:27017, connection attempt failed :
connect@src/mongo/shell/mongo.js:251:13
@(connect):1:6
exception: connect failed
Tried to reinstall mongodb and run brew services start mongodb.
If mongodb is started manually the CLI client connects well.
brew doctor > Your system is ready to brew.
brew gist-logs > Error: No logs.
brew config >
HOMEBREW_VERSION: 1.4.3
ORIGIN: https://github.com/Homebrew/brew
HEAD: 987805d3dcd4c8dbc70127399d4ea7aee8e98c21
Last commit: 8 days ago
Core tap ORIGIN: https://github.com/Homebrew/homebrew-core
Core tap HEAD: fb1f1e43ab4c60c833e40cd5005b345a92f47886
Core tap last commit: 21 minutes ago
HOMEBREW_PREFIX: /usr/local
CPU: quad-core 64-bit haswell
Homebrew Ruby: 2.3.3 => /System/Library/Frameworks/Ruby.framework/Versions/2.3/usr/bin/ruby
Clang: 9.0 build 900
Git: 2.14.3 => /Applications/Xcode.app/Contents/Developer/usr/bin/git
Curl: 7.54.0 => /usr/bin/curl
Perl: /usr/local/bin/perl => /usr/local/Cellar/perl/5.26.1/bin/perl
Python: /usr/local/opt/python/libexec/bin/python => /usr/local/Cellar/python/2.7.14_2/Frameworks/Python.framework/Versions/2.7/bin/python2.7
Ruby: /usr/local/bin/ruby => /usr/local/Cellar/ruby/2.5.0/bin/ruby
Java: 1.8.0_131
macOS: 10.13.2-x86_64
Xcode: 9.2
CLT: 9.2.0.0.1.1510905681
X11: N/A
https://github.com/Homebrew/brew/issues/3157 looks like a similar issue, but closed unresolved.
This is probably a permissions/ownership issue. Try
sudo chown -R $(whoami) /usr/local/*
@ilovezfs it didn't help.
What's the output of
ps aux | grep mongo
Also what's the output of
cat /usr/local/var/log/mongodb/output.log
srg 19738 0.0 0.0 4276968 888 s000 S+ 5:40PM 0:00.00 grep --color=auto --exclude-dir=.bzr --exclude-dir=CVS --exclude-dir=.git --exclude-dir=.hg --exclude-dir=.svn mongo
The result of cat /usr/local/var/log/mongodb/output.log is empty.
OK. So it's not running.
brew services stop mongodb
brew services start mongodb
ps aux | grep mongo
cat /usr/local/var/log/mongodb/output.log
Looks like nothing changed.
srg 21084 0.0 0.0 4267752 536 s000 R+ 5:47PM 0:00.00 grep --color=auto --exclude-dir=.bzr --exclude-dir=CVS --exclude-dir=.git --exclude-dir=.hg --exclude-dir=.svn mongo
The result of cat /usr/local/var/log/mongodb/output.log is empty.
what's the output of
cat ~srg/Library/LaunchAgents/homebrew.mxcl.mongodb.plist
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
<key>Label</key>
<string>homebrew.mxcl.mongodb</string>
<key>ProgramArguments</key>
<array>
<string>/usr/local/opt/mongodb/bin/mongod</string>
<string>--config</string>
<string>/usr/local/etc/mongod.conf</string>
</array>
<key>RunAtLoad</key>
<true/>
<key>KeepAlive</key>
<false/>
<key>WorkingDirectory</key>
<string>/usr/local</string>
<key>StandardErrorPath</key>
<string>/usr/local/var/log/mongodb/output.log</string>
<key>StandardOutPath</key>
<string>/usr/local/var/log/mongodb/output.log</string>
<key>HardResourceLimits</key>
<dict>
<key>NumberOfFiles</key>
<integer>4096</integer>
</dict>
<key>SoftResourceLimits</key>
<dict>
<key>NumberOfFiles</key>
<integer>4096</integer>
</dict>
</dict>
</plist>
And
brew services stop -dv mongodb
brew services start -dv mongodb
dev » brew services stop -dv mongodb ~/dev 1 ↵
/usr/local/Homebrew/Library/Homebrew/brew.rb (Formulary::FormulaLoader): loading /usr/local/Homebrew/Library/Taps/homebrew/homebrew-core/Formula/mongodb.rb
Stopping `mongodb`... (might take a while)
==> Successfully stopped `mongodb` (label: homebrew.mxcl.mongodb)
/usr/local/Homebrew/Library/Homebrew/brew.rb:107:in `exit'
/usr/local/Homebrew/Library/Homebrew/brew.rb:107:in `<main>'
dev » brew services start -dv mongodb ~/dev
/usr/local/Homebrew/Library/Homebrew/brew.rb (Formulary::FormulaLoader): loading /usr/local/Homebrew/Library/Taps/homebrew/homebrew-core/Formula/mongodb.rb
==> Generated plist for mongodb:
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
<key>Label</key>
<string>homebrew.mxcl.mongodb</string>
<key>ProgramArguments</key>
<array>
<string>/usr/local/opt/mongodb/bin/mongod</string>
<string>--config</string>
<string>/usr/local/etc/mongod.conf</string>
</array>
<key>RunAtLoad</key>
<true/>
<key>KeepAlive</key>
<false/>
<key>WorkingDirectory</key>
<string>/usr/local</string>
<key>StandardErrorPath</key>
<string>/usr/local/var/log/mongodb/output.log</string>
<key>StandardOutPath</key>
<string>/usr/local/var/log/mongodb/output.log</string>
<key>HardResourceLimits</key>
<dict>
<key>NumberOfFiles</key>
<integer>4096</integer>
</dict>
<key>SoftResourceLimits</key>
<dict>
<key>NumberOfFiles</key>
<integer>4096</integer>
</dict>
</dict>
</plist>
/bin/launchctl enable gui/501/homebrew.mxcl.mongodb
/bin/launchctl bootstrap gui/501 /Users/srg/Library/LaunchAgents/homebrew.mxcl.mongodb.plist
==> Successfully started `mongodb` (label: homebrew.mxcl.mongodb)
/usr/local/Homebrew/Library/Homebrew/brew.rb:107:in `exit'
/usr/local/Homebrew/Library/Homebrew/brew.rb:107:in `<main>'
What's the output of id
uid=501(srg) gid=20(staff) groups=20(staff),12(everyone),61(localaccounts),79(_appserverusr),80(admin),81(_appserveradm),98(_lpadmin),701(com.apple.sharepoint.group.1),33(_appstore),100(_lpoperator),204(_developer),250(_analyticsusers),395(com.apple.access_ftp),398(com.apple.access_screensharing),399(com.apple.access_ssh)
ps aux | grep mongo
srg 22680 0.0 0.0 4267752 864 s000 S+ 6:18PM 0:00.00 grep --color=auto --exclude-dir=.bzr --exclude-dir=CVS --exclude-dir=.git --exclude-dir=.hg --exclude-dir=.svn mongo
Have you tried rebooting?
Yep, didn't help. 🙂
What happens if you
/usr/local/opt/mongodb/bin/mongod --config /usr/local/etc/mongod.conf
No output, the client still gives the same error.
what happens when you run the command? It just exits and gives you new prompt?
Yes.
OK that is bad. It's supposed to block and not exit.
What's the output of cat /usr/local/etc/mongod.conf
systemLog:
destination: file
path: /usr/local/var/log/mongodb/mongo.log
logAppend: true
storage:
dbPath: /usr/local/var/mongodb
net:
bindIp: 127.0.0.1
Can you post a gist of /usr/local/var/log/mongodb/mongo.log
Well there ya go!
2018-01-16T18:29:05.183+0300 I STORAGE [initandlisten] wiredtiger_open config: create,cache_size=3584M,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),
2018-01-16T18:29:05.380+0300 I STORAGE [initandlisten] WiredTiger message [1516116545:380414][22728:0x7fff9a904340], txn-recover: Main recovery loop: starting at 180/768
2018-01-16T18:29:05.499+0300 I STORAGE [initandlisten] WiredTiger message [1516116545:499015][22728:0x7fff9a904340], txn-recover: Recovering log 180 through 181
2018-01-16T18:29:05.573+0300 I STORAGE [initandlisten] WiredTiger message [1516116545:573483][22728:0x7fff9a904340], txn-recover: Recovering log 181 through 181
2018-01-16T18:29:05.699+0300 I CONTROL [initandlisten]
2018-01-16T18:29:05.699+0300 I CONTROL [initandlisten] ** WARNING: Access control is not enabled for the database.
2018-01-16T18:29:05.699+0300 I CONTROL [initandlisten] ** Read and write access to data and configuration is unrestricted.
2018-01-16T18:29:05.699+0300 I CONTROL [initandlisten]
2018-01-16T18:29:05.730+0300 F CONTROL [initandlisten] ** IMPORTANT: UPGRADE PROBLEM: The data files need to be fully upgraded to version 3.4 before attempting an upgrade to 3.6; see http://dochub.mongodb.org/core/3.6-upgrade-fcv for more details.
2018-01-16T18:29:05.730+0300 I NETWORK [initandlisten] shutdown: going to close listening sockets...
2018-01-16T18:29:05.730+0300 I NETWORK [initandlisten] removing socket file: /tmp/mongodb-27017.sock
2018-01-16T18:29:05.731+0300 I REPL [initandlisten] shutdown: removing all drop-pending collections...
2018-01-16T18:29:05.731+0300 I REPL [initandlisten] shutdown: removing checkpointTimestamp collection...
2018-01-16T18:29:05.731+0300 I STORAGE [initandlisten] WiredTigerKVEngine shutting down
2018-01-16T18:29:06.028+0300 I STORAGE [initandlisten] WiredTiger message [1516116546:28559][22728:0x7fff9a904340], txn-recover: Main recovery loop: starting at 181/3328
2018-01-16T18:29:06.148+0300 I STORAGE [initandlisten] WiredTiger message [1516116546:148826][22728:0x7fff9a904340], txn-recover: Recovering log 181 through 182
2018-01-16T18:29:06.226+0300 I STORAGE [initandlisten] WiredTiger message [1516116546:226819][22728:0x7fff9a904340], txn-recover: Recovering log 182 through 182
2018-01-16T18:29:06.502+0300 I STORAGE [initandlisten] shutdown: removing fs lock...
2018-01-16T18:29:06.505+0300 I CONTROL [initandlisten] now exiting
2018-01-16T18:29:06.505+0300 I CONTROL [initandlisten] shutting down with code:62
I haven't done a mongodb upgrade myself, but you probably can brew install [email protected] and use that to get the database upgraded to 3.4, and then run 3.6 successfully.
If you don't care about the existing data, then just start over by moving /usr/local/var/mongodb out of the way.
See http://dochub.mongodb.org/core/3.6-upgrade-fcv as noted in the log.
I removed /usr/local/var/mongodb and removed/installed again mongodb, nothing changed. I don't care about the existing data.
I used version 3.6 before on this machine and it worked fine.
mv /usr/local/var/log/mongodb/mongo.log ~/mongodb-old.log
/usr/local/opt/mongodb/bin/mongod --config /usr/local/etc/mongod.conf
and what does the new log file show?
2018-01-16T18:49:49.615+0300 I CONTROL [initandlisten] MongoDB starting : pid=24716 port=27017 dbpath=/usr/local/var/mongodb 64-bit host=MacBook-Pro.lan
2018-01-16T18:49:49.615+0300 I CONTROL [initandlisten] db version v3.6.2
2018-01-16T18:49:49.615+0300 I CONTROL [initandlisten] git version: 489d177dbd0f0420a8ca04d39fd78d0a2c539420
2018-01-16T18:49:49.615+0300 I CONTROL [initandlisten] OpenSSL version: OpenSSL 1.0.2n 7 Dec 2017
2018-01-16T18:49:49.615+0300 I CONTROL [initandlisten] allocator: system
2018-01-16T18:49:49.615+0300 I CONTROL [initandlisten] modules: none
2018-01-16T18:49:49.615+0300 I CONTROL [initandlisten] build environment:
2018-01-16T18:49:49.615+0300 I CONTROL [initandlisten] distarch: x86_64
2018-01-16T18:49:49.615+0300 I CONTROL [initandlisten] target_arch: x86_64
2018-01-16T18:49:49.615+0300 I CONTROL [initandlisten] options: { config: "/usr/local/etc/mongod.conf", net: { bindIp: "127.0.0.1" }, storage: { dbPath: "/usr/local/var/mongodb" }, systemLog: { destination: "file", logAppend: true, path: "/usr/local/var/log/mongodb/mongo.log" } }
2018-01-16T18:49:49.616+0300 I - [initandlisten] Detected data files in /usr/local/var/mongodb created by the 'wiredTiger' storage engine, so setting the active storage engine to 'wiredTiger'.
2018-01-16T18:49:49.616+0300 I STORAGE [initandlisten] wiredtiger_open config: create,cache_size=3584M,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),
2018-01-16T18:49:49.819+0300 I STORAGE [initandlisten] WiredTiger message [1516117789:819582][24716:0x7fff9a904340], txn-recover: Main recovery loop: starting at 1/13696
2018-01-16T18:49:49.940+0300 I STORAGE [initandlisten] WiredTiger message [1516117789:940019][24716:0x7fff9a904340], txn-recover: Recovering log 1 through 2
2018-01-16T18:49:50.014+0300 I STORAGE [initandlisten] WiredTiger message [1516117790:14916][24716:0x7fff9a904340], txn-recover: Recovering log 2 through 2
2018-01-16T18:49:50.155+0300 I CONTROL [initandlisten]
2018-01-16T18:49:50.155+0300 I CONTROL [initandlisten] ** WARNING: Access control is not enabled for the database.
2018-01-16T18:49:50.155+0300 I CONTROL [initandlisten] ** Read and write access to data and configuration is unrestricted.
2018-01-16T18:49:50.155+0300 I CONTROL [initandlisten]
2018-01-16T18:49:50.161+0300 I FTDC [initandlisten] Initializing full-time diagnostic data capture with directory '/usr/local/var/mongodb/diagnostic.data'
2018-01-16T18:49:50.162+0300 I NETWORK [initandlisten] waiting for connections on port 27017
and can you connect?
Yes, I can.
Good. And how about via brew services?
That is the problem. I can connect to it when mongodb is run manually, but can't when it run with brew services despite brew services list gives mongodb started srg /Users/srg/Library/LaunchAgents/homebrew.mxcl.mongodb.plist
Yeah it will say that if it copies the plist and run the launchctl commands. Don't read too much into it.
What's in the log file after starting it with brew services?
2018-01-16T18:49:49.615+0300 I CONTROL [initandlisten] MongoDB starting : pid=24716 port=27017 dbpath=/usr/local/var/mongodb 64-bit host=MacBook-Pro.lan
2018-01-16T18:49:49.615+0300 I CONTROL [initandlisten] db version v3.6.2
2018-01-16T18:49:49.615+0300 I CONTROL [initandlisten] git version: 489d177dbd0f0420a8ca04d39fd78d0a2c539420
2018-01-16T18:49:49.615+0300 I CONTROL [initandlisten] OpenSSL version: OpenSSL 1.0.2n 7 Dec 2017
2018-01-16T18:49:49.615+0300 I CONTROL [initandlisten] allocator: system
2018-01-16T18:49:49.615+0300 I CONTROL [initandlisten] modules: none
2018-01-16T18:49:49.615+0300 I CONTROL [initandlisten] build environment:
2018-01-16T18:49:49.615+0300 I CONTROL [initandlisten] distarch: x86_64
2018-01-16T18:49:49.615+0300 I CONTROL [initandlisten] target_arch: x86_64
2018-01-16T18:49:49.615+0300 I CONTROL [initandlisten] options: { config: "/usr/local/etc/mongod.conf", net: { bindIp: "127.0.0.1" }, storage: { dbPath: "/usr/local/var/mongodb" }, systemLog: { destination: "file", logAppend: true, path: "/usr/local/var/log/mongodb/mongo.log" } }
2018-01-16T18:49:49.616+0300 I - [initandlisten] Detected data files in /usr/local/var/mongodb created by the 'wiredTiger' storage engine, so setting the active storage engine to 'wiredTiger'.
2018-01-16T18:49:49.616+0300 I STORAGE [initandlisten] wiredtiger_open config: create,cache_size=3584M,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),
2018-01-16T18:49:49.819+0300 I STORAGE [initandlisten] WiredTiger message [1516117789:819582][24716:0x7fff9a904340], txn-recover: Main recovery loop: starting at 1/13696
2018-01-16T18:49:49.940+0300 I STORAGE [initandlisten] WiredTiger message [1516117789:940019][24716:0x7fff9a904340], txn-recover: Recovering log 1 through 2
2018-01-16T18:49:50.014+0300 I STORAGE [initandlisten] WiredTiger message [1516117790:14916][24716:0x7fff9a904340], txn-recover: Recovering log 2 through 2
2018-01-16T18:49:50.155+0300 I CONTROL [initandlisten]
2018-01-16T18:49:50.155+0300 I CONTROL [initandlisten] ** WARNING: Access control is not enabled for the database.
2018-01-16T18:49:50.155+0300 I CONTROL [initandlisten] ** Read and write access to data and configuration is unrestricted.
2018-01-16T18:49:50.155+0300 I CONTROL [initandlisten]
2018-01-16T18:49:50.161+0300 I FTDC [initandlisten] Initializing full-time diagnostic data capture with directory '/usr/local/var/mongodb/diagnostic.data'
2018-01-16T18:49:50.162+0300 I NETWORK [initandlisten] waiting for connections on port 27017
2018-01-16T18:51:21.878+0300 I NETWORK [listener] connection accepted from 127.0.0.1:50119 #1 (1 connection now open)
2018-01-16T18:51:21.878+0300 I NETWORK [conn1] received client metadata from 127.0.0.1:50119 conn: { application: { name: "MongoDB Shell" }, driver: { name: "MongoDB Internal Client", version: "3.6.2" }, os: { type: "Darwin", name: "Mac OS X", architecture: "x86_64", version: "17.3.0" } }
2018-01-16T18:51:37.668+0300 I NETWORK [conn1] end connection 127.0.0.1:50119 (0 connections now open)
2018-01-16T18:51:44.168+0300 I CONTROL [signalProcessingThread] got signal 2 (Interrupt: 2), will terminate after current cmd ends
2018-01-16T18:51:44.168+0300 I NETWORK [signalProcessingThread] shutdown: going to close listening sockets...
2018-01-16T18:51:44.168+0300 I NETWORK [signalProcessingThread] removing socket file: /tmp/mongodb-27017.sock
2018-01-16T18:51:44.169+0300 I FTDC [signalProcessingThread] Shutting down full-time diagnostic data capture
2018-01-16T18:51:44.171+0300 I STORAGE [signalProcessingThread] WiredTigerKVEngine shutting down
2018-01-16T18:51:44.296+0300 I STORAGE [signalProcessingThread] shutdown: removing fs lock...
2018-01-16T18:51:44.297+0300 I CONTROL [signalProcessingThread] now exiting
2018-01-16T18:51:44.297+0300 I CONTROL [signalProcessingThread] shutting down with code:0
2018-01-16T18:56:20.212+0300 I CONTROL [main] ***** SERVER RESTARTED *****
2018-01-16T18:56:20.231+0300 I CONTROL [initandlisten] MongoDB starting : pid=25211 port=27017 dbpath=/usr/local/var/mongodb 64-bit host=MacBook-Pro.lan
2018-01-16T18:56:20.231+0300 I CONTROL [initandlisten] db version v3.6.2
2018-01-16T18:56:20.231+0300 I CONTROL [initandlisten] git version: 489d177dbd0f0420a8ca04d39fd78d0a2c539420
2018-01-16T18:56:20.231+0300 I CONTROL [initandlisten] OpenSSL version: OpenSSL 1.0.2n 7 Dec 2017
2018-01-16T18:56:20.231+0300 I CONTROL [initandlisten] allocator: system
2018-01-16T18:56:20.231+0300 I CONTROL [initandlisten] modules: none
2018-01-16T18:56:20.231+0300 I CONTROL [initandlisten] build environment:
2018-01-16T18:56:20.231+0300 I CONTROL [initandlisten] distarch: x86_64
2018-01-16T18:56:20.231+0300 I CONTROL [initandlisten] target_arch: x86_64
2018-01-16T18:56:20.231+0300 I CONTROL [initandlisten] options: { config: "/usr/local/etc/mongod.conf", net: { bindIp: "127.0.0.1" }, storage: { dbPath: "/usr/local/var/mongodb" }, systemLog: { destination: "file", logAppend: true, path: "/usr/local/var/log/mongodb/mongo.log" } }
2018-01-16T18:56:20.232+0300 I - [initandlisten] Detected data files in /usr/local/var/mongodb created by the 'wiredTiger' storage engine, so setting the active storage engine to 'wiredTiger'.
2018-01-16T18:56:20.232+0300 I STORAGE [initandlisten] wiredtiger_open config: create,cache_size=3584M,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),
2018-01-16T18:56:20.456+0300 I STORAGE [initandlisten] WiredTiger message [1516118180:456262][25211:0x7fff9a904340], txn-recover: Main recovery loop: starting at 2/6272
2018-01-16T18:56:20.587+0300 I STORAGE [initandlisten] WiredTiger message [1516118180:587785][25211:0x7fff9a904340], txn-recover: Recovering log 2 through 3
2018-01-16T18:56:20.684+0300 I STORAGE [initandlisten] WiredTiger message [1516118180:684632][25211:0x7fff9a904340], txn-recover: Recovering log 3 through 3
2018-01-16T18:56:20.823+0300 I CONTROL [initandlisten]
2018-01-16T18:56:20.823+0300 I CONTROL [initandlisten] ** WARNING: Access control is not enabled for the database.
2018-01-16T18:56:20.823+0300 I CONTROL [initandlisten] ** Read and write access to data and configuration is unrestricted.
2018-01-16T18:56:20.823+0300 I CONTROL [initandlisten]
2018-01-16T18:56:20.830+0300 I FTDC [initandlisten] Initializing full-time diagnostic data capture with directory '/usr/local/var/mongodb/diagnostic.data'
2018-01-16T18:56:20.831+0300 I NETWORK [initandlisten] waiting for connections on port 27017
@ilovezfs I don't know why, but now I can connect to it. Thank you for the help anyway. 🙂
You're welcome! Make sure it survives a reboot :)
So I seem to be having the same issue @ilovezfs. Should I make a new issue or continue here?
Looks like link in log is broken. This worked for me:
https://docs.mongodb.com/manual/release-notes/3.6-upgrade-standalone/
I had the same issue but didn't had the same luck as @osenvosem, it didn't fix magically.
I will write the steps that worked for me since I lost like two hours trying different things, I really wanted to make it work using Homebrew since it's the recommended way to run mongo in mac and almost the only one that people actually use.
1) downloaded mongodb without homebrew from here: https://docs.mongodb.com/manual/tutorial/install-mongodb-on-os-x/#run-mongodb
2) installed, following this steps https://docs.mongodb.com/manual/tutorial/install-mongodb-on-os-x/#run-mongodb
3) I installed it in /Applications/mongodb, so I added to my ~/.bash_profile
# mongo
export PATH="/Applications/mongodb/bin:${PATH}"
Optional if you want it to run when your system starts
4) Since everybody launchs it as a brew service it was difficult, but I found this: https://gist.github.com/ghalusa/5de968091f9adc1dd037
basically you have to run
[sudo] vim /Library/LaunchDaemons/org.mongo.mongod.plist
and paste that gist replacing the folders for yours
5) To avoid restarting to launch the service you can run
sudo launchctl load -w ~/Library/LaunchAgents/org.mongo.mongod.plist
Most helpful comment
So I seem to be having the same issue @ilovezfs. Should I make a new issue or continue here?