mirror of
https://github.com/MariaDB/server.git
synced 2025-01-16 20:12:31 +01:00
5b2c312627
BitKeeper/etc/ignore: auto-union BitKeeper/etc/logging_ok: auto-union mysql-test/r/ctype_tis620.result-old: Merge rename: mysql-test/r/ctype_tis620.result -> mysql-test/r/ctype_tis620.result-old BUILD/compile-pentium-max: Auto merged BitKeeper/etc/config: Auto merged Build-tools/Bootstrap: Auto merged Build-tools/Do-compile: Auto merged configure.in: Auto merged mysql-test/t/ctype_tis620.test-old: Merge rename: mysql-test/t/ctype_tis620.test -> mysql-test/t/ctype_tis620.test-old Docs/Makefile.am: Auto merged client/mysqldump.c: Auto merged client/mysqltest.c: Auto merged include/my_global.h: Auto merged include/my_pthread.h: Auto merged include/my_sys.h: Auto merged include/myisam.h: Auto merged innobase/btr/btr0cur.c: Auto merged innobase/ibuf/ibuf0ibuf.c: Auto merged innobase/include/dict0dict.h: Auto merged innobase/include/srv0srv.h: Auto merged innobase/include/ut0mem.h: Auto merged innobase/log/log0log.c: Auto merged innobase/row/row0ins.c: Auto merged innobase/row/row0sel.c: Auto merged innobase/srv/srv0start.c: Auto merged innobase/ut/ut0mem.c: Auto merged myisam/mi_check.c: Auto merged myisam/mi_dynrec.c: Auto merged myisam/mi_key.c: Auto merged myisam/myisam_ftdump.c: Auto merged myisam/myisamdef.h: Auto merged mysql-test/mysql-test-run.sh: Auto merged mysql-test/r/alter_table.result: Auto merged mysql-test/r/bdb.result: Auto merged mysql-test/r/bigint.result: Auto merged mysql-test/r/fulltext.result: Auto merged
60 lines
1.8 KiB
C
60 lines
1.8 KiB
C
#ifdef HAVE_REPLICATION
|
|
#include "slave.h"
|
|
|
|
typedef struct st_slave_info
|
|
{
|
|
uint32 server_id;
|
|
uint32 rpl_recovery_rank, master_id;
|
|
char host[HOSTNAME_LENGTH+1];
|
|
char user[USERNAME_LENGTH+1];
|
|
char password[MAX_PASSWORD_LENGTH+1];
|
|
uint16 port;
|
|
THD* thd;
|
|
} SLAVE_INFO;
|
|
|
|
extern my_bool opt_show_slave_auth_info;
|
|
extern char *master_host, *master_info_file;
|
|
extern bool server_id_supplied;
|
|
extern I_List<i_string> binlog_do_db, binlog_ignore_db;
|
|
|
|
extern int max_binlog_dump_events;
|
|
extern my_bool opt_sporadic_binlog_dump_fail;
|
|
|
|
#define KICK_SLAVE(thd) { pthread_mutex_lock(&(thd)->LOCK_delete); (thd)->awake(0 /* do not prepare to die*/); pthread_mutex_unlock(&(thd)->LOCK_delete); }
|
|
|
|
File open_binlog(IO_CACHE *log, const char *log_file_name,
|
|
const char **errmsg);
|
|
|
|
int start_slave(THD* thd, MASTER_INFO* mi, bool net_report);
|
|
int stop_slave(THD* thd, MASTER_INFO* mi, bool net_report);
|
|
int change_master(THD* thd, MASTER_INFO* mi);
|
|
int show_binlog_events(THD* thd);
|
|
int cmp_master_pos(const char* log_file_name1, ulonglong log_pos1,
|
|
const char* log_file_name2, ulonglong log_pos2);
|
|
int reset_slave(THD *thd, MASTER_INFO* mi);
|
|
int reset_master(THD* thd);
|
|
int purge_master_logs(THD* thd, const char* to_log);
|
|
int purge_master_logs_before_date(THD* thd, time_t purge_time);
|
|
bool log_in_use(const char* log_name);
|
|
void adjust_linfo_offsets(my_off_t purge_offset);
|
|
int show_binlogs(THD* thd);
|
|
extern int init_master_info(MASTER_INFO* mi);
|
|
void kill_zombie_dump_threads(uint32 slave_server_id);
|
|
int check_binlog_magic(IO_CACHE* log, const char** errmsg);
|
|
|
|
typedef struct st_load_file_info
|
|
{
|
|
THD* thd;
|
|
my_off_t last_pos_in_file;
|
|
sql_exchange* ex;
|
|
List <Item> *fields;
|
|
enum enum_duplicates handle_dup;
|
|
char* db;
|
|
char* table_name;
|
|
bool wrote_create_file, log_delayed;
|
|
} LOAD_FILE_INFO;
|
|
|
|
int log_loaded_block(IO_CACHE* file);
|
|
|
|
#endif /* HAVE_REPLICATION */
|
|
|