Mysql master<->master replication getting entirely messed up. What config do I need to tweak?

dormando dormando at rydia.net
Wed Mar 19 19:08:09 UTC 2008


Are you writing to both sides?

MogileFS _only_ supports sending writes to a *single* database. This is 
partially due to how FID locking works, and partially because it's 
otherwise completely untested.

I run mogilefs under master-master setups, with the following concessions:

- auto_increment_offset is used to ensure each side gets unique values.
- writes only go to one *active* side.

Either done via an HA VIP or explicit configuration.

You can use the slave configuration and, say, a secondary HA VIP to use 
the internal readonly slave support to send some queries to the second 
machine.

I've never had to even think about running mogilefs with active 
multimaster due to load... It's always been pathetically low.

-Dormando

Clinton Goudie-Nice wrote:
> Greetings all,
> 
> We've been bulk testing our multimaster setup with a tracker attached to 
> each master, but we're seeing some odd behavior that I'm hoping I'm just 
> missing something obvious on.
> 
> After a round of bulk testing, the stats for the different trackers is 
> different. Additionally, after complete (and even after a restart), the 
> trackers are just going nuts with queries to the database servers.
> 
> Stats against node 1:
> 
> mogadm --tracker tracker01fs:6001 stats
> Statistics for replication...
>   domain               class        devcount      files
>   -------------------- ----------- ---------- ----------
>   testdomain           testclass           1        187
>   testdomain           testclass           2      48309
>   -------------------- ----------- ---------- ----------
> 
> Stats against node 2:
> 
> mogadm --tracker tracker02fs:6001 stats
> Statistics for replication...
>   domain               class        devcount      files
>   -------------------- ----------- ---------- ----------
>   testdomain           testclass           1          2
>   testdomain           testclass           2      48494
>   -------------------- ----------- ---------- ----------
> 
> Additionally, I've seen times where I end up with files with a devcount 
> of 3 even though testclass has a devcount of 2.
> 
> Initially, my mogilefsd.conf file looked like this:
> 
> db_dsn DBI:mysql:mogilefs:somedbserver
> db_user root
> db_pass somepass
> conf_port 6001
> listener_jobs 20
> 
> After thinking this through for a bit, It occurred to me that I may need 
> replication to occur on only one tracker, and deletes to occur on only 
> one tracker, so...
> 
> On the tracker01 node in the mogilefsd.conf I set:
> 
> replicate_jobs 5
> delete_jobs 0
> 
> On the tracker02 node in the mogilefsd.conf I set:
> 
> replicate_jobs 0
> delete_jobs 5
> 
> Then I reran our bulk test, but it ended up out of sync again with the 
> stats shown above.
> 
> Do I need to set some (other) specific settings on each tracker that 
> says what to do and what not to do on that node, or is something else 
> going on here?
> 
> Thanks!
> 
> Clint
> 
> 
> Twelve Horses <http://web.twelvehorses.com/> 	Mobile 
> <http://web.twelvehorses.com/info_center/whitepaper/> 	Social 
> <http://web.twelvehorses.com/solutions/blogging_for_business/> 	Web 
> <http://web.twelvehorses.com/solutions/website_design/> 	Email 
> <http://web.twelvehorses.com/technology/>
> 
> 
> *Clinton Goudie-Nice*
> Architect / Senior Software Engineer
> cgoudie at twelvehorses.com <mailto:cgoudie at twelvehorses.com>
> Phone: 	+1.801.571.2665 ext 3264
> Mobile: 	+1.801.915.0629
> Fax: 	+1.801.571.2669
> LinkedIn: 	http://www.linkedin.com/in/cgoudie
> 
> 	
> *Twelve Horses*
> 13961 Minuteman Drive
> Suite 125
> Draper, UT 84020
> *www.twelvehorses.com <http://www.twelvehorses.com>*
> 
> 
> 
> 
> 



More information about the mogilefs mailing list