I just installed mysql with homebrew on mac OSX.
The very first thing I did after the installation was the following symlink: /usr/bin/mysql -> /usr/local/Cellar/mysql/5.5.15/bin/mysql
But if I type 'mysql', instead of having the mysql-client interface, I get into /var/empty/, exactly like if I was doing a cd /var/empty/
Why, and how can I fix this problem so that the mysql command execute the mysql client ?
This can occur if you're using zsh since it will drop you into a user's home directory just by typing their user name. So if mysql isn't in your path (which it wouldn't be since it's a keg only formula), but you have a mysql user, then this is the behavior you would see. You can force Homebrew to link mysql into your path with brew link --force mysql55
.
Does your shell have a 'mysql' alias, perhaps, which is malfunctioning? alias
at the prompt will show any aliases that are set.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With