• Got error: 1045:


    错误日志

    [root@gaosheng ~]# mysqlcheck arcerdb t1;
    mysqlcheck: Got error: 1045: Access denied for user 'root'@'localhost' (using password: NO) when trying to connect
    [root@gaosheng ~]# mysql
    ERROR 1045 (28000): Access denied for user 'root'@'localhost' (using password: NO)

    解决方案:

    [root@gaosheng ~]# mysql -uroot -parcerzhang
    Welcome to the MySQL monitor.  Commands end with ; or g.
    Your MySQL connection id is 8
    Server version: 5.0.77-log Source distribution
    
    Type 'help;' or 'h' for help. Type 'c' to clear the buffer.
    
    mysql> 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
    mysql> set passwrod for 'root'@'localhost' = password('');
    ERROR 1193 (HY000): Unknown system variable 'passwrod'
    mysql> set password for 'root'@'localhost' = password('');
    Query OK, 0 rows affected (0.00 sec)
    
    mysql> flush privileges;
    Query OK, 0 rows affected (0.00 sec)
    
    mysql> exit
    Bye
    [root@gaosheng ~]# mysqlcheck arcerdb t1;
    arcerdb.t1                                         OK
    [root@gaosheng ~]# 
  • 相关阅读:
    吊打XXX
    [CQOI2011]动态逆序对
    陌上花开
    【BOI2007】摩基亚Mokia
    [SCOI2008]奖励关
    最小生成树
    打表
    【中学高级本】倒酒
    整数合并
    韩信点兵
  • 原文地址:https://www.cnblogs.com/arcer/p/3721631.html
Copyright © 2020-2023  润新知