RE: Add a replicated DB w/o rebooting the server
Your clients "should" be able to handle the restart.
* What if there were a network glitch? The clients should be able to
reconnect when they notice the dropped connection.
* What if the slave has a disk crash? The clients should automatically
switch to another slave.
* What if an earthquake wipes out the data center? Then you need
replication to a remote site.
* Etc.
Adding a line to my.cnf and restarting the slave is minor compared to
all the other things that can (and eventually will) go wrong.
By having two (or more) slaves behind a load balancer, one can simply
(tediously) restart one slave at a time.
> -----Original Message----- > From: Oriol Capsada [mailto:oriolc@voztele.com] > Sent: Wednesday, October 31, 2007 4:52 AM > To: replication@lists.mysql.com > Subject: Re: Add a replicated DB w/o rebooting the server > > > Eric Frazier wrote: > > Oriol Capsada wrote: > >> Hi Norbert, > >> > >> Ok, when I said reboot the server I was referring to restart the > >> mysql proceess. I see that my expression was not clear enough :) > >> > >> And I would prefer not to restart the mysql process because some > >> services may not have persistent connections. Therefore, > if I restart > >> the server those connections would be lost... > >> > >> So, any way to add the database without having to restart > the mysql > >> process? > >> > >> Regards, > >> Oriol. > >> > >> Norbert Tretkowski wrote: > >>> Am Mittwoch, den 31.10.2007, 11:21 +0100 schrieb Oriol Capsada: > >>> > >>>> Everything I have read about adding a new database to a slave > >>>> replication talks about adding a new line in the > configuration file > >>>> (for example a replicate-wild-do-table) and then restart > the server. > >>>> > >>>> Is it possible to do so without having to reboot the server? > >>>> > >>> > >>> You don't need to reboot the whole server, it's enough to > restart just > >>> the mysqld server process (e.g. with '/etc/init.d/mysql restart'). > >>> > >>> Norbert > >>> > >>> > >>> > >> > >> > > > > You just need to NOT specify all of the dbs you are > replicating. It is > > like a tradition that people do that, but not needed. Once > you specify > > one DB however, you imply that the others are not to be > replicated. I > > have done this before and create database statements do get > replicated > > as well. > > > > Eric > > > > > > As DBs can't be added without rebooting I suppose that this > is what I am > finally going to do, not specify the DB names and replicate > all of them. > > Thanks for your answers. > > Regards, > Oriol. > > > > -- > MySQL Replication Mailing List > For list archives: http://lists.mysql.com/replication > To unsubscribe: > http://lists.mysql.com/replication?unsub=rjames@yahoo-inc.com > >
--
MySQL Replication Mailing List
For list archives:
http://lists.mysql.com/replication
To unsubscribe:
http://lists.mysql.com/replication?unsub=lists@pantek.com
Received on Wed Oct 31 11:18:05 2007
This archive was generated by hypermail 2.1.8
: Fri Jul 04 2008 - 00:24:15 EDT
|