Percona Server with XtraDB

InnoDB does not start automatically with shm buffer pool

Reported by Vadim Tkachenko on 2010-09-27
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
Percona Server
High
Unassigned

Bug Description

If we use buffer pool in shm, InnoDB can't start automatically after crash

InnoDB: The InnoDB memory heap is disabled
InnoDB: Mutexes and rw_locks use GCC atomic builtins
InnoDB: Compressed tables use zlib 1.2.3
InnoDB: Warning: The innodb_buffer_pool_shm_key option has been specified.
InnoDB: Do not change the following between restarts of the server while this option is being used:
InnoDB: * the mysqld executable between restarts of the server.
InnoDB: * the value of innodb_buffer_pool_size.
InnoDB: * the value of innodb_page_size.
InnoDB: * datafiles created by InnoDB during this session.
InnoDB: Otherwise, data corruption in datafiles may result.
InnoDB: The shared memory segment containing the buffer pool is: key 0x1561 (5473).
InnoDB: A shared memory segment containing the buffer pool seems to already exist.
InnoDB: The existent shared memory segment is used.
InnoDB: Error: The shared memory was not shut down cleanly.
InnoDB: Fatal error: cannot allocate the memory for the buffer pool
100926 15:41:38 [ERROR] Plugin 'InnoDB' init function returned error.
100926 15:41:38 [ERROR] Plugin 'InnoDB' registration as a STORAGE ENGINE failed.
100926 15:41:38 [Note] /usr/local/mysql/libexec/mysqld: ready for connections.

This is serious problem, as many production system are expect to restart mysqld automatically.

If needed we should remove and create segment from InnoDB.

Related branches

Changed in percona-server:
status: New → Confirmed
importance: Undecided → High
assignee: nobody → Yasufumi Kinoshita (yasufumi-kinoshita)

Please give me exact specification to obey.
This is alpha-version without no specification about exceptions.

"If needed we should remove and create segment from InnoDB."
is dull to be programmed.

Even if the segment does not seem to be buffer pool?
If the segment of the key is already used and cannot treat?
If the segment is used by another binary of mysqld?
and so on....

Please give me all pattern of shm usage.
There should be the case which should/can not restart automatically.

Initially it is OK if we handle only case

=====
if (!shm_info->clean) {
                               fprintf(stderr,
                               "InnoDB: Error: The shared memory was
not shut down cleanly.\n");
                               return(NULL);
                       }
=====
for now.

In this case I propose to remove existing segment and create new one.

On Mon, Sep 27, 2010 at 6:29 PM, Yasufumi Kinoshita
<email address hidden> wrote:
> Please give me exact specification to obey.
> This is alpha-version without no specification about exceptions.
>
> "If needed we should remove and create segment from InnoDB."
> is dull to be programmed.
>
> Even if the segment does not seem to be buffer pool?
> If the segment of the key is already used and cannot treat?
> If the segment is used by another binary of mysqld?
> and so on....
>
> Please give me all pattern of shm usage.
> There should be the case which should/can not restart automatically.
>
> --
> InnoDB does not start automatically with shm buffer pool
> https://bugs.launchpad.net/bugs/649393
> You received this bug notification because you are a direct subscriber
> of the bug.
>
> Status in Percona Server with XtraDB: Confirmed
>
> Bug description:
> If we use buffer pool in shm, InnoDB can't start automatically after crash
>
> InnoDB: The InnoDB memory heap is disabled
> InnoDB: Mutexes and rw_locks use GCC atomic builtins
> InnoDB: Compressed tables use zlib 1.2.3
> InnoDB: Warning: The innodb_buffer_pool_shm_key option has been specified.
> InnoDB: Do not change the following between restarts of the server while this option is being used:
> InnoDB:   * the mysqld executable between restarts of the server.
> InnoDB:   * the value of innodb_buffer_pool_size.
> InnoDB:   * the value of innodb_page_size.
> InnoDB:   * datafiles created by InnoDB during this session.
> InnoDB: Otherwise, data corruption in datafiles may result.
> InnoDB: The shared memory segment containing the buffer pool is: key  0x1561 (5473).
> InnoDB: A shared memory segment containing the buffer pool seems to already exist.
> InnoDB: The existent shared memory segment is used.
> InnoDB: Error: The shared memory was not shut down cleanly.
> InnoDB: Fatal error: cannot allocate the memory for the buffer pool
> 100926 15:41:38 [ERROR] Plugin 'InnoDB' init function returned error.
> 100926 15:41:38 [ERROR] Plugin 'InnoDB' registration as a STORAGE ENGINE failed.
> 100926 15:41:38 [Note] /usr/local/mysql/libexec/mysqld: ready for connections.
>
> This is serious problem, as many production system are expect to restart mysqld automatically.
>
> If needed we should remove and create segment from InnoDB.
>
> To unsubscribe from this bug, go to:
> https://bugs.launchpad.net/percona-server/+bug/649393/+subscribe
>

--
Vadim Tkachenko, CTO, Percona Inc.
Phone +1-888-401-3403,  Skype: vadimtk153
Schedule meeting: http://tungle.me/VadimTkachenko

Changed in percona-server:
status: Confirmed → Fix Committed
Changed in percona-server:
status: Fix Committed → Fix Released
To post a comment you must log in.
This report contains Public information  Edit
Everyone can see this information.

Other bug subscribers