Commit graph

309 commits

Author SHA1 Message Date
Alexey Botchkov
ed899ec8f2 MDEV-6124 Audit plugin fails with the Percona-Server 5.6.
Some lines of code in file_logger.c were lost while moving to the
   general MariaDB tree. Adding them.
2014-04-17 02:12:08 +05:00
Sergei Golubchik
cb67dcb618 mysql-5.5.37 selective merge 2014-03-27 22:26:58 +01:00
Alexey Botchkov
0c84a47c97 MDEV-5862 server_audit test fails in buildbot on Mac (labrador).
The RTLD_DEFAULT value on Labrador machine is not NULL,
        so the dlsym() commands in the server_audit just fail
        to bind the necessary functions.
        Fixed by using RTLD_DEFAULT explicitly.
2014-03-23 18:44:48 +04:00
Michael Widenius
1127d56735 Fixed some buildbot failures
mysql-test/suite/rpl/t/rpl_000011-master.opt:
  Added master.opt file to ensure that other tests don't interfere with rpl_000011
plugin/server_audit/server_audit.c:
  Fixed compiler error on solaris
support-files/compiler_warnings.supp:
  Ignore warning from xtradb
2014-03-18 10:26:50 +02:00
Alexey Botchkov
3f8c76f9e5 MDEV-5681 audit log will not rotate when the file size exceeds global variable setting.
Notifications about changed variables:
              server_audit_file_rotate_now
              server_audit_file_rotations
              server_audit_file_rotations
   are now handled and one doesn't need to stop/start logging to make them effective.
2014-03-17 19:09:53 +04:00
Murthy Narkedimilli
075a2fb716 Updated/added copyright header. Added line "use is subject to license terms"
to copyright header.
2014-02-17 18:19:04 +05:30
Alexey Botchkov
222e73c7a1 MariaDB Audit plugin added. 2014-02-24 23:40:16 +04:00
Sergei Golubchik
7b9c7c18d0 MDEV-5654 Server crashes on second installation of daemon_example plugin
daemon plugin: join the thread to make sure it exits before the plugin is unloaded
2014-02-17 11:10:26 +01:00
Sergei Golubchik
84651126c0 MySQL-5.5.36 merge
(without few incorrect bugfixes and with 1250 files where only a copyright year was changed)
2014-02-17 11:00:51 +01:00
Sergei Golubchik
37d240ecf9 MySQL-5.5.35 merge 2014-01-22 15:29:36 +01:00
Luis Soares
863d67e3ac BUG#17460821: ASSERTION ERROR WHEN STOPPING SLAVE AFTER SEMI-SYNC ON MASTER IS DISABLED
The assertion happens when: (i) the master and slave are configured to
use the semisync plugin; (ii) the DBA disables semisync on the master;
(iii) and he also unsets the option to wait for slaves ACK even if the
semisync slave count reaches 0 during the waiting period. This
combination of factors makes the server run into an assertion as soon
as the last semisync slave disconnects and its dump thread exits.
  
The root of the problem is the fact that when the dump thread
disconnects and calls the observer hook transmit_stop, which ends up
calling ReplSemiSyncMaster::remove_slave, there is no check whether
the master has already disabled semisync or not. If it has, the then a
second call to the switch_off member function must be avoided.
  
The quick fix is to avoid calling switch_off if the DBA has disabled
the semisync plugin interactively on the master. Also, the switch_off
member function should only be called if the plugin has not been
switched off already. This is basically the pattern throughout the
rest of the semisync plugin and no other calls seem vulnerable to
similar crashes/assertions.

(This a backport of the patch to 5.5, which is also vulnerable.)
2013-10-17 17:48:26 +01:00
Luis Soares
d97df1e8ff BUG#17508351: REDUNDANT CODE IN REPLSEMISYNCMASTER::UPDATESYNCHEADER
ReplSemiSyncMaster::updateSyncHeader contains redundant assignments
to the local variable sync.

This patch removes them.
2013-10-08 18:37:43 +01:00
Sujatha Sivakumar
cc4043f013 Bug#17327454:SEMI-SYNC REPLICATION MASTER CRASH WHEN SET
RPL_SEMI_SYNC_MASTER_ENABLED OFF.

Problem:
=======
If master is waiting for a reply from slave, at this time
set global rpl_semi_sync_master_enabled=OFF, the master
server will crash.

Analysis:
========
When master is waiting for a reply from slave, at this time
if semi sync is switched off on master, during switch off if
active transactions are present the transactions will be
cleared and "active_tranxs_" variable will be set to NULL.

