• 如何修改Xampp服务器上的mysql密码(图解)


    https://www.jb51.net/article/111289.htm

    https://www.cnblogs.com/Leequik/p/5323795.html

    1、点击MySQL的admin进入phpMyAdmin页面

    或者在浏览器地址上输入http://localhost通过选择phymyadmin进入

    2、进入到数据库控制面板,然后选择名称为mysql数据库,如图,可从中看出 user表中,root的两个用户的密码为空。

    想把密码改成别的,可以直接执行下面的SQL 语句,把new_password改成自己的密码即可:

    1
    UPDATE user SET password=PASSWORD('new_password') WHERE user='root';

    3、设计好自己密码后点击执行,此时密码已经修改成功,但是问题来了,此页面已经不再是phpMyAdmin页面了,而是拒绝访问,原因是我们修改了mysql的访问密码;

    4、打开XamppphpMyAdminconfig_inc.php文件,将下面图片中的config修改为新密码,此时就完成了mysql密码修改的整个步骤,然后重新启动Xampp,点击刷新phpMyAdmin页面就可以去操作了。

    Authentication type and info */$cfg['Servers'][$i]['auth_type']
     = 'config';$cfg['Servers'][$i]['user']
     = 'root';$cfg['Servers'][$i]['password']
     = '';$cfg['Servers'][$i]['extension']
     = 'mysql';$cfg['Servers'][$i]['AllowNoPassword']
     = true;

    修改为

     Authentication type and info */$cfg['Servers'][$i]['auth_type']
     = 'config';$cfg['Servers'][$i]['user']
     = 'root';$cfg['Servers'][$i]['password']
     = '123456';$cfg['Servers'][$i]['extension']
     = 'mysql';$cfg['Servers'][$i]['AllowNoPassword']
     = true;

    假设新密码为123456

  • 相关阅读:
    java语法基础
    向linux内核增加一个系统调用-1
    dp-矩阵连乘
    struct和typedef struct
    Ubuntu安装Chrome及hosts修改
    c++primer-p100.用迭代器进行二分法搜索
    c++primer-p101.ex3.24
    c++ vector用法和迭代器
    Bytes和bits的区别(字节和位的区别)
    基于R语言的数据分析和挖掘方法总结——中位数检验
  • 原文地址:https://www.cnblogs.com/bnuvincent/p/9253915.html
Copyright © 2020-2023  润新知