Remote Accessing HomeBrew’d MySQL on MacOS  

I’ve recently been proof of concepting a new idea for work. It involves local and external access to MySQL servers. While transitioning from local development to a Vagrant VM I discovered the VM couldn’t access my host local MySQL server.

Googling turned up some obvious answers, find my.cnf and remove bind_address = I had installed MySQL using HomeBrew which installed MySQL to /usr/local/Cellar/mysql/5.7.10. My my.cnf configuration file was located in support_files within this directory. Much to my dismay there was no bind_address =

Running sudo lsof -i -n -P | grep mysql within the shell told me MySQL was indeed binding to despite the configuration file. Executing ps aux | grep -i mysqld was more enlightening, telling me the daemon was being passed the bind_address argument directly. This led me to the DBA Exchange post giving me what I needed:

  1. Edit /usr/local/Cellar/mysql//homebrew.mxcl.mysql.plist
    1. replace --bind-address= with bind-address=* or --bind-address= (see MySQL documentation on bind-address)
  2. Restart mysql using brew services restart mysql

Now read this

Consistency in Python Development

Consistency Consistency is important. Make sure that what you think you’re building is actually what you’re building. If you’re developing and testing in a Window’s environment but are intending to deploy to a Linux environment you’re... Continue →