When the waiting master connection finds that semi sync is
switched of it tries to access "active_tranxs_" without
checking if the transaction list exists or not. Accessing
NULL transaction list causes the crash.

Fix:
===
A check has been added to see a valid list exists before
accessing the "active_tranxs_".

plugin/semisync/semisync_master.cc:
  Added check for the existence of valid 'active_transx_'.
2013-09-23 12:13:37 +05:30
Vladislav Vaintroub
b0d98371b9 Update feedback plugin to recognize Windows 8.1 / Windows Server 2012 R2. 2013-09-20 14:37:30 +02:00
Sergei Golubchik
42f56557f5 MDEV-4941 make: AIX fails with 'Identifier not allowed in cast'; syntax error in include/my_global.h
C++ comments in C files, and a typo in my_global.h
2013-09-09 19:31:29 +02:00
Alexey Botchkov
92265da9d7 MDEV-4472 Audit-plugin. Server-related part of the task.
file_logger became the service.
     Data like query_id now are sent to the audit plugin.
     Fix for MDEV-4770 ported from 10.0.
     Fix added for the read_maria_plugin_info().
     Log rotation can be disabled with 'set rotations=0'.
2013-09-09 16:56:35 +05:00
Vladislav Vaintroub
078388f39c MDEV-4926: Remove division-using-subtraction implementation from semi-sync plugin
If rpl_semi_sync_master_timeout is large, calculation of absolute waiting time in semi-sync plugin is inefficient. This error is specific to systems with 64 bit long values (all 64 bit Unixes)
In  rpl_semi_sync_master_timeout has maximal value (= MAX_ULONGLONG), calculating abstime may require  ~ 18 billion subtract operations.

The fix is to use division instead of subtraction-in-a-loop. Also fixed an integer overflow bug.
2013-09-03 22:45:12 +02:00
Sergei Golubchik
005c7e5421 mysql-5.5.32 merge 2013-07-16 19:09:54 +02:00
Alexander Barkov
c51ed128b0 Merge from 5.3 2013-07-10 02:05:06 +04:00
Alexander Barkov
8a732d5a5e Merge from 5.2
modified:
  mysql-test/suite/plugins/r/fulltext_plugin.result
  mysql-test/suite/plugins/t/fulltext_plugin.test
  plugin/fulltext/plugin_example.c
  sql/sql_show.cc
pending merges:
  Alexander Barkov 2013-07-09 [merge] Merge from 5.1
    Sergei Golubchik 2013-07-06 Bug #69682 - mysqld crashes after uninst...
    Sergei Golubchik 2013-05-24 MDEV-4575 MySQL client doesn't strip off...
2013-07-09 11:02:56 +04:00
Alexander Barkov
762d3cb8ed Merge from 5.1
modified:
  mysql-test/suite/plugins/r/fulltext_plugin.result
  mysql-test/suite/plugins/t/fulltext_plugin.test
  plugin/fulltext/plugin_example.c
  sql/sql_show.cc
pending merges:
  Sergei Golubchik 2013-07-06 Bug #69682 - mysqld crashes after uninstall ...
    Sergei Golubchik 2013-05-24 MDEV-4575 MySQL client doesn't strip off...
