Commit graph

50420 commits

Author SHA1 Message Date
unknown
9a20ca1390 Merge gleb.loc:/home/uchum/work/bk/5.0-opt
into  gleb.loc:/home/uchum/work/bk/5.1-opt
2007-09-14 12:35:06 +05:00
unknown
a89c768bc0 Merge gleb.loc:/home/uchum/work/bk/5.1
into  gleb.loc:/home/uchum/work/bk/5.1-opt
2007-09-14 12:18:48 +05:00
unknown
a87365e5db Merge gleb.loc:/home/uchum/work/bk/5.0
into  gleb.loc:/home/uchum/work/bk/5.0-opt
2007-09-14 12:16:19 +05:00
unknown
f77e2969ef Check of log initialization added.
storage/maria/ma_loghandler.c:
  Check of log initialization added.
  Function descriptions fixed.
2007-09-14 09:17:36 +03:00
unknown
c0a9e9961e scripts/mysqld_safe.sh
Copy a fix by jperkin for bug#30624 into the 5.1.22 build tree.


scripts/mysqld_safe.sh:
  Copy a fix by jperkin for bug#30624 into the 5.1.22 build tree.
2007-09-14 00:59:22 +02:00
unknown
c51f1e1b86 Merge trift2.:/MySQL/M50/tmp-5.0
into  trift2.:/MySQL/M51/tmp-5.1
2007-09-13 23:56:48 +02:00
unknown
fc670a822a Merge trift2.:/MySQL/M51/push-5.1
into  trift2.:/MySQL/M51/tmp-5.1


config/ac-macros/misc.m4:
  Auto merged
2007-09-13 23:54:22 +02:00
unknown
f2dd535bbc Merge trift2.:/MySQL/M50/push-5.0
into  trift2.:/MySQL/M50/tmp-5.0
2007-09-13 23:42:17 +02:00
unknown
ce3bf14628 Bugfix: --pagecache* options were ignored; with --key-cache*=# --pagecache*=#,
the latter wrote into the settings of the key cache! Problem was that
--pagecache* options reused OPT_KEY_CACHE* enum values.


sql/mysqld.cc:
  --pagecache* options should not reuse the OPT_KEY_CACHE* enum values, it
  confuses my_getopt. Making handling of page caches similar to handling
  of key caches, in mysqld.cc.
2007-09-13 21:05:17 +02:00
unknown
e34c130441 fix intermittant timing-related test failure 2007-09-13 09:34:21 -07:00
unknown
037a0f7677 Fixed bug #27695.
Declaring an all space column name in the SELECT FROM DUAL or in a view
leads to misleading warning message:
"Leading spaces are removed from name ' '".

The Item::set_name method has been modified to raise warnings like
"Name ' ' has become ''" in case of the truncation of an all
space identifier to an empty string identifier instead of the
"Leading spaces are removed from name ' '" warning message.


sql/item.cc:
  Fixed bug #27695.
  The Item::set_name method has been modified to raise warnings like
  "Name ' ' has become ''" in case of the truncation of an all
  space identifier to an empty string identifier instead of the
  "Leading spaces are removed from name ' '" warning message.
sql/share/errmsg.txt:
  Fixed bug #27695.
mysql-test/t/select.test:
  Added test case for bug #27695.
mysql-test/r/select.result:
  Added test case for bug #27695.
2007-09-13 18:41:50 +05:00
unknown
35ed02ba9a Merge gleb.loc:/home/uchum/work/bk/5.0-opt
into  gleb.loc:/home/uchum/work/bk/5.1-opt


sql/opt_range.cc:
  Auto merged
2007-09-13 15:05:54 +05:00
unknown
a0403f7a51 Merge mskold@bk-internal.mysql.com:/home/bk/mysql-5.0-ndb
into  mysql.com:/windows/Linux_space/MySQL/mysql-5.0-ndb
2007-09-13 10:35:11 +02:00
unknown
577a1633a9 Merge mskold@bk-internal.mysql.com:/home/bk/mysql-5.1-ndb
into  mysql.com:/windows/Linux_space/MySQL/mysql-5.1-new-ndb
2007-09-13 10:06:42 +02:00
unknown
39d845945d Merge mysql.com:/windows/Linux_space/MySQL/mysql-5.0-ndb
into  mysql.com:/windows/Linux_space/MySQL/mysql-5.1-new-ndb


sql/ha_ndbcluster_cond.cc:
  Auto merged
2007-09-13 10:00:14 +02:00
unknown
eacd5ec43c bug#27494 An invalid subselect crashes mysql server: Added check for missing arguments 2007-09-13 09:47:21 +02:00
unknown
a303f5b2c8 Fixes of the empty log problem.
storage/maria/ma_checkpoint.c:
  The new macro for easier printing LSN added.
storage/maria/ma_loghandler.c:
  The assertion returned.
  The new macro for easier printing LSN added.
storage/maria/ma_loghandler_lsn.h:
  The new macro for easier printing LSN added.
storage/maria/ma_pagecache.c:
  The new macro for easier printing LSN added.
storage/maria/ma_recovery.c:
  Recovery checks empty log state.
  RECHEADER_READ_ERROR means some real error.
storage/maria/maria_read_log.c:
  Read log starts from real beggining of the log and precess
  error and empty log states.
  The new macro for easier printing LSN added.
storage/maria/unittest/ma_test_loghandler-t.c:
  The new macro for easier printing LSN added.
storage/maria/unittest/ma_test_loghandler_first_lsn-t.c:
  The new macro for easier printing LSN added.
storage/maria/unittest/ma_test_loghandler_max_lsn-t.c:
  The new macro for easier printing LSN added.
storage/maria/unittest/ma_test_loghandler_multigroup-t.c:
  The new macro for easier printing LSN added.
storage/maria/unittest/ma_test_loghandler_multithread-t.c:
  The new macro for easier printing LSN added.
storage/maria/unittest/ma_test_loghandler_noflush-t.c:
  The new macro for easier printing LSN added.
2007-09-13 10:37:51 +03:00
unknown
aa5da0fc9e Merge gshchepa@bk-internal.mysql.com:/home/bk/mysql-5.0-opt
into  gleb.loc:/home/uchum/work/bk/5.0-opt
2007-09-13 11:48:58 +05:00
unknown
fa09f66722 Merge gleb.loc:/home/uchum/work/bk/5.0-opt
into  gleb.loc:/home/uchum/work/bk/5.1-opt


mysql-test/r/sp.result:
  Auto merged
mysql-test/t/sp.test:
  Auto merged
sql/sql_yacc.yy:
  Auto merged
2007-09-13 11:31:45 +05:00
unknown
fa12674c09 Changes for pushbuild test runs and VSC compile warnings
mysql-test/suite/rpl/r/rpl_innodb_bug28430.result:
  Fix test results for pushbuild
mysql-test/suite/rpl/t/rpl_innodb_bug28430.test:
  Fix test results for pushbuild
mysql-test/suite/rpl/t/rpl_innodb_bug30888.test:
  Fix test results for pushbuild
storage/innobase/handler/ha_innodb.cc:
  resolve a VSC++ typecast compile warning.
2007-09-12 18:16:50 -07:00
unknown
33e51ec729 sql_view.cc:
Post-merge fix.


sql/sql_view.cc:
  Post-merge fix.
2007-09-13 02:09:29 +05:00
unknown
23227604be undo unneccessary change to ha_innodb.cc
remove 'drop database' from new tests.


mysql-test/suite/rpl/r/rpl_innodb_bug28430.result:
  remove "DROP DATABASE test"
mysql-test/suite/rpl/r/rpl_innodb_bug30888.result:
  remove "DROP DATABASE test"
mysql-test/suite/rpl/r/rpl_innodb_bug30919.result:
  remove "DROP DATABASE test"
mysql-test/suite/rpl/t/rpl_innodb_bug28430.test:
  remove "DROP DATABASE test"
mysql-test/suite/rpl/t/rpl_innodb_bug30888.test:
  remove "DROP DATABASE test"
mysql-test/suite/rpl/t/rpl_innodb_bug30919.test:
  remove "DROP DATABASE test"
storage/innobase/handler/ha_innodb.cc:
  undo unneccessary edits.
2007-09-12 13:35:39 -07:00
unknown
5b541452a8 Merge gleb.loc:/home/uchum/work/bk/5.1
into  gleb.loc:/home/uchum/work/bk/5.1-opt


mysql-test/r/sp.result:
  SCCS merged
mysql-test/t/sp.test:
  SCCS merged
sql/sql_lex.h:
  SCCS merged
sql/sql_parse.cc:
  SCCS merged
sql/sql_yacc.yy:
  SCCS merged
2007-09-13 00:44:50 +05:00
unknown
2978fcc3e9 Merge gleb.loc:/home/uchum/work/bk/5.0
into  gleb.loc:/home/uchum/work/bk/5.0-opt


sql/sql_yacc.yy:
  Auto merged
mysql-test/r/sp.result:
  SCCS merged
mysql-test/t/sp.test:
  SCCS merged
2007-09-12 23:41:35 +05:00
unknown
9b2663926b MY_ALLOW_ZERO_PTR in my_realloc() to fix safemalloc errors in pushbuild
storage/maria/ma_recovery.c:
  MY_ALLOW_ZERO_PTR needed as log_record_buffer.str is initially NULL.
2007-09-12 19:18:52 +02:00
unknown
0068c18930 Better wording in comments 2007-09-12 18:13:19 +04:00
unknown
5becb1e404 fix for pushbuild test failures
mysql-test/r/rpl_row_flsh_tbls.result:
  result update
mysql-test/r/rpl_row_insert_delayed.result:
  result update
mysql-test/t/rpl_row_flsh_tbls.test:
  CREATE TABLE statement got an ENGINE clause so became longer
2007-09-12 15:10:41 +02:00
unknown
20d871e5de fix for pushbuild test failure (my_realloc() failed => checkpoint
failed => Maria didn't start => tables were created as MyISAM).


storage/maria/ma_checkpoint.c:
  safemalloc complains if my_realloc() is passed NULL and
  MY_ALLOW_ZERO_PTR is not used.
2007-09-12 14:46:05 +02:00
unknown
bf520ce740 Merge whalegate.ndb.mysql.com:/home/tomas/mysql-5.0-ndb-merge
into  whalegate.ndb.mysql.com:/home/tomas/mysql-5.1-new-ndb-merge


mysql-test/Makefile.am:
  Auto merged
sql/ha_ndbcluster.cc:
  Auto merged
2007-09-12 14:03:21 +02:00
unknown
a1de9c7827 Merge whalegate.ndb.mysql.com:/home/tomas/mysql-5.1-new-ndb
into  whalegate.ndb.mysql.com:/home/tomas/mysql-5.1-new-ndb-merge


sql/ha_ndbcluster.cc:
  Auto merged
2007-09-12 14:02:27 +02:00
unknown
345891d76b Merge whalegate.ndb.mysql.com:/home/tomas/mysql-5.0-ndb
into  whalegate.ndb.mysql.com:/home/tomas/mysql-5.0-ndb-merge


mysql-test/Makefile.am:
  Auto merged
sql/ha_ndbcluster.cc:
  Auto merged
2007-09-12 14:01:51 +02:00
unknown
6bead54df8 Merge whalegate.ndb.mysql.com:/home/tomas/mysql-5.0-ndb-bj
into  whalegate.ndb.mysql.com:/home/tomas/mysql-5.1-new-ndb-bj


sql/ha_ndbcluster.cc:
  Auto merged
storage/ndb/src/common/debugger/EventLogger.cpp:
  Auto merged
storage/ndb/src/mgmclient/CommandInterpreter.cpp:
  Auto merged
storage/ndb/src/ndbapi/NdbDictionaryImpl.cpp:
  Auto merged
2007-09-12 13:58:03 +02:00
unknown
85b4a64cdf Merge whalegate.ndb.mysql.com:/home/tomas/mysql-5.1-new-ndb
into  whalegate.ndb.mysql.com:/home/tomas/mysql-5.1-new-ndb-bj


sql/ha_ndbcluster.cc:
  Auto merged
2007-09-12 13:55:45 +02:00
unknown
46bca215c7 Merge whalegate.ndb.mysql.com:/home/tomas/mysql-5.0-ndb
into  whalegate.ndb.mysql.com:/home/tomas/mysql-5.0-ndb-bj
2007-09-12 13:55:22 +02:00
unknown
2ef5838c90 BUG#23354 revert 2007-09-12 13:53:32 +02:00
unknown
a5f4e79db9 WL#3072 Maria Recovery
* added replaying of REDO_REPAIR_TABLE, but disabled it as
mysterious linker errors appear.
* after replaying RENAME/REPAIR, we must bump create_rename_lsn
for idempotency of maria_read_log.


sql/mysqld.cc:
  typo
storage/maria/ma_checkpoint.c:
  silence compiler warning
storage/maria/ma_recovery.c:
  * added replaying of REDO_REPAIR_TABLE, but disabled it as
  mysterious linker errors appear.
  * after replaying RENAME/REPAIR, we must bump create_rename_lsn
  for idempotency of maria_read_log.
2007-09-12 12:39:04 +02:00
unknown
bdf0ab58be Merge bk-internal.mysql.com:/data0/bk/mysql-5.0-opt
into  bk-internal.mysql.com:/data0/bk/mysql-5.1-opt


sql/opt_range.cc:
  Auto merged
2007-09-12 11:52:42 +02:00
unknown
cec8ac3e07 WL#3071 Maria checkpoint
Finally this is the real checkpoint code.
It however exhibits unstabilities when a checkpoint runs concurrently
with data-modifying clients (table corruption, transaction log's
assertions) so for now a checkpoint is taken only at startup after
recovery and at shutdown, i.e. not in concurrent situations. Later
we will let it run periodically, as well as flush dirty pages
periodically (almost all needed code is there already, only pagecache
code is written but not committed).
WL#3072 Maria recovery
* replacing UNDO_ROW_PURGE with CLR_END; testing of those CLR_END via
ma_test2 which has INSERTs failing with duplicate keys.
* replaying of REDO_RENAME_TABLE
Now, off to test Recovery in ha_maria :)


BitKeeper/deleted/.del-ma_least_recently_dirtied.c:
  Delete: storage/maria/ma_least_recently_dirtied.c
BitKeeper/deleted/.del-ma_least_recently_dirtied.h:
  Delete: storage/maria/ma_least_recently_dirtied.h
storage/maria/Makefile.am:
  compile Checkpoint module
storage/maria/ha_maria.cc:
  When ha_maria starts, do a recovery from last checkpoint.
  Take a checkpoint when that recovery has ended and when ha_maria
  shuts down cleanly.
storage/maria/ma_blockrec.c:
  * even if my_sync() fails we have to my_close() (otherwise we leak
  a descriptor)
  * UNDO_ROW_PURGE is replaced by a simple CLR_END for UNDO_ROW_INSERT,
  as promised in the old comment; it gives us skipping during the
  UNDO phase.
storage/maria/ma_check.c:
  All REDOs before create_rename_lsn are ignored by Recovery. So
  create_rename_lsn must be set only after all data/index has been
  flushed and forced to disk. We thus move write_log_record_for_repair()
  to after _ma_flush_tables_files_after_repair().
storage/maria/ma_checkpoint.c:
  Checkpoint module.
storage/maria/ma_checkpoint.h:
  optional argument if caller wants a thread to periodically take
  checkpoints and flush dirty pages.
storage/maria/ma_create.c:
  * no need to init some vars as the initial bzero(share) takes care of this.
  * update to new function's name
  * even if we fail in my_sync() we have to my_close()
storage/maria/ma_extra.c:
  Checkpoint reads share->last_version under intern_lock, so we make
  maria_extra() update it under intern_lock. THR_LOCK_maria still needed
  because of _ma_test_if_reopen().
storage/maria/ma_init.c:
  destroy checkpoint module when Maria shuts down.
storage/maria/ma_loghandler.c:
  * UNDO_ROW_PURGE gone (see ma_blockrec.c)
  * we need to remember the LSN of the LOGREC_FILE_ID for a share,
  because this LSN is needed into the checkpoint record (Recovery wants
  to know the validity domain of an id->name mapping)
  * translog_get_horizon_no_lock() needed for Checkpoint
  * comment about failing assertion (Sanja knows)
  * translog_init_reader_data() thought that translog_read_record_header_scan()
  returns 0 in case of error, but 0 just means "0-length header".
  * translog_assign_id_to_share() now needs the MARIA_HA because
  LOGREC_FILE_ID uses a log-write hook.
  * Verify that (de)assignment of share->id happens only under intern_lock,
  as Checkpoint reads this id with intern_lock.
  * translog_purge() can accept TRANSLOG_ADDRESS, not necessarily
  a real LSN.
storage/maria/ma_loghandler.h:
  prototype updates
storage/maria/ma_open.c:
  no need to initialize "res"
storage/maria/ma_pagecache.c:
  When taking a checkpoint, we don't need to know the maximum rec_lsn
  of dirty pages; this LSN was intended to be used in the two-checkpoint
  rule, but last_checkpoint_lsn is as good.
  4 bytes for stored_list_size is enough as PAGECACHE::blocks (number
  of blocks which the pagecache can contain) is int.
storage/maria/ma_pagecache.h:
  new prototype
storage/maria/ma_recovery.c:
  * added replaying of REDO_RENAME_TABLE
  * UNDO_ROW_PURGE gone (see ma_blockrec.c), replaced by CLR_END
  * Recovery from the last checkpoint record now possible
  * In new_table() we skip the table if the id->name mapping is older than
  create_rename_lsn (mapping dates from lsn_of_file_id).
  * in get_MARIA_HA_from_REDO_record() we skip the record
  if the id->name mapping is newer than the record (can happen if processing
  a record which is before the checkpoint record).
  * parse_checkpoint_record() has to return a LSN, that's what caller expects
storage/maria/ma_rename.c:
  new function's name; log end zeroes of tables' names (ease recovery)
storage/maria/ma_test2.c:
  * equivalent of ma_test1's --test-undo added (named -u here).
  * -t=1 now stops right after creating the table, so that
  we can test undoing of INSERTs with duplicate keys (which tests the
  CLR_END logged by _ma_write_abort_block_record()).
storage/maria/ma_test_recovery.expected:
  Result of testing undoing of INSERTs with duplicate keys; there are
  some differences in maria_chk -dvv but they are normal (removing
  records does not shrink data/index file, does not put back the
  "analyzed, optimized keys"(etc) index state.
storage/maria/ma_test_recovery:
  Test undoing of INSERTs with duplicate keys, using ma_test2;
  when such INSERT happens, it logs REDO_INSERT, UNDO_INSERT, REDO_DELETE,
  CLR_END; we abort after that, and test that CLR_END causes recovery
  to jump over UNDO_INSERT.
storage/maria/ma_write.c:
  comment
storage/maria/maria_chk.c:
  comment
storage/maria/maria_def.h:
  * a new bit in MARIA_SHARE::in_checkpoint, used to build a list
  of unique shares during Checkpoint.
  * MARIA_SHARE::lsn_of_file_id added: the LSN of the last LOGREC_FILE_ID
  for this share; needed to know to which LSN domain the mappings
  found in the Checkpoint record apply (new mappings should not apply
  to old REDOs).
storage/maria/trnman.c:
  * small changes to how trnman_collect_transactions() fills its buffer;
  it also uses a non-dummy lsn_read_non_atomic() found in ma_checkpoint.h
2007-09-12 11:27:34 +02:00
unknown
6d37d4b7b4 Merge whalegate.ndb.mysql.com:/home/tomas/mysql-5.0-ndb-merge
into  whalegate.ndb.mysql.com:/home/tomas/mysql-5.1-new-ndb-merge


sql/ha_ndbcluster.cc:
  Auto merged
2007-09-12 07:37:27 +02:00
unknown
5f183053df Merge whalegate.ndb.mysql.com:/home/tomas/mysql-5.0
into  whalegate.ndb.mysql.com:/home/tomas/mysql-5.0-ndb-merge


sql/ha_ndbcluster.cc:
  Auto merged
2007-09-12 07:34:42 +02:00
unknown
ba39449e01 Post-merge fixes 2007-09-12 01:52:27 +04:00
unknown
bc093b0131 Merge whalegate.ndb.mysql.com:/home/tomas/mysql-5.1-new-ndb
into  whalegate.ndb.mysql.com:/home/tomas/mysql-5.1-new-ndb-merge
2007-09-11 19:56:26 +02:00
unknown
337390e950 Merge tulin@bk-internal.mysql.com:/home/bk/mysql-5.1-new-ndb
into  whalegate.ndb.mysql.com:/home/tomas/mysql-5.1-new-ndb
2007-09-11 19:52:05 +02:00
unknown
4c2d50e426 merging 2007-09-11 20:47:17 +05:00
unknown
7f8e80927d Merge perch.ndb.mysql.com:/home/jonas/src/51-telco-gca
into  perch.ndb.mysql.com:/home/jonas/src/51-ndb


storage/ndb/src/kernel/blocks/dbtup/DbtupCommit.cpp:
  Auto merged
storage/ndb/test/src/HugoTransactions.cpp:
  Auto merged
storage/ndb/test/src/Makefile.am:
  merge
2007-09-11 16:55:37 +02:00
unknown
f15444833e ndb - bug#30914
Dont add insert+delete tuple(s) to lcp-keep-list
2007-09-11 16:45:22 +02:00
unknown
4c888fcb67 Merge whalegate.ndb.mysql.com:/home/tomas/mysql-5.1
into  whalegate.ndb.mysql.com:/home/tomas/mysql-5.1-new-ndb-merge


mysql-test/suite/rpl/r/rpl_row_tabledefs_2myisam.result:
  Auto merged
mysql-test/suite/rpl/r/rpl_row_tabledefs_3innodb.result:
  Auto merged
mysql-test/t/disabled.def:
  Auto merged
sql/field.cc:
  Auto merged
sql/field.h:
  Auto merged
sql/ha_ndbcluster.cc:
  Auto merged
sql/ha_ndbcluster_binlog.h:
  Auto merged
sql/log_event.cc:
  Auto merged
sql/log_event.h:
  Auto merged
sql/rpl_record.cc:
  Auto merged
sql/rpl_rli.h:
  Auto merged
sql/rpl_utility.cc:
  Auto merged
sql/rpl_utility.h:
  Auto merged
2007-09-11 16:17:28 +02:00
unknown
cf9b8d332d Merge gbichot@bk-internal.mysql.com:/home/bk/mysql-maria
into  gbichot4.local:/home/mysql_src/mysql-maria-no-flush-state
2007-09-11 11:12:04 +02:00
unknown
0b2ba820c3 WL#3072 Maria recovery
* testing of execution of UNDO_ROW_UPDATE
* when executing an UNDO_ROW_UPDATE, store "UNDO_ROW_UPDATE" as
"type of undone record" into the CLR_END record.


storage/maria/ma_blockrec.c:
  When logging a CLR_END in write_block_record(), it can be for
  a DELETE or for an UPDATE (now that Monty has coded execution of
  UNDO_UPDATE)
storage/maria/ma_loghandler.c:
  UNDO_ROW_UPDATE's execution coded, so no crash
storage/maria/ma_recovery.c:
  UNDO_ROW_UPDATE's execution now coded, so no crash
storage/maria/ma_test1.c:
  upper case letter
storage/maria/ma_test_recovery.expected:
  output of testing execution of UNDO_ROW_UPDATE. Table's checksum
  not recovered (known issue not specific to UPDATE).
storage/maria/ma_test_recovery:
  Test execution of UNDO_ROW_UPDATE: first we stop ma_test1 after
  deletes and commit, then we stop ma_test1 after updates and abort;
  we verify that updates are rolled back by comparing tables
2007-09-11 11:11:22 +02:00
unknown
48189ca420 Absence of test_file.h fixed. 2007-09-11 09:37:17 +03:00