首页
学习
活动
专区
圈层
工具
发布
首页
学习
活动
专区
圈层
工具
MCP广场
社区首页 >问答首页 >在OS X上设置MySQL根用户密码

在OS X上设置MySQL根用户密码
EN

Stack Overflow用户
提问于 2011-06-25 07:37:57
回答 24查看 514.3K关注 0票数 250

我刚刚在Mac上安装了MySQL。下一步是设置根用户密码,所以我接下来这样做:

  1. 启动终端应用程序以访问Unix命令行。
  2. 在Unix提示符下执行以下命令:

$ cd /usr/local/mysql/bin $ ./mysqladmin -u根密码' password '

但是,当我执行以下命令时

$ ./mysql -u root,这是答案:

代码语言:javascript
运行
复制
Welcome to the MySQL monitor.  Commands end with ; or \g.
Your MySQL connection id is 224
Server version: 5.5.13 MySQL Community Server (GPL)

Copyright (c) 2000, 2010, Oracle and/or its affiliates. All rights reserved.

Oracle is a registered trademark of Oracle Corporation and/or its
affiliates. Other names may be trademarks of their respective
owners.

Type 'help;' or '\h' for help. Type '\c' to clear the current input statement.

mysql>

我不需要任何密码就可以进入mysql命令行!

为什么会这样呢?

EN
页面原文内容由Stack Overflow提供。腾讯云小微IT领域专用引擎提供翻译支持
原文链接:

https://stackoverflow.com/questions/6474775

复制
相关文章

相似问题

领券
问题归档专栏文章快讯文章归档关键词归档开发者手册归档开发者手册 Section 归档