mirror of
https://github.com/MariaDB/server.git
synced 2025-07-29 05:21:33 +03:00
Added nety_retry_count as a changeable variable
Make safe_mysqld a symlink to mysqld_safe in binary distribution Fixed problem with CTRL-C when using mysqld --bootstrap Docs/manual.texi: Added nety_retry_count as a changeable variables include/mysql_com.h: Added nety_retry_count as a changeable variables libmysql/libmysql.c: Added nety_retry_count as a changeable variables mysql-test/r/olap.result: Fixed wrong error message mysql-test/r/variables.result: Update for freebsd mysql-test/t/variables.test: Update for freebsd scripts/make_binary_distribution.sh: Make safe_mysqld a symlink to mysqld_safe in binary distribution. sql/item_func.cc: Cleaned up tmp_table_field() handling. sql/item_func.h: Cleaned up tmp_table_field() handling. sql/item_strfunc.h: Cleaned up tmp_table_field() handling. sql/item_timefunc.h: Cleaned up tmp_table_field() handling. sql/mysql_priv.h: Added nety_retry_count as a changeable variables sql/mysqld.cc: Added nety_retry_count as a changeable variables Allow one to specify a defaults file to be read when installing MySQL as a service. sql/net_pkg.cc: Added nety_retry_count as a changeable variables sql/net_serv.cc: Added nety_retry_count as a changeable variables sql/set_var.cc: Added nety_retry_count as a changeable variables sql/share/czech/errmsg.txt: Fixed wrong error message sql/share/danish/errmsg.txt: Fixed wrong error message sql/share/english/errmsg.txt: Fixed wrong error message sql/share/estonian/errmsg.txt: Fixed wrong error message sql/share/french/errmsg.txt: Fixed wrong error message sql/share/german/errmsg.txt: Fixed wrong error message sql/share/greek/errmsg.txt: Fixed wrong error message sql/share/hungarian/errmsg.txt: Fixed wrong error message sql/share/italian/errmsg.txt: Fixed wrong error message sql/share/japanese/errmsg.txt: Fixed wrong error message sql/share/korean/errmsg.txt: Fixed wrong error message sql/share/norwegian-ny/errmsg.txt: Fixed wrong error message sql/share/norwegian/errmsg.txt: Fixed wrong error message sql/share/polish/errmsg.txt: Fixed wrong error message sql/share/portuguese/errmsg.txt: Fixed wrong error message sql/share/romanian/errmsg.txt: Fixed wrong error message sql/share/russian/errmsg.txt: Fixed wrong error message sql/share/slovak/errmsg.txt: Fixed wrong error message sql/share/spanish/errmsg.txt: Fixed wrong error message sql/share/swedish/errmsg.txt: Fixed wrong error message sql/share/ukrainian/errmsg.txt: Fixed wrong error message sql/sql_class.cc: Indentaion cleanup sql/sql_class.h: Fixed wrong error message sql/sql_parse.cc: Fixed problem with CTRL-C when using mysqld --bootstrap sql/sql_select.cc: Ensure that select terminates if create_myisam_from_heap() fails. sql/sql_yacc.yy: Portability fix
This commit is contained in:
@ -8220,7 +8220,9 @@ In 3.23, @code{INSERT INTO ... SELECT} always had @code{IGNORE} enabled.
|
|||||||
In 4.0.1, MySQL will stop (and possibly roll back) in case of an error if you
|
In 4.0.1, MySQL will stop (and possibly roll back) in case of an error if you
|
||||||
don't specify @code{IGNORE}.
|
don't specify @code{IGNORE}.
|
||||||
@item
|
@item
|
||||||
@file{safe_mysqld} is renamed to @file{mysqld_safe}.
|
@file{safe_mysqld} is renamed to @file{mysqld_safe}. For some time we
|
||||||
|
will in our binary distributions include @code{safe_mysqld} as a symlink to
|
||||||
|
@code{mysqld_safe}.
|
||||||
@item
|
@item
|
||||||
The old C API functions @code{mysql_drop_db}, @code{mysql_create_db}, and
|
The old C API functions @code{mysql_drop_db}, @code{mysql_create_db}, and
|
||||||
@code{mysql_connect} are not supported anymore, unless you compile
|
@code{mysql_connect} are not supported anymore, unless you compile
|
||||||
@ -28663,6 +28665,7 @@ and if you can use @code{GLOBAL} or @code{SESSION} with them.
|
|||||||
@item myisam_sort_buffer_size @tab num @tab GLOBAL | SESSION
|
@item myisam_sort_buffer_size @tab num @tab GLOBAL | SESSION
|
||||||
@item net_buffer_length @tab num @tab GLOBAL | SESSION
|
@item net_buffer_length @tab num @tab GLOBAL | SESSION
|
||||||
@item net_read_timeout @tab num @tab GLOBAL | SESSION
|
@item net_read_timeout @tab num @tab GLOBAL | SESSION
|
||||||
|
@item net_retry_count @tab num @tab GLOBAL | SESSION
|
||||||
@item net_write_timeout @tab num @tab GLOBAL | SESSION
|
@item net_write_timeout @tab num @tab GLOBAL | SESSION
|
||||||
@item query_cache_limit @tab num @tab GLOBAL
|
@item query_cache_limit @tab num @tab GLOBAL
|
||||||
@item query_cache_size @tab num @tab GLOBAL
|
@item query_cache_size @tab num @tab GLOBAL
|
||||||
@ -50222,6 +50225,8 @@ each individual 4.0.x release.
|
|||||||
|
|
||||||
@itemize @bullet
|
@itemize @bullet
|
||||||
@item
|
@item
|
||||||
|
Made @code{safe_mysqld} a symlink to @code{mysqld_safe} in binary distribution.
|
||||||
|
@item
|
||||||
mysqld now has the option @code{--temp-pool} enabled by default as this
|
mysqld now has the option @code{--temp-pool} enabled by default as this
|
||||||
gives better performance with some OS.
|
gives better performance with some OS.
|
||||||
@item
|
@item
|
||||||
|
@ -116,7 +116,7 @@ typedef struct st_net {
|
|||||||
my_socket fd; /* For Perl DBI/dbd */
|
my_socket fd; /* For Perl DBI/dbd */
|
||||||
unsigned long max_packet,max_packet_size;
|
unsigned long max_packet,max_packet_size;
|
||||||
unsigned int last_errno,pkt_nr,compress_pkt_nr;
|
unsigned int last_errno,pkt_nr,compress_pkt_nr;
|
||||||
unsigned int write_timeout,read_timeout;
|
unsigned int write_timeout, read_timeout, retry_count;
|
||||||
int fcntl;
|
int fcntl;
|
||||||
char last_error[MYSQL_ERRMSG_SIZE];
|
char last_error[MYSQL_ERRMSG_SIZE];
|
||||||
unsigned char error;
|
unsigned char error;
|
||||||
|
@ -2902,6 +2902,7 @@ void my_net_local_init(NET *net)
|
|||||||
net->max_packet= (uint) net_buffer_length;
|
net->max_packet= (uint) net_buffer_length;
|
||||||
net->read_timeout= (uint) net_read_timeout;
|
net->read_timeout= (uint) net_read_timeout;
|
||||||
net->write_timeout=(uint) net_write_timeout;
|
net->write_timeout=(uint) net_write_timeout;
|
||||||
|
net->retry_count= 1;
|
||||||
net->max_packet_size= max(net_buffer_length, max_allowed_packet);
|
net->max_packet_size= max(net_buffer_length, max_allowed_packet);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -15,13 +15,13 @@ insert into sales values ( 'Computer', 'India',2000, 1200),
|
|||||||
( 'Computer', 'United States', 2000,1500),
|
( 'Computer', 'United States', 2000,1500),
|
||||||
( 'Calculator', 'United States', 2000,75);
|
( 'Calculator', 'United States', 2000,75);
|
||||||
select product, country , year, sum(profit) from sales group by product, country, year with cube;
|
select product, country , year, sum(profit) from sales group by product, country, year with cube;
|
||||||
This version of MySQL doesn't yet support 'CUBE',
|
This version of MySQL doesn't yet support 'CUBE'
|
||||||
explain select product, country , year, sum(profit) from sales group by product, country, year with cube;
|
explain select product, country , year, sum(profit) from sales group by product, country, year with cube;
|
||||||
This version of MySQL doesn't yet support 'CUBE',
|
This version of MySQL doesn't yet support 'CUBE'
|
||||||
select product, country , year, sum(profit) from sales group by product, country, year with rollup;
|
select product, country , year, sum(profit) from sales group by product, country, year with rollup;
|
||||||
This version of MySQL doesn't yet support 'ROLLUP',
|
This version of MySQL doesn't yet support 'ROLLUP'
|
||||||
explain select product, country , year, sum(profit) from sales group by product, country, year with rollup;
|
explain select product, country , year, sum(profit) from sales group by product, country, year with rollup;
|
||||||
This version of MySQL doesn't yet support 'ROLLUP',
|
This version of MySQL doesn't yet support 'ROLLUP'
|
||||||
select product, country , year, sum(profit) from sales group by product, country, year with cube union all select product, country , year, sum(profit) from sales group by product, country, year with rollup;
|
select product, country , year, sum(profit) from sales group by product, country, year with cube union all select product, country , year, sum(profit) from sales group by product, country, year with rollup;
|
||||||
This version of MySQL doesn't yet support 'CUBE',
|
This version of MySQL doesn't yet support 'CUBE'
|
||||||
drop table sales;
|
drop table sales;
|
||||||
|
@ -120,6 +120,7 @@ set myisam_max_sort_file_size=default;
|
|||||||
show variables like 'myisam_max_sort_file_size';
|
show variables like 'myisam_max_sort_file_size';
|
||||||
Variable_name Value
|
Variable_name Value
|
||||||
myisam_max_sort_file_size 20000
|
myisam_max_sort_file_size 20000
|
||||||
|
set global net_retry_count=10, session net_retry_count=10;
|
||||||
set global net_buffer_length=1024, net_write_timeout=200, net_read_timeout=300;
|
set global net_buffer_length=1024, net_write_timeout=200, net_read_timeout=300;
|
||||||
set session net_buffer_length=2048, net_write_timeout=500, net_read_timeout=600;
|
set session net_buffer_length=2048, net_write_timeout=500, net_read_timeout=600;
|
||||||
show global variables like 'net_%';
|
show global variables like 'net_%';
|
||||||
|
@ -73,6 +73,7 @@ show global variables like 'myisam_max_sort_file_size';
|
|||||||
set myisam_max_sort_file_size=default;
|
set myisam_max_sort_file_size=default;
|
||||||
show variables like 'myisam_max_sort_file_size';
|
show variables like 'myisam_max_sort_file_size';
|
||||||
|
|
||||||
|
set global net_retry_count=10, session net_retry_count=10;
|
||||||
set global net_buffer_length=1024, net_write_timeout=200, net_read_timeout=300;
|
set global net_buffer_length=1024, net_write_timeout=200, net_read_timeout=300;
|
||||||
set session net_buffer_length=2048, net_write_timeout=500, net_read_timeout=600;
|
set session net_buffer_length=2048, net_write_timeout=500, net_read_timeout=600;
|
||||||
show global variables like 'net_%';
|
show global variables like 'net_%';
|
||||||
|
@ -123,6 +123,10 @@ $BASE/bin/replace \@localstatedir\@ ./data \@bindir\@ ./bin \@scriptdir\@ ./bin
|
|||||||
$BASE/bin/replace \@prefix\@ /usr/local/mysql \@bindir\@ ./bin \@MYSQLD_USER\@ root \@localstatedir\@ /usr/local/mysql/data < $SOURCE/support-files/mysql.server.sh > $BASE/support-files/mysql.server
|
$BASE/bin/replace \@prefix\@ /usr/local/mysql \@bindir\@ ./bin \@MYSQLD_USER\@ root \@localstatedir\@ /usr/local/mysql/data < $SOURCE/support-files/mysql.server.sh > $BASE/support-files/mysql.server
|
||||||
$BASE/bin/replace /my/gnu/bin/hostname /bin/hostname -- $BASE/bin/mysqld_safe
|
$BASE/bin/replace /my/gnu/bin/hostname /bin/hostname -- $BASE/bin/mysqld_safe
|
||||||
|
|
||||||
|
# Make safe_mysqld a symlink to mysqld_safe for backwards portability
|
||||||
|
# To be removed in MySQL 4.1
|
||||||
|
(cd $BASE/bin ; ln -s mysqld_safe safe_mysqld )
|
||||||
|
|
||||||
mv $BASE/support-files/binary-configure $BASE/configure
|
mv $BASE/support-files/binary-configure $BASE/configure
|
||||||
chmod a+x $BASE/bin/* $BASE/scripts/* $BASE/support-files/mysql-* $BASE/configure
|
chmod a+x $BASE/bin/* $BASE/scripts/* $BASE/support-files/mysql-* $BASE/configure
|
||||||
$CP -r sql-bench/* $BASE/sql-bench
|
$CP -r sql-bench/* $BASE/sql-bench
|
||||||
|
@ -166,6 +166,36 @@ bool Item_func::eq(const Item *item, bool binary_cmp) const
|
|||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
Field *Item_func::tmp_table_field(TABLE *t_arg)
|
||||||
|
{
|
||||||
|
Field *res;
|
||||||
|
LINT_INIT(res);
|
||||||
|
|
||||||
|
if (!t_arg)
|
||||||
|
return result_field;
|
||||||
|
switch (args[0]->result_type()) {
|
||||||
|
case INT_RESULT:
|
||||||
|
if (max_length > 11)
|
||||||
|
res= new Field_longlong(max_length, maybe_null, name, t_arg,
|
||||||
|
unsigned_flag);
|
||||||
|
else
|
||||||
|
res= new Field_long(max_length, maybe_null, name, t_arg,
|
||||||
|
unsigned_flag);
|
||||||
|
break;
|
||||||
|
case REAL_RESULT:
|
||||||
|
res= new Field_double(max_length, maybe_null, name, t_arg, decimals);
|
||||||
|
break;
|
||||||
|
case STRING_RESULT:
|
||||||
|
if (max_length > 255)
|
||||||
|
res= new Field_blob(max_length, maybe_null, name, t_arg, binary);
|
||||||
|
else
|
||||||
|
res= new Field_string(max_length, maybe_null, name, t_arg, binary);
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
return res;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
String *Item_real_func::val_str(String *str)
|
String *Item_real_func::val_str(String *str)
|
||||||
{
|
{
|
||||||
double nr=val();
|
double nr=val();
|
||||||
|
@ -122,6 +122,7 @@ public:
|
|||||||
bool is_null() { (void) val_int(); return null_value; }
|
bool is_null() { (void) val_int(); return null_value; }
|
||||||
friend class udf_handler;
|
friend class udf_handler;
|
||||||
unsigned int size_of() { return sizeof(*this);}
|
unsigned int size_of() { return sizeof(*this);}
|
||||||
|
Field *tmp_table_field(TABLE *t_arg);
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
||||||
@ -136,14 +137,10 @@ public:
|
|||||||
longlong val_int() { return (longlong) val(); }
|
longlong val_int() { return (longlong) val(); }
|
||||||
enum Item_result result_type () const { return REAL_RESULT; }
|
enum Item_result result_type () const { return REAL_RESULT; }
|
||||||
void fix_length_and_dec() { decimals=NOT_FIXED_DEC; max_length=float_length(decimals); }
|
void fix_length_and_dec() { decimals=NOT_FIXED_DEC; max_length=float_length(decimals); }
|
||||||
Field *tmp_table_field(TABLE *t_arg)
|
|
||||||
{
|
|
||||||
if (!t_arg) return result_field;
|
|
||||||
return new Field_double(max_length, maybe_null, name,t_arg,decimals);
|
|
||||||
}
|
|
||||||
unsigned int size_of() { return sizeof(*this);}
|
unsigned int size_of() { return sizeof(*this);}
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
||||||
class Item_num_func :public Item_func
|
class Item_num_func :public Item_func
|
||||||
{
|
{
|
||||||
protected:
|
protected:
|
||||||
@ -172,24 +169,6 @@ class Item_num_op :public Item_func
|
|||||||
void fix_length_and_dec() { fix_num_length_and_dec(); find_num_type(); }
|
void fix_length_and_dec() { fix_num_length_and_dec(); find_num_type(); }
|
||||||
void find_num_type(void);
|
void find_num_type(void);
|
||||||
bool is_null() { (void) val(); return null_value; }
|
bool is_null() { (void) val(); return null_value; }
|
||||||
Field *tmp_table_field(TABLE *t_arg)
|
|
||||||
{
|
|
||||||
Field *res;
|
|
||||||
if (!t_arg)
|
|
||||||
return result_field;
|
|
||||||
if (args[0]->result_type() == INT_RESULT)
|
|
||||||
{
|
|
||||||
if (max_length > 11)
|
|
||||||
res= new Field_longlong(max_length, maybe_null, name, t_arg,
|
|
||||||
unsigned_flag);
|
|
||||||
else
|
|
||||||
res= new Field_long(max_length, maybe_null, name, t_arg,
|
|
||||||
unsigned_flag);
|
|
||||||
}
|
|
||||||
else
|
|
||||||
res= new Field_double(max_length, maybe_null, name, t_arg, decimals);
|
|
||||||
return res;
|
|
||||||
}
|
|
||||||
unsigned int size_of() { return sizeof(*this);}
|
unsigned int size_of() { return sizeof(*this);}
|
||||||
};
|
};
|
||||||
|
|
||||||
@ -206,18 +185,9 @@ public:
|
|||||||
String *val_str(String*str);
|
String *val_str(String*str);
|
||||||
enum Item_result result_type () const { return INT_RESULT; }
|
enum Item_result result_type () const { return INT_RESULT; }
|
||||||
void fix_length_and_dec() {}
|
void fix_length_and_dec() {}
|
||||||
Field *tmp_table_field(TABLE *t_arg)
|
|
||||||
{
|
|
||||||
if (!t_arg)
|
|
||||||
return result_field;
|
|
||||||
return ((max_length > 11) ?
|
|
||||||
(Field *)new Field_longlong(max_length, maybe_null, name, t_arg,
|
|
||||||
unsigned_flag) :
|
|
||||||
(Field *)new Field_long(max_length, maybe_null, name, t_arg,
|
|
||||||
unsigned_flag));
|
|
||||||
}
|
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
||||||
class Item_func_signed :public Item_int_func
|
class Item_func_signed :public Item_int_func
|
||||||
{
|
{
|
||||||
public:
|
public:
|
||||||
@ -228,6 +198,7 @@ public:
|
|||||||
{ max_length=args[0]->max_length; unsigned_flag=0; }
|
{ max_length=args[0]->max_length; unsigned_flag=0; }
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
||||||
class Item_func_unsigned :public Item_int_func
|
class Item_func_unsigned :public Item_int_func
|
||||||
{
|
{
|
||||||
public:
|
public:
|
||||||
|
@ -35,16 +35,6 @@ public:
|
|||||||
double val();
|
double val();
|
||||||
enum Item_result result_type () const { return STRING_RESULT; }
|
enum Item_result result_type () const { return STRING_RESULT; }
|
||||||
void left_right_max_length();
|
void left_right_max_length();
|
||||||
Field *tmp_table_field(TABLE *t_arg)
|
|
||||||
{
|
|
||||||
if (!t_arg)
|
|
||||||
return result_field;
|
|
||||||
return ((max_length > 255) ?
|
|
||||||
(Field *) new Field_blob(max_length, maybe_null, name, t_arg,
|
|
||||||
binary) :
|
|
||||||
(Field *) new Field_string(max_length, maybe_null, name, t_arg,
|
|
||||||
binary));
|
|
||||||
}
|
|
||||||
unsigned int size_of() { return sizeof(*this);}
|
unsigned int size_of() { return sizeof(*this);}
|
||||||
};
|
};
|
||||||
|
|
||||||
@ -60,6 +50,7 @@ public:
|
|||||||
unsigned int size_of() { return sizeof(*this);}
|
unsigned int size_of() { return sizeof(*this);}
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
||||||
class Item_func_sha :public Item_str_func
|
class Item_func_sha :public Item_str_func
|
||||||
{
|
{
|
||||||
public:
|
public:
|
||||||
|
@ -71,13 +71,9 @@ public:
|
|||||||
const char *func_name() const { return "month"; }
|
const char *func_name() const { return "month"; }
|
||||||
enum Item_result result_type () const { return INT_RESULT; }
|
enum Item_result result_type () const { return INT_RESULT; }
|
||||||
void fix_length_and_dec() { decimals=0; max_length=2; maybe_null=1; }
|
void fix_length_and_dec() { decimals=0; max_length=2; maybe_null=1; }
|
||||||
Field *tmp_table_field(TABLE *t_arg)
|
|
||||||
{
|
|
||||||
if (!t_arg) return result_field;
|
|
||||||
return (Field *) new Field_string(max_length,maybe_null, name,t_arg, binary);
|
|
||||||
}
|
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
||||||
class Item_func_monthname :public Item_func_month
|
class Item_func_monthname :public Item_func_month
|
||||||
{
|
{
|
||||||
public:
|
public:
|
||||||
|
@ -622,7 +622,7 @@ extern ulong ha_read_count, ha_write_count, ha_delete_count, ha_update_count;
|
|||||||
extern ulong ha_read_key_count, ha_read_next_count, ha_read_prev_count;
|
extern ulong ha_read_key_count, ha_read_next_count, ha_read_prev_count;
|
||||||
extern ulong ha_read_first_count, ha_read_last_count;
|
extern ulong ha_read_first_count, ha_read_last_count;
|
||||||
extern ulong ha_read_rnd_count, ha_read_rnd_next_count;
|
extern ulong ha_read_rnd_count, ha_read_rnd_next_count;
|
||||||
extern ulong ha_commit_count, ha_rollback_count, mysqld_net_retry_count;
|
extern ulong ha_commit_count, ha_rollback_count;
|
||||||
extern ulong keybuff_size,table_cache_size;
|
extern ulong keybuff_size,table_cache_size;
|
||||||
extern ulong max_connections,max_connect_errors, connect_timeout;
|
extern ulong max_connections,max_connect_errors, connect_timeout;
|
||||||
extern ulong max_insert_delayed_threads, max_user_connections;
|
extern ulong max_insert_delayed_threads, max_user_connections;
|
||||||
|
127
sql/mysqld.cc
127
sql/mysqld.cc
@ -184,7 +184,9 @@ static uint handler_count;
|
|||||||
static bool opt_enable_named_pipe = 0;
|
static bool opt_enable_named_pipe = 0;
|
||||||
#endif
|
#endif
|
||||||
#ifdef __WIN__
|
#ifdef __WIN__
|
||||||
static bool opt_console=0,start_mode=0;
|
static bool opt_console=0, start_mode=0, use_opt_args;
|
||||||
|
static int opt_argc;
|
||||||
|
static char **opt_argv;
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
/* Set prefix for windows binary */
|
/* Set prefix for windows binary */
|
||||||
@ -316,7 +318,7 @@ struct system_variables max_system_variables;
|
|||||||
ulong keybuff_size,table_cache_size,
|
ulong keybuff_size,table_cache_size,
|
||||||
thread_stack,
|
thread_stack,
|
||||||
thread_stack_min,what_to_log= ~ (1L << (uint) COM_TIME),
|
thread_stack_min,what_to_log= ~ (1L << (uint) COM_TIME),
|
||||||
query_buff_size, mysqld_net_retry_count,
|
query_buff_size,
|
||||||
slow_launch_time = 2L,
|
slow_launch_time = 2L,
|
||||||
slave_open_temp_tables=0,
|
slave_open_temp_tables=0,
|
||||||
open_files_limit=0, max_binlog_size;
|
open_files_limit=0, max_binlog_size;
|
||||||
@ -1151,7 +1153,7 @@ sig_handler end_thread_signal(int sig __attribute__((unused)))
|
|||||||
{
|
{
|
||||||
THD *thd=current_thd;
|
THD *thd=current_thd;
|
||||||
DBUG_ENTER("end_thread_signal");
|
DBUG_ENTER("end_thread_signal");
|
||||||
if (thd)
|
if (thd && ! thd->bootstrap)
|
||||||
end_thread(thd,0);
|
end_thread(thd,0);
|
||||||
DBUG_VOID_RETURN; /* purecov: deadcode */
|
DBUG_VOID_RETURN; /* purecov: deadcode */
|
||||||
}
|
}
|
||||||
@ -2218,10 +2220,52 @@ The server will not act as a slave.");
|
|||||||
#if defined(__WIN__) && !defined(EMBEDDED_LIBRARY)
|
#if defined(__WIN__) && !defined(EMBEDDED_LIBRARY)
|
||||||
int mysql_service(void *p)
|
int mysql_service(void *p)
|
||||||
{
|
{
|
||||||
win_main(Service.my_argc, Service.my_argv);
|
if (use_opt_args)
|
||||||
|
win_main(opt_argc, opt_argv);
|
||||||
|
else
|
||||||
|
win_main(Service.my_argc, Service.my_argv);
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/*
|
||||||
|
Handle basic handling of services, like installation and removal
|
||||||
|
|
||||||
|
SYNOPSIS
|
||||||
|
default_service_handling()
|
||||||
|
argv Pointer to argument list
|
||||||
|
servicename Internal name of service
|
||||||
|
displayname Display name of service (in taskbar ?)
|
||||||
|
file_path Path to this program
|
||||||
|
|
||||||
|
RETURN VALUES
|
||||||
|
0 option handled
|
||||||
|
1 Could not handle option
|
||||||
|
*/
|
||||||
|
|
||||||
|
bool default_service_handling(char **argv,
|
||||||
|
const char *servicename,
|
||||||
|
const char *displayname,
|
||||||
|
const char *file_path)
|
||||||
|
{
|
||||||
|
if (Service.got_service_option(argv, "install"))
|
||||||
|
{
|
||||||
|
Service.Install(1, servicename, displayname, file_path);
|
||||||
|
return 0;
|
||||||
|
}
|
||||||
|
if (Service.got_service_option(argv, "install-manual"))
|
||||||
|
{
|
||||||
|
Service.Install(0, servicename, displayname, file_path);
|
||||||
|
return 0;
|
||||||
|
}
|
||||||
|
if (Service.got_service_option(argv, "remove"))
|
||||||
|
{
|
||||||
|
Service.Remove(servicename);
|
||||||
|
return 0;
|
||||||
|
}
|
||||||
|
return 1;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
int main(int argc, char **argv)
|
int main(int argc, char **argv)
|
||||||
{
|
{
|
||||||
if (Service.GetOS()) /* true NT family */
|
if (Service.GetOS()) /* true NT family */
|
||||||
@ -2232,52 +2276,51 @@ int main(int argc, char **argv)
|
|||||||
|
|
||||||
if (argc == 2)
|
if (argc == 2)
|
||||||
{
|
{
|
||||||
if (Service.got_service_option(argv, "install"))
|
if (!default_service_handling(argv,MYSQL_SERVICENAME, MYSQL_SERVICENAME,
|
||||||
{
|
file_path))
|
||||||
Service.Install(1, MYSQL_SERVICENAME, MYSQL_SERVICENAME, file_path);
|
return 0;
|
||||||
return 0;
|
if (Service.IsService(argv[1]))
|
||||||
}
|
|
||||||
else if (Service.got_service_option(argv, "install-manual"))
|
|
||||||
{
|
|
||||||
Service.Install(0, MYSQL_SERVICENAME, MYSQL_SERVICENAME, file_path);
|
|
||||||
return 0;
|
|
||||||
}
|
|
||||||
else if (Service.got_service_option(argv, "remove"))
|
|
||||||
{
|
|
||||||
Service.Remove(MYSQL_SERVICENAME);
|
|
||||||
return 0;
|
|
||||||
}
|
|
||||||
else if (Service.IsService(argv[1]))
|
|
||||||
{
|
{
|
||||||
/* start an optional service */
|
/* start an optional service */
|
||||||
load_default_groups[0]= argv[1];
|
event_name = load_default_groups[0]= argv[1];
|
||||||
event_name= argv[1];
|
|
||||||
start_mode= 1;
|
start_mode= 1;
|
||||||
Service.Init(event_name, mysql_service );
|
Service.Init(event_name, mysql_service);
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
else if (argc == 3) /* install or remove any optional service */
|
else if (argc == 3) /* install or remove any optional service */
|
||||||
{
|
{
|
||||||
|
/* Add service name after filename */
|
||||||
uint length=strlen(file_path);
|
uint length=strlen(file_path);
|
||||||
file_path[sizeof(file_path)-1]=0;
|
strxnmov(file_path + length, sizeof(file_path)-length-2, " ",
|
||||||
strxnmov(file_path + length, sizeof(file_path)-2, " ", argv[2], NullS);
|
argv[2], NullS)= '\0';
|
||||||
if (Service.got_service_option(argv, "install"))
|
|
||||||
|
if (!default_service_handling(argv, argv[2], argv[2], file_path))
|
||||||
|
return 0;
|
||||||
|
if (Service.IsService(argv[2]))
|
||||||
{
|
{
|
||||||
Service.Install(1, argv[2], argv[2], file_path);
|
/* start an optional service */
|
||||||
return 0;
|
use_opt_args=1;
|
||||||
}
|
opt_argc=argc;
|
||||||
else if (Service.got_service_option(argv, "install-manual"))
|
opt_argv=argv;
|
||||||
{
|
event_name= argv[2];
|
||||||
Service.Install(0, argv[2], argv[2], file_path);
|
start_mode= 1;
|
||||||
return 0;
|
Service.Init(event_name, mysql_service);
|
||||||
}
|
return 0;
|
||||||
else if (Service.got_service_option(argv, "remove"))
|
|
||||||
{
|
|
||||||
Service.Remove(argv[2]);
|
|
||||||
return 0;
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
else if (argc == 4)
|
||||||
|
{
|
||||||
|
/*
|
||||||
|
Install an optional service with optional config file
|
||||||
|
mysqld --install-manual mysqldopt --defaults-file=c:\miguel\my.ini
|
||||||
|
*/
|
||||||
|
uint length=strlen(file_path);
|
||||||
|
strxnmov(file_path + length, sizeof(file_path)-length-2, " ",
|
||||||
|
argv[3], " ", argv[2], NullS)= '\0';
|
||||||
|
if (!default_service_handling(argv, argv[2], argv[2], file_path))
|
||||||
|
return 0;
|
||||||
|
}
|
||||||
else if (argc == 1 && Service.IsService(MYSQL_SERVICENAME))
|
else if (argc == 1 && Service.IsService(MYSQL_SERVICENAME))
|
||||||
{
|
{
|
||||||
/* start the default service */
|
/* start the default service */
|
||||||
@ -2305,6 +2348,7 @@ static int bootstrap(FILE *file)
|
|||||||
{
|
{
|
||||||
THD *thd= new THD;
|
THD *thd= new THD;
|
||||||
int error;
|
int error;
|
||||||
|
DBUG_ENTER("bootstrap");
|
||||||
|
|
||||||
thd->bootstrap=1;
|
thd->bootstrap=1;
|
||||||
thd->client_capabilities=0;
|
thd->client_capabilities=0;
|
||||||
@ -2319,7 +2363,7 @@ static int bootstrap(FILE *file)
|
|||||||
(void*) thd))
|
(void*) thd))
|
||||||
{
|
{
|
||||||
sql_print_error("Warning: Can't create thread to handle bootstrap");
|
sql_print_error("Warning: Can't create thread to handle bootstrap");
|
||||||
return -1;
|
DBUG_RETURN(-1);
|
||||||
}
|
}
|
||||||
/* Wait for thread to die */
|
/* Wait for thread to die */
|
||||||
(void) pthread_mutex_lock(&LOCK_thread_count);
|
(void) pthread_mutex_lock(&LOCK_thread_count);
|
||||||
@ -2333,7 +2377,7 @@ static int bootstrap(FILE *file)
|
|||||||
net_end(&thd->net);
|
net_end(&thd->net);
|
||||||
thd->cleanup();
|
thd->cleanup();
|
||||||
delete thd;
|
delete thd;
|
||||||
return error;
|
DBUG_RETURN(error);
|
||||||
}
|
}
|
||||||
|
|
||||||
static bool read_init_file(char *file_name)
|
static bool read_init_file(char *file_name)
|
||||||
@ -3511,7 +3555,8 @@ struct my_option my_long_options[] =
|
|||||||
REQUIRED_ARG, 16384, 1024, 1024*1024L, 0, 1024, 0},
|
REQUIRED_ARG, 16384, 1024, 1024*1024L, 0, 1024, 0},
|
||||||
{"net_retry_count", OPT_NET_RETRY_COUNT,
|
{"net_retry_count", OPT_NET_RETRY_COUNT,
|
||||||
"If a read on a communication port is interrupted, retry this many times before giving up.",
|
"If a read on a communication port is interrupted, retry this many times before giving up.",
|
||||||
(gptr*) &mysqld_net_retry_count, (gptr*) &mysqld_net_retry_count, 0,
|
(gptr*) &global_system_variables.net_retry_count,
|
||||||
|
(gptr*) &max_system_variables.net_retry_count,0,
|
||||||
GET_ULONG, REQUIRED_ARG, MYSQLD_NET_RETRY_COUNT, 1, ~0L, 0, 1, 0},
|
GET_ULONG, REQUIRED_ARG, MYSQLD_NET_RETRY_COUNT, 1, ~0L, 0, 1, 0},
|
||||||
{"net_read_timeout", OPT_NET_READ_TIMEOUT,
|
{"net_read_timeout", OPT_NET_READ_TIMEOUT,
|
||||||
"Number of seconds to wait for more data from a connection before aborting the read.",
|
"Number of seconds to wait for more data from a connection before aborting the read.",
|
||||||
|
@ -381,6 +381,7 @@ void my_net_local_init(NET *net)
|
|||||||
net->max_packet= (uint) global_system_variables.net_buffer_length;
|
net->max_packet= (uint) global_system_variables.net_buffer_length;
|
||||||
net->read_timeout= (uint) global_system_variables.net_read_timeout;
|
net->read_timeout= (uint) global_system_variables.net_read_timeout;
|
||||||
net->write_timeout=(uint) global_system_variables.net_write_timeout;
|
net->write_timeout=(uint) global_system_variables.net_write_timeout;
|
||||||
|
net->retry_count= (uint) global_system_variables.net_retry_count;
|
||||||
net->max_packet_size= max(global_system_variables.net_buffer_length,
|
net->max_packet_size= max(global_system_variables.net_buffer_length,
|
||||||
global_system_variables.max_allowed_packet);
|
global_system_variables.max_allowed_packet);
|
||||||
}
|
}
|
||||||
|
@ -62,15 +62,12 @@ extern void query_cache_insert(NET *net, const char *packet, ulong length);
|
|||||||
#ifndef NO_ALARM
|
#ifndef NO_ALARM
|
||||||
#include "my_pthread.h"
|
#include "my_pthread.h"
|
||||||
void sql_print_error(const char *format,...);
|
void sql_print_error(const char *format,...);
|
||||||
#define RETRY_COUNT mysqld_net_retry_count
|
|
||||||
extern ulong mysqld_net_retry_count;
|
|
||||||
extern ulong bytes_sent, bytes_received;
|
extern ulong bytes_sent, bytes_received;
|
||||||
extern pthread_mutex_t LOCK_bytes_sent , LOCK_bytes_received;
|
extern pthread_mutex_t LOCK_bytes_sent , LOCK_bytes_received;
|
||||||
#else
|
#else
|
||||||
#undef statistic_add
|
#undef statistic_add
|
||||||
#define statistic_add(A,B,C)
|
#define statistic_add(A,B,C)
|
||||||
#define DONT_USE_THR_ALARM
|
#define DONT_USE_THR_ALARM
|
||||||
#define RETRY_COUNT 1
|
|
||||||
#endif /* NO_ALARM */
|
#endif /* NO_ALARM */
|
||||||
|
|
||||||
#include "thr_alarm.h"
|
#include "thr_alarm.h"
|
||||||
@ -85,11 +82,12 @@ static int net_write_buff(NET *net,const char *packet,ulong len);
|
|||||||
|
|
||||||
int my_net_init(NET *net, Vio* vio)
|
int my_net_init(NET *net, Vio* vio)
|
||||||
{
|
{
|
||||||
|
DBUG_ENTER("my_net_init");
|
||||||
my_net_local_init(net); /* Set some limits */
|
my_net_local_init(net); /* Set some limits */
|
||||||
if (!(net->buff=(uchar*) my_malloc((uint32) net->max_packet+
|
if (!(net->buff=(uchar*) my_malloc((uint32) net->max_packet+
|
||||||
NET_HEADER_SIZE + COMP_HEADER_SIZE,
|
NET_HEADER_SIZE + COMP_HEADER_SIZE,
|
||||||
MYF(MY_WME))))
|
MYF(MY_WME))))
|
||||||
return 1;
|
DBUG_RETURN(1);
|
||||||
net->buff_end=net->buff+net->max_packet;
|
net->buff_end=net->buff+net->max_packet;
|
||||||
net->vio = vio;
|
net->vio = vio;
|
||||||
net->no_send_ok = 0;
|
net->no_send_ok = 0;
|
||||||
@ -114,14 +112,16 @@ int my_net_init(NET *net, Vio* vio)
|
|||||||
#endif
|
#endif
|
||||||
vio_fastsend(vio);
|
vio_fastsend(vio);
|
||||||
}
|
}
|
||||||
return 0;
|
DBUG_RETURN(0);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
void net_end(NET *net)
|
void net_end(NET *net)
|
||||||
{
|
{
|
||||||
|
DBUG_ENTER("net_end");
|
||||||
my_free((gptr) net->buff,MYF(MY_ALLOW_ZERO_PTR));
|
my_free((gptr) net->buff,MYF(MY_ALLOW_ZERO_PTR));
|
||||||
net->buff=0;
|
net->buff=0;
|
||||||
|
DBUG_VOID_RETURN;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
@ -385,7 +385,7 @@ net_real_write(NET *net,const char *packet,ulong len)
|
|||||||
my_bool old_mode;
|
my_bool old_mode;
|
||||||
while (vio_blocking(net->vio, TRUE, &old_mode) < 0)
|
while (vio_blocking(net->vio, TRUE, &old_mode) < 0)
|
||||||
{
|
{
|
||||||
if (vio_should_retry(net->vio) && retry_count++ < RETRY_COUNT)
|
if (vio_should_retry(net->vio) && retry_count++ < net->retry_count)
|
||||||
continue;
|
continue;
|
||||||
#ifdef EXTRA_DEBUG
|
#ifdef EXTRA_DEBUG
|
||||||
fprintf(stderr,
|
fprintf(stderr,
|
||||||
@ -404,7 +404,7 @@ net_real_write(NET *net,const char *packet,ulong len)
|
|||||||
if (thr_alarm_in_use(&alarmed) && !thr_got_alarm(&alarmed) &&
|
if (thr_alarm_in_use(&alarmed) && !thr_got_alarm(&alarmed) &&
|
||||||
interrupted)
|
interrupted)
|
||||||
{
|
{
|
||||||
if (retry_count++ < RETRY_COUNT)
|
if (retry_count++ < net->retry_count)
|
||||||
continue;
|
continue;
|
||||||
#ifdef EXTRA_DEBUG
|
#ifdef EXTRA_DEBUG
|
||||||
fprintf(stderr, "%s: write looped, aborting thread\n",
|
fprintf(stderr, "%s: write looped, aborting thread\n",
|
||||||
@ -476,7 +476,7 @@ static void my_net_skip_rest(NET *net, uint32 remain, thr_alarm_t *alarmed)
|
|||||||
my_bool interrupted = vio_should_retry(net->vio);
|
my_bool interrupted = vio_should_retry(net->vio);
|
||||||
if (!thr_got_alarm(&alarmed) && interrupted)
|
if (!thr_got_alarm(&alarmed) && interrupted)
|
||||||
{ /* Probably in MIT threads */
|
{ /* Probably in MIT threads */
|
||||||
if (retry_count++ < RETRY_COUNT)
|
if (retry_count++ < net->retry_count)
|
||||||
continue;
|
continue;
|
||||||
}
|
}
|
||||||
return;
|
return;
|
||||||
@ -543,7 +543,7 @@ my_real_read(NET *net, ulong *complen)
|
|||||||
while (vio_blocking(net->vio, TRUE, &old_mode) < 0)
|
while (vio_blocking(net->vio, TRUE, &old_mode) < 0)
|
||||||
{
|
{
|
||||||
if (vio_should_retry(net->vio) &&
|
if (vio_should_retry(net->vio) &&
|
||||||
retry_count++ < RETRY_COUNT)
|
retry_count++ < net->retry_count)
|
||||||
continue;
|
continue;
|
||||||
DBUG_PRINT("error",
|
DBUG_PRINT("error",
|
||||||
("fcntl returned error %d, aborting thread",
|
("fcntl returned error %d, aborting thread",
|
||||||
@ -568,7 +568,7 @@ my_real_read(NET *net, ulong *complen)
|
|||||||
if (thr_alarm_in_use(&alarmed) && !thr_got_alarm(&alarmed) &&
|
if (thr_alarm_in_use(&alarmed) && !thr_got_alarm(&alarmed) &&
|
||||||
interrupted)
|
interrupted)
|
||||||
{ /* Probably in MIT threads */
|
{ /* Probably in MIT threads */
|
||||||
if (retry_count++ < RETRY_COUNT)
|
if (retry_count++ < net->retry_count)
|
||||||
continue;
|
continue;
|
||||||
#ifdef EXTRA_DEBUG
|
#ifdef EXTRA_DEBUG
|
||||||
fprintf(stderr, "%s: read looped with error %d, aborting thread\n",
|
fprintf(stderr, "%s: read looped with error %d, aborting thread\n",
|
||||||
|
@ -72,6 +72,7 @@ static void fix_low_priority_updates(THD *thd, enum_var_type type);
|
|||||||
static void fix_tx_isolation(THD *thd, enum_var_type type);
|
static void fix_tx_isolation(THD *thd, enum_var_type type);
|
||||||
static void fix_net_read_timeout(THD *thd, enum_var_type type);
|
static void fix_net_read_timeout(THD *thd, enum_var_type type);
|
||||||
static void fix_net_write_timeout(THD *thd, enum_var_type type);
|
static void fix_net_write_timeout(THD *thd, enum_var_type type);
|
||||||
|
static void fix_net_retry_count(THD *thd, enum_var_type type);
|
||||||
static void fix_max_join_size(THD *thd, enum_var_type type);
|
static void fix_max_join_size(THD *thd, enum_var_type type);
|
||||||
static void fix_query_cache_size(THD *thd, enum_var_type type);
|
static void fix_query_cache_size(THD *thd, enum_var_type type);
|
||||||
static void fix_key_buffer_size(THD *thd, enum_var_type type);
|
static void fix_key_buffer_size(THD *thd, enum_var_type type);
|
||||||
@ -167,6 +168,9 @@ sys_var_thd_ulong sys_net_read_timeout("net_read_timeout",
|
|||||||
sys_var_thd_ulong sys_net_write_timeout("net_write_timeout",
|
sys_var_thd_ulong sys_net_write_timeout("net_write_timeout",
|
||||||
&SV::net_write_timeout,
|
&SV::net_write_timeout,
|
||||||
fix_net_write_timeout);
|
fix_net_write_timeout);
|
||||||
|
sys_var_thd_ulong sys_net_retry_count("net_retry_count",
|
||||||
|
&SV::net_retry_count,
|
||||||
|
fix_net_retry_count);
|
||||||
sys_var_thd_ulong sys_read_buff_size("read_buffer_size",
|
sys_var_thd_ulong sys_read_buff_size("read_buffer_size",
|
||||||
&SV::read_buff_size);
|
&SV::read_buff_size);
|
||||||
sys_var_thd_ulong sys_read_rnd_buff_size("read_rnd_buffer_size",
|
sys_var_thd_ulong sys_read_rnd_buff_size("read_rnd_buffer_size",
|
||||||
@ -332,6 +336,7 @@ sys_var *sys_variables[]=
|
|||||||
&sys_myisam_sort_buffer_size,
|
&sys_myisam_sort_buffer_size,
|
||||||
&sys_net_buffer_length,
|
&sys_net_buffer_length,
|
||||||
&sys_net_read_timeout,
|
&sys_net_read_timeout,
|
||||||
|
&sys_net_retry_count,
|
||||||
&sys_net_wait_timeout,
|
&sys_net_wait_timeout,
|
||||||
&sys_net_write_timeout,
|
&sys_net_write_timeout,
|
||||||
&sys_query_cache_size,
|
&sys_query_cache_size,
|
||||||
@ -472,7 +477,7 @@ struct show_var_st init_vars[]= {
|
|||||||
#endif
|
#endif
|
||||||
{sys_net_buffer_length.name,(char*) &sys_net_buffer_length, SHOW_SYS},
|
{sys_net_buffer_length.name,(char*) &sys_net_buffer_length, SHOW_SYS},
|
||||||
{sys_net_read_timeout.name, (char*) &sys_net_read_timeout, SHOW_SYS},
|
{sys_net_read_timeout.name, (char*) &sys_net_read_timeout, SHOW_SYS},
|
||||||
{"net_retry_count", (char*) &mysqld_net_retry_count, SHOW_LONG},
|
{sys_net_retry_count.name, (char*) &sys_net_retry_count, SHOW_SYS},
|
||||||
{sys_net_write_timeout.name,(char*) &sys_net_write_timeout, SHOW_SYS},
|
{sys_net_write_timeout.name,(char*) &sys_net_write_timeout, SHOW_SYS},
|
||||||
{"open_files_limit", (char*) &open_files_limit, SHOW_LONG},
|
{"open_files_limit", (char*) &open_files_limit, SHOW_LONG},
|
||||||
{"pid_file", (char*) pidfile_name, SHOW_CHAR},
|
{"pid_file", (char*) pidfile_name, SHOW_CHAR},
|
||||||
@ -599,6 +604,12 @@ static void fix_net_write_timeout(THD *thd, enum_var_type type)
|
|||||||
thd->net.write_timeout=thd->variables.net_write_timeout;
|
thd->net.write_timeout=thd->variables.net_write_timeout;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
static void fix_net_retry_count(THD *thd, enum_var_type type)
|
||||||
|
{
|
||||||
|
if (type != OPT_GLOBAL)
|
||||||
|
thd->net.retry_count=thd->variables.net_retry_count;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
static void fix_query_cache_size(THD *thd, enum_var_type type)
|
static void fix_query_cache_size(THD *thd, enum_var_type type)
|
||||||
{
|
{
|
||||||
|
@ -245,4 +245,4 @@
|
|||||||
"Wrong argument type to variable '%-.64s'",
|
"Wrong argument type to variable '%-.64s'",
|
||||||
"Variable '%-.64s' can only be set, not read",
|
"Variable '%-.64s' can only be set, not read",
|
||||||
"Wrong usage/placement of '%s'",
|
"Wrong usage/placement of '%s'",
|
||||||
"This version of MySQL doesn't yet support '%s',"
|
"This version of MySQL doesn't yet support '%s'",
|
||||||
|
@ -239,4 +239,4 @@
|
|||||||
"Wrong argument type to variable '%-.64s'",
|
"Wrong argument type to variable '%-.64s'",
|
||||||
"Variable '%-.64s' can only be set, not read",
|
"Variable '%-.64s' can only be set, not read",
|
||||||
"Wrong usage/placement of '%s'",
|
"Wrong usage/placement of '%s'",
|
||||||
"This version of MySQL doesn't yet support '%s',"
|
"This version of MySQL doesn't yet support '%s'",
|
||||||
|
@ -236,4 +236,4 @@
|
|||||||
"Wrong argument type to variable '%-.64s'",
|
"Wrong argument type to variable '%-.64s'",
|
||||||
"Variable '%-.64s' can only be set, not read",
|
"Variable '%-.64s' can only be set, not read",
|
||||||
"Wrong usage/placement of '%s'",
|
"Wrong usage/placement of '%s'",
|
||||||
"This version of MySQL doesn't yet support '%s',"
|
"This version of MySQL doesn't yet support '%s'",
|
||||||
|
@ -241,4 +241,4 @@
|
|||||||
"Wrong argument type to variable '%-.64s'",
|
"Wrong argument type to variable '%-.64s'",
|
||||||
"Variable '%-.64s' can only be set, not read",
|
"Variable '%-.64s' can only be set, not read",
|
||||||
"Wrong usage/placement of '%s'",
|
"Wrong usage/placement of '%s'",
|
||||||
"This version of MySQL doesn't yet support '%s',"
|
"This version of MySQL doesn't yet support '%s'",
|
||||||
|
@ -236,4 +236,4 @@
|
|||||||
"Wrong argument type to variable '%-.64s'",
|
"Wrong argument type to variable '%-.64s'",
|
||||||
"Variable '%-.64s' can only be set, not read",
|
"Variable '%-.64s' can only be set, not read",
|
||||||
"Wrong usage/placement of '%s'",
|
"Wrong usage/placement of '%s'",
|
||||||
"This version of MySQL doesn't yet support '%s',"
|
"This version of MySQL doesn't yet support '%s'",
|
||||||
|
@ -239,4 +239,4 @@
|
|||||||
"Wrong argument type to variable '%-.64s'",
|
"Wrong argument type to variable '%-.64s'",
|
||||||
"Variable '%-.64s' can only be set, not read",
|
"Variable '%-.64s' can only be set, not read",
|
||||||
"Wrong usage/placement of '%s'",
|
"Wrong usage/placement of '%s'",
|
||||||
"This version of MySQL doesn't yet support '%s',"
|
"This version of MySQL doesn't yet support '%s'",
|
||||||
|
@ -236,4 +236,4 @@
|
|||||||
"Wrong argument type to variable '%-.64s'",
|
"Wrong argument type to variable '%-.64s'",
|
||||||
"Variable '%-.64s' can only be set, not read",
|
"Variable '%-.64s' can only be set, not read",
|
||||||
"Wrong usage/placement of '%s'",
|
"Wrong usage/placement of '%s'",
|
||||||
"This version of MySQL doesn't yet support '%s',"
|
"This version of MySQL doesn't yet support '%s'",
|
||||||
|
@ -238,4 +238,4 @@
|
|||||||
"Wrong argument type to variable '%-.64s'",
|
"Wrong argument type to variable '%-.64s'",
|
||||||
"Variable '%-.64s' can only be set, not read",
|
"Variable '%-.64s' can only be set, not read",
|
||||||
"Wrong usage/placement of '%s'",
|
"Wrong usage/placement of '%s'",
|
||||||
"This version of MySQL doesn't yet support '%s',"
|
"This version of MySQL doesn't yet support '%s'",
|
||||||
|
@ -236,4 +236,4 @@
|
|||||||
"Wrong argument type to variable '%-.64s'",
|
"Wrong argument type to variable '%-.64s'",
|
||||||
"Variable '%-.64s' can only be set, not read",
|
"Variable '%-.64s' can only be set, not read",
|
||||||
"Wrong usage/placement of '%s'",
|
"Wrong usage/placement of '%s'",
|
||||||
"This version of MySQL doesn't yet support '%s',"
|
"This version of MySQL doesn't yet support '%s'",
|
||||||
|
@ -238,4 +238,4 @@
|
|||||||
"Wrong argument type to variable '%-.64s'",
|
"Wrong argument type to variable '%-.64s'",
|
||||||
"Variable '%-.64s' can only be set, not read",
|
"Variable '%-.64s' can only be set, not read",
|
||||||
"Wrong usage/placement of '%s'",
|
"Wrong usage/placement of '%s'",
|
||||||
"This version of MySQL doesn't yet support '%s',"
|
"This version of MySQL doesn't yet support '%s'",
|
||||||
|
@ -236,4 +236,4 @@
|
|||||||
"Wrong argument type to variable '%-.64s'",
|
"Wrong argument type to variable '%-.64s'",
|
||||||
"Variable '%-.64s' can only be set, not read",
|
"Variable '%-.64s' can only be set, not read",
|
||||||
"Wrong usage/placement of '%s'",
|
"Wrong usage/placement of '%s'",
|
||||||
"This version of MySQL doesn't yet support '%s',"
|
"This version of MySQL doesn't yet support '%s'",
|
||||||
|
@ -238,4 +238,4 @@
|
|||||||
"Wrong argument type to variable '%-.64s'",
|
"Wrong argument type to variable '%-.64s'",
|
||||||
"Variable '%-.64s' can only be set, not read",
|
"Variable '%-.64s' can only be set, not read",
|
||||||
"Wrong usage/placement of '%s'",
|
"Wrong usage/placement of '%s'",
|
||||||
"This version of MySQL doesn't yet support '%s',"
|
"This version of MySQL doesn't yet support '%s'",
|
||||||
|
@ -238,4 +238,4 @@
|
|||||||
"Wrong argument type to variable '%-.64s'",
|
"Wrong argument type to variable '%-.64s'",
|
||||||
"Variable '%-.64s' can only be set, not read",
|
"Variable '%-.64s' can only be set, not read",
|
||||||
"Wrong usage/placement of '%s'",
|
"Wrong usage/placement of '%s'",
|
||||||
"This version of MySQL doesn't yet support '%s',"
|
"This version of MySQL doesn't yet support '%s'",
|
||||||
|
@ -240,4 +240,4 @@
|
|||||||
"Wrong argument type to variable '%-.64s'",
|
"Wrong argument type to variable '%-.64s'",
|
||||||
"Variable '%-.64s' can only be set, not read",
|
"Variable '%-.64s' can only be set, not read",
|
||||||
"Wrong usage/placement of '%s'",
|
"Wrong usage/placement of '%s'",
|
||||||
"This version of MySQL doesn't yet support '%s',"
|
"This version of MySQL doesn't yet support '%s'",
|
||||||
|
@ -236,4 +236,4 @@
|
|||||||
"Wrong argument type to variable '%-.64s'",
|
"Wrong argument type to variable '%-.64s'",
|
||||||
"Variable '%-.64s' can only be set, not read",
|
"Variable '%-.64s' can only be set, not read",
|
||||||
"Wrong usage/placement of '%s'",
|
"Wrong usage/placement of '%s'",
|
||||||
"This version of MySQL doesn't yet support '%s',"
|
"This version of MySQL doesn't yet support '%s'",
|
||||||
|
@ -240,4 +240,4 @@
|
|||||||
"Wrong argument type to variable '%-.64s'",
|
"Wrong argument type to variable '%-.64s'",
|
||||||
"Variable '%-.64s' can only be set, not read",
|
"Variable '%-.64s' can only be set, not read",
|
||||||
"Wrong usage/placement of '%s'",
|
"Wrong usage/placement of '%s'",
|
||||||
"This version of MySQL doesn't yet support '%s',"
|
"This version of MySQL doesn't yet support '%s'",
|
||||||
|
@ -239,4 +239,4 @@
|
|||||||
"Wrong argument type to variable '%-.64s'",
|
"Wrong argument type to variable '%-.64s'",
|
||||||
"Variable '%-.64s' can only be set, not read",
|
"Variable '%-.64s' can only be set, not read",
|
||||||
"Wrong usage/placement of '%s'",
|
"Wrong usage/placement of '%s'",
|
||||||
"This version of MySQL doesn't yet support '%s',"
|
"This version of MySQL doesn't yet support '%s'",
|
||||||
|
@ -244,4 +244,4 @@
|
|||||||
"Wrong argument type to variable '%-.64s'",
|
"Wrong argument type to variable '%-.64s'",
|
||||||
"Variable '%-.64s' can only be set, not read",
|
"Variable '%-.64s' can only be set, not read",
|
||||||
"Wrong usage/placement of '%s'",
|
"Wrong usage/placement of '%s'",
|
||||||
"This version of MySQL doesn't yet support '%s',"
|
"This version of MySQL doesn't yet support '%s'",
|
||||||
|
@ -237,4 +237,4 @@
|
|||||||
"Wrong argument type to variable '%-.64s'",
|
"Wrong argument type to variable '%-.64s'",
|
||||||
"Variable '%-.64s' can only be set, not read",
|
"Variable '%-.64s' can only be set, not read",
|
||||||
"Wrong usage/placement of '%s'",
|
"Wrong usage/placement of '%s'",
|
||||||
"This version of MySQL doesn't yet support '%s',"
|
"This version of MySQL doesn't yet support '%s'",
|
||||||
|
@ -236,4 +236,4 @@
|
|||||||
"Wrong argument type to variable '%-.64s'",
|
"Wrong argument type to variable '%-.64s'",
|
||||||
"Variable '%-.64s' can only be set, not read",
|
"Variable '%-.64s' can only be set, not read",
|
||||||
"Wrong usage/placement of '%s'",
|
"Wrong usage/placement of '%s'",
|
||||||
"This version of MySQL doesn't yet support '%s',"
|
"This version of MySQL doesn't yet support '%s'",
|
||||||
|
@ -241,4 +241,4 @@
|
|||||||
"Wrong argument type to variable '%-.64s'",
|
"Wrong argument type to variable '%-.64s'",
|
||||||
"Variable '%-.64s' can only be set, not read",
|
"Variable '%-.64s' can only be set, not read",
|
||||||
"Wrong usage/placement of '%s'",
|
"Wrong usage/placement of '%s'",
|
||||||
"This version of MySQL doesn't yet support '%s',"
|
"This version of MySQL doesn't yet support '%s'",
|
||||||
|
@ -208,7 +208,6 @@ THD::~THD()
|
|||||||
hash_free(&user_vars);
|
hash_free(&user_vars);
|
||||||
|
|
||||||
DBUG_PRINT("info", ("freeing host"));
|
DBUG_PRINT("info", ("freeing host"));
|
||||||
|
|
||||||
if (host != localhost) // If not pointer to constant
|
if (host != localhost) // If not pointer to constant
|
||||||
safeFree(host);
|
safeFree(host);
|
||||||
if (user != delayed_user)
|
if (user != delayed_user)
|
||||||
|
@ -296,6 +296,7 @@ struct system_variables
|
|||||||
ulong net_read_timeout;
|
ulong net_read_timeout;
|
||||||
ulong net_wait_timeout;
|
ulong net_wait_timeout;
|
||||||
ulong net_write_timeout;
|
ulong net_write_timeout;
|
||||||
|
ulong net_retry_count;
|
||||||
ulong query_cache_type;
|
ulong query_cache_type;
|
||||||
ulong read_buff_size;
|
ulong read_buff_size;
|
||||||
ulong read_rnd_buff_size;
|
ulong read_rnd_buff_size;
|
||||||
|
@ -721,7 +721,7 @@ pthread_handler_decl(handle_bootstrap,arg)
|
|||||||
|
|
||||||
thd->proc_info=0;
|
thd->proc_info=0;
|
||||||
thd->version=refresh_version;
|
thd->version=refresh_version;
|
||||||
thd->priv_user=thd->user=(char*)"boot";
|
thd->priv_user=thd->user=(char*) my_strdup("boot", MYF(MY_WME));
|
||||||
|
|
||||||
buff= (char*) thd->net.buff;
|
buff= (char*) thd->net.buff;
|
||||||
init_sql_alloc(&thd->mem_root, MEM_ROOT_BLOCK_SIZE, MEM_ROOT_PREALLOC);
|
init_sql_alloc(&thd->mem_root, MEM_ROOT_BLOCK_SIZE, MEM_ROOT_PREALLOC);
|
||||||
@ -752,7 +752,6 @@ pthread_handler_decl(handle_bootstrap,arg)
|
|||||||
free_root(&thd->mem_root,MYF(MY_KEEP_PREALLOC));
|
free_root(&thd->mem_root,MYF(MY_KEEP_PREALLOC));
|
||||||
free_root(&thd->transaction.mem_root,MYF(MY_KEEP_PREALLOC));
|
free_root(&thd->transaction.mem_root,MYF(MY_KEEP_PREALLOC));
|
||||||
}
|
}
|
||||||
thd->priv_user=thd->user=0;
|
|
||||||
|
|
||||||
/* thd->fatal_error should be set in case something went wrong */
|
/* thd->fatal_error should be set in case something went wrong */
|
||||||
end:
|
end:
|
||||||
|
@ -5086,7 +5086,7 @@ end_write(JOIN *join, JOIN_TAB *join_tab __attribute__((unused)),
|
|||||||
error == HA_ERR_FOUND_DUPP_UNIQUE)
|
error == HA_ERR_FOUND_DUPP_UNIQUE)
|
||||||
goto end;
|
goto end;
|
||||||
if (create_myisam_from_heap(table, &join->tmp_table_param, error,1))
|
if (create_myisam_from_heap(table, &join->tmp_table_param, error,1))
|
||||||
DBUG_RETURN(1); // Not a table_is_full error
|
DBUG_RETURN(-1); // Not a table_is_full error
|
||||||
table->uniques=0; // To ensure rows are the same
|
table->uniques=0; // To ensure rows are the same
|
||||||
}
|
}
|
||||||
if (++join->send_records >= join->tmp_table_param.end_write_records &&
|
if (++join->send_records >= join->tmp_table_param.end_write_records &&
|
||||||
@ -5258,7 +5258,7 @@ end_write_group(JOIN *join, JOIN_TAB *join_tab __attribute__((unused)),
|
|||||||
{
|
{
|
||||||
if (create_myisam_from_heap(table, &join->tmp_table_param,
|
if (create_myisam_from_heap(table, &join->tmp_table_param,
|
||||||
error, 0))
|
error, 0))
|
||||||
DBUG_RETURN(1); // Not a table_is_full error
|
DBUG_RETURN(-1); // Not a table_is_full error
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
join->send_records++;
|
join->send_records++;
|
||||||
|
@ -3449,7 +3449,7 @@ revoke:
|
|||||||
lex->columns.empty();
|
lex->columns.empty();
|
||||||
lex->grant= lex->grant_tot_col=0;
|
lex->grant= lex->grant_tot_col=0;
|
||||||
lex->select->db=0;
|
lex->select->db=0;
|
||||||
bzero(&(lex->mqh),sizeof(lex->mqh));
|
bzero((char*) &lex->mqh, sizeof(lex->mqh));
|
||||||
}
|
}
|
||||||
grant_privileges ON opt_table FROM user_list;
|
grant_privileges ON opt_table FROM user_list;
|
||||||
|
|
||||||
|
Reference in New Issue
Block a user