Find the answer to your Linux question:
Results 1 to 7 of 7
hi can antbody tell what was error when i am log in mysql server mysql -u root -p password xxxxxx (ERROR 2002 (HY000): Can't connect to local MySQL server through ...
Enjoy an ad free experience by logging in. Not a member yet? Register.
  1. #1
    Just Joined!
    Join Date
    Nov 2012
    Posts
    32

    mysql error


    hi can antbody tell what was error when i am log in mysql server mysql -u root -p
    passwordxxxxxx
    (ERROR 2002 (HY000): Can't connect to local MySQL server through socket '/var/lib/mysql/mysql.sock' (2))

  2. #2
    Linux Guru Lakshmipathi's Avatar
    Join Date
    Sep 2006
    Location
    3rd rock from sun - Often seen near moon
    Posts
    1,763
    mysql server running ? Can you try restarting it. Whats your distro ?
    First they ignore you,Then they laugh at you,Then they fight with you,Then you win. - M.K.Gandhi
    -----
    FOSS India Award winning ext3fs Undelete tool www.giis.co.in. Online Linux Terminal http://www.webminal.org

  3. #3
    Just Joined!
    Join Date
    Nov 2012
    Posts
    32
    Quote Originally Posted by Lakshmipathi View Post
    mysql server running ? Can you try restarting it. Whats your distro ?
    thanx for the reply
    when i restart the service it show me
    -bash: sevice: command not found
    but when i am checking package it is showing
    [root@yash ~]# rpm -qa |grep mysql
    mysql-5.0.95-5.el5_9

    i cound not found any mysqld service in cd /etc/init.d/

  4. $spacer_open
    $spacer_close
  5. #4
    Linux Guru Lakshmipathi's Avatar
    Join Date
    Sep 2006
    Location
    3rd rock from sun - Often seen near moon
    Posts
    1,763
    Did you try 'service' or 'sevice' ?

    -bash: sevice: command not found
    First they ignore you,Then they laugh at you,Then they fight with you,Then you win. - M.K.Gandhi
    -----
    FOSS India Award winning ext3fs Undelete tool www.giis.co.in. Online Linux Terminal http://www.webminal.org

  6. #5
    Just Joined!
    Join Date
    Nov 2012
    Posts
    32
    sorry its service
    now i restart the service it is successful
    now i am getting a new error
    mysql -u root -p
    ERROR 1045 (28000): Access denied for user 'root'@'localhost' (using password: YES)

  7. #6
    Linux Guru Lakshmipathi's Avatar
    Join Date
    Sep 2006
    Location
    3rd rock from sun - Often seen near moon
    Posts
    1,763
    Did you know the root password for mysql ? Is this your first attempt to run/connect to db ? If so run
    mysql_secure_installation
    first then proceed.
    First they ignore you,Then they laugh at you,Then they fight with you,Then you win. - M.K.Gandhi
    -----
    FOSS India Award winning ext3fs Undelete tool www.giis.co.in. Online Linux Terminal http://www.webminal.org

  8. #7
    Just Joined!
    Join Date
    Nov 2012
    Posts
    32
    now its working

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •