Commit graph

67 commits

Author SHA1 Message Date
guilhem@mysql.com
b03ec0d7db Replication: new code to not modify in-memory log positions until the COMMIT
is executed, even if the transaction spans on >=2 relay logs (bug #53).
New variable relay_log_purge =0|1
New test to verify bug #53
2003-04-24 15:29:25 +02:00
monty@narttu.mysql.fi
b883a9c01c Merge with 4.0.12 2003-03-19 22:25:44 +02:00
guilhem@mysql.com
87e1c552ed New variable rli->ignore_log_space_limit to resolve
a deadlock between I/O and SQL threads in replication
when relay_log_space is too small. This fixes bug #79.
2003-03-17 22:51:56 +01:00
monty@narttu.mysql.fi
a434bca704 Merge with 4.0 2003-03-16 19:17:54 +02:00
guilhem@mysql.com
e66992aef5 Replication: simplification of init_relay_log_pos: always initialize,
remove variable rli->log_pos_current.
2003-03-02 00:45:19 +01:00
papa@gbichot.local
264d8c095d Replication: give the slave I/O thread a higher priority than the slave SQL thread
so that it has fetched the most from the master's binlog before the master
accidently dies. SCRUM task #756.
2003-03-01 23:59:27 +01:00
monty@mashka.mysql.fi
023d6dd39b Merge with 4.0.11 2003-02-04 21:52:14 +02:00
monty@mashka.mysql.fi
689578a099 Fixes for Netware
Call pthread_mutex_destroy() on not used mutex.
Changed comments in .h and .c files from // -> /* */
Added detection of mutex on which one didn't call pthread_mutex_destroy()
Fixed bug in create_tmp_field() which causes a memory overrun in queries that uses "ORDER BY constant_expression"
Added optimisation for ORDER BY NULL
2003-01-28 08:38:28 +02:00
monty@mashka.mysql.fi
fa7a94ed14 Added timeout for wait_for_master_pos
Fixed comparision of log-binary name to handle comparison when file name extension wraps from .999 to .1000
Don't replicate CREATE/DROP DATABASE if wild_xxx_table=database.% is used.
2003-01-25 15:07:51 +02:00
hf@deer.mysql.r18.ru
96089e2b3a resolving conflicts 2003-01-15 13:15:35 +04:00
hf@deer.mysql.r18.ru
c59bff7c96 SCRUM
embedded library trimming
2003-01-15 12:11:44 +04:00
monty@mashka.mysql.fi
07daf3169e Merge with 4.0.8 2003-01-03 00:04:33 +02:00
hf@deer.mysql.r18.ru
e3b3b68307 Big purge about embedded library (scrum) 2002-12-16 17:33:29 +04:00
monty@mashka.mysql.fi
5022e56cba Ensure that BEGIN / COMMIT is handled properly if slave dies
Added syntax support for
CREATE TABLE foo (a char CHARACTER SET latin1) CHARSET=latin1;
2002-12-11 15:46:39 +02:00
monty@mashka.mysql.fi
dac6498f9b Merge with 4.0 2002-11-21 15:56:48 +02:00
monty@butch.
a2bdf9265f Portability fixes for Fortre C++ 5.0 (on Sun) in 32 and 64 bit modes. 2002-11-07 03:54:00 +02:00
nick@mysql.com
6ea83e1127 Added comment blocks for all functions 2002-10-29 15:12:47 -07:00
monty@mashka.mysql.fi
f3a186c905 Portability fixes.
Improve mysql-test to be more robust.
Fix that GRANT doesn't delete SSL options
Change innobase_flush_log_at_trx_commit to uint.
Don't rotate logs if we read a rotate log entry from the master.
2002-09-11 06:40:08 +03:00
monty@mashka.mysql.fi
04723cf74d Give better error from reconnect()
Fixed hang in start_slave_threads() when thread dies quickly.
2002-08-24 05:44:16 +03:00
monty@hundin.mysql.fi
7dac7062fa Changed relay_log_space to ulonglong
Removed compiler warnings.
2002-08-23 15:14:01 +03:00
monty@hundin.mysql.fi
f36f9d00ff Fixed bug in wait_for_update() that I had introduced.
Changed option variables to my_bool (to avoid bugs in my_getopt())
Added new thread specific mutex LOCK_delete to be able to free LOCK_thread_count early.
Changed usage of LOCK_thread_count -> LOCK_status for statistics variables
2002-08-22 16:50:58 +03:00
monty@hundin.mysql.fi
03b0179af9 Use our version of RWLOCKS on UNIXWARE 7
More DBUG info for replication
Better error messages from replication
Fixed bug in replication code when connecting to 'localhost' (time was not released properly)
Block ALARM signal on Linux for signal handler thread (Fixes problem with running mysqld with --debug)
Removed warning when setting an AUTO_INCREMENT field to NULL
2002-08-21 22:04:22 +03:00
monty@mashka.mysql.fi
2c4fa340cc Lots of code fixes to the replication code (especially the binary logging and index log file handling)
Fixed bugs in my last changeset that made MySQL hard to compile.
Added mutex around some data that could cause table cache corruptions when using OPTIMIZE TABLE / REPAIR TABLE or automatic repair of MyISAM tables.
Added mutex around some data in the slave start/stop code that could cause THD linked list corruptions
Extended my_chsize() to allow one to specify a filler character.
Extend vio_blocking to return the old state (This made some usage of this function much simpler)
Added testing for some functions that they caller have got the required mutexes before calling the function.
Use setrlimit() to ensure that we can write core file if one specifies --core-file.
Added --slave-compressed-protocol
Made 2 the minimum length for ft_min_word_len
Added variables foreign_key_checks & unique_checks.
Less logging from replication code (if not started with --log-warnings)
Changed that SHOW INNODB STATUS requre the SUPER privilege
More DBUG statements and a lot of new code comments
2002-08-08 03:12:02 +03:00
monty@mashka.mysql.fi
bc035c71f1 Merge with 3.23.51
Fixed wrong usage of sprintf() in ha_innodb.cc
2002-07-25 22:46:28 +03:00
salle@geopard.online.bg
b472f401b1 Some
C++ comments cleanup
2002-07-17 15:17:20 +03:00
heikki@hundin.mysql.fi
a4b29743bc slave.h, slave.cc:
Do not flush the position to master.info file if we have a transaction open
2002-06-22 20:00:32 +03:00
monty@mashka.mysql.fi
2aecdd1a91 Big code cleanup/review before 4.0.2 release.
(All commit emails since 4.0.1 checked)
This had to be done now, before the 4.1 tree changes to much, to make it easy to propagate bug fixes to the 4.1 tree.
2002-06-11 11:20:31 +03:00
monty@hundin.mysql.fi
e4130b11c9 removed init_count from IO_CACHE.
Added missing mutex_unlock to slave replication code.
2002-06-05 23:04:38 +03:00
jani@hynda.(none)
ff7016e962 Fixed a bug. 2002-05-29 15:29:42 +03:00
monty@hundin.mysql.fi
7d276c3bb8 Portability fix 2002-04-30 16:40:46 +03:00
sasha@mysql.sashanet.com
08623f050c replication bugfixes 2002-04-25 07:33:02 -06:00
sasha@mysql.sashanet.com
d7b7e09293 reckless slave option
bison 1.34 yacc rule compliance
more robust handling of relay log corruption
2002-04-15 17:09:30 -06:00
sasha@mysql.sashanet.com
14603a3620 relay_log_space_limit
DBUG_ macro cleanup
buffer boundary cleanup
This changeset, although not fully tested, works for me better than 
anything I've had so far, including what is in the repository. I will 
push it unless something crashes while I am writing this :-)
2002-04-01 21:46:23 -07:00
sasha@mysql.sashanet.com
be388422eb replication updates. This changeset seems to be working fine on test systems.
If no problems are discovered in the next week, this will make the replication
code ready for 4.0.2 release.
2002-03-30 12:36:05 -07:00
sasha@mysql.sashanet.com
a664ca007d fixed the use of unitialized variable - code now works on the test system
of one of our users which replicates from a live server. So I now have a
lot of confidence in it and will push. It passes all tests, so I if I broke
somebody's code in 3.23 merge this is your fault - you should have had a good test
case :-)
2002-03-02 22:00:37 -07:00
sasha@mysql.sashanet.com
6980a24e9d fixes for slave backward compat
fixed bug in LOAD DATA FROM MASTER
fixed rpl000001.result
Slave now replicates 3.23 master, with the exception of LOAD DATA INFILE, 
which is still buggy. Will push this one after the pull/merge
2002-02-07 15:29:46 -07:00
monty@hundin.mysql.fi
6a1b08cbd4 Added --sql-mode=NO_UNSIGNED_SUBTRACTION 2002-01-30 15:32:48 +02:00
monty@hundin.mysql.fi
be46289855 New error messages
Test of unsigned BIGINT values
Fixes for queries-per-hour
Cleanup of replication code (comments and portability fixes)
Make most of the binary log code 4G clean
Changed syntax for GRANT ... QUERIES PER HOUR
2002-01-29 18:32:16 +02:00
sasha@mysql.sashanet.com
7275dcef35 misc replication bugfixes including some needed modifications in IO_CACHE
likely() and unlikely() branch prediction compiler hint macros
clean-up of comments
2002-01-26 22:26:24 -07:00
sasha@mysql.sashanet.com
8e43ad12c3 post-merge fixes, including slave-skip-errors backport
fixed too quick timeout in mysql-test-run which caused a race with the
 new server getting started before the old one completely finished 
 shutdown. This should fix the pid warning we've been getting as well as
 inconsistent results when running tests with the manager
