Linux using Haproxy to build a Web cluster (2)

Source: Internet
Author: User
Tags haproxy

Linux using haproxy to build a web cluster (2)

Case TWO:

First, experimental topological diagram

650) this.width=650; "style=" Float:none; "title=" Picture 1.png "src=" https://s3.51cto.com/wyfs02/M00/9A/7A/ Wkiol1lwh0fqqow1aadcp5iqmy4560.png "alt=" Wkiol1lwh0fqqow1aadcp5iqmy4560.png "/>

Second, Experimental Objectives: use keepalived+haproxy for dual standby and load balancing.

Third, Lab Environment:

650) this.width=650; "style=" Float:none; "title=" Picture 2.png "src=" https://s3.51cto.com/wyfs02/M00/9A/7A/ Wkiom1lwh0fhpncxaabivz6wln8278.png "alt=" Wkiom1lwh0fhpncxaabivz6wln8278.png "/>

each virtual machine firewall Iptables and NetworkManager Close

Four, Experimental Requirements:

Continue with the experiment of case one. K Eepalived ,

1.10:

Keepalived Configuration is the main

650) this.width=650; "style=" Float:none; "title=" Picture 3.png "src=" https://s3.51cto.com/wyfs02/M00/9A/7A/ Wkiol1lwh0is7driaaew7d2fcek616.png "alt=" Wkiol1lwh0is7driaaew7d2fcek616.png "/>

650) this.width=650; "style=" Float:none; "title=" Picture 4.png "src=" https://s4.51cto.com/wyfs02/M01/9A/7A/ Wkiom1lwh0jhi7-vaadrrhnftuc476.png "alt=" Wkiom1lwh0jhi7-vaadrrhnftuc476.png "/>

650) this.width=650; "style=" Float:none; "title=" Picture 5.png "src=" https://s3.51cto.com/wyfs02/M01/9A/7A/ Wkiol1lwh0nhk6ixaab5-vzl_-e916.png "alt=" Wkiol1lwh0nhk6ixaab5-vzl_-e916.png "/>

192.168.1.40 Server

The Haproxy configuration is the same as 1.10. the Ha service is started after configuration .

Keepalived configured as from, installed as with 1.10

650) this.width=650; "style=" Float:none; "title=" Picture 6.png "src=" https://s3.51cto.com/wyfs02/M01/9A/7A/ Wkiom1lwh0niyqrraaf3aygp15i447.png "alt=" Wkiom1lwh0niyqrraaf3aygp15i447.png "/>

650) this.width=650; "style=" Float:none; "title=" Picture 7.png "src=" https://s3.51cto.com/wyfs02/M02/9A/7A/ Wkiom1lwh0qralgzaabtjakdaqu714.png "alt=" Wkiom1lwh0qralgzaabtjakdaqu714.png "/>

Verify:

650) this.width=650; "style=" Float:none; "title=" Picture 8.png "src=" https://s2.51cto.com/wyfs02/M02/9A/7A/ Wkiol1lwh0qhxdezaacnllgascs844.png "alt=" Wkiol1lwh0qhxdezaacnllgascs844.png "/>

will hap/keep The primary server is down for testing:

650) this.width=650; "style=" Float:none; "title=" Picture 9.png "src=" https://s2.51cto.com/wyfs02/M00/9A/7A/ Wkiom1lwh0vxbzetaadcit0z1ci042.png "alt=" Wkiom1lwh0vxbzetaadcit0z1ci042.png "/>

This article is from the "Duyuheng" blog, make sure to keep this source http://duyuheng.blog.51cto.com/12879147/1943559

Linux using Haproxy to build a Web cluster (2)

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.