- I had installed
[email protected]from homebrew, but the diffusiongemfilecalled for version 5. As a result I was seeing errors frombundle exec rspec ./spec/workers/artist_match_worker_spec.rbcomplaining about the syntax of elasticsearch queries. - I tried to
brew install [email protected]but the 5.6 formula had been removed in the last month :(- https://formulae.brew.sh/formula/[email protected] gives a 404
- the only available versions in homebrew are v6 and latest
- I ran
brew install elasticsearch@6and tried to run the tests but there were breaking changes between 5 and 6, and I got more query errors from the same spec file. - I tried to install v5.6 again and Jon made me read the error output better. I discovered that you can still get to the deleted formula via the old git SHA, with this command:
git -C "$(brew --repo homebrew/core)" show 157167491^:Formula/[email protected]
- That will output the entire contents of that file, so I saved it to a local file:
git -C "$(brew --repo homebrew/core)" show 157167491^:Formula/[email protected] > [email protected]
- Now I could use homebrew to install the local formula:
brew install [email protected]- note the
.rbat the end of this command and the previous, as it distinguishes the local file from the formula within homebrew's official tap
- The output of the install mentioned that homebrew didn't create a symlink for it because it was an old/deleted version. I manually linked it with:
brew link [email protected] --force- The
forceflag was necessary because it's an old/deleted version.
- The
[email protected]service didn't start up correctly.brew services listshowed it as started, but yellow.- I ran
cat /Users/stevenhicks/Library/LaunchAgents/[email protected], which is the path associated with[email protected]outputted bybrew services list, to identify the location of the log file for this service. - It gave me the path
/usr/local/var/log/elasticsearch.log. - I tried to
cat /usr/local/var/log/elasticsearch.logbut the file didn't exist. - I created the file with
touch /usr/local/var/log/elasticsearch.log, hoping that the service would be able to tell me why it couldn't start. - I ran
brew services restart [email protected]to restart the service. It started up andbrew services listshowed it as green!
- I ran
- You can still get to deleted formulae
brew infolies about where the log/data paths are.cat ...plist(with the plist output bybrew services list) is a more accurate way to find the log/data paths.