2002-01-22 15:05:11 -07:00
sasha@mysql.sashanet.com
56129ce634 Here comes a nasty patch, although I am not ready to push it yet. I will
first pull, merge,test, and get it to work.

The main change is the new replication code - now we have two slave threads
SQL thread and I/O thread. I have also re-written a lot of the code to 
prepare for multi-master implementation. 

I also documented IO_CACHE quite extensively and to some extend, THD class.
2002-01-19 19:16:52 -07:00
sasha@mysql.sashanet.com
f7acf09d9c slave-skip-errors
added extra/mysql_install.c - will work on it in 4.0, but it does not hurt
to have it sit in 3.23 tree for now since it will eventually be backported 
to 3.23 anyway
2001-12-12 18:55:33 -07:00
sasha@mysql.sashanet.com
beaf95b09d work to enable reading 3.23 logs - not yet finished
moved fail-safe replication routines from sql_repl.cc to repl_failsafe.cc
write start event only in the first log
2001-11-10 22:24:12 -07:00
monty@work.mysql.com
1805368556 merge 2001-10-03 18:00:38 +02:00
monty@hundin.mysql.fi
f5a53594c8 Added usage of --master-retry-count to make mysql-test-run safer. 2001-10-03 16:27:20 +03:00
sasha@mysql.sashanet.com
09eda84f2e LOAD DATA INFILE is now replicated properly, except for cleanup on
Stop event and bugs the test suite could not catch
Did some big restructuring of binlog event classes - most important
change is that now each event class has exec_event method and one does
not need to modify slave core code to add a new event. Slave code is
now much smaller and easier to read
2001-08-03 15:57:53 -06:00
sasha@mysql.sashanet.com
b5f76be024 merged with 3.23 2001-07-17 16:23:36 -06:00
sasha@mysql.sashanet.com
14c23716a6 added slave_net_timeout 2001-07-17 14:22:52 -06:00
sasha@mysql.sashanet.com
5527f9bfc3 mysql-test/t/rpl_sporadic_master.test
fixed test case to produce same results on txn-enabled binary. 
    temporary fix - permanent fix is it make mysqld behave the same with
    MyISAM on auto_increment insert after delete from tbl_name regardless
    of how the binary was compiled
sql/slave.cc
    fixed concurrency bug with log_seq
sql/slave.h
    last_log_seq needs to be updated atomically with pos
sql/sql_repl.cc
    cleared up comment and fixed concurrency bug
2001-07-10 18:08:37 -06:00
sasha@mysql.sashanet.com
27561841d1 merged latest changes in 3.23 2001-07-07 15:35:23 -06:00