Решено: Mysql 5.5 обновленный с 5.0.95 не запускается

Обсуждение настройки и работы сервисов, резервирования, сетевых настроек и вопросов безопасности ОС.

Модераторы: SLEDopit, Модераторы разделов

Arthes
Сообщения: 282
ОС: OS X Yosemite and CentOS

Решено: Mysql 5.5 обновленный с 5.0.95 не запускается

Сообщение Arthes »

Имеется ОС CentOS 5.6 на ней установлены пакеты:
ySQL-python.i386 1.2.3-0.1.c1.el5 @base
mysql.i386 5.0.95-5.el5_9 @updates
mysql-server.i386 5.0.95-5.el5_9 @updates

Я удалил данные пакеты и зависимости к ним, добавил репозитарий Atomic и из него поставил пакеты:
Installing:
mysql i386 5.5.30-15.el5.art atomic 7.6 M
Installing for dependencies:
mysql-libs i386 5.5.30-15.el5.art atomic 1.1 M

и
mysql-server i386 5.5.30-15.el5.art atomic 13 M
Installing for dependencies:
mysqlclient15 i386 5.0.90-2.el5.art atomic 1.4 M
perl-DBD-MySQL i386 3.0007-2.el5 base 148 k

После чего при попытке запустить MYSQL ---- /etc/init.d/mysqld start
Вылазиет ошибка FAILED

Если имеющуюся БД временно переместить, то есть при старте mysql не обнаруживает БД, то он создает новую и запускается без ошибок.

Как я понимаю надо имеющуюся БД обновить, но тоже не выходит:

Код: Выделить всё

[root@localhost]# mysqld_safe --datadir=/var/lib/mysql/
130613 11:37:14 mysqld_safe Logging to '/var/log/mysqld.log'.
130613 11:37:14 mysqld_safe Starting mysqld daemon with databases from /var/lib/mysql/
130613 11:37:14 mysqld_safe mysqld from pid file /var/run/mysqld/mysqld.pid ended


Ну и после этого команда mysql_upgrade кончено же заканчивается на ошибке:

Код: Выделить всё

[root@localhost]# mysql_upgrade -u root -p
Enter password:
Looking for 'mysql' as: mysql
Looking for 'mysqlcheck' as: mysqlcheck
Running 'mysqlcheck with default connection arguments
mysqlcheck: Got error: 2002: Can't connect to local MySQL server through socket '/var/lib/mysql/mysql.sock' (2) when trying to connect
FATAL ERROR: Upgrade failed


Как мне запустить Mysql 5.5 и обновить БД?
Спасибо сказали:
BigBrother
Сообщения: 436
Статус: ¯\_(ツ)_/¯
ОС: linux based

Re: Решено: Mysql 5.5 обновленный с 5.0.95 не запускается

Сообщение BigBrother »

Arthes писал(а):
13.06.2013 11:39
После чего при попытке запустить MYSQL ---- /etc/init.d/mysqld start
Вылазиет ошибка FAILED

покажи лог с ошибкой.
Спасибо сказали:
Arthes
Сообщения: 282
ОС: OS X Yosemite and CentOS

Re: Решено: Mysql 5.5 обновленный с 5.0.95 не запускается

Сообщение Arthes »

Лог запуска mysqld:

Код: Выделить всё

130613 12:27:34 mysqld_safe Starting mysqld daemon with databases from /var/lib/mysql
130613 12:27:34 [Note] libgovernor.so not found
130613 12:27:34 [Note] Plugin 'FEDERATED' is disabled.
/usr/libexec/mysqld: Table 'mysql.plugin' doesn't exist
130613 12:27:34 [ERROR] Can't open the mysql.plugin table. Please run mysql_upgrade to create it.
130613 12:27:34 InnoDB: The InnoDB memory heap is disabled
130613 12:27:34 InnoDB: Mutexes and rw_locks use InnoDB's own implementation
130613 12:27:34 InnoDB: Compressed tables use zlib 1.2.3
130613 12:27:34 InnoDB: Using Linux native AIO
130613 12:27:34 InnoDB: Initializing buffer pool, size = 128.0M
130613 12:27:34 InnoDB: Completed initialization of buffer pool
InnoDB: Error: log file ./ib_logfile0 is of different size 0 24117248 bytes
InnoDB: than specified in the .cnf file 0 5242880 bytes!
130613 12:27:34 [ERROR] Plugin 'InnoDB' init function returned error.
130613 12:27:34 [ERROR] Plugin 'InnoDB' registration as a STORAGE ENGINE failed.
130613 12:27:34 [ERROR] Unknown/unsupported storage engine: InnoDB
130613 12:27:34 [ERROR] Aborting

130613 12:27:34 [Note] /usr/libexec/mysqld: Shutdown complete

130613 12:27:34 mysqld_safe mysqld from pid file /var/run/mysqld/mysqld.pid ended
Спасибо сказали:
BigBrother
Сообщения: 436
Статус: ¯\_(ツ)_/¯
ОС: linux based

Re: Решено: Mysql 5.5 обновленный с 5.0.95 не запускается

Сообщение BigBrother »

Arthes писал(а):
13.06.2013 12:29
Лог запуска mysqld:

Код: Выделить всё

InnoDB: Error: log file ./ib_logfile0 is of different size 0 24117248 bytes
InnoDB: than specified in the .cnf file 0 5242880 bytes!

удали из /var/lib/mysql файлы вида

Код: Выделить всё

ib_logfile0
ib_logfile1
ib_logfile2
ib_logfileN

и запусти mysql-server, он заново их создаст в соответствии с my.cnf. Только лишнего не удали, например ibdata1 :laugh:
Спасибо сказали:
Arthes
Сообщения: 282
ОС: OS X Yosemite and CentOS

Re: Решено: Mysql 5.5 обновленный с 5.0.95 не запускается

Сообщение Arthes »

BigBrother писал(а):
13.06.2013 13:00
Arthes писал(а):
13.06.2013 12:29
Лог запуска mysqld:

Код: Выделить всё

InnoDB: Error: log file ./ib_logfile0 is of different size 0 24117248 bytes
InnoDB: than specified in the .cnf file 0 5242880 bytes!

удали из /var/lib/mysql файлы вида

Код: Выделить всё

ib_logfile0
ib_logfile1
ib_logfile2
ib_logfileN

и запусти mysql-server, он заново их создаст в соответствии с my.cnf. Только лишнего не удали, например ibdata1 :laugh:



Огромное спасибо помогло!!! Не знал о такой особенности mysql.
Спасибо сказали: