← Back to team overview

maria-developers team mailing list archive

Re: crash in TC_LOG_MMAP::log_one_transaction in maria-10.0.0

 

Hello Sergei,
I made a 10.0.0 branch on launchpad with tokudb in it.  The following
can be used to hit the assert in TC_LOG_MMAP::log_one_transaction.  If
you have a chance, please take a look and let us know what we need to
change (if the maria 10 code base or in our storage engine) to get
this fixed.

Thanks
Rich Prohaska

Here is what i did to reproduce the problem:

mkdir m10 m10-build
cd m10-build

# get my maria10 branch and the 6.5.0 fractal tree SDK
bzr branch lp:~prohaska7/maria/2pc-crash-with-maria10-and-tokudb
wget https://s3.amazonaws.com/tokutek-mysql-6.5.0/tokufractaltreeindex-6.5.0-48167-linux-x86_64.tar.gz.md5
wget https://s3.amazonaws.com/tokutek-mysql-6.5.0/tokufractaltreeindex-6.5.0-48167-linux-x86_64.tar.gz
md5sum --check *.md5
tar xzf tokufractaltreeindex-6.5.0-48167-linux-x86_64.tar.gz

# setup env to point to	the fractal tree includes and libs
export TOKUFRACTALTREE=$PWD/tokufractaltreeindex-6.5.0-48167-linux-x86_64
export TOKUFRACTALTREE_LIBNAME=tokufractaltreeindex-6.5.0-48167_static
export TOKUPORTABILITY_LIBNAME=tokuportability-6.5.0-48167_static
export TOKUDB_VERSION=test10
export MYSQL_BUILD_PREFIX=$HOME/m10

# build and install
cd 2pc-crash-with-maria10-and.tokudb
./BUILD/compile-pentium-debug-max
make install

# run mysql_install_db

# start	mysqld

# install plugin tokudb	soname 'ha_tokudb.so';

# shutdown and reboot mysqld (so as to avoid a nasty crash in

# start	mysqld without binlog so that TC_LOG_MMAP is being used

# create tokudb and innodb test tables
# the following python program is attached.
# ./logxid.deadlock.py --docreate=1

# run some simple multi-engine txns until mysqld crashes.  takes a
couple of minutes on my machine.
# ./logxid.deadlock.py --k=1

# should hit this assert eventually:
# mysqld: /home/prohaska/m10-build/2pc-crash-with-maria10-and-tokudb/sql/log.cc:7547:
int TC_LOG_MMAP::log_one_transaction(my_xid): Assertion `p->ptr <
p->end' failed.


On Thu, Nov 15, 2012 at 11:05 AM, Sergei Golubchik <serg@xxxxxxxxxxxx> wrote:
> Hi, Rich!
>
> On Nov 15, Rich Prohaska wrote:
>> Hello,
>> I am having problems with the shinny new mariadb-10.0.0.
>>
>> I have a simple test case that replaces a row in innodb and tokudb and
>> then commits.  Eventually, mysqld hits this assert:
>>
>> mysqld: /home/prohaska/maria10-build/mariadb-10.0.0/sql/log.cc:7547:
>> int TC_LOG_MMAP::log_one_transaction(my_xid): Assertion `p->ptr <
>> p->end' failed.
>>
>> The test works great when the binlog is enabled.  The test crashes
>> when the binlog is OFF.  So, maybe the problem is isolated to the
>> TC_LOG_MMAP logic.  I noticed that the TC_LOG_MMAP::unlog function is
>> quite different than the mariadb-5.5 version.
>
> Yes, that's because of MDEV-232 (Remove one fsync() inside engine's
> commit() method).
>
>> What is the best way to get this fixed?  Would it help if i made the
>> test case available?
>
> Yes, please, it would help a lot!
>
> Regards,
> Sergei

Attachment: logxid.deadlock.py
Description: Binary data


Follow ups

References