Go Back   HowtoForge Forums | HowtoForge - Linux Howtos and Tutorials > Linux Forums > HOWTO-Related Questions

Do you like HowtoForge? Please consider supporting us by becoming a subscriber.
Reply
 
Thread Tools Display Modes
  #1  
Old 16th March 2008, 01:34
tfunky tfunky is offline
Member
 
Join Date: Jan 2007
Posts: 85
Thanks: 4
Thanked 2 Times in 2 Posts
Default Mysql Load Balancer Reccomendation

Hi All,

I just built and tested the master-master mysql5 pair on Etch (whoohoo) !

I was going to put a load balancer pair in front of them so I could use a VIP, etc.

I went to follow the directions for ultra monkey on debian like I did in the past, but it's for sarge. After snooping around the ultramonkey website I don't see a etch version.

All that being said...

What's the easiest way to do the equivalent with etch?

Or is there a better way to go about doing this? (ie just install haproxy or ldirector, or heartbeat, etc)

I'm love to hear your recommendations!

Thanks!

Tfunk
Reply With Quote
Sponsored Links
  #2  
Old 16th March 2008, 14:52
falko falko is offline
Super Moderator
 
Join Date: Apr 2005
Location: Lneburg, Germany
Posts: 41,701
Thanks: 1,900
Thanked 2,740 Times in 2,575 Posts
Default

You can use haproxy and heartbeat (or keepalived) for this.
__________________
Falko
--
Download the ISPConfig 3 Manual! | Check out the ISPConfig 3 Billing Module!

FB: http://www.facebook.com/howtoforge

nginx-Webhosting: Timme Hosting | Follow me on:
Reply With Quote
  #3  
Old 18th March 2008, 07:57
tfunky tfunky is offline
Member
 
Join Date: Jan 2007
Posts: 85
Thanks: 4
Thanked 2 Times in 2 Posts
Default

Hey Falko!

I took your advice and setup a HAProxy/heartbeat pair.

It took some considerable reading to pull it off as it's not really made for that and most people use it for web proxying.

That being said, I thought I'd paste the revelent part of the config here to save others some time if they attempt it This may not be the best way, but it is working.

Code:
listen db_proxy 192.168.1.190:3306
        mode tcp
       stats enable
       stats auth someuser:somepassword
       balance roundrobin
     #  cookie JSESSIONID prefix
     #  option httpclose
     #  option forwardfor
     #  option httpchk HEAD /check.txt HTTP/1.0
       server c1 192.168.1.191
       server c2 192.168.1.192
I can't seem to get the stats to work though. I'm not sure what I have messed up. I thought stats enabled and the password was all that was needed, but apparently I'm missing something.

Hopefully that helps someone!

Thanks for your help Falko!
Reply With Quote
The Following User Says Thank You to tfunky For This Useful Post:
falko (19th March 2008)
  #4  
Old 19th March 2008, 14:41
falko falko is offline
Super Moderator
 
Join Date: Apr 2005
Location: Lneburg, Germany
Posts: 41,701
Thanks: 1,900
Thanked 2,740 Times in 2,575 Posts
Default

I think the problem is that you've enabled the stats for a MySQL connection, not a web connection, but that's just a guess. I haven't tried this myself...
__________________
Falko
--
Download the ISPConfig 3 Manual! | Check out the ISPConfig 3 Billing Module!

FB: http://www.facebook.com/howtoforge

nginx-Webhosting: Timme Hosting | Follow me on:
Reply With Quote
  #5  
Old 20th March 2008, 03:05
tfunky tfunky is offline
Member
 
Join Date: Jan 2007
Posts: 85
Thanks: 4
Thanked 2 Times in 2 Posts
 
Default

I've played with the stats thing some more and I've got it working...I don't know if this is the best way...but at least it's working....

I added a "new" proxy

Code:
    # catches any URI and returns the status page.
listen stats :8080
        mode http
        balance roundrobin
        stats uri /
and moved the stats enable to the defaults section.

With that stanza you can access the http://<your virtual ip>:8080 and see the stats.

Thanks for getting me to look in the right place
Reply With Quote
The Following User Says Thank You to tfunky For This Useful Post:
falko (20th March 2008)
Reply

Bookmarks

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Load balancing on Fedora with Heartbeat (MySQL Cluster) rwillie6 HOWTO-Related Questions 7 17th December 2009 12:32
Management/system config/settings & /server/settings not working!! dactor Installation/Configuration 9 6th February 2008 09:11
Question about the hardware requirement for mysql cluster with load balancing??? johN5Five^ HOWTO-Related Questions 3 12th April 2007 17:06
No luck mysql clustering and load balancer with Fedora Core 4 mobilehunter HOWTO-Related Questions 2 21st October 2006 09:26
Howto suggestion suse PhP ver 4 + Ver 5 wwparrish Suggest HOWTO 11 7th August 2006 13:29


All times are GMT +2. The time now is 03:43.


Powered by vBulletin® Version 3.8.7
Copyright ©2000 - 2014, vBulletin Solutions, Inc.