MaGiAsHoK Experiences

09 Jan, 2008

MySQL Error

Posted by: MaGiAsHoK In: MYSQL


Today in morning when I checked my email, I found that there was an email with subject FAILURE ALERT, saying that my site was down at 5.56am, when I checked other mails I found that there was another email with RECOVERY ALERT informing that site was recovered at 6.46 means downtime was of 50mins. I thought once in two three months these downtime is not uncommon.

But after 5 minute when I visited one of my site, I found mysql connect error, I shocked what the hell is this. Then I opened my this blog magiashok.wordpress.com. It was also showing database error. I checked my another 3 -4 sites all were showing database error.

Initially I thought that some of the tables of my database has corrupted. I opened SQLyog tool which I use generally in place of phpmyadmin to access database, SQLyog connected smoothly with my database server and showed me all database, there was no error in database and all tables were fine.

I opened phpmyadmin via browser, but it was also refusing to connect saying incorrect userid of password. It was really a puzzling situation I was able to connect to my database server via SQLyog but not via phpmyadmin.

I login in to my control panel and tried to open phpmyadmin through it. Again it was refused with this error message: Error connecting to MySQL: Can’t connect to local MySQL server through socket ‘/var/lib/mysql/mysql.sock’ (2). I thought ok, atleast I got an error message means half problem has been solved. Before that I was getting error message of access denied, which was not throwing any light in the problem.

So I just googled the error message, and found that I was not the only one who has faced this problem.

The reason of connecting through SQLyog and not through phpmyadmin was that SQLyog was connecting via TCP/IP where as phpmyadmin and my sites were connecting to database through socket.

I login to server and found that mysql.sock file were not present in directory /var/lib/mysql whereas it should be there.

The solution of this was simple i restarted my mysqld and refreshed my blog and vow it was open. Mysqld when restarted created the mysql.sock file and the problem rectified.
Technorati Tags: , , , , ,

ashok




Securenext Software Pvt Ltd, Chennai, India


No Responses to "MySQL Error"

Comment Form

Categories

Calender

July 2010
M T W T F S S
« Jun    
 1234
567891011
12131415161718
19202122232425
262728293031  

Alexa Rank


RSS India News

  • 'Unani and ayurveda docs can conduct surgery' July 29, 2010
    The Madras high court has said registered practitioners in siddha, ayurveda, homeopathy and unani are eligible to practise surgery, obstetrics and gynaecology, anaesthesiology, ENT, ophthalmology, etc. […]
  • Number of Indian students going to US falls, rises for UK July 29, 2010
    More than twice the number of Indian students who applied to fly abroad for entry into colleges this year chose the UK over the US. […]
  • CVC X-rays 16 Commonwealth Games projects, detects brazen corruption July 29, 2010
    The Commonwealth Games edifice is crumbling under thickening suspicions of corruption and inefficiency, with the CVC referring one of the several cases of corruption bedeviling the event to the CBI. […]
  • PF scam: 3 HC judges spent money on beauty treatment July 29, 2010
    The tenure of the three former Allahabad HC judges as district judge of Ghaziabad between 2003 and 2006, saw them sanction fraudulent withdrawal of Rs 2.73 crore from PF accounts of class III and IV employees. […]
  • Qureshi to blame for failure of India-Pak talks: PM July 29, 2010
    Breaking his silence on the recent India-Pakistan dialogue, PM Manmohan Singh on Thursday blamed Pakistan's pugnacious foreign minister Shah Mahmood Qureshi for the failure of the Islamabad talks. […]
  • Seven laws of attraction July 29, 2010
    Surprising factors come into play when you are looking for a mate, we find out […]
  • UK to talk to Pakistan on ending terror in India July 29, 2010
    Addressing a joint press conference with PM Manmohan Singh, visiting British PM David Cameron today said he will discuss with Pakistan 'frankly, clearly and openly' on the need to reduce and eliminate terror from India. […]
  • Pak 'saddened' by Cameron's remarks July 29, 2010
    Pakistan today said it was 'saddened' by British PM David Cameron's remarks that it was exporting terror, adding they did not reflect ground realities. Cameron's remarks came days before Asif Ali Zardari's UK visit. […]
  • Tips for steamy sex July 29, 2010
    […]
  • Tendulkar slams 5th double ton in Test cricket July 29, 2010
    Milestone man Sachin Tendulkar re-wrote the record books, hammering the fifth double Test century to add another feather to his well-adorned cap. […]

RSS Cricket News

Twitter Goodies

Suscribete GRATIS

Configurar el USUARIO Feedburner!!
KnxDT

Feedburner Subscription Widget


Hotmail

Gmail


Search Engine Optimization and SEO Tools


Open Source Shopping Cart, Chennai, India Bench on Demand IT Professionals, Chennai, India Ruby on Rails: Rapid Web Development, Chennai, India


Videos, Slideshows and Podcasts by Cincopa Wordpress Plugin

Ads Plugin created by MaGiAsHoK