数据库|mysql教程
mac,homebrew,MySQL
数据库-mysql教程
如果你电脑是Mac的,使用homebrew安装MySQL是一个非常便捷的方式,但是还是会出现一些问题。下面通过本文给大家介绍解决mac使用homebrew安装MySQL无法登陆问题,需要的朋友可以参考下
微信大转盘源码 c,vscode背景图片透明,ubuntu待机蓝牙,tomcat有证书吗,知名公司爬虫,ecshop支持php7,湖南新品seo收益转化率lzw
如果你电脑是Mac的,使用homebrew安装MySQL是一个非常便捷的方式,但是还是会出现一些问题;
asp点餐系统源码下载,vscode打包指令,slack ubuntu,tomcat日志搜索,sqlite框架封装,服务器尺寸规格,mobiscroll时间插件,webapp的前端框架,网络爬虫为什么叫爬虫,php上传慢,企业seo培训班,cms网站有哪些,网页钟表,时时彩html模板,页面上自由漂浮的图片代码,188旅游管理系统v7.0,抽奖程序下载lzw
首先保证你已经安装了mysql,如果是通过homebrew安装的,输入mysql.server start
启动服务
android源码大小,vscode c c 索引,ubuntu 调出命令,网页tomcat怎么启动,爬虫造假,php 网站授权,绵阳seo优化哪家好,有后台的导航网站源码,学生管理系统网站模板简lzw
如果在输入
mysql -u root
出现这个错误ERROR 1045 (28000): Access denied for user ‘zhongchengming’@’localhost’ (using password: YES),应该是修改初始密码没有成功
解决步骤
(1)终端输入mysqld_safe –skip-grant-tables 显示如下
-03-21T11:44:11.6NZ mysqld_safe Logging to /usr/local/var/mysql/zhongchengmingdeMacBook-Air.local.err.-03-21T11:44:11.6NZ mysqld_safe Logging to /usr/local/var/mysql/zhongchengmingdeMacBook-Air.local.err.-03-21T11:44:11.6NZ mysqld_safe A mysqld process already exists
(2)再次输入mysql -u root显示如下
Welcome to the MySQL monitor. Commands end with ; or \g.Your MySQL connection id is 10Server version: 5.7.17 HomebrewCopyright (c) 2000, , Oracle and/or its affiliates. All rights reserved.Oracle is a registered trademark of Oracle Corporation and/or itsaffiliates. Other names may be trademarks of their respectiveowners.Type help; or \h for help. Type \c to clear the current input statement.mysql>
(3)终端输入 use mysql显示如下
Reading table information for completion of table and column namesYou can turn off this feature to get a quicker startup with -ADatabase changedmysql>
(4)修改密码UPDATE mysql.user SET authentication_string=PASSWORD(你的密码) WHERE User=
oot;
成功 Query OK, 1 row affected, 1 warning (0.05 sec)
Rows matched: 1 Changed: 1 Warnings: 1
如果觉得《详解mac使用homebrew安装MySQL无法登陆问题的解决办法》对你有帮助,请点赞、收藏,并留下你的观点哦!