修改MYSQL默认账户密码
在安装完MySQL数据库后,必须修改数据库的默认账号密码,以保证数据库的安全性,以下为操作步骤:
#mysql
mysql> use mysql;
Database changed
mysql> select user,password,host from user;
+-------+-------------------------------------------+-----------------+
| user | password | host |
+-------+-------------------------------------------+-----------------+
| root | | localhost |
| root | | email-admin |
自定义qq头像
| root | | 127.0.0.1 |
| root | | ::1 |
八月十五月儿圆儿歌歌词| | | localhost |
| | | email-admin |
| root | | % |露天温泉
查看发现数据库默认root账号和空账号都未设置密码
修改root用户的密码
mysql> update user set password=PASSWORD('yourpassword') where user='root' ;
Query OK, 5 rows affected (0.00 sec)
Rows matched: 5 Changed: 5 Warnings: 0
删除空账号
mysql> delete from user where user='';
Query OK, 2 rows affected (0.00 sec)
mysql> select user,password,host from user;
+-------+-------------------------------------------+-----------------+
| user | password | host |
+-------+-------------------------------------------+-----------------+
| root | *5A85E100F2A0D4AD5805DD6E3331937747369E5B | localhost | | root | *5A85E100F2A0D4AD5805DD6E3331937747369E5B | email-admin | | root | *5A85E100F2A0D4AD5805DD6E3331937747369E5B | 127.0.0.1 | | root | *5A85E100F2A0D4AD5805DD6E3331937747369E5B | ::1 |
| root | *5A85E100F2A0D4AD5805DD6E3331937747369E5B | % |
八角亭迷雾小说最后刷新缓存,确保新的密码立即开始使用
mysql>flush privileges;
qq爱情留言qq飞车音乐库Query OK, 0 rows affected (0.01 sec)
版权声明:本站内容均来自互联网,仅供演示用,请勿用于商业和其他非法用途。如果侵犯了您的权益请与我们联系QQ:729038198,我们将在24小时内删除。
发表评论