Hyper-v High Availability 1: Create and configure ISCSI

Source: Internet
Author: User

Hyper-v High Availability 1: Create and configure ISCSI
Hyper-v High Availability 1: Create and configure ISCSI

In the previous blog, we introduced how to migrate Hyper-v virtual machines in real time without clusters or shared storage, but non-cluster virtual machines, real-time migration of virtual machines is still very risky. It is not the best practice for enterprise deployment. dedicated storage devices and Failover clusters must be used to achieve high availability of virtual machines to ensure business continuity. This blog will show you how to use ISCSI to build a Hyper-V cluster in a multi-cluster environment and implement real-time migration of virtual machines under the cluster.

Failover clusters are a feature of Windows Server. Since the first introduction of clusters in Windows NT 4.0 Enterprise Edition, failover clusters provide high availability for Server loads and are composed of a group of independent servers, and collaborate with each other to improve the availability of services and applications. When a computer in the cluster fails, the resources will be redirected to another computer in the cluster, the workload is also distributed to another computer in the cluster. Failover clusters can be used to ensure that users have almost always the permissions to access important server-based resources. Failover clusters are designed for applications with long-running memory statuses or large and frequently-updated data statuses. These applications are called State applications and include database applications and message applications. Typical use of failover clusters includes file servers, print servers, database servers, and message servers.

The Windows Server failover cluster provides a critical technology for the Hyper-V infrastructure that not only provides availability, but also provides portability. An important concept of virtualization and private cloud environments is to break the binding relationship between loads and underlying physical resources, failover clusters use real-time migration technology to move and place virtual machines between different physical hosts without stopping services. If a node fails, the VM is distributed to other cluster nodes. In earlier versions of Windows Server, any resource can be distributed to the cluster nodes that carry the least number of virtual machines. In Windows Server 2012, this logic is improved to determine the way virtual machines are distributed based on the memory size of the host machine, the most common binding resource. Each virtual machine can be placed in the node with the most idle memory resources, and the resource requirements of each virtual machine are evaluated.

Next we will start today's experiment: Using failover clusters to achieve high availability of Hyper-v

The following table shows the experiment environment:

Computer Name

Operating System

IP

DNS

Cluster address

DC

Windows Server 2012 R2

192.168.1.1

192.168.1.1

 

NWEB01

Windows Server 2012 R2

PUBLIC: 192.168.1.2

HART: 172.16.1.1

192.168.1.1

Vmmcluser

192.168.1.100

NWEB2

Windows Server 2012 R2

PUBLIC: 192.168.1.3

HART: 172.16.1.2

192.168.1.1

OK. I believe everyone will definitely upgrade a domain controller. If not, you can find an article about domain control in my blog. So today's experiment begins with configuring the shared storage ISCIS.

1. Install shared storage (ISCSI)

For shared storage of failover clusters, we can use SAN storage or ISCIS. Because I am an experimental environment, ISCSI is used. For ISCSI, Microsoft uses it as a role in Windows Server 2012 R2, you can add them. The following shows how to add ISCSI to Windows Server 2012 R2:

Open the Server Manager on the computer that has been promoted to the domain controller:

Click "add role and function ":

Click next:

Expand "file storage service"> "file and ISCSI service" in the order of adding server roles, select "ISCSI target server", and click "Next:

On the confirmation page, confirm that there is no problem. Click to install:

The installation is successful. Click Close.

2. Use ISCIS to create a virtual disk:

Open the Server Manager:

Click "file and storage service" on the left side ":

Click "ISCSI ":

As you can see, there is no shared storage currently. Click "to create an ISCSI virtual disk, please start the" Create ISCSI Virtual Disk "Wizard ":

The new ISCSI Virtual Disk wizard dialog box is displayed. In the select ISCSI Virtual Disk location option, you can specify the storage location of the Virtual Disk created by ISCSI. Here, I select an edisk and click Next:

Enter the name and description of the virtual disk at the "ISCIS Virtual Disk name" and click "Next:

Specify the size of the virtual disk here, because the system will default the disk with a smaller capacity as the arbitration disk, so I gave the Q Disk 1 GB, click Next:

In the ISCSI target location, select create ISCSI target and click Next:

Enter the target name and click Next:

In the Access Server location, click Add:

Select "Enter the value of the selected type", select "IP" in the type location, enter the IP addresses of the two cluster nodes in the value location, and click OK:

After adding, click Next:

Keep the default value here. Click next:

Click create:

Created successfully. Click CLOSE:

You can see that the virtual disk has been created successfully! However, currently, we only have one arbitration disk and one data disk. Therefore, we need to right-click the disk in the blank space:

Click "create ISCSI Virtual Disk ":

As before, you need to select the location of the virtual disk here. Select the elastic drive and click Next:

Enter the disk Name and description, and click Next:

 

Enter the disk size and click Next:

Keep the default value here. Click next:

Click create:

After the creation is complete, Click CLOSE:

We can see the new two disks Q and S!

3. Connect a cluster node to a virtual disk:

Open the Server Manager of the cluster node:

Click "tool"-"ISCSI initiator ":

In the displayed dialog box, click:

You can see the "ISCSI initiator" pop-up ":

Enter the IP address of the ISCSI target server in the target location and click "quick link ":

You can see that you have successfully linked to the ISCSI initiator. Click Finish:

Make sure the target is connected. Click OK.

Open the Server Manager and click "Tools"-"Computer Management ":

In the "Computer Management" dialog box, click "disk management ":

We can see that the two Virtual Disks just added:

Right-click the Virtual Disk in this table shard and click "online ":

After the two disks are online, right-click the disk and click "initialize disk ":

Click OK:

Right-click two Virtual Disks and click Create simple volume:

Click next:

Note: assign a drive letter here. We recommend that you use the same drive letter for both nodes:

Click "OK:

Repeat the preceding operations on another cluster node. We will not describe them here!

4. Test

Open my computer on the cluster node to see if the cluster disk is mounted:

We can see that the two new cluster disks Q and S have been successfully linked!

Related Article

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.