MySQL install problems.

AidanF

Registered
Oct 8, 2006
4
0
151
ok i have CPanel installed on my dedicated server, No matter what i do i cant install MySQL. I get the following erorr:
/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").
Now i know that you need to set the dir inside my.cnf but i cant seem to find MySQl.sock even when i type in locate MySQL.sock it doesnt seem to have any MySQl.sock file. i was wondeing if i have to create the file myself and edit it with certain information. If you have any ideas on what my problem may be please post a reply.
Os = Linux, Fedora 6
Email = fewstera[replace this with a @ sign just stopping spam]hotmail.com
Thanx in advanced,
Aidan (If you have MSN please could you add me)
 
Last edited:

jayh38

Well-Known Member
Mar 3, 2006
1,213
0
166
Try running the following commands to create the sock and
then link it to your temp. That should get you going.

cd /var/lib/mysql
touch mysql.sock
chown mysql:mysql mysql.sock
chmod 1777 mysql.sock
ln -s /var/lib/mysql/mysql.sock /tmp
chmod 1777 /tmp
/scripts/mysqlup --force
/etc/rc.d/init.d/mysql restart
 

AidanF

Registered
Oct 8, 2006
4
0
151
Thanx alot im just running it now. I gotta reinstall HTTP, APache and PHP now because i uninstalled them all because i was gong to install LAMP. But this seems to be working atm it says:
Preparing... ########################################### [100%]
1:MySQL-shared ########################################### [100%]
Preparing... ########################################### [100%]
1:MySQL-devel ########################################### [100%]
Preparing... ########################################### [100%]
1:MySQL-client ########################################### [100%]
Preparing... ########################################### [100%]
1:MySQL-bench ########################################### [100%]
So i think it working
Thanx again,
Aidan
 

AidanF

Registered
Oct 8, 2006
4
0
151
Now i get:

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

cPanelKenneth

cPanel Development
Staff member
Apr 7, 2006
4,608
77
308
cPanel Access Level
Root Administrator
Are you using i386 or x86-64 version of Fedora Core 6?

We don't distribute RPMs of MySQL, so if you are using /scripts/mysqlup it will be trying to build the RPMs from source. Try executing
Code:
/scripts/mysqlup --force --verbose --source
It's possible you are lacking a library or something that is needed during compiling.

If you are simply doing yum install mysql-server then it's obviously not anything related to the above and might need researched on Fedoras Forums/mailing lists.
 

katmai

Well-Known Member
Mar 13, 2006
564
3
168
Brno, Czech Republic
[mysqld]
datadir=/var/lib/mysql
socket=/var/lib/mysql/mysql.sock
skip-locking
skip-innodb
query_cache_limit=1M
query_cache_size=32M
query_cache_type=1
max_user_connections=500
max_connections=1000
interactive_timeout=10
wait_timeout=30
connect_timeout=10
thread_cache_size=96
key_buffer=32M
join_buffer=1M
max_allowed_packet=8M
table_cache=1024
record_buffer=1M
sort_buffer_size=1024K
read_buffer_size=1024K
max_connect_errors=10
thread_concurrency=8
myisam_sort_buffer_size=64M
server-id=1
log-slow-queries
long_query_time = 5

[mysql.server]
user=mysql

[safe_mysqld]
err-log=/var/log/mysqld.log
pid-file=/var/lib/mysql/mysql.pid
open_files_limit=8192

[mysqldump]
quick
max_allowed_packet=16M

[mysql]
no-auto-rehash

[isamchk]
key_buffer=64M
sort_buffer=64M
read_buffer=16M
write_buffer=16M

[myisamchk]
key_buffer=64M
sort_buffer=64M
read_buffer=16M
write_buffer=16M

[mysqlhotcopy]
interactive-timeout

here is my.cnf. try replacing /etc/my.cnf with this, and then restarting mysql.
 

k1k

Active Member
Mar 24, 2006
27
0
151
Mysql issues

The easiest procedure:

su mysql

When you are logged as "mysql" user you could try to strart the service manually:

"mysqld"

If there are any issues with your configuration then you will see the exact error.
 

jayh38

Well-Known Member
Mar 3, 2006
1,213
0
166
I was asked to look at the box so here is a followup for those interested.

After creating the mysql.sock and forced update, MySql started fine.
Root was unable to connect at all. I tried every type of reset
procedure and password change via ssh and whm with no luck.

The privileges table seemingly accepted the new passwords but also seemed
to corrupt it as well. With no way to run utilities on it, I decided to delete the
the priv data. This rebuilt fine after another forced update.

I then recompiled apache and updated cPanel.

This was a fedora 6 686 box