zoukankan      html  css  js  c++  java
  • 更改数据库登陆密码




    登陆数据库,进入mysql数据库:


    MariaDB [(none)]> use mysql; Reading table information for completion of table and column names You can turn off this feature to get a quicker startup with -A Database changed MariaDB [mysql]>
    查看mysql数据库中user表: MariaDB
    [mysql]> select user,host,password from user; +------+-----------+-------------------------------------------+ | user | host | password | +------+-----------+-------------------------------------------+ | root | localhost | *E56A114692FE0DE073F9A1DD68A00EEB9703F3F1 | +------+-----------+-------------------------------------------+ 1 row in set (0.00 sec)
    更新user表中用户root对应的password字段: MariaDB
    [mysql]> update user set password=password('123123') where user='root'; Query OK, 0 rows affected (0.02 sec) Rows matched: 1 Changed: 0 Warnings: 0 MariaDB [mysql]> select user,host,password from user; +------+-----------+-------------------------------------------+ | user | host | password | +------+-----------+-------------------------------------------+ | root | localhost | *E56A114692FE0DE073F9A1DD68A00EEB9703F3F1 | +------+-----------+-------------------------------------------+ 1 row in set (0.00 sec)
    刷新权限:
    MariaDB [(none)]> flush privileges;
    Query OK, 0 rows affected (0.00 sec)
    
    
    
    MariaDB [mysql]> 
  • 相关阅读:
    判断平衡二叉树 --牛客网
    二叉树深度 --牛客网
    重建二叉树 来源:牛客网
    快速排序
    30天自制操作系统笔记(第四天)
    pat 1047
    机器学习 周志华 第1章习题
    POJ 3126 Prime Path
    POJ 3279 Fliptile
    POJ 3278 Catch That Cow
  • 原文地址:https://www.cnblogs.com/hui-shao/p/mysqladmin.html
Copyright © 2011-2022 走看看