Commit eeefb8ba authored by brian@zim.tangent.org's avatar brian@zim.tangent.org

Merge baker@bk-internal.mysql.com:/home/bk/mysql-5.1-new

into  zim.tangent.org:/home/brian/raid/mysql-5.1-new
parents cbe5fb2e 9485856f
......@@ -1381,10 +1381,6 @@ void ha_myisam::info(uint flag)
if (share->tmp_table == NO_TMP_TABLE)
pthread_mutex_unlock(&share->mutex);
raid_type= info.raid_type;
raid_chunks= info.raid_chunks;
raid_chunksize= info.raid_chunksize;
/*
Set data_file_name and index_file_name to point at the symlink value
if table is symlinked (Ie; Real name is not same as generated name)
......@@ -1461,12 +1457,6 @@ void ha_myisam::update_create_info(HA_CREATE_INFO *create_info)
{
create_info->auto_increment_value=auto_increment_value;
}
if (!(create_info->used_fields & HA_CREATE_USED_RAID))
{
create_info->raid_type= raid_type;
create_info->raid_chunks= raid_chunks;
create_info->raid_chunksize= raid_chunksize;
}
create_info->data_file_name=data_file_name;
create_info->index_file_name=index_file_name;
}
......@@ -1658,11 +1648,6 @@ int ha_myisam::create(const char *name, register TABLE *table_arg,
(ulonglong) 0);
create_info.data_file_length= ((ulonglong) share->max_rows *
share->avg_row_length);
create_info.raid_type=info->raid_type;
create_info.raid_chunks= (info->raid_chunks ? info->raid_chunks :
RAID_DEFAULT_CHUNKS);
create_info.raid_chunksize= (info->raid_chunksize ? info->raid_chunksize :
RAID_DEFAULT_CHUNKSIZE);
create_info.data_file_name= info->data_file_name;
create_info.index_file_name= info->index_file_name;
......@@ -1787,9 +1772,6 @@ bool ha_myisam::check_if_incompatible_data(HA_CREATE_INFO *info,
uint options= table->s->db_options_in_use;
if (info->auto_increment_value != auto_increment_value ||
info->raid_type != raid_type ||
info->raid_chunks != raid_chunks ||
info->raid_chunksize != raid_chunksize ||
info->data_file_name != data_file_name ||
info->index_file_name != index_file_name ||
table_changes == IS_EQUAL_NO)
......
......@@ -4284,9 +4284,6 @@ void ha_partition::info(uint flag)
sortkey: Never used at any place so ignored
ref_length: We set this to the value calculated
and stored in local object
raid_type: Set by first handler (MyISAM)
raid_chunks: Set by first handler (MyISAM)
raid_chunksize: Set by first handler (MyISAM)
create_time: Creation time of table
Set by first handler
......@@ -4297,9 +4294,6 @@ void ha_partition::info(uint flag)
file= m_file[0];
file->info(HA_STATUS_CONST);
create_time= file->create_time;
raid_type= file->raid_type;
raid_chunks= file->raid_chunks;
raid_chunksize= file->raid_chunksize;
ref_length= m_ref_length;
}
if (flag & HA_STATUS_ERRKEY)
......
......@@ -266,7 +266,7 @@ enum enum_binlog_command {
/* Bits in used_fields */
#define HA_CREATE_USED_AUTO (1L << 0)
#define HA_CREATE_USED_RAID (1L << 1)
#define HA_CREATE_USED_RAID (1L << 1) //RAID is no longer availble
#define HA_CREATE_USED_UNION (1L << 2)
#define HA_CREATE_USED_INSERT_METHOD (1L << 3)
#define HA_CREATE_USED_MIN_ROWS (1L << 4)
......@@ -1068,14 +1068,12 @@ typedef struct st_ha_create_information
ulonglong auto_increment_value;
ulong table_options;
ulong avg_row_length;
ulong raid_chunksize;
ulong used_fields;
SQL_LIST merge_list;
handlerton *db_type;
enum row_type row_type;
uint null_bits; /* NULL bits at start of record */
uint options; /* OR of HA_CREATE_ options */
uint raid_type,raid_chunks;
uint merge_insert_method;
uint extra_size; /* length of extra data segment */
bool table_existed; /* 1 in create if table existed */
......@@ -1204,7 +1202,6 @@ class handler :public Sql_alloc
ulonglong auto_increment_value;
ha_rows records; /* Records in table */
ha_rows deleted; /* Deleted records */
ulong raid_chunksize;
ulong mean_rec_length; /* physical reclength */
time_t create_time; /* When table was created */
time_t check_time;
......@@ -1228,7 +1225,6 @@ class handler :public Sql_alloc
/* Length of ref (1-8 or the clustered key length) */
uint ref_length;
uint block_size; /* index block size */
uint raid_type,raid_chunks;
FT_INFO *ft_handler;
enum {NONE=0, INDEX, RND} inited;
bool auto_increment_column_changed;
......@@ -1245,7 +1241,7 @@ class handler :public Sql_alloc
create_time(0), check_time(0), update_time(0),
key_used_on_scan(MAX_KEY), active_index(MAX_KEY),
ref_length(sizeof(my_off_t)), block_size(0),
raid_type(0), ft_handler(0), inited(NONE), implicit_emptied(0),
ft_handler(0), inited(NONE), implicit_emptied(0),
pushed_cond(NULL)
{}
virtual ~handler(void)
......
......@@ -410,10 +410,6 @@ static SYMBOL symbols[] = {
{ "QUARTER", SYM(QUARTER_SYM)},
{ "QUERY", SYM(QUERY_SYM)},
{ "QUICK", SYM(QUICK)},
{ "RAID0", SYM(RAID_0_SYM)},
{ "RAID_CHUNKS", SYM(RAID_CHUNKS)},
{ "RAID_CHUNKSIZE", SYM(RAID_CHUNKSIZE)},
{ "RAID_TYPE", SYM(RAID_TYPE)},
{ "RANGE", SYM(RANGE_SYM)},
{ "READ", SYM(READ_SYM)},
{ "READ_ONLY", SYM(READ_ONLY_SYM)},
......@@ -512,7 +508,6 @@ static SYMBOL symbols[] = {
{ "STORAGE", SYM(STORAGE_SYM)},
{ "STRAIGHT_JOIN", SYM(STRAIGHT_JOIN)},
{ "STRING", SYM(STRING_SYM)},
{ "STRIPED", SYM(RAID_STRIPED_SYM)},
{ "SUBJECT", SYM(SUBJECT_SYM)},
{ "SUBPARTITION", SYM(SUBPARTITION_SYM)},
{ "SUBPARTITIONS", SYM(SUBPARTITIONS_SYM)},
......
......@@ -576,7 +576,7 @@ CHARSET_INFO *national_charset_info, *table_alias_charset;
CHARSET_INFO *character_set_filesystem;
SHOW_COMP_OPTION have_row_based_replication;
SHOW_COMP_OPTION have_raid, have_openssl, have_symlink, have_query_cache;
SHOW_COMP_OPTION have_openssl, have_symlink, have_query_cache;
SHOW_COMP_OPTION have_geometry, have_rtree_keys;
SHOW_COMP_OPTION have_crypt, have_compress;
......@@ -1193,9 +1193,6 @@ void clean_up(bool print_message)
multi_keycache_free();
free_status_vars();
end_thr_alarm(1); /* Free allocated memory */
#ifdef USE_RAID
end_raid();
#endif
my_free_open_file_info();
my_free((char*) global_system_variables.date_format,
MYF(MY_ALLOW_ZERO_PTR));
......@@ -7094,11 +7091,6 @@ static void mysql_init_variables(void)
#else
have_ndbcluster=SHOW_OPTION_NO;
#endif
#ifdef USE_RAID
have_raid=SHOW_OPTION_YES;
#else
have_raid=SHOW_OPTION_NO;
#endif
#ifdef HAVE_OPENSSL
have_openssl=SHOW_OPTION_YES;
#else
......
......@@ -636,7 +636,6 @@ sys_var_have_variable sys_have_partition_db("have_partitioning",
&have_partition_db);
sys_var_have_variable sys_have_query_cache("have_query_cache",
&have_query_cache);
sys_var_have_variable sys_have_raid("have_raid", &have_raid);
sys_var_have_variable sys_have_rtree_keys("have_rtree_keys", &have_rtree_keys);
sys_var_have_variable sys_have_symlink("have_symlink", &have_symlink);
sys_var_have_variable sys_have_row_based_replication("have_row_based_replication",&have_row_based_replication);
......@@ -755,7 +754,6 @@ SHOW_VAR init_vars[]= {
{sys_have_openssl.name, (char*) &have_openssl, SHOW_HAVE},
{sys_have_partition_db.name,(char*) &have_partition_db, SHOW_HAVE},
{sys_have_query_cache.name, (char*) &have_query_cache, SHOW_HAVE},
{sys_have_raid.name, (char*) &have_raid, SHOW_HAVE},
{sys_have_row_based_replication.name, (char*) &have_row_based_replication, SHOW_HAVE},
{sys_have_rtree_keys.name, (char*) &have_rtree_keys, SHOW_HAVE},
{sys_have_symlink.name, (char*) &have_symlink, SHOW_HAVE},
......
......@@ -1234,15 +1234,6 @@ store_create_info(THD *thd, TABLE_LIST *table_list, String *packet,
packet->append(STRING_WITH_LEN(" CONNECTION="));
append_unescaped(packet, share->connect_string.str, share->connect_string.length);
}
if (file->raid_type)
{
uint length;
length= my_snprintf(buff,sizeof(buff),
" RAID_TYPE=%s RAID_CHUNKS=%d RAID_CHUNKSIZE=%ld",
my_raid_type(file->raid_type), file->raid_chunks,
file->raid_chunksize/RAID_BLOCK_SIZE);
packet->append(buff, length);
}
append_directory(thd, packet, "DATA", create_info.data_file_name);
append_directory(thd, packet, "INDEX", create_info.index_file_name);
}
......@@ -2591,15 +2582,6 @@ static int get_schema_tables_record(THD *thd, struct st_table_list *tables,
ptr=strxmov(ptr, " row_format=",
ha_row_type[(uint) share->row_type],
NullS);
if (file->raid_type)
{
char buff[100];
my_snprintf(buff,sizeof(buff),
" raid_type=%s raid_chunks=%d raid_chunksize=%ld",
my_raid_type(file->raid_type), file->raid_chunks,
file->raid_chunksize/RAID_BLOCK_SIZE);
ptr=strmov(ptr,buff);
}
table->field[19]->store(option_buff+1,
(ptr == option_buff ? 0 :
(uint) (ptr-option_buff)-1), cs);
......
......@@ -516,11 +516,6 @@ bool my_yyoverflow(short **a, YYSTYPE **b, ulong *yystacksize);
%token QUARTER_SYM
%token QUERY_SYM
%token QUICK
%token RAID_0_SYM
%token RAID_CHUNKS
%token RAID_CHUNKSIZE
%token RAID_STRIPED_SYM
%token RAID_TYPE
%token RAND
%token RANGE_SYM
%token READS_SYM
......@@ -753,7 +748,7 @@ bool my_yyoverflow(short **a, YYSTYPE **b, ulong *yystacksize);
union_opt select_derived_init option_type2
%type <ulong_num>
ulong_num raid_types merge_insert_types
ulong_num merge_insert_types
%type <ulonglong_number>
ulonglong_num size_number
......@@ -4027,21 +4022,6 @@ create_table_option:
| CHECKSUM_SYM opt_equal ulong_num { Lex->create_info.table_options|= $3 ? HA_OPTION_CHECKSUM : HA_OPTION_NO_CHECKSUM; Lex->create_info.used_fields|= HA_CREATE_USED_CHECKSUM; }
| DELAY_KEY_WRITE_SYM opt_equal ulong_num { Lex->create_info.table_options|= $3 ? HA_OPTION_DELAY_KEY_WRITE : HA_OPTION_NO_DELAY_KEY_WRITE; Lex->create_info.used_fields|= HA_CREATE_USED_DELAY_KEY_WRITE; }
| ROW_FORMAT_SYM opt_equal row_types { Lex->create_info.row_type= $3; Lex->create_info.used_fields|= HA_CREATE_USED_ROW_FORMAT; }
| RAID_TYPE opt_equal raid_types
{
my_error(ER_WARN_DEPRECATED_SYNTAX, MYF(0), "RAID_TYPE", "PARTITION");
YYABORT;
}
| RAID_CHUNKS opt_equal ulong_num
{
my_error(ER_WARN_DEPRECATED_SYNTAX, MYF(0), "RAID_CHUNKS", "PARTITION");
YYABORT;
}
| RAID_CHUNKSIZE opt_equal ulong_num
{
my_error(ER_WARN_DEPRECATED_SYNTAX, MYF(0), "RAID_CHUNKSIZE", "PARTITION");
YYABORT;
}
| UNION_SYM opt_equal '(' table_list ')'
{
/* Move the union list to the merge_list */
......@@ -4121,11 +4101,6 @@ row_types:
| REDUNDANT_SYM { $$= ROW_TYPE_REDUNDANT; }
| COMPACT_SYM { $$= ROW_TYPE_COMPACT; };
raid_types:
RAID_STRIPED_SYM { $$= RAID_TYPE_0; }
| RAID_0_SYM { $$= RAID_TYPE_0; }
| ulong_num { $$=$1;};
merge_insert_types:
NO_SYM { $$= MERGE_INSERT_DISABLED; }
| FIRST_SYM { $$= MERGE_INSERT_TO_FIRST; }
......@@ -9496,11 +9471,6 @@ keyword_sp:
| QUARTER_SYM {}
| QUERY_SYM {}
| QUICK {}
| RAID_0_SYM {}
| RAID_CHUNKS {}
| RAID_CHUNKSIZE {}
| RAID_STRIPED_SYM {}
| RAID_TYPE {}
| REBUILD_SYM {}
| RECOVER_SYM {}
| REDO_BUFFER_SIZE_SYM {}
......
......@@ -438,9 +438,6 @@ static int open_binary_frm(THD *thd, TABLE_SHARE *share, uchar *head,
{
share->avg_row_length= uint4korr(head+34);
share-> row_type= (row_type) head[40];
share->raid_type= head[41];
share->raid_chunks= head[42];
share->raid_chunksize= uint4korr(head+43);
share->table_charset= get_charset((uint) head[38],MYF(0));
share->null_field_first= 1;
}
......@@ -2021,12 +2018,6 @@ File create_frm(THD *thd, const char *name, const char *db,
if (create_info->min_rows > UINT_MAX32)
create_info->min_rows= UINT_MAX32;
/*
Ensure that raid_chunks can't be larger than 255, as this would cause
problems with drop database
*/
set_if_smaller(create_info->raid_chunks, 255);
if ((file= my_create(name, CREATE_MODE, create_flags, MYF(0))) >= 0)
{
uint key_length, tmp_key_length;
......@@ -2059,9 +2050,13 @@ File create_frm(THD *thd, const char *name, const char *db,
fileinfo[38]= (create_info->default_table_charset ?
create_info->default_table_charset->number : 0);
fileinfo[40]= (uchar) create_info->row_type;
fileinfo[41]= (uchar) create_info->raid_type;
fileinfo[42]= (uchar) create_info->raid_chunks;
int4store(fileinfo+43,create_info->raid_chunksize);
/* Next few bytes were for RAID support */
fileinfo[41]= 0;
fileinfo[42]= 0;
fileinfo[43]= 0;
fileinfo[44]= 0;
fileinfo[45]= 0;
fileinfo[46]= 0;
int4store(fileinfo+47, key_length);
tmp= MYSQL_VERSION_ID; // Store to avoid warning from int4store
int4store(fileinfo+51, tmp);
......@@ -2098,9 +2093,6 @@ void update_create_info_from_table(HA_CREATE_INFO *create_info, TABLE *table)
create_info->table_options= share->db_create_options;
create_info->avg_row_length= share->avg_row_length;
create_info->row_type= share->row_type;
create_info->raid_type= share->raid_type;
create_info->raid_chunks= share->raid_chunks;
create_info->raid_chunksize= share->raid_chunksize;
create_info->default_table_charset= share->table_charset;
create_info->table_charset= 0;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment