Tuesday, September 3, 2013

MySQL start FAILED on VM Virtual Box

Recently  I had on issue with MySQL Start-up with VM. my environment was
Host OS   : Debian / BOSS
Guest OS : CentOS
Application running in CentsOS. We tried to replicate the same in Debian/BOSS but wouldn't because some missing packages. so decided to go with Virtual Machine concept.

When we boot the CentOS from Debian/BOSS, MySQL Failed to start.

As we followed my error.log we managed to start the MySQL.

1) Network Adapter settings in your VM settings to be bridged mode

2) Change bind address  in /etc/mysql/my.cnf to
bind-address =
 start the server by /etc/init.d/mysql start

3) gone through the log file (img),

MySQL error log  running on VM

got few error which was related to permission denied.

  • Error 1)
/usr/libexec/mysqld: File '/var/lib/mysql/log-bin.index' 
not found (Errcode: 13)
130930 15:27:22 [ERROR] Aborting
root@boss[~]# chmod -R 777   /var/lib/mysql/log-bin.index 
  • Error 2) 

innoDB : Operating Systems error number 13 in a file operation. the Error means mysqld doesn't have the access rights to the directory
File name ./ibdata
File operation call : 'open'
Cannot continue operation

root@boss[~]# chomd -R 777 `locate ibdata`

  • Error 3)
[ERROR] /usr/libexec/mysqld: Can't create/write to file '/var/run/mysqld/mysqld.pid' (Errcode: 13)
[ERROR] Can't start server : can't create PID file: Persmission denied

root@boss[~]#  chmod -R 777 /var/run/mysqld/mysqld.pid

root@boss[~]#  /etc/init.d/mysql start 

now MySQL started successfully

1 comment:

Anonymous said...

helped in some point to resolve the issue.