The Community Forums

Interact with an entire community of cPanel & WHM users!
  1. This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn More.

mysql root / urgent

Discussion in 'General Discussion' started by Secret Agent, Jun 3, 2005.

  1. Secret Agent

    Secret Agent Guest

    root@server [/var/lib/mysql]# /usr/sbin/mysqld --basedir=/ --datadir=/var/lib/mysql --user=mysql --pid-file=/var/lib/mysql/ --skip-locking &
    [1] 9569

    root@server [/var/lib/mysql]# 050603 14:59:20 [Warning] Asked for 196608 thread stack, but got 126976
    050603 14:59:21 InnoDB: Started; log sequence number 0 2301004
    050603 14:59:21 [ERROR] /usr/sbin/mysqld: Can't find file: './mysql/host.frm' (errno: 13)
    050603 14:59:21 [ERROR] Fatal error: Can't open privilege tables: Can't find file: './mysql/host.frm' (errno: 13)

    [1]+ Exit 1 /usr/sbin/mysqld --basedir=/ --datadir=/var/lib/mysql --user=mysql --pid-file=/var/lib/mysql/ --skip-locking

    WHM MySQL restart:

    /usr/bin/mysqladmin: connect to server at 'localhost' failed error: 'Can't connect to local MySQL server through socket '/var/lib/mysql/mysql.sock' (2)' Check that mysqld is running and that the socket: '/var/lib/mysql/mysql.sock' exists! mysql has failed, please contact the sysadmin (result was "Warning, no valid mysql.sock file found.mysql has failed").


    /scripts/mysqlup --force
    ln -s /var/lib/mysql/mysql.sock /tmp/mysql.sock
    chmod 0755 /var/lib/mysql
    chown mysql:root /var/lib/mysql
    cat /etc/passwd (user mysql exists)
    mysql.sock is NOT in /var/lib/mysql but is in /tmp
    Reset root / local mysql passwords

    Still no good. Anyone?
  2. Secret Agent

    Secret Agent Guest

    Ran /scripts/mysqlup --force again and got this at the end

    ERROR 2002 (HY000): Can't connect to local MySQL server through socket '/var/lib/mysql/mysql.sock' (2)
    Got a failure from command:
    /usr/bin/mysql --no-defaults --force --user=root --host=localhost --password=QaS&Suz --database=mysql
    Please check the above output and try again.

    If you get an 'Access denied' error, you should run this script again and
    give the MySQL root user password as an argument with the --password= option
    /usr/sbin/setfiles: read 2 specifications
    /usr/sbin/setfiles: labeling files under /
    /usr/sbin/setfiles: hash table stats: 1 elements, 1/65536 buckets used, longest chain length 1
    /usr/sbin/setfiles: Done.
    Install Complete

    I'm still getting the error

    Everytime I restart mysql from whm it removes mysql.sock from /tmp and /var/lib/mysql
    #2 Secret Agent, Jun 3, 2005
    Last edited by a moderator: Jun 3, 2005

Share This Page