[MDEV-11460] server_audit does not work with mysql_community 5.7.16 Created: 2016-12-02  Updated: 2017-03-06  Resolved: 2017-03-06

Status: Closed
Project: MariaDB Server
Component/s: Plugin - Audit
Affects Version/s: 10.1.19
Fix Version/s: 10.1.22

Type: Bug Priority: Major
Reporter: A De Maria Assignee: Alexey Botchkov
Resolution: Fixed Votes: 0
Labels: None
Environment:

ubuntu trusty
mysql-community-server 5.7.16-1ubuntu14.04


Sprint: 10.1.22

 Description   

Hello,

I am trying to use the *server_audit* plugin which I understand is also compatible with MySql community.

Unfortunately, while the plugin loads successfully, mysql stops accepting connections, and the following can be found in the error.log

11:55:42 UTC - mysqld got signal 11 ;
This could be because you hit a bug. It is also possible that this binary
or one of the libraries it was linked against is corrupt, improperly built,
or misconfigured. This error can also be caused by malfunctioning hardware.
Attempting to collect some information that could help diagnose the problem.
As this is a crash and something is definitely wrong, the information
collection process might fail.
 
key_buffer_size=8388608
read_buffer_size=131072
max_used_connections=1
max_threads=151
thread_count=1
connection_count=1
It is possible that mysqld could use up to 
key_buffer_size + (read_buffer_size + sort_buffer_size)*max_threads = 68190 K  bytes of memory
Hope that's ok; if not, decrease some variables in the equation.
 
Thread pointer: 0x7f0868000ae0
Attempting backtrace. You can use the following information to find out
where mysqld died. If you see no messages after this, something went
terribly wrong...
stack_bottom = 7f089a556e40 thread_stack 0x40000
/usr/sbin/mysqld(my_print_stacktrace+0x2c)[0xec38ac]
/usr/sbin/mysqld(handle_fatal_signal+0x451)[0x7add51]
/lib/x86_64-linux-gnu/libpthread.so.0(+0x10330)[0x7f08aef27330]
/usr/lib/mysql/plugin/server_audit.so(auditing+0x65e)[0x7f089404afae]
/usr/lib/mysql/plugin/server_audit.so(+0xa11b)[0x7f089404c11b]
/usr/sbin/mysqld[0x7adf43]
/usr/sbin/mysqld(_Z18mysql_audit_notifyP3THD30mysql_event_general_subclass_tiPKcm+0x1f4)[0x7ae4c4]
/usr/sbin/mysqld(_ZN12Query_logger17general_log_printEP3THD19enum_server_commandPKcz+0xc5)[0xbeedb5]
/usr/sbin/mysqld(_Z15acl_log_connectPKcS0_S0_S0_P3THD19enum_server_command+0xa0)[0x7b5f00]
/usr/sbin/mysqld(_Z16acl_authenticateP3THD19enum_server_command+0xb51)[0x7b6cb1]
/usr/sbin/mysqld[0xc5fc9d]
/usr/sbin/mysqld(_Z22thd_prepare_connectionP3THD+0x53)[0xc60d93]
/usr/sbin/mysqld(handle_connection+0x250)[0xd5dc60]
/usr/sbin/mysqld(pfs_spawn_thread+0x1b4)[0x1230034]
/lib/x86_64-linux-gnu/libpthread.so.0(+0x8184)[0x7f08aef1f184]
/lib/x86_64-linux-gnu/libc.so.6(clone+0x6d)[0x7f08ae42c37d]
 
Trying to get some variables.
Some pointers may be invalid and cause the dump to abort.
Query (0): Connection ID (thread ID): 2
Status: NOT_KILLED

I have tried using the plugin from the binary tarball of MariaDB 10.1.19.
I have also tried compiling it with the following instructions:

apt-key adv --keyserver pgp.mit.edu --recv-keys 5072E1F5
mysql.list /etc/apt/sources.list.d/
apt-get -y update && apt-get install -y build-essential curl cmake libncurses5-dev libreadline-dev zlib1g-dev libaio-dev libjemalloc-dev libmysqlclient-dev
cd /mariadb-source
cmake . -DBUILD_CONFIG=mysql_release
cd plugin/server_audit
make



 Comments   
Comment by Alexey Botchkov [ 2017-03-06 ]

This bug was fixed since Server Audit v 1.4.1.
The fix is in MariaDB 5.5 already, though wasn't yet merged into 10.1.

Generated at Thu Feb 08 07:50:07 UTC 2024 using Jira 8.20.16#820016-sha1:9d11dbea5f4be3d4cc21f03a88dd11d8c8687422.