Actually, if you are using 4.1.1 optimize table does get passed to the
slave. This is from the 4.1.1 change log.
ANALYZE TABLE, OPTIMIZE TABLE, REPAIR TABLE, and FLUSH statements are now
stored in the binary log and thus replicated to slaves. This logging does
not occur if the optional NO_WRITE_TO_BINLOG keyword (or its alias LOCAL) is
given. Exceptions are that FLUSH LOGS, FLUSH MASTER, FLUSH SLAVE, and FLUSH
TABLES WITH READ LOCK are not logged in any case. For a syntax example, see
section 184.108.40.206 FLUSH Syntax.
> -----Original Message-----
> From: Jeremy Zawodny [mailto:Jeremy@stripped]
> Sent: Friday, May 14, 2004 2:46 PM
> To: Jim
> Cc: mysql@stripped
> Subject: Re: OPTIMIZE TABLE and mySQL replication
> On Fri, May 14, 2004 at 03:10:05PM -0400, Jim wrote:
> > Hi List,
> > What are some issues relating to using OPTIMIZE TABLE and replication?
> > Does running OPTIMIZE TABLE on a master DB cause the optimizations to be
> > passed on to the slaves?
> It does not. The command doesn't replicate.
> Jeremy D. Zawodny | Perl, Web, MySQL, Linux Magazine, Yahoo!
> <Jeremy@stripped> | http://jeremy.zawodny.com/
> [book] High Performance MySQL -- http://highperformancemysql.com/
> MySQL General Mailing List
> For list archives: http://lists.mysql.com/mysql
> To unsubscribe: