percona-server-5.5.37-35.0.tar.gz
This commit is contained in:
parent
7996f5061e
commit
d60b4df1ef
@ -1,6 +1,6 @@
|
||||
/*****************************************************************************
|
||||
|
||||
Copyright (c) 1995, 2013, Oracle and/or its affiliates. All Rights Reserved.
|
||||
Copyright (c) 1995, 2014, Oracle and/or its affiliates. All Rights Reserved.
|
||||
Copyright (c) 2008, Google Inc.
|
||||
|
||||
Portions of this file contain modifications contributed and copyrighted by
|
||||
@ -2519,7 +2519,9 @@ loop:
|
||||
rw_lock_s_unlock(&buf_pool->page_hash_latch);
|
||||
}
|
||||
|
||||
#if defined UNIV_DEBUG || defined UNIV_IBUF_DEBUG
|
||||
loop2:
|
||||
#endif
|
||||
if (block && buf_pool_watch_is_sentinel(buf_pool, &block->page)) {
|
||||
mutex_exit(block_mutex);
|
||||
block = NULL;
|
||||
|
@ -4953,14 +4953,24 @@ fil_extend_space_to_desired_size(
|
||||
|
||||
#ifdef HAVE_POSIX_FALLOCATE
|
||||
if (srv_use_posix_fallocate) {
|
||||
offset_high = (size_after_extend - file_start_page_no)
|
||||
* page_size / (4ULL * 1024 * 1024 * 1024);
|
||||
offset_low = (size_after_extend - file_start_page_no)
|
||||
* page_size % (4ULL * 1024 * 1024 * 1024);
|
||||
|
||||
ib_int64_t start_offset
|
||||
= file_start_page_no * page_size;
|
||||
ib_int64_t end_offset
|
||||
= (size_after_extend - file_start_page_no) * page_size;
|
||||
|
||||
mutex_exit(&fil_system->mutex);
|
||||
success = os_file_set_size(node->name, node->handle,
|
||||
offset_low, offset_high);
|
||||
success = (posix_fallocate(node->handle, start_offset,
|
||||
end_offset) == 0);
|
||||
if (!success)
|
||||
{
|
||||
fprintf(stderr,
|
||||
"InnoDB: Error: preallocating file space for "
|
||||
"file \'%s\' failed. Current size %lld, "
|
||||
"len %lld, desired size %lld\n", node->name,
|
||||
start_offset, end_offset,
|
||||
start_offset + end_offset);
|
||||
}
|
||||
mutex_enter(&fil_system->mutex);
|
||||
if (success) {
|
||||
node->size += (size_after_extend - start_page_no);
|
||||
|
@ -1,6 +1,6 @@
|
||||
/*****************************************************************************
|
||||
|
||||
Copyright (c) 2000, 2013, Oracle and/or its affiliates. All Rights Reserved.
|
||||
Copyright (c) 2000, 2014, Oracle and/or its affiliates. All Rights Reserved.
|
||||
Copyright (c) 2008, 2009 Google Inc.
|
||||
Copyright (c) 2009, Percona Inc.
|
||||
|
||||
@ -2936,7 +2936,8 @@ skip_relay:
|
||||
internal_innobase_data_file_path);
|
||||
if (ret == FALSE) {
|
||||
sql_print_error(
|
||||
"InnoDB: syntax error in innodb_data_file_path");
|
||||
"InnoDB: syntax error in innodb_data_file_path"
|
||||
" or size specified is less than 1 megabyte");
|
||||
mem_free_and_error:
|
||||
srv_free_paths_and_sizes();
|
||||
my_free(internal_innobase_data_file_path);
|
||||
@ -11329,6 +11330,21 @@ ha_innobase::get_auto_increment(
|
||||
|
||||
current = *first_value > col_max_value ? autoinc : *first_value;
|
||||
|
||||
/* If the increment step of the auto increment column
|
||||
decreases then it is not affecting the immediate
|
||||
next value in the series. */
|
||||
if (prebuilt->autoinc_increment > increment) {
|
||||
|
||||
current = autoinc - prebuilt->autoinc_increment;
|
||||
|
||||
current = innobase_next_autoinc(
|
||||
current, 1, increment, 1, col_max_value);
|
||||
|
||||
dict_table_autoinc_initialize(prebuilt->table, current);
|
||||
|
||||
*first_value = current;
|
||||
}
|
||||
|
||||
/* Compute the last value in the interval */
|
||||
next_value = innobase_next_autoinc(
|
||||
current, *nb_reserved_values, increment, offset,
|
||||
@ -13070,7 +13086,7 @@ static MYSQL_SYSVAR_ULONG(thread_concurrency, srv_thread_concurrency,
|
||||
static MYSQL_SYSVAR_ULONG(thread_sleep_delay, srv_thread_sleep_delay,
|
||||
PLUGIN_VAR_RQCMDARG,
|
||||
"Time of innodb thread sleeping before joining InnoDB queue (usec). Value 0 disable a sleep",
|
||||
NULL, NULL, 10000L, 0L, ~0UL, 0);
|
||||
NULL, NULL, 10000L, 0L, 1000000L, 0);
|
||||
|
||||
static MYSQL_SYSVAR_STR(data_file_path, innobase_data_file_path,
|
||||
PLUGIN_VAR_RQCMDARG | PLUGIN_VAR_READONLY,
|
||||
|
@ -1,6 +1,7 @@
|
||||
/*****************************************************************************
|
||||
|
||||
Copyright (c) 2000, 2010, MySQL AB & Innobase Oy. All Rights Reserved.
|
||||
Use is subject to license terms
|
||||
|
||||
This program is free software; you can redistribute it and/or modify it under
|
||||
the terms of the GNU General Public License as published by the Free Software
|
||||
|
@ -110,16 +110,16 @@ innobase_col_to_mysql(
|
||||
/* These column types should never be shipped to MySQL. */
|
||||
ut_ad(0);
|
||||
|
||||
case DATA_FIXBINARY:
|
||||
case DATA_FLOAT:
|
||||
case DATA_DOUBLE:
|
||||
case DATA_DECIMAL:
|
||||
/* Above are the valid column types for MySQL data. */
|
||||
ut_ad(flen == len);
|
||||
/* fall through */
|
||||
case DATA_FIXBINARY:
|
||||
case DATA_CHAR:
|
||||
/* We may have flen > len when there is a shorter
|
||||
prefix on a CHAR column. */
|
||||
prefix on the CHAR and BINARY column. */
|
||||
ut_ad(flen >= len);
|
||||
#else /* UNIV_DEBUG */
|
||||
default:
|
||||
|
@ -64,7 +64,7 @@ component, i.e. we show M.N.P as M.N */
|
||||
(INNODB_VERSION_MAJOR << 8 | INNODB_VERSION_MINOR)
|
||||
|
||||
#ifndef PERCONA_INNODB_VERSION
|
||||
#define PERCONA_INNODB_VERSION 34.0
|
||||
#define PERCONA_INNODB_VERSION 35.0
|
||||
#endif
|
||||
|
||||
#define INNODB_VERSION_STR MYSQL_SERVER_VERSION "-" IB_TO_STR(PERCONA_INNODB_VERSION)
|
||||
|
@ -1,6 +1,6 @@
|
||||
/*****************************************************************************
|
||||
|
||||
Copyright (c) 1996, 2013, Oracle and/or its affiliates. All Rights Reserved.
|
||||
Copyright (c) 1996, 2014, Oracle and/or its affiliates. All Rights Reserved.
|
||||
|
||||
This program is free software; you can redistribute it and/or modify it under
|
||||
the terms of the GNU General Public License as published by the Free Software
|
||||
@ -2290,6 +2290,10 @@ row_ins_index_entry(
|
||||
{
|
||||
ulint err;
|
||||
|
||||
DBUG_EXECUTE_IF("row_ins_index_entry_timeout", {
|
||||
DBUG_SET("-d,row_ins_index_entry_timeout");
|
||||
return(DB_LOCK_WAIT);});
|
||||
|
||||
if (foreign && UT_LIST_GET_FIRST(index->table->foreign_list)) {
|
||||
err = row_ins_check_foreign_constraints(index->table, index,
|
||||
entry, thr);
|
||||
|
@ -1,6 +1,6 @@
|
||||
/*****************************************************************************
|
||||
|
||||
Copyright (c) 1996, 2013, Oracle and/or its affiliates. All Rights Reserved.
|
||||
Copyright (c) 1996, 2014, Oracle and/or its affiliates. All Rights Reserved.
|
||||
|
||||
This program is free software; you can redistribute it and/or modify it under
|
||||
the terms of the GNU General Public License as published by the Free Software
|
||||
@ -1789,9 +1789,7 @@ row_upd_clust_rec_by_insert_inherit_func(
|
||||
data += len - BTR_EXTERN_FIELD_REF_SIZE;
|
||||
/* The pointer must not be zero. */
|
||||
ut_a(memcmp(data, field_ref_zero, BTR_EXTERN_FIELD_REF_SIZE));
|
||||
/* The BLOB must be owned. */
|
||||
ut_a(!(data[BTR_EXTERN_LEN] & BTR_EXTERN_OWNER_FLAG));
|
||||
|
||||
data[BTR_EXTERN_LEN] &= ~BTR_EXTERN_OWNER_FLAG;
|
||||
data[BTR_EXTERN_LEN] |= BTR_EXTERN_INHERITED_FLAG;
|
||||
/* The BTR_EXTERN_INHERITED_FLAG only matters in
|
||||
rollback. Purge will always free the extern fields of
|
||||
@ -1896,7 +1894,13 @@ err_exit:
|
||||
rec, offsets, entry, node->update);
|
||||
|
||||
if (change_ownership) {
|
||||
btr_pcur_store_position(pcur, mtr);
|
||||
/* The blobs are disowned here, expecting the
|
||||
insert down below to inherit them. But if the
|
||||
insert fails, then this disown will be undone
|
||||
when the operation is rolled back. */
|
||||
btr_cur_disown_inherited_fields(
|
||||
btr_cur_get_page_zip(btr_cur),
|
||||
rec, index, offsets, node->update, mtr);
|
||||
}
|
||||
}
|
||||
|
||||
@ -1922,35 +1926,6 @@ err_exit:
|
||||
? UPD_NODE_INSERT_BLOB
|
||||
: UPD_NODE_INSERT_CLUSTERED;
|
||||
|
||||
if (err == DB_SUCCESS && change_ownership) {
|
||||
/* Mark the non-updated fields disowned by the old record. */
|
||||
|
||||
/* NOTE: this transaction has an x-lock on the record
|
||||
and therefore other transactions cannot modify the
|
||||
record when we have no latch on the page. In addition,
|
||||
we assume that other query threads of the same
|
||||
transaction do not modify the record in the meantime.
|
||||
Therefore we can assert that the restoration of the
|
||||
cursor succeeds. */
|
||||
|
||||
mtr_start(mtr);
|
||||
|
||||
if (!btr_pcur_restore_position(BTR_MODIFY_LEAF, pcur, mtr)) {
|
||||
ut_error;
|
||||
}
|
||||
|
||||
rec = btr_cur_get_rec(btr_cur);
|
||||
offsets = rec_get_offsets(rec, index, offsets,
|
||||
ULINT_UNDEFINED, &heap);
|
||||
ut_ad(page_rec_is_user_rec(rec));
|
||||
|
||||
btr_cur_disown_inherited_fields(
|
||||
btr_cur_get_page_zip(btr_cur),
|
||||
rec, index, offsets, node->update, mtr);
|
||||
|
||||
mtr_commit(mtr);
|
||||
}
|
||||
|
||||
mem_heap_free(heap);
|
||||
|
||||
return(err);
|
||||
|
@ -150,7 +150,7 @@ UNIV_INTERN mysql_pfs_key_t srv_log_tracking_thread_key;
|
||||
#endif /* UNIV_PFS_THREAD */
|
||||
|
||||
/*********************************************************************//**
|
||||
Convert a numeric string that optionally ends in G or M, to a number
|
||||
Convert a numeric string that optionally ends in G or M or K, to a number
|
||||
containing megabytes.
|
||||
@return next character in string */
|
||||
static
|
||||
@ -174,6 +174,10 @@ srv_parse_megabytes(
|
||||
case 'M': case 'm':
|
||||
str++;
|
||||
break;
|
||||
case 'K': case 'k':
|
||||
size /= 1024;
|
||||
str++;
|
||||
break;
|
||||
default:
|
||||
size /= 1024 * 1024;
|
||||
break;
|
||||
|
Loading…
x
Reference in New Issue
Block a user