MySQL not working

This is insane. I will reinstall this server now and see if that solves the problem.

Thanks for your help!
 
If you still need some hands to fix your problem, feel free to contact me, for some USD I'll make MySQL running OK on your box.
 
If you still need some hands to fix your problem, feel free to contact me, for some USD I'll make MySQL running OK on your box.

Thanks for the offer. Hopefully it will run OK once i have reinstalled it though. I must have done something wrong this time around since i have installed DA multiple times before without any problem on Debian.
 
OK now i have reinstalled the entire server and STILL have the same problem.

I only have a Debian 6.0 64-bit minimal + DA now. No firewall, no mod_security, no nothing yet!
 
Inside DA when i browse to MySQL management:

"Error connecting to MySQL: Access denied for user 'da_admin'@'localhost' (using password: YES)"

This is on a clean install!
 
Make sure you dont have any mysql stuff installed before you install directadmin. Make sure you dont have anything in /root/.my.cnf /root/my.cnf or any other mysql config file loading besides /etc/my.cnf
 
Make sure you dont have any mysql stuff installed before you install directadmin. Make sure you dont have anything in /root/.my.cnf /root/my.cnf or any other mysql config file loading besides /etc/my.cnf

I have no MySQL installed prior to installing DA.

A search for "my.cnf" gives me:
Code:
s01:# find / -name my.cnf
/etc/my.cnf
/usr/local/mysql-5.5.9-linux2.6-x86_64/mysql-test/suite/federated/my.cnf
/usr/local/mysql-5.5.9-linux2.6-x86_64/mysql-test/suite/rpl/my.cnf
/usr/local/mysql-5.1.59-linux-x86_64/mysql-test/suite/federated/my.cnf
/usr/local/mysql-5.1.59-linux-x86_64/mysql-test/suite/ndb/my.cnf
/usr/local/mysql-5.1.59-linux-x86_64/mysql-test/suite/rpl_ndb/my.cnf
/usr/local/mysql-5.1.59-linux-x86_64/mysql-test/suite/rpl/my.cnf
 
Make sure there is no .my.cnf too the preceeding dot is required. Sometimes there is one in /root/.my.cnf that will cause problems with a username and password tied to it. Make sure your /etc/my.cnf doesnt have a username= password= line in there with hardcoded login.
 
Make sure there is no .my.cnf too the preceeding dot is required. Sometimes there is one in /root/.my.cnf that will cause problems with a username and password tied to it. Make sure your /etc/my.cnf doesnt have a username= password= line in there with hardcoded login.

There's no ".my.cnf" file anywhere and "my.cnf" does not have username and password in it.

Contents of /etc/my.cnf:
Code:
[mysqld]
local-infile=0
 
If you login to mysql from the shell like this does it work?

mysql -uda_admin -p`cat /usr/local/directadmin/conf/mysql.conf |grep -i passwd|cut -d= -f2`
 
If you login to mysql from the shell like this does it work?

mysql -uda_admin -p`cat /usr/local/directadmin/conf/mysql.conf |grep -i passwd|cut -d= -f2`

Doesn't work:
Code:
s01:~# mysql -uda_admin -p`cat /usr/local/directadmin/conf/mysql.conf |grep -i passwd|cut -d= -f2`
ERROR 2002 (HY000): Can't connect to local MySQL server through socket '/tmp/mysql.sock' (2)
 
I added "socket=/tmp/mysql.sock" to /etc/my.cnf and get this instead:
Code:
ERROR 1045 (28000): Access denied for user 'da_admin'@'localhost' (using password: YES)
 
Hello,

For the password issue:
http://help.directadmin.com/item.php?id=45

Also check:
Code:
which mysql
as it should exist in /usr/local/mysql/bin/mysql. Try runnning with the full mysql path.

If it exists anywhere else (including the mysqd binary), then it's likely that another instance of mysql is on the box.

John
 
which mysql gives me:
/usr/local/bin/mysql

If i try to run "mysqld_safe --skip-grant-tables &" from that path i get:
bash: mysqld_safe: command not found
 
This has now been solved.

This is how i did:
Code:
/etc/init.d/mysqld stop

/usr/bin/mysqld_safe --skip-grant-tables &

mysql --user=root mysql

mysql> update user set Password=PASSWORD('new-password-here') WHERE User='root';

mysql> flush privileges;

mysql> exit

Then i went on to change password for da_admin:
Code:
mysql -uroot -p

GRANT ALL PRIVILEGES ON *.* TO da_admin@localhost IDENTIFIED BY 'newdapass' WITH GRANT OPTION;

mysql> flush privileges;

mysql> quit

Logged in as user and it seems to be working. Will try to restore some databases now.
 
I have absolutley no idea why "--skip-grant-tables &" didn't work before... probably something about the path?
 
Back
Top