After wiping my mac and starting fresh, I was having issues trying to install mySQL via homebrew. The connection to the download server kept timing out.
$ brew install mysql ==> Downloading http://downloads.mysql.com/archives/mysql-5.5/mysql-5.5.15.tar.gz curl: (7) couldn't connect to host Error: Download failed: http://downloads.mysql.com/archives/mysql-5.5/mysql-5.5.15.tar.gz
As it turns out, downloads.mysql.com doesn’t exist any more, so you’ll need to grab it from somewhere else and move it to the Homebrew cache directory. The following bit of code will do it for you:
curl ftp://ftp.ntua.gr/pub/databases/mysql/Downloads/MySQL-5.5/mysql-5.5.15.tar.gz > mysql-5.5.15.tar.gz mv mysql-5.5.15.tar.gz `brew --cache` brew install mysql
This downloads the code from another location and moves it into the Homebrew cache path, meaning that the recipe can find the source. You’ll need to make sure that you’re grabbing the correct version (5.5.15 at the time of writing), or homebrew might kick up a fuss.
Michael is a polyglot software engineer, committed to reducing complexity in systems and making them more predictable. Working with a variety of languages and tools, he shares his technical expertise to audiences all around the world at user groups and conferences. You can follow @mheap on Twitter