zoukankan      html  css  js  c++  java
  • ERROR 2002 (HY000): Can't connect to local MySQL server through socket '/var/lib/mysql/mysql.sock' (111)

    [root@gaosheng ~]# mysql -uarcerzhang -parcerzhang -hlocalhost
    ERROR 2002 (HY000): Can't connect to local MySQL server through socket '/var/lib/mysql/mysql.sock' (111)
    [root@gaosheng ~]# ll /var/lib/mysql/
    total 20544
    drwx------ 2 mysql mysql     4096 Apr  1 04:01 arcerdb
    drwx------ 2 mysql mysql     4096 Mar 31 22:34 billy
    -rw-rw---- 1 mysql mysql 10485760 Apr  1 03:56 ibdata1
    -rw-rw---- 1 mysql mysql  5242880 Apr  1 03:56 ib_logfile0
    -rw-rw---- 1 mysql mysql  5242880 Mar 30 23:07 ib_logfile1
    drwx------ 2 mysql mysql     4096 Mar 31 23:32 meta
    drwx------ 2 mysql mysql     4096 Mar 30 23:07 mysql
    srwxrwxrwx 1 mysql mysql        0 Apr  1 03:56 mysql.sock
    drwx------ 2 mysql mysql     4096 Mar 30 23:07 test
    drwx------ 2 mysql mysql     4096 Mar 31 00:47 testdb
    [root@gaosheng ~]# /etc/init.d/mysqld start
    Starting MySQL:                                            [  OK  ]
    [root@gaosheng ~]# mysql -uarcerzhang -parcerzhang
    Welcome to the MySQL monitor.  Commands end with ; or g.
    Your MySQL connection id is 2
    Server version: 5.0.77-log Source distribution
    
    Type 'help;' or 'h' for help. Type 'c' to clear the buffer.
    
    mysql> show databases;
    +--------------------+
    | Database           |
    +--------------------+
    | information_schema | 
    | arcerdb            | 
    | billy              | 
    | meta               | 
    | mysql              | 
    | test               | 
    | testdb             | 
    +--------------------+
    7 rows in set (0.07 sec)
    
    mysql> 
  • 相关阅读:
    mouseleave 与 mouseout 的不同
    Web 前端开发者必知CSS 属性
    Javascript定时器
    事件冒泡案例
    我自己的style
    加快网站访问速度
    HTML5数据存储
    JQuery 选择器
    jquery radio取值,checkbox取值,select取值,radio选中,checkbox选中,select选中
    c_aw_最高的牛(差分+区间处理)
  • 原文地址:https://www.cnblogs.com/arcer/p/3702590.html
Copyright © 2011-2022 走看看