Problems with MySQL not starting due to power outages:
1. Error
shell> mysql.server start starting mysql ..................................................................................................... error! the server quit without updating pid file (/usr/local/var/mysql /nilyangdeimac.local.pid).
1.1 Logs:
2015-08-06 15:05:36 1920 [note] innodb: check that you do not already have another mysqld process using the same InnoDB Data or log files.2015-08-06 15:05:37 1920 [error] innodb: unable to lock ./ibdata1, error: 352015-08-06 15:05:37 1920 [Note] innodb: check that you do not already have another mysqld process using the same innodb data or log files.2015-08-06 15:05:37 1920 [note] innodb: unable to open the first data file2015-08-06 15:05:37 7fff77755300 innodb: operating system error Number 35 in a file operation. innodb: error number 35 means ' Resource temporarily unAvailable '. Innodb: some operating system error numbers are described atinnodb: http://dev.mysql.com/doc/refman/5.6/en/operating-system-error-codes.html2015-08-06 15:05:37 1920 [error] innodb: can ' t open './ibdata1 ' 2015-08-06 15:05:37 1920 [ Error] innodb: could not open or create the system tablespace. If you tried to add new data files to the system Tablespace, and it failed here, you should now edit innodb_data_ File_path in my.cnf back to what it was, and remove the new ibdata files InnoDB created in this failed attempt. Innodb only wrote those files full of zeros, but did not yet use them in any way. but be careful: do not remove old data files which contain your precious data!2015-08-06 15:05:37 1920 [ERROR] Plugin ' InnoDB ' init function returned error.2015-08-06 15:05:37 1920 [error] plugin ' InnoDB ' registration as a STORAGE engine failed.2015-08-06 15:05:37 1920 [error] unknown/unsupported storage Engine: innodb2015-08-06 15:05:37 1920 [error] aborting
Note Some of the errors mentioned below:
Check that the already has another mysqld process using the same InnoDB data or log files (there are already processes running)
?
unable to lock./ibdata1
Innodb:can ' t open './ibdata1 '
Unable to open the first data file
Description log file may be broken, you have to start again
3. Workaround3.1. Delete the log file and try again:
shell> RM ib_logfile0 Ib_logfile1 ibdata1
3.2. Erase the MySQL process
shell> PS aux|grep mysqld |grep-v ' grep ' | awk ' {print $} ' |xargs Kill
3.3. Start Mysql
shell> mysql.server startstarting MySQL ............ .............. success!
Problem solving.
MySQL power outage multiple times, log file corruption, unable to start the issue