OpenSUSE :: MySql Won't Start / No File Mysql.sock?
Feb 5, 2009
I thought that the problem is in the phpMyAdmin not in the mysql. But now i think different. It seems that the problem is right in the mysql. I think that there was no root user, when mysql was freshly installed. Unfortunately i did everything i can find on internet (some tutorials) but they don`t helped me at all, maybe i fu**ed up the mysql service. So i reinstalled it, and when i want to start it there is no file mysql.sock and i get the following:
linux-nepg:~ # service mysql restart
Restarting service MySQL
Shutting down service MySQL done
Starting service MySQL warning: /var/lib/mysql/mysql.sock didn't appear within 30 seconds
I think this goes here, but I'm not sure. I decided that XAMPP had been troublesome enough. MySQL never worked. So I decided to instal the LAMP stack offered by YaST. I went about installing it thinking that it would all work. But it seems that I was wrong. So I try to start mysql, and here's what I get:
Code: the-matrix:~ # mysql start ERROR 2002 (HY000): Can't connect to local MySQL server through socket '/var/mysql/mysql.sock' (2) or Code: the-matrix:~ # rcmysql start Starting service MySQL warning: /var/mysql/mysql.sock didn't appear within 30 seconds chmod: cannot access `/var/run/mysql/mysqld.pid': No such file or directory
I was playing with the mysql my.cnf file yesterday, trying to move my database files to my dropbox folder so I can use the database on my other machine. All I changed was the datadir setting to point to my dropbox folder. I also moved my mysql data files there.
When I tried to restart mysql and test the new location it said my mysqld.sock was missing. I searched and searched the web and my filing system for it but I have no idea what's happened to it?? I have even tried changing the datadir path back and reinstalling mysql but that doesn't seem to work either.
I am getting the following error when starting mysql using 'sudo /etc/init.d/mysql start':
Mar 15 16:33:56 MoodFishDev /etc/init.d/mysql: 0 processes alive and '/usr/bin/mysqladmin --defaults-file=/etc/mysql/debian.cnf ping' resulted in Mar 15 16:33:56 MoodFishDev /etc/init.d/mysql: ^G/usr/bin/mysqladmin: connect to
I've downloaded and installed MySQL-client-5.1.53-1.glibc23.x86_64.rpm. I'm rather new to linux so it might be I haven't started the server. Unfortunately I have no idea which file is responsible for that. It is also possible that my head isn't functioning correctly ( if at all ).
Error I receive is:
ERROR 2002 (HY000): Can't connect to local MySQL server through socket '/var/lib/mysql/mysql.sock' (2)
After the upgrade from 8.10 to 9.04, all was well. But after the upgrade from 9.04 to 9.10, I lost the MySQL server. Now, I recall during the upgrade, I was asked if I wanted to keep the existing my.cnf file or replace it with a newer one. I did as suggested and kept the original as I had edited it before. The same question was asked with a couple other config files. I kept the original in each case. After the first step, I checked the server was running and the websites were up, all was well. After the update to 9.10, when I checked the server, I get the following error:
Code: error: 'Can't connect to local MySQL server through socket '/var/run/mysqld/mysqld.sock' (2)' Check that mysqld is running and that the socket: '/var/run/mysqld/mysqld.sock' exists! Can anyone point me in the right direction to getting this resolved?
I need some help.Trying to set up bugzilla on my VM.After setting up the IP to use static i could log on to the url its not even loading up from command line its issueing an error.when i try to log on to mysql
bugzilla:~# mysql -u root mysql] ERROR 2002 (HY000): Can't connect to local MySQL server through socket '/var/run/mysqld/mysqld.sock' (2)
I'm the lead Dev of GnackTrack and we're having issues with running MySQL on the LiveDVD.Once installed everything works fine, mysql can be connected to but when using the liveDVD we get the following error:
root@root:~# mysql ERROR 2002 (HY000): Can't connect to local MySQL server through socket '/var/run/mysqld/mysqld.sock' (2) Contents of /etc/mysql/my.cf point to /var/run/mysqld/mysqld.sock but because this is a liveDVD the actual file is located in: /rofs/var/run/mysqld/mysqld.sock
I am trying to get mysql to start at boot without any success.
The mysqld scripts works fine when run from the command line, but it does not work when i use the links created by chkconfig. I checked the boot.log and found that mysql starts but then it stops or gets shutdown. This is the log message:
Starting mysqld daemon with databases from /data/mysql [ OK ] Starting cups: [ OK ] STOPPING server from pid file /var/run/mysqld/mysqld.pid starting DenyHosts: /usr/bin/denyhosts.py --daemon --config=/usr/share/denyho sts/denyhosts.cfg 090727 04:35:47 mysqld ended
i am using putty to connect to my server and wanted to restart mysql server. searched the internet and found thatcommand is /etc/init.d/mysqld start or stopbut it did not worked.then tried /etc/init.d/mysql stop or startthis also did not worked.
Through YaST's System Services I configured an application to start on boot. However, the application (mediatomb) is using mysql, so it should not be started before mysql. It is however, which means mediatomb fails to start.
How can I make sure mysql is started before mediatomb?
In looking at the release notes, I saw the comment File locations changes:
* MySQL socket file and pid file were moved from /var/lib/mysql to more reasonable location /var/run/mysql by default.
* MySQL log files are in /var/log/mysql. Not sure what I was supposed to do with that information. So I ignored it. Now, I am finding some issues with it. The web server works, but any connection to the database fails with 2002: Can't connect to local MySQL server through socket '/var/run/mysql/mysql.sock' (2)The thought dawned on me that maybe all my databases were erased and none set up. Going in to the terminal, I could connect and list and query the databases. So even though I backed them up, they still are there!
phpMyAdmin gives the same error message.
However, when I go into MySQL Administrator, it works fine.
I forgot where I saw it, but the socket is still set to var/lib/mysql. I could not find any mysql install log and would say what was in my cnf.my, but it still doesn't exist just as it has not in the past. Not sure if I should allow the MySQL Administrator to create it since I always ignored the prompt in the past and it worked. (Just wishing to keep the defaults)
At first I thought the upgrade upgraded the MySQL, but it's still 5.1.39 as I believe before. I've un-installed mysql-server and re-installed it with no change.
Can anyone can tell me how to get the socket to /var/run/mysql or what else is wrong? I read one place where mysql is supposed to set it up.
I'm having problems connecting to the mysql database on my system. I first noticed this when I was trying to set up the program anymeal. I subsequently tried using MySQL Administrator (mysql-admin), but had no luck. It gives my the following feedback:
Can't connect to local MySQL server through socket '/var/run/mysqld/mysqld.sock' (2)
Click the 'Ping' button to see if there is a networking problem. I press the ping button, and it seems to connect.
Mysql starting problem after changing mysqladmin password.I tried all the solutions available on forums, but not solve the problem.At last I restored the mysql db backup, this make mysql service start, but till other databases not showing all tables.