"VMC Labs" Create your SQL Cluster on Qcloud (2)

Source: Internet
Author: User

In the previous article we introduced how to build a set of domain environments in Qcloud standardization and how to avoid some pits in the production process, today we present another role in this demo-how to deploy and design shared storage sg.

Then set up the storage server to talk about how to do line separation on the Qcloud.

Q1, Qcloud provides the technology for multiple network cards for virtual machines, but how do you ensure that they are physically isolated?

A1: It is impossible to completely isolate, because not only is the Qcloud, most of the public cloud (including the international) at the bottom of the use of multiple network cards to do the team to carry out multi-card disaster, if you want to multiple vnet split corresponding to multiple physical network card is to increase the cost of server hardware, But so far there seems to be no public cloud manufacturer dare to claim that the full SDN (SDN means to block the hardware, the vnet can be randomly landed on a host of a network card, which at least we are on the agenda), if there is a brother know this resource Welcome correction:)

Q2, since can not completely physical isolation is there no way to solve the problem of line separation?

A2: Complete physical separation of the perfect solution is almost impossible, for the domestic public cloud is also a bit difficult, so as far as possible to avoid a single point of failure or possible, there is a solution, now qcloud virtual machine delivery strategy is as far as possible scattered in different host, That means that the possibility of a single physical NIC for multiple VMS on the same host is negligible, and to ensure this information, a ticket can be submitted to ensure that the problem is:

650) this.width=650; "Style=" background-image:none;padding-left:0px;padding-right:0px;float:none; Border-top-width:0px;border-bottom-width:0px;margin-left:auto;border-left-width:0px;margin-right:auto; padding-top:0px; "title=" wps4d2.tmp "border=" 0 "alt=" wps4d2.tmp "src=" http://s3.51cto.com/wyfs02/M02/89/F9/ Wkiol1gjabhgu1_yaaawjaiyfuu756.jpg "width=" 292 "height=" 178 "/>

Okay, after answering the above questions, we began to get to the point, the following is the server information needed today (in this case, the external network traffic is mainly to facilitate the demo, but the production environment does not recommend the use of external network bandwidth):

Number

Server name

Production IP

Storage IP

Heartbeat IP

Foreign VIP

1

Q-dc01

192.168.108.188

No

No


2

Q-sg01

192.168.108.206

10.11.11.231

No


3

Q-sql01

192.168.108.254

10.11.11.

10.10.10.2


4

Q-sql02

192.168.108.114

10.11.11.

10.10.10.234


About SG, which is used as a SQL cluster shared storage, the storage function is divided into three blocks, one piece as the quorum disk, a piece as production data, a piece as a spare (not enabled reserved space).

The following schemas are involved:

650) this.width=650; "Style=" background-image:none;padding-left:0px;padding-right:0px;float:none; Border-top-width:0px;border-bottom-width:0px;margin-left:auto;border-left-width:0px;margin-right:auto; padding-top:0px; "title=" wps4d3.tmp "border=" 0 "alt=" wps4d3.tmp "src=" http://s3.51cto.com/wyfs02/M01/89/F9/ Wkiol1gjabkdhqwraabgiae4-ug607.jpg "width=" 408 "height=" 447 "/>

Okay, Get Started:

1, the creation of multiple network cards as a secondary network card to add to the corresponding CVM, which is temporarily not supported from the console directly new (already fast on-line function)

650) this.width=650; "Style=" background-image:none;padding-left:0px;padding-right:0px;float:none; Border-top-width:0px;border-bottom-width:0px;margin-left:auto;border-left-width:0px;margin-right:auto; padding-top:0px; "title=" wps4d4.tmp "border=" 0 "alt=" wps4d4.tmp "src=" http://s3.51cto.com/wyfs02/M02/89/FD/ Wkiom1gjablgrzr5aaaxd3ijis0052.jpg "width=" "height="/>

So let's add it through the API.

You can refer to the following two articles:

A,Https://www.qcloud.com/doc/api/245/%E5%88%9B%E5%BB%BA%E7%A7%81%E6%9C%89%E7%BD%91%E7%BB%9C

B,https://www.qcloud.com/doc/product/215/5850

(Remember to apply for API authorization first)

650) this.width=650; "Style=" background-image:none;padding-left:0px;padding-right:0px;float:none; Border-top-width:0px;border-bottom-width:0px;margin-left:auto;border-left-width:0px;margin-right:auto; padding-top:0px; "title=" wps4e5.tmp "border=" 0 "alt=" wps4e5.tmp "src=" http://s3.51cto.com/wyfs02/M02/89/F9/ Wkiol1gjabpsvm5laaayuynryjo939.jpg "width=" 558 "height=" "/>"

2, after the completion of the creation to use Describenetworkinterfaces Traversal network card (using the API created by the network card will not display in the interface, https://www.qcloud.com/doc/api/245/4814)

650) this.width=650; "Style=" background-image:none;padding-left:0px;padding-right:0px;float:none; Border-top-width:0px;border-bottom-width:0px;margin-left:auto;border-left-width:0px;margin-right:auto; padding-top:0px; "title=" wps4e6.tmp "border=" 0 "alt=" wps4e6.tmp "src=" http://s3.51cto.com/wyfs02/M01/89/FD/ Wkiom1gjabtdr4zeaaboxz012mi410.jpg "width=" 558 "height=" 103 "/>

3, the network adapter to bind (currently can only through the API, https://www.qcloud.com/doc/api/245/4820):

650) this.width=650; "Style=" background-image:none;padding-left:0px;padding-right:0px;float:none; Border-top-width:0px;border-bottom-width:0px;margin-left:auto;border-left-width:0px;margin-right:auto; padding-top:0px; "title=" wps4e7.tmp "border=" 0 "alt=" wps4e7.tmp "src=" http://s3.51cto.com/wyfs02/M00/89/F9/ Wkiol1gjabsrawsqaabsimdzxus677.jpg "width=" 558 "height=" 145 "/>

PS: Note that Networkinterfaceid is not a name and will not be visible on the console after success, but can be seen inside the system

650) this.width=650; "Style=" background-image:none;padding-left:0px;padding-right:0px;float:none; Border-top-width:0px;border-bottom-width:0px;margin-left:auto;border-left-width:0px;margin-right:auto; padding-top:0px; "title=" wps4f7.tmp "border=" 0 "alt=" wps4f7.tmp "src=" http://s3.51cto.com/wyfs02/M01/89/F9/ Wkiol1gjabxgecdgaaa8u-naiiy082.jpg "width=" 558 "height=" 153 "/>

650) this.width=650; "Style=" background-image:none;padding-left:0px;padding-right:0px;float:none; Border-top-width:0px;border-bottom-width:0px;margin-left:auto;border-left-width:0px;margin-right:auto; padding-top:0px; "title=" wps4f8.tmp "border=" 0 "alt=" wps4f8.tmp "src=" http://s3.51cto.com/wyfs02/M02/89/F9/ Wkiol1gjabbcjwd0aaa_yqj8vzo980.jpg "width=" 558 "height=" 127 "/>

4, using the same way to create the network card, confirm that two SQL sub-machine can obtain the NIC (three pieces, 1 pieces of production, 1 heartbeats, 1 pieces of storage), here stole the lazy under the internal system to see the corresponding relationship is correct:

650) this.width=650; "Style=" background-image:none;padding-left:0px;padding-right:0px;float:none; Border-top-width:0px;border-bottom-width:0px;margin-left:auto;border-left-width:0px;margin-right:auto; padding-top:0px; "title=" wps4f9.tmp "border=" 0 "alt=" wps4f9.tmp "src=" http://s3.51cto.com/wyfs02/M02/89/F9/ Wkiol1gjababsscgaabbovnowmk019.jpg "width=" 558 "height=" 103 "/>

(Storage network, two SQL nodes, one storage node)

650) this.width=650; "Style=" background-image:none;padding-left:0px;padding-right:0px;float:none; Border-top-width:0px;border-bottom-width:0px;margin-left:auto;border-left-width:0px;margin-right:auto; padding-top:0px; "title=" wps4fa.tmp "border=" 0 "alt=" wps4fa.tmp "src=" http://s3.51cto.com/wyfs02/M00/89/F9/ Wkiol1gjabfstsq3aaay4y9dz7s636.jpg "width=" 558 "height=" "/>"

(Heartbeat network, two SQL nodes)

5, to ensure that the heartbeat network, storage Network 22 is a pass (slightly).

Appendix, this article slot point:

A) Creating an elastic NIC to a bound host this process is too test operation and maintenance strength, the code of the operation and maintenance of children's shoes directly determines whether the architecture is successful, because the creation of an elastic network card requires API calls to see the elastic network card requires API calls, binding elastic network card also requires API calls. (this point blogger has directly contacted the corresponding product children's shoes, product children's shoes response in December will be online GUI create network card These functions, the API is mainly convenient for automated scene calls)

b) Here in fact there is more optimization of the scheme to do network isolation, that is, the private network is also different, but this is the blogger thought, create a network card also need to specify the subnet ID, it means to modify the network card weight, according to slot a This is fatal, so Bo Master in accordance with the specification and architecture considerations, strongly recommend separation, operation

I. Creating a VPC private network

650) this.width=650; "Style=" background-image:none;padding-left:0px;padding-right:0px;float:none; Border-top-width:0px;border-bottom-width:0px;margin-left:auto;border-left-width:0px;margin-right:auto; padding-top:0px; "title=" wps50b.tmp "border=" 0 "alt=" wps50b.tmp "src=" http://s3.51cto.com/wyfs02/M00/89/F9/ Wkiol1gjabjtl3yraaa7avejezi144.jpg "width=" 456 "height=" 267 "/>

(Create a storage heartbeat in the same way)

II. The effect is as follows:

650) this.width=650; "Style=" background-image:none;padding-left:0px;padding-right:0px;float:none; Border-top-width:0px;border-bottom-width:0px;margin-left:auto;border-left-width:0px;margin-right:auto; padding-top:0px; "title=" wps50c.tmp "border=" 0 "alt=" wps50c.tmp "src=" http://s3.51cto.com/wyfs02/M01/89/FA/ Wkiol1gjabirofsuaaayn2siryu175.jpg "width=" 558 "height=" 124 "/>

III. Next, SQL01, SQL02 re-create the NIC and bind it according to the steps in the body (cannot be modified directly, see slot three).

650) this.width=650; "Style=" background-image:none;padding-left:0px;padding-right:0px;float:none; Border-top-width:0px;border-bottom-width:0px;margin-left:auto;border-left-width:0px;margin-right:auto; padding-top:0px; "title=" wps50d.tmp "border=" 0 "alt=" wps50d.tmp "src=" http://s3.51cto.com/wyfs02/M02/89/FD/ Wkiom1gjabmavgtiaabdshdfgqa519.jpg "width=" 535 "height=" "/>

c) Modify the elastic network card API Modifynetworkinterface can only modify the network card name and network card description, if you want to change the network card, to go through the host network interface-Remove the elastic network card-Create a new elastic network card-binding host. And all of that, yes, still has to be done through the API (see slot two).

650) this.width=650; "Style=" background-image:none;padding-left:0px;padding-right:0px;float:none; Border-top-width:0px;border-bottom-width:0px;margin-left:auto;border-left-width:0px;margin-right:auto; padding-top:0px; "title=" Logo_thumb "border=" 0 "alt=" logo_thumb "src=" http://s3.51cto.com/wyfs02/M01/89/FA/ Wkiol1gjabqjy6ufaaeqmfweoom723.png "width=" 534 "height=" 351 "/>

This article from "Vmcloud" blog, declined reprint!

"VMC Labs" Create your SQL Cluster on Qcloud (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.