• mysql设置初始密码


    E:\zhurong_soft\MySQL\MySQL Server 8.1\bin>mysql -uroot
    Welcome to the MySQL monitor.  Commands end with ; or \g.
    Your MySQL connection id is 29
    Server version: 8.1.0 MySQL Community Server - GPL
    
    Copyright (c) 2000, 2023, Oracle and/or its affiliates.
    
    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> update user set authentication_string='' where user='root';
    ERROR 1046 (3D000): No database selected
    mysql> update user set authentication_string='' where user='root';
    ERROR 1046 (3D000): No database selected
    mysql> use mysql;
    Database changed
    mysql> update user set authentication_string='' where user='root';
    Query OK, 0 rows affected (0.00 sec)
    Rows matched: 1  Changed: 0  Warnings: 0
    
    mysql> ALTER USER 'root'@'localhost' IDENTIFIED BY '123456';
    Query OK, 0 rows affected (0.01 sec)
    
    mysql>
    
    • 1
    • 2
    • 3
    • 4
    • 5
    • 6
    • 7
    • 8
    • 9
    • 10
    • 11
    • 12
    • 13
    • 14
    • 15
    • 16
    • 17
    • 18
    • 19
    • 20
    • 21
    • 22
    • 23
    • 24
    • 25
    • 26
    • 27
    • 28

    在这里插入图片描述

  • 相关阅读:
    工具应用:使用JMeter实现Phpwind的性能测试!
    第二部分:聚合根
    查询&会议签字
    1、什么是复杂度?
    双线路捆绑
    Spring Security密码加密
    3 .NET Core笔试题
    机器学习-10-基于paddle实现神经网络
    Kubernetes学习01
    python【判断奇偶数】
  • 原文地址:https://blog.csdn.net/JavaBigData/article/details/133820515