ERROR 1045 (28000): Access denied for user 'root'@'localhost' (using password: YES)

ERROR 2013 (HY000): Lost connection to MySQL server during query

bin/safe_mysqld --skip-grant-tables &

>mysql -uroot //另打开一个shell,执行Mysql
>use mysql //切换数据库为mysql
>update user set password=password("new_pass") where user="root"; //更新用户密码
>flush privileges; //更新Mysql权限表

mysql 出了这个问题,网上的各种解决方案,都不靠谱,最后看到一条

mysql_upgrade -uroot -padmin

解决问题

很靠谱

ERROR 1045 (28000): Access denied for user 'root'@'localhost' (using password: YES)的更多相关文章

  1. Linux mysql 5.6: ERROR 1045 (28000): Access denied for user 'root'@'localhost' (using password: NO)

    案例环境: 操作系统 :Red Hat Enterprise Linux Server release 5.7 (Tikanga) 64 bit 数据库版本 : Mysql 5.6.19 64 bit ...

  2. MySQL ERROR 1045 (28000): Access denied for user 'root'@'localhost' (using password: NO)的真正原因

    在博客Linux mysql 5.6: ERROR 1045 (28000): Access denied for user 'root'@'localhost' (using password: N ...

  3. 升级到macOS 10.12 mysqlb报错ERROR 1045 (28000): Access denied for user 'root'@'localhost' (using password: NO)

    系统升级到macOS 10.12后启动mysql后,在终端输入mysql 报错ERROR 1045 (28000): Access denied for user 'root'@'localhost' ...

  4. mysql 链接失败(ERROR 1045 (28000): Access denied for user 'root'@'localhost' (using password: YES))

    mysql链接失败(ERROR 1045 (28000): Access denied for user 'root'@'localhost' (using password: YES)) 修改: # ...

  5. 安装mysql因为/tmp权限不足而导致ERROR 1045 (28000): Access denied for user root@localhost (using password: NO)的解决方案

    本机是centos 6.5  安装的mysql是5.1的版本. 在安装mysql之后,第一次启动mysql服务的时候,需要/tmp有777(rwxrwxrwx)的权限,然而楼主的/tmp是755(rw ...

  6. MySQL5.5出面ERROR 1045 (28000): Access denied for user 'root'@'localhost' (using password: YES)问题的解决办法

    问题描述 安装完MySQL5.5数据库,使用Navicat Premium以及命令窗口连接数据库都报以下错误: ERROR 1045 (28000): Access denied for user ' ...

  7. MySQL学习笔记——ERROR 1045 (28000): Access denied for user 'root'@'localhost' (using password: NO)

    ERROR 1045 (28000): Access denied for user 'root'@'localhost' (using password: NO) Enter password: E ...

  8. ERROR 1045 (28000): Access denied for user root@localhost (using password:

    错误描述: Mysql中添加用户之后可能出现登录时提示ERROR 1045 (28000): Access denied for user的错误.删除user.user中值为NULL的,或更新NULL ...

  9. Mysql ERROR 1045 (28000): Access denied for user 'root'@'localhost'(using password: YSE)

    安装mysql后,使用命令登录mysql居然报错了,Mysql ERROR 1045 (28000): Access denied for user 'root'@'localhost'(using ...

随机推荐

  1. First Position of Target

    For a given sorted array (ascending order) and a target number, find the first index of this number ...

  2. sharepoint读取启用了追加功能的多行文本的历史版本记录

    当建立多行文本栏时,有个功能就是"追加对现有文本所做的更改",这个功能启用后,这个多行文本就只运行追加内容而不允许修改以前提交的内容.常常被应用在多个用户之间的协作.问题的追踪等记 ...

  3. iOS 用CALayer实现动画

    与动画有关的几个类的继承关系 涉及到动画的类主要有6个,看一下它们的基本用途: 1. CAAnimation  动画基类 2. CAAnimationGroup 组合多个动画 3. CAPropert ...

  4. 【JAVA、C++】LeetCode 021 Merge Two Sorted Lists

      Merge two sorted linked lists and return it as a new list. The new list should be made by splicing ...

  5. 【JAVA、C++】LeetCode 018 4Sum

    Given an array S of n integers, are there elements a, b, c, and d in S such that a + b + c + d = tar ...

  6. UVA 11827 Maximum GCD (输入流)

    题目:传送门 题意:求n个数的最大公约数,暴力不会超时,难点在没有个数控制的输入. 题解:用特殊方法输入. #include <iostream> #include <cmath&g ...

  7. @RequestBody, @ResponseBody 注解详解

    简介: @RequestBody 作用: i) 该注解用于读取Request请求的body部分数据,使用系统默认配置的HttpMessageConverter进行解析,然后把相应的数据绑定到要返回的对 ...

  8. Mysql查询比较

    创建一个表: article,书编码:dealer,书店:price ,书的价格. 导入一些数据: INSERT INTO shop VALUES (1,'A',3.45),(1,'B',3.99), ...

  9. fork

    #include <unistd.h> #include <stdlib.h> #include <stdio.h> #include <fcntl.h> ...

  10. ***CI新增记录成功后的返回值判断,是用isset还是empty

    Q: 新增记录插入成功后,加了一个return $this->db->insert_id(); $digg_id = $this->m_feed_digg->create(js ...