HA LAMP

Adrian Chapela achapela.rexistros at gmail.com
Wed Apr 11 12:31:15 BST 2007


Thomas Champagne escribió:
> Hi
> I would like to create a high availability LAMP. But I have only two
> machines.
> I have read the Streamline High Availability and Load Balancing :
> http://www.ultramonkey.org/3/topologies/sl-ha-lb-overview.html
>
> The situation :
> My config is available here :
> http://jay.bertrand.free.fr/blog/uploads/images/cluster.png
> I have two servers on Debian GNU/Linux Etch with IP : 10.5.195.40 and
> 10.5.195.41
> There are two services on each servers : Apache and Mysql.
> Each service have its IP and have a VIP address :
> 10.5.195.120 -> apache
> 10.5.195.121 -> Mysql
OK, In your case I will balance only apache and in the test includes a 
test with a mysql connection.

Apache 1 --> Mysql 1
Apache 2 --> Mysql 2

You need one PC more to use with keepalived, lvs director, ultramonkey ....

In the test you  can test a page of the server which connects with 
mysql... If mysql goes down.. all the server goes down and you have 
another server OK...
>
> The problem :
> Accessing services from a remote client (outside the cluster) to the 
> VIP is
> ok.
> But when the client is the cluster, it always connects on the local 
> machine.
>
> For example, when Apache connects to the VIP Mysql with PHP script, it
> always connect to the local Mysql.
It was ok. It's caused for ROUTES.
> So if Mysql is down on the local but up on the other, Apache can't 
> connect
> to Mysql.
>
> I have read that to solve the problem in the LVS HOwTO :
> http://www.austintek.com/LVS/LVS-HOWTO/HOWTO/LVS-HOWTO.LVS-DR.html#realserver_as_client_in_LVS-DR 
>
> But as it is written in the man page of iptables :
> "Please note: This target requires kernel support that might not  be
> available  in  official  Linux  kernel  sources  or
> Debian's packaged Linux kernel sources.  And if support for this 
> target is
> available for the specific Linux kernel source
> version, that support might not be enabled in the current Linux kernel
> binary."
> This command returns nothing :
> ls /lib/modules/2.6.18-4-686/kernel/net/ipv4/netfilter/ | grep ROUTE
>
> So, I can't use the target ROUTE.
> There is an other solution ?
>
> Thomas Champagne
> _______________________________________________
> LinuxVirtualServer.org mailing list - lvs-users at LinuxVirtualServer.org
> Send requests to lvs-users-request at LinuxVirtualServer.org
> or go to http://www.in-addr.de/mailman/listinfo/lvs-users
>


Search lvs-users Archives
Limit search to: Subject & Body Subject Author
Sort by: Reverse Sort

More information about the lvs-users mailing list