2013-07-09 10:54:47 +04:00
Sergei Golubchik
48b403cd65 Bug #69682 - mysqld crashes after uninstall of plugin with "first" status var 2013-07-06 15:28:11 +02:00
Sergei Golubchik
7c61679c4e MDEV-4685 Compile error on LFS
fix the code to compile w/o perfomance schema
2013-06-22 14:02:03 +02:00
Sergei Golubchik
f722b15dc2 MDEV-4636 use mysql_cleartext_plugin from auth_pam
add a new command-line option --pam-use-cleartext-plugin
2013-06-11 12:53:35 +02:00
Sergei Golubchik
9bc4c4183d MDEV-4516 SELECT from I_S.QUERY_CACHE_INFO produces ER_UNKNOWN_ERROR when query cache size is 0
if qc->try_lock() fails, it's not an error
2013-05-24 14:33:04 +02:00
Vladislav Vaintroub
1d130cc697 Fix build on Windows 2013-04-25 15:11:59 +02:00
Sergei Golubchik
b9b3d5330a MDEV-260 auditing table accesses 2013-04-19 12:50:16 +02:00
Sergei Golubchik
5d4ba5589d compilation warnings 2013-04-04 11:37:23 +02:00
Sergei Golubchik
102a7a2a76 MDEV-4307 Support at least 48 utf8 characters in username in server and PAM
Extend plugin auth api to support up to 512 bytes in the user names.
Use the API versioning to support old auth plugins too!
2013-03-26 19:17:26 +01:00
Sergei Golubchik
01fd55ccae MDEV-249 QUERY CACHE INFORMATION 2013-03-20 20:56:14 +01:00
Sergei Golubchik
8f1b1ab5b0 MDEV-4175 auth_socket to build on OpenBSD / Bitrig 2013-03-08 19:09:15 +01:00
Sergei Golubchik
aca8e7ed6b 5.3 merge 2013-01-15 19:07:46 +01:00
Sergei Golubchik
4f67a14700 5.2->5.3 merge 2013-01-10 15:40:21 +01:00
Vladislav Vaintroub
f8f2cdf21f Fix broken feedback plugin after MDEV-712.
Link feedback plugin with yassl libraries, if with-ssl=bundled is used, since mysqld does not export SSL symbols anymore.
2012-11-26 13:33:24 +01:00
Vladislav Vaintroub
089119cab5 merge 5.1 2012-11-22 18:29:53 +01:00
Vladislav Vaintroub
3fa3561066 Feedback plugin now recognizes Windows 8 / Windows Server 2012. 2012-11-22 18:27:02 +01:00
Sergei Golubchik
a48a91d90f 5.3->5.5 merge 2012-11-22 10:19:31 +01:00
unknown
cbae294396 Merge MariaDB 5.1->5.2. 2012-11-20 13:40:13 +01:00
Sergei Golubchik
9e7d870b36 potential crash in the feedback plugin 2012-11-19 11:18:40 +01:00
unknown
ecf04668a2 Merge MariaDB 5.2->5.3 2012-11-20 13:57:49 +01:00
Sergei Golubchik
06365bf841 rename plugin null_audit -> audit_null (to match status variable names)
create audit_null.test
2012-11-07 19:07:47 +01:00
Sergei Golubchik
0380b0e280 build feedback plugin with ssl (changes for cmake).
fix the ssl related code to use newer function prototypes
2012-11-06 18:09:26 +01:00
Sergei Golubchik
68baf07dcd 5.3 merge 2012-10-18 23:33:06 +02:00
Sergei Golubchik
352d7cad1b merge 2012-09-27 15:02:17 +02:00
Sergei Golubchik
22c5ffde30 a simple pam user mapper module 2012-09-25 20:23:01 +02:00
Michael Widenius
89036b9f8a Fixed compiler warnings
Fixed error in test that caused following tests to fail

extra/yassl/taocrypt/src/dsa.cpp:
  Fixed compiler warning by adding cast
mysql-test/suite/rpl/t/rpl_start_slave_deadlock_sys_vars.test:
  We have to first test for have_debug_sync to not start master wrongly
plugin/auth_pam/auth_pam.c:
  Fixed compiler warning
sql/sys_vars.h:
  Fixed compiler warning (Sys_var_max_user_conn is now signed)
support-files/compiler_warnings.supp:
  Don't give warnings for auth_pam.c (Tried to fix it by changing the code, but could not find an easy way to do that on solaris)
2012-08-17 10:01:19 +03:00
Michael Widenius
c0f04fa31c Automatic merge 2012-08-13 23:45:16 +03:00
Michael Widenius
cee888acb3 Fixed compiler warnings (A few of these was bugs)
client/mysqldump.c:
  Slave needs to be initialized with 0
dbug/dbug.c:
  Removed not existing function
plugin/semisync/semisync_master.cc:
  Fixed compiler warning
sql/opt_range.cc:
  thd needs to be set early as it's used in some error conditions.
sql/sql_table.cc:
  Changed to use uchar* to make array indexing portable
storage/innobase/handler/ha_innodb.cc:
  Removed not used variable
storage/maria/ma_delete.c:
  Fixed compiler warning
storage/maria/ma_write.c:
  Fixed compiler warning
2012-08-13 22:23:28 +03:00
Sergei Golubchik
d11829654c merge with MySQL 5.5.27
manually checked every change, reverted incorrect or stupid changes.
2012-08-09 17:22:00 +02:00
Jon Olav Hauglid
66ef5b0d48 Bug#14238406 NEW COMPILATION WARNINGS WITH GCC 4.7 (-WERROR=NARROWING)
Manual merge from mysql-5.1 to mysql-5.5
2012-06-29 13:36:01 +02:00