brew安装mysql
1、
安装mysql5.7版本,不指定版本就默认安装最新的,目前最新是8
brew install mysql@5.7
2、
安装完进入/usr/local/Cellar/mysql@5.7目录,可以看到安装了5.7的哪些版本,我的是5.7.25
3、
打开.zshrc文件,在PATH下面加上这行export PATH=${PATH}:/usr/local/Cellar/mysql@5.7/5.7.25/bin,这样就能直接用mysql的bin目录的命令了
4、
启动mysql是mysql.server start,停止是mysql.server stop,启动后就可以直接连接了mysql -uroot -p,默认是没有密码的,回车就能进去了
5、
mysql读取配置的顺序是/etc/my.cnf /etc/mysql/my.cnf /usr/local/etc/my.cnf ~/.my.cnf,brew安装完的默认是有一份配置在/usr/local/etc/my.cnf,后续需要改配置就改这个文件好了。
brew安装mysql的更多相关文章
- Mac用brew安装MySQL
1.先安装brew 网址:https://brew.sh/ 复制命令:/usr/bin/ruby -e "$(curl -fsSL https://raw.githubusercontent ...
- brew 安装 mysql
在网上看到各种教程,都会出现ERROR 2002 (HY000): Can't connect to local MySQL server through socket '/tmp/mysql.soc ...
- mac使用brew安装mysql
1.安装mysql #brew install mysql 报错 Error: The following directories are not writable by your user: /us ...
- mac brew安装mysql
mac不自带mysql,这里需要重新安装,方法依然很简单 brew install mysql unset TMPDIR mysql_install_db --verbose --user=`whoa ...
- macOS 使用brew安装mysql,客户端连接不上
macos 使用brew安装mysql8.0后,使用mysql官方的workbench连接不上,出现√ mysql8.0 Authentication plugin 'caching_sha2_pas ...
- Homebrew(brew)安装MySQL成功后无法登录
Homebrew简称brew,OSX上的软件包管理工具,在Mac终端可以通过brew安装.更新.卸载各种软件,(简直就是神器级武器). 废话不多说,没安装brew自己去百度学习安装,这里就不多说了. ...
- mac使用brew安装mysql报RROR 2002 (HY000): Can't connect to local MySQL server through socket '/tmp/mysql.sock' (2)
使用mac安装mysql安装完后运行 mysql -uroot -p 报了 ERROR 2002 (HY000): Can't connect to local MySQL server throug ...
- Homebrew(brew)安装MySQL@5.7及配置
查找并确定自己需要安装的版本 brew search mysql ==> Formulae automysqlbackup mysql-connector-c mysql@5.5 mysql m ...
- Mac中使用brew安装mysql
若不考虑版本直接执行以下命令 brew install mysql 若要选择版本只要加上@版本即可,例如 brew install mysql@5.7 安装完后启动mysql mysql.server ...
随机推荐
- unity 归纳
1.获取控件四个角在屏幕上的坐标 Vector3[] corners = new Vector3[]; gameObject.GetComponent<RectTransform>().G ...
- esayui combotree 只能选择子节点
esayui combotree 只能选择子节点用onBeforeSelect:参数是node,节点被选中之前触发,返回false取消选择动作. 网上找了好多都没一个可用的,要想知道他是子节点还是根节 ...
- 【WebService】——SOAP、WSDL和UDDI
WebService的三要素:SOAP.WSDL和UDDI.soap用来描述传递信息的格式,wsdl描述如何访问具体的接口,uddi管理.分发查询WebService. 1.SOAP SOAP Sim ...
- spring笔记(一)
1. 回顾 Struts与Hibernate可以做什么事? Struts, Mvc中控制层解决方案 可以进行请求数据自动封装.类型转换.文件上传.效验… Hibernate, 持久层的解决方案: 可以 ...
- javascript prototype原型链的原理
javascript prototype原型链的原理 说到prototype,就不得不先说下new的过程. 我们先看看这样一段代码: <script type="text/javasc ...
- bootstrap-table 增加序号列(支持分页)
columns: [ { checkbox: true }, { title: '序号', align: 'center', halign: 'center', formatter: function ...
- [洛谷P1251]餐巾计划问题
题目大意:一个餐厅N天,每天需要$r_i$块餐巾.每块餐巾需要p元,每天用过的餐巾变脏,不能直接用.现在有快洗店和慢洗店,快洗店洗餐巾需要m天,每块花费f元:慢洗店洗餐巾需要n天,每块餐巾s元(m & ...
- HDU4370:0 or 1(最短路)
0 or 1 题目链接:http://acm.hdu.edu.cn/showproblem.php?pid=4370 Description: Given a n*n matrix Cij (1< ...
- HDU 4417 划分树写法
Problem Description Mario is world-famous plumber. His “burly” figure and amazing jumping ability re ...
- BAT定期删除N天前的文件
1.直接看脚本在win2008测试可用 ::clean logs @echo off title clean up logs ::delete logs FORFILES /P /C "cm ...