WO2014026387A1 - 一种云环境下虚拟应用双机的切换方法、装置及系统 - Google Patents

一种云环境下虚拟应用双机的切换方法、装置及系统 Download PDF

Info

Publication number
WO2014026387A1
WO2014026387A1 PCT/CN2012/080318 CN2012080318W WO2014026387A1 WO 2014026387 A1 WO2014026387 A1 WO 2014026387A1 CN 2012080318 W CN2012080318 W CN 2012080318W WO 2014026387 A1 WO2014026387 A1 WO 2014026387A1
Authority
WO
WIPO (PCT)
Prior art keywords
virtual
shared
ebs
ebs volume
management platform
Prior art date
Application number
PCT/CN2012/080318
Other languages
English (en)
French (fr)
Inventor
傅财斌
Original Assignee
华为技术有限公司
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by 华为技术有限公司 filed Critical 华为技术有限公司
Priority to PCT/CN2012/080318 priority Critical patent/WO2014026387A1/zh
Priority to EP12882921.5A priority patent/EP2800303B1/en
Priority to CN201280000892.4A priority patent/CN102972010B/zh
Publication of WO2014026387A1 publication Critical patent/WO2014026387A1/zh
Priority to US14/464,272 priority patent/US9448899B2/en

Links

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F11/00Error detection; Error correction; Monitoring
    • G06F11/07Responding to the occurrence of a fault, e.g. fault tolerance
    • G06F11/16Error detection or correction of the data by redundancy in hardware
    • G06F11/20Error detection or correction of the data by redundancy in hardware using active fault-masking, e.g. by switching out faulty elements or by switching in spare elements
    • G06F11/202Error detection or correction of the data by redundancy in hardware using active fault-masking, e.g. by switching out faulty elements or by switching in spare elements where processing functionality is redundant
    • G06F11/2023Failover techniques
    • G06F11/2033Failover techniques switching over of hardware resources
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F11/00Error detection; Error correction; Monitoring
    • G06F11/30Monitoring
    • G06F11/3003Monitoring arrangements specially adapted to the computing system or computing system component being monitored
    • G06F11/301Monitoring arrangements specially adapted to the computing system or computing system component being monitored where the computing system is a virtual computing platform, e.g. logically partitioned systems
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F11/00Error detection; Error correction; Monitoring
    • G06F11/07Responding to the occurrence of a fault, e.g. fault tolerance
    • G06F11/14Error detection or correction of the data by redundancy in operation
    • G06F11/1479Generic software techniques for error detection or fault masking
    • G06F11/1482Generic software techniques for error detection or fault masking by means of middleware or OS functionality
    • G06F11/1484Generic software techniques for error detection or fault masking by means of middleware or OS functionality involving virtual machines
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F11/00Error detection; Error correction; Monitoring
    • G06F11/07Responding to the occurrence of a fault, e.g. fault tolerance
    • G06F11/16Error detection or correction of the data by redundancy in hardware
    • G06F11/20Error detection or correction of the data by redundancy in hardware using active fault-masking, e.g. by switching out faulty elements or by switching in spare elements
    • G06F11/202Error detection or correction of the data by redundancy in hardware using active fault-masking, e.g. by switching out faulty elements or by switching in spare elements where processing functionality is redundant
    • G06F11/2023Failover techniques
    • G06F11/2025Failover techniques using centralised failover control functionality
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F11/00Error detection; Error correction; Monitoring
    • G06F11/07Responding to the occurrence of a fault, e.g. fault tolerance
    • G06F11/16Error detection or correction of the data by redundancy in hardware
    • G06F11/20Error detection or correction of the data by redundancy in hardware using active fault-masking, e.g. by switching out faulty elements or by switching in spare elements
    • G06F11/202Error detection or correction of the data by redundancy in hardware using active fault-masking, e.g. by switching out faulty elements or by switching in spare elements where processing functionality is redundant
    • G06F11/2038Error detection or correction of the data by redundancy in hardware using active fault-masking, e.g. by switching out faulty elements or by switching in spare elements where processing functionality is redundant with a single idle spare processing component
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F11/00Error detection; Error correction; Monitoring
    • G06F11/07Responding to the occurrence of a fault, e.g. fault tolerance
    • G06F11/16Error detection or correction of the data by redundancy in hardware
    • G06F11/20Error detection or correction of the data by redundancy in hardware using active fault-masking, e.g. by switching out faulty elements or by switching in spare elements
    • G06F11/202Error detection or correction of the data by redundancy in hardware using active fault-masking, e.g. by switching out faulty elements or by switching in spare elements where processing functionality is redundant
    • G06F11/2046Error detection or correction of the data by redundancy in hardware using active fault-masking, e.g. by switching out faulty elements or by switching in spare elements where processing functionality is redundant where the redundant components share persistent storage
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F2201/00Indexing scheme relating to error detection, to error correction, and to monitoring
    • G06F2201/815Virtual
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F2201/00Indexing scheme relating to error detection, to error correction, and to monitoring
    • G06F2201/85Active fault masking without idle spares

Definitions

  • the present invention relates to the field of communications technologies, and in particular, to a handover method, apparatus, and system for a virtual application dual-machine in a cloud environment. Background technique
  • the dual-machine mode is usually used to install dual-machine software on two machines, through FC-SAN (Fibre Channel Storage Area Network) or IP.
  • FC-SAN Fibre Channel Storage Area Network
  • IP IP Protocol Storage Area Network
  • - SAN IP Protocol Storage Area Network
  • Treating shared disks as a set of resources is controlled by dual-machine software such as Veritas Cluster Server.
  • Veritas Cluster Server For dual-system applications in warm standby and cold standby mode, when the original host unmounts the shared disk, the original standby disk mounts the shared disk, ensuring that only one machine can operate the shared disk at the same time.
  • the embodiment of the invention provides a method for switching a virtual application dual-machine in a cloud environment, so as to solve the problem that the host fails to release the control of the shared disk, and the standby device cannot obtain the control of the shared disk, thereby affecting the active/standby switchover.
  • the problem is a problem that the host fails to release the control of the shared disk, and the standby device cannot obtain the control of the shared disk, thereby affecting the active/standby switchover.
  • the embodiment of the present invention provides a method for switching a virtual application dual-machine in a cloud environment, where the virtual application dual-system includes a virtual host and a virtual standby device, and the method includes: the cloud management platform stores the associated state of the EBS volume by using the shared elastic block. Sending to the virtual standby device; receiving a request sent by the virtual standby device to release the association between the virtual host and the shared EBS volume; the cloud management platform canceling the association between the virtual host and the shared EBS volume Receiving a request sent by the virtual standby machine to associate the shared EBS volume; associating the virtual standby machine with the shared EBS volume, so that the virtual standby machine controls the shared EBS volume.
  • the embodiment of the present invention further provides a cloud management platform, which is used for switching a virtual application dual-machine in a cloud environment, and includes: a sending module, configured to send an association state of the shared elastic block storage EBS volume to the virtual standby machine;
  • the receiving module is further configured to: receive a request sent by the virtual standby to release the association between the virtual host and the shared EBS volume; and a de-association module, configured to cancel the virtual according to the receiving by the receiving module Resetting the association between the host and the shared EBS volume, and disassociating the virtual host from the shared EBS volume;
  • the receiving module is further configured to receive a request sent by the virtual standby machine to associate the shared EBS volume
  • an association module configured to associate the virtual standby machine with the shared EBS volume according to the request received by the receiving module to associate the shared EBS volume with the virtual standby device, so that the virtual standby device controls the Share EBS volumes.
  • the embodiment of the present invention further provides a virtual application dual-system in a cloud environment, which is used for switching a virtual application dual-machine in a cloud environment, where the system includes a cloud management platform, a virtual host, and a virtual standby device, specifically: a cloud management platform, configured to send an association state of the shared elastic block storage EBS volume to the virtual standby machine, where the virtual standby device is further configured to associate with the shared EBS volume according to the cloud management platform a state, detecting that the shared EBS volume is associated with the virtual host, sending a request to release the association between the virtual host and the shared EBS volume to the cloud management platform; the cloud management platform is further configured to receive Deleting the association between the virtual host and the shared EBS volume by the virtual standby device, and disassociating the virtual host from the shared EBS volume; the virtual standby device is further configured to send to the cloud The management platform sends a request for associating the shared EBS volume; the cloud management platform is further configured to associate the virtual standby device with the shared
  • the switching method of the virtual application dual-machine in the cloud environment disclosed by the embodiment of the present invention, the cloud management platform, and the virtual application dual-system are used to virtualize the application, and when the virtual host fails to release the control of the shared disk, the virtual The standby device can request the cloud management platform to remove the association between the virtual host and the shared disk, thereby obtaining control of the shared disk, and realizing the switching from the virtual host to the virtual standby device, thereby improving the reliability of the application dual-machine operation.
  • FIG. 1 is a schematic diagram of a virtual machine dual-machine switching method in a cloud environment according to an embodiment of the present invention
  • FIG. 2 is a schematic diagram of mounting an EBS volume for a virtual machine in an open source Xen virtualization environment according to an embodiment of the present invention
  • FIG. 3 is a schematic diagram of a virtual application dual-system in a cloud environment according to an embodiment of the present invention.
  • FIG. 4 is a schematic diagram of a startup procedure of a virtual application dual-machine in a cloud environment according to an embodiment of the present invention
  • FIG. 5 is a schematic diagram of an active handover procedure of a virtual application dual-machine in a cloud environment according to an embodiment of the present disclosure
  • FIG. 6 is a schematic diagram of a passive handover procedure of a virtual application dual-machine in a cloud environment according to an embodiment of the present disclosure
  • FIG. 7 is a schematic structural diagram of a cloud management platform according to an embodiment of the present disclosure.
  • FIG. 8 is another schematic structural diagram of a cloud management platform according to an embodiment of the present disclosure.
  • FIG. 9 is a structural diagram of a virtual application dual-system in a cloud environment according to an embodiment of the present invention. detailed description
  • FIG. 1 is a schematic diagram of a method for switching a virtual application dual-system in a cloud environment according to an embodiment of the present invention.
  • a virtual application dual-machine in a cloud environment includes a virtual host and a virtual standby. machine. Combined with the figure, the steps of the method are detailed as follows:
  • Step 101 The cloud management platform sends the association status of the shared EBS volume (Elastic block store) to the virtual standby machine.
  • EBS volume Elastic block store
  • the cloud management platform sends the association status of the shared EBS volume to the virtual standby device, which may be specifically: when the virtual host fails, the cloud management platform receives the query sharing EBS volume association status sent by the virtual standby machine.
  • the cloud management platform sends the association status of the shared EBS volume to the virtual standby machine according to the query request sent by the virtual standby machine.
  • the virtual standby machine first acquires the associated state of the shared EBS volume to avoid the situation that the virtual application dual-machine associates the EBS volume at the same time.
  • the virtual standby device can obtain the associated state of the shared EBS volume in multiple manners, for example, the cloud management platform periodically sends the associated state information of the shared EBS volume to the virtual standby device; The management platform sends a share to the virtual standby when it detects that the virtual host has failed (for example, the virtual host has failed, the virtual host's network connection has failed, or the virtual host's host has failed).
  • the virtual host for example, the virtual host has failed, the virtual host's network connection has failed, or the virtual host's host has failed.
  • Correlation status information of the EBS volume or sending a request for querying the shared state of the shared EBS volume to the cloud management platform when the virtual standby fails or the virtual host fails, and the cloud management platform sends the shared EBS volume to the virtual standby according to the request.
  • the association state and the like are not limited in this embodiment of the present invention.
  • Step 102 The cloud management platform receives a request sent by the virtual standby device to cancel the association between the virtual host and the shared EBS volume.
  • Step 103 The cloud management platform releases the association between the virtual host and the shared EBS volume.
  • the cloud management platform If the virtual host is faulty and does not actively release the control of the shared EBS volume, the cloud management platform first removes the association between the virtual host and the shared EBS volume, and then associates the shared EBS volume with the virtual standby to avoid The occurrence of the simultaneous association between the shared EBS volume and the virtual application dual machine.
  • Step 104 The cloud management platform receives the request for the associated shared EBS volume sent by the virtual standby device.
  • Step 105 The cloud management platform associates the virtual standby device with the shared EBS volume, so that the virtual standby device controls the shared EBS volume.
  • the virtual standby machine loads the EBS volume locally through the mount command, and the EBS volume can be controlled. This share is used like a local disk. EBS volume.
  • the switching scheme of the virtual application dual-machine in the cloud environment disclosed by the embodiment of the present invention causes a node to be unable to provide external services and cannot be perceived by other network elements when the virtual host and the network are faulty.
  • This node is called an island node.
  • the virtual standby machine can timely acquire the fault information and request the cloud management platform to release the virtual host's control of the shared EBS volume, thereby Enables the virtual standby machine to gain control over the shared EBS volume, enabling smooth switching from the virtual host to the virtual standby.
  • this embodiment discloses the application basis of the foregoing solution, the detailed content of the cloud environment.
  • the cloud management system manages a large number of computing devices and storage devices.
  • the cloud management platform virtualizes physical resources into logical resources through virtualization technology, thereby providing virtual computing resources (virtual machines) and virtual storage resources (such as EBS volumes) services. .
  • virtual computing resources virtual machines
  • virtual storage resources such as EBS volumes
  • the cloud management platform divides various devices into multiple areas for management. Each area has its own proprietary computing and storage devices, and resources cannot be shared between different areas.
  • the EBS volume is a virtual storage resource created by the cloud management platform in a specified area.
  • the size ranges from 1 GB to 1 TB.
  • the storage device NAS Network Attached Storage
  • SAN Storage Area Network
  • DAS Direct Attached Storage
  • the EBS volume is a file with the suffix vmdk. This file belongs to a VMFS (VMware Virtual Machine File System, a virtual machine file system provided by VMware). File system;
  • XenServer a linux-based virtualization server
  • the EBS volume can be either a file or a logical volume.
  • the EBS volume After the EBS volume is created successfully, you can call the virtualized environment API (Application Programming Interface, application programming interface. For example, call VirtualMachine.ReconfigVM_Task in the VMware virtualization environment; call xenapi.VBD.plug in the XenServer virtualization environment) It is associated with any virtual machine in the same area and can also be detached from the virtual machine.
  • the EBS volume After the EBS volume is successfully associated with the virtual machine, it is equivalent to adding a disk to the virtual machine.
  • the virtual machine can partition, format, and create various operations for the physical disk such as the file system. From the perspective of use, the EBS volume is equivalent to a pluggable disk, similar to a USB disk.
  • an EBS volume can be assigned to only one virtual machine or to multiple virtual machines.
  • an EBS volume can only be allocated. Use it for a virtual machine.
  • the EBS volume is managed by the cloud management platform, and the following restrictions can be imposed on the following: An EBS volume can be allocated to only one virtual machine at a time, and the EBS volume can be successfully separated from the original virtual machine. Assigned to other virtual machines for use.
  • FIG. 2 is a schematic diagram of a virtual office associated with an EBS volume in an open source Xen virtualization environment according to an embodiment of the present invention.
  • the case of associating EBS volumes for virtual machines in a VMware virtualization environment is similar and will not be described again.
  • a logical drive (such as LUN1 and LUN2) is provided by the S AN storage system, and a volume group (Volume Group) is managed by the cloud management platform to join multiple LUNs.
  • a logical volume (Logical Volume) is divided on the volume group, and an EBS volume corresponds to a logical volume (as shown in the figure, EBS1 corresponds to logical volume 4, and EBS2 corresponds to logical volume 6).
  • EBS1 corresponds to logical volume 4
  • EBS2 corresponds to logical volume 6
  • a virtual machine's disk it is also a disk corresponding to a logical volume.
  • the virtual machine 1 is associated with the logical volume 1; the virtual machine 2 and the virtual machine 3 are the virtual application dual machines created in the embodiment of the present invention, and the EBS1 is a shared disk of the dual machine, which is mentioned according to the foregoing embodiment.
  • the restrictions on the shared EBS volume, EBS1 can only be associated by virtual machine 2 or virtual machine 3 at the same time, can not be associated with two virtual machines at the same time; virtual machine 4 is not associated with the disk.
  • FIG. 3 is a schematic diagram of a virtual application dual-system in a cloud environment according to an embodiment of the present invention.
  • the application in the physical environment is composed of only one host and one standby machine, and in the embodiment of the present invention, the virtual application in the cloud environment
  • the two-machine system also includes a cloud management platform; the second is that the application between the two machines in the physical environment needs to have heartbeat information to keep in touch, so as to know the operation of the other party, and in the present invention
  • the virtual application dual-machine in the cloud environment no longer needs to keep contact with the heartbeat information, but the cloud management platform is used to know the running status of the other party.
  • the two virtual machines created by the cloud management platform include a virtual host and a virtual machine.
  • a disk In standby mode, a disk (EBS volume) is shared between the virtual host and the virtual standby.
  • the cloud management platform can create one or more EBS volumes.
  • One EBS volume shown in this figure is used for example and is not intended to limit the embodiments of the present invention.
  • the virtual machine and the EBS volume are both logical objects.
  • the virtual host's physical host fails, the virtual machine's dual-machine relationship is still stored in the cloud management platform. Therefore, only the new physical host needs to be specified to restart the virtual machine. Yes, it is not necessary to reconfigure the application duplex as in a two-machine system in the existing physical environment.
  • the heartbeat information is no longer needed to be contacted between the virtual application dual-machines in the cloud environment.
  • the cloud management platform provides the state information of the virtual application dual-machine.
  • the cloud management platform in the embodiment of the present invention can conveniently obtain the status information of the virtual application dual-machine, for example: the virtual machine health status (such as running, stopping, or faulting).
  • the virtual machine mounts the EBS volume information (such as whether it is mounted, when it is mounted, and the EBS volume ID of the mount), and the performance data of the virtual machine (such as CPU usage, disk or network I/O traffic, etc.). .
  • the objects to be monitored are generally divided into a resource group, and the resources are grouped, stopped, or monitored.
  • the dual-machine software in the virtual application dual-machine can obtain the current running state of the dual-machine from the cloud management platform through the monitoring script, and provide accurate virtual machine state information for the dual-machine monitoring. Because any virtual machine in the virtual application dual-machine can query the status information of another virtual machine through the cloud management platform, and because the performance of the cloud management platform is highly reliable, the island node can be minimized. appear.
  • the present embodiment separately describes the creation, startup, and handover of the virtual application dual-machine.
  • the user applies for creating a virtual application dual-machine through the portal of the cloud management platform, and specifies the size of the shared disk (ie, the EBS volume) while submitting the application.
  • the cloud management platform creates active and standby virtual dual-machines—virtual hosts and virtual standbys, and installs dual-machine software (such as Veritas Cluster Server) on the active and standby virtual dual-nodes to monitor dual-system applications.
  • set the health status such as running, stopping, or failing
  • the virtual machine mounts the EBS volume information (such as whether it is mounted, when it is mounted, and the EBS volume ID of the mount), and the performance data of the virtual machine (such as CPU). Occupancy, disk or network I/O traffic, etc.).
  • the cloud management platform creates a shared EBS volume while creating a virtual application dual-machine.
  • the number of shared EBS volumes can be one or more.
  • the created shared EBS volume can only be used by the pair of virtual applications.
  • the EBS volume is set at the same time. It can only be controlled by a single virtual machine.
  • FIG. 4 is a schematic diagram of a startup procedure of a virtual application dual-system in a cloud environment according to an embodiment of the present invention.
  • the virtual machine metadata may include a virtual machine ID and a virtual machine.
  • Information such as the mounted EBS volume ID, the mounted EBS volume ID, and the mount time.
  • the virtual host can acquire the virtual machine metadata through the web server (web server) service of the cloud management platform by the dual-machine startup script (script) installed thereon. For example, you can get the corresponding data by using the command: wget http://l 1.22.33.44/255/meta-data/.
  • Step 402 The virtual host applies to the cloud management platform for the associated shared EBS volume; the command line interface) tool, and initiates an AttachVolume request by using the EBS ID (EBS volume identifier) of the EBS volume obtained in step 401.
  • the management platform adds disks to the virtual host;
  • the CLI tool is provided by the cloud management platform and can run on any virtual machine. It only needs to be connected to the cloud management platform.
  • the EBS volume is controlled by the cloud management platform to ensure one EBS volumes can only be controlled by one virtual machine, completely eliminating the problem of splitting brains when dual-machine applications are used. .
  • the disk size can be distinguished only by the disk size. It is difficult to distinguish the purpose of each disk.
  • the cloud management platform can simultaneously set a name for each EBS volume when creating multiple shared EBS volumes, so that the virtual machine can specify the EBS volume when requesting to mount the EBS volume.
  • the name solves the problem that the existing physical dual-machine cannot distinguish between multiple shared disks, and can facilitate the writing of the two-machine script and reduce the problems caused by human error.
  • a virtual application dual-machine requires two shared disks, one CDR and one database file.
  • EBS1, EBS2 EBS volumes
  • the EBS volume name of the bill can be set to /dev/sdb
  • the EBS volume name of the stored database file can be set to /dev/sdc.
  • the request to mount the EBS volume can be as follows:
  • Step 403 The virtual host loads the EBS volume to the local device.
  • the virtual host loads the EBS volume locally through the mount command, and the shared EBS volume can be used like a local disk.
  • the switching of the virtual application dual-machine in the cloud environment can be divided into two situations: one situation is that the virtual host actively initiates the handover, and the virtual host switches to the virtual standby machine, which may be called active handover. Another situation is a failure that causes a virtual host to virtual standby to switch, which can be called passive switching. The following describes the switching steps of the virtual application dual-machine in these two cases.
  • FIG. 5 is a schematic diagram showing an active switching step of a virtual application dual machine in a cloud environment according to an embodiment of the present invention. Schematic diagram. The following steps are detailed in conjunction with the figure:
  • Step 501 The virtual host uninstalls the locally loaded shared EBS volume.
  • the virtual host can unmount the shared EBS volume loaded to the local by using the unmount command.
  • Step 502 The virtual host requests the cloud management platform to release the association with the shared EBS volume.
  • the virtual host can share the EBS volume by using a CLI tool provided by the cloud management platform.
  • the EBS ID is used as a parameter to initiate a DetachVolume request to the cloud management platform.
  • the cloud management platform After receiving the request, the cloud management platform releases the association between the shared EBS volume and the virtual host.
  • Step 503 The virtual standby device applies for an associated shared EBS volume to the cloud management platform.
  • Step 504 The virtual standby machine loads the EBS volume to the local.
  • the virtual standby device is associated with the shared EBS volume and is loaded to the local device through the steps 503 and 504.
  • the operation is the same as the operation of the virtual host in the foregoing steps 402 and 403, and the operation of loading the shared EBS volume is the same.
  • the virtual host In the case of a virtual host actively switching between two machines, the virtual host first releases the control of the shared EBS volume, and then performs the dual-machine switching, so that only one virtual machine can share the EBS volume at the same time, thereby avoiding the The emergence of brain-split.
  • the virtual standby machine before the virtual standby machine applies for the associated shared EBS volume, it may first query the cloud management platform for the association status of the EBS volume, and determine that the EBS volume is not associated with other virtual organs. In the case of a joint, the application will be associated with this EBS volume.
  • the step of the virtual standby machine querying the cloud management platform for the EBS volume association state is described in detail in the subsequent embodiments.
  • FIG. 6 shows the present. A schematic diagram of steps in a virtual application dual-machine passive switching in a cloud environment provided by an embodiment. The following steps detail the passive switching:
  • Step 601 The virtual standby device detects that dual-machine switching is required.
  • two-machine software is installed in the virtual application dual-machine, and the dual-machine software obtains the running state of the virtual dual-machine from the cloud management platform through a script.
  • the dual-machine software in the virtual standby machine can obtain the running status of the virtual host from the cloud management platform through the monitoring script, thereby detecting that the virtual host is faulty, and performing dual-machine switching.
  • the types of failures that occur include, but are not limited to, virtual host failures, network connectivity failures of virtual hosts, or host failures of virtual virtual hosts.
  • Step 602 The virtual standby device queries the cloud management platform for the associated state of the shared EBS volume.
  • the virtual standby machine queries the cloud management platform for the associated state of the shared EBS volume before the handover, and performs corresponding operations according to the queried situation;
  • the virtual standby machine can query the cloud management platform for the association status of the shared EBS volume through the DescribeVolume command.
  • the virtual standby machine can also perform the step of querying the association state of the shared EBS volume before the associated shared EBS volume, thereby better avoiding the occurrence of brain splitting and enhancing the virtual application double. Machine reliability.
  • Step 603 The cloud management platform feeds back the association status of the shared EBS volume to the virtual standby machine.
  • step 604 is performed; if the shared EBS volume is not associated with the virtual host, step 606 is performed.
  • Step 604 The virtual standby device requests the cloud management platform to remove the association between the virtual host and the shared EBS volume. Specifically, the virtual standby device can initiate a DetachVolume request to the cloud management platform through the CLI tool, and the virtual host is associated with the EBS volume.
  • the cloud management platform can conveniently obtain the status information of the virtual application dual-machine.
  • the cloud management platform receives the association between the detached virtual host and the shared EBS volume sent by the virtual standby machine. After the request, the state of the virtual host may be judged first, and after the virtual host does fail, the association between the virtual host and the shared EBS volume is released.
  • Step 605 The cloud management platform releases the association between the virtual host and the shared EBS volume.
  • Step 606 The virtual standby device applies to the cloud management platform to establish an association with the shared EBS volume, and the cloud management platform establishes an association between the virtual standby device and the shared EBS volume.
  • Step 607 The virtual standby device loads the shared EBS volume to the local.
  • the virtual standby device can initiate an Attach Volume request to the cloud management platform by using the CLI tool, and the cloud management platform associates the virtual standby device with the shared EBS volume, and then the virtual standby device performs the mount operation. , load this EBS volume locally.
  • the virtual standby machine can learn the associated state of the shared EBS volume through the cloud management platform, and then perform related operations on the basis of the virtual host, thereby effectively reducing the occurrence of brain splitting. , enhance the reliability of the virtual application dual machine.
  • the virtual standby machine can unassociate the virtual host from the shared EBS volume through the cloud management platform, so that the virtual standby pair can share the EBS volume. Separate control to ensure the smooth completion of the switch.
  • the present embodiment discloses a cloud management platform, which is used to implement the switching scheme of the virtual application dual-machine in the cloud environment disclosed in the foregoing embodiment.
  • FIG. 7 is a schematic structural diagram of a cloud management platform according to an embodiment of the present invention. The components of the cloud management platform are described in detail below in conjunction with the figure.
  • the cloud management platform 700 is composed of a sending module 701, a receiving module 702, a decorrelation module 703, and an association module 704.
  • the sending module 701 is configured to send the association status of the shared EBS volume to the virtual standby device.
  • the sending module 701 sends the association status of the shared EBS volume to the virtual standby device, which may be specifically: When the host fails, the receiving module 702 receives the request for querying the shared EBS volume association status sent by the virtual standby device.
  • the sending module 701 sends the association status of the shared EBS volume to the request for the shared EBS volume association status received by the receiving module 702. Virtual standby.
  • the virtual standby machine first acquires the association state of the shared EBS volume to avoid the situation that the virtual application dual-machine associates the EBS volume at the same time.
  • the virtual standby device can obtain the associated state of the shared EBS volume in multiple manners, for example, the cloud management platform periodically sends the associated state information of the shared EBS volume to the virtual standby device; the virtual host is detected on the cloud management platform.
  • the cloud management platform sends a request for querying the associated state of the shared EBS volume to the cloud management platform, and the cloud management platform sends the associated state of the shared EBS volume to the virtual standby device according to the request, which is not limited in this embodiment of the present invention.
  • the receiving module 702 is configured to receive, by the virtual standby device, a request for releasing the association between the virtual host and the shared EBS volume;
  • the association module 703 is configured to remove the association between the virtual host and the shared EBS volume according to the request received by the receiving module 701 to release the association between the virtual host and the shared EBS volume.
  • the virtual standby machine requests the cloud management platform to unassociate the shared EBS volume from the virtual host, so as to implement the control of the shared EBS volume by the virtual standby machine, and complete the virtual host. Switch to a virtual standby.
  • the receiving module 702 is further configured to: receive a request for the associated shared EBS volume sent by the virtual standby device, and the association module 704 is configured to associate the virtual standby device with the shared EBS according to the request of the associated shared EBS volume and the virtual standby device received by the receiving module 702. Volume, so that the virtual standby controls the shared EBS volume.
  • the cloud management platform shown in FIG. 7 and FIG. 8 further includes a creation module 705.
  • the creating module 705 is configured to: create a virtual host, a virtual standby device, and a shared EBS volume according to the request of the user, and set the virtual host and the virtual standby device to obtain the state information of the other party through the cloud management platform, and share the EBS volume by the virtual The host or virtual standby is controlled separately;
  • the created shared EBS volume may be one or more.
  • the creating module 705 When the creating module 705 creates more than one shared EBS volume, the creating module 705 is further configured to use more than one shared EBS.
  • the volumes each specify a name.
  • the receiving module 702 is further configured to: receive a request for the associated shared EBS volume sent by the virtual host; the association module 704 is further configured to associate the virtual host with the shared EBS volume according to the request of the associated shared EBS volume and the virtual host received by the receiving module 702, So that the virtual host controls the shared EBS volume.
  • the cloud management platform disclosed in this embodiment can create a virtual application dual-machine and a shared EBS volume according to the request of the user, which can meet the requirements of the user to the maximum extent; and run the state information after the virtual application is started, especially in the virtual host.
  • the virtual standby machine can obtain the information from the cloud management platform in time, and perform corresponding operations, thereby avoiding the situation that the dual-machine simultaneously reads the shared disk, which greatly enhances the reliable operation of the virtual application dual-machine. Sex.
  • FIG. 9 is a schematic structural diagram of a virtual application dual-system in a cloud environment according to an embodiment of the present invention. As shown in the figure, the system is used for switching a virtual application dual-machine in a cloud environment, including a cloud management platform 901, and a virtual Host 902 and virtual standby 903. specifically:
  • the cloud management platform 901 is configured to send the association status of the shared EBS volume to the virtual standby 903.
  • the cloud management platform 901 sends the association status of the shared EBS volume to the virtual standby 903.
  • the virtual standby 903 sends a request for querying the shared EBS volume association status to the cloud management platform 901.
  • the cloud management platform 901 sends the association status of the shared EBS volume to the virtual standby 903.
  • the virtual standby machine first acquires the associated state of the shared EBS volume to avoid the situation that the virtual application dual-machine associates the EBS volume at the same time.
  • the virtual standby device can obtain the associated state of the shared EBS volume in multiple manners, for example, the cloud management platform periodically sends the associated state information of the shared EBS volume to the virtual standby device; the virtual host is detected on the cloud management platform.
  • a failure occurs (for example, a virtual host fails, a virtual host's network Send a share to the virtual standby when the connection fails or the host of the virtual host fails.
  • the association state and the like are not limited in the embodiment of the present invention.
  • the virtual standby 903 is configured to detect, according to the association status of the shared EBS volume sent by the cloud management platform 901, that the shared EBS volume is associated with the virtual host 902, and send the association of the virtual host 902 and the shared EBS volume to the cloud management platform 901. Request
  • the cloud management platform 901 is further configured to receive a request sent by the virtual standby 903 to cancel the association between the virtual host 902 and the shared EBS volume, and release the association between the virtual host 902 and the shared EBS volume.
  • the virtual standby 903 is further configured to send a request for the associated shared EBS volume to the cloud management platform 901.
  • the cloud management platform 901 is further configured to associate the virtual standby 903 with the request according to the associated shared EBS volume sent by the virtual standby 903.
  • the virtual standby 903 is also used to load the shared EBS volume locally to control the shared EBS volume.
  • the cloud management platform 901 is further configured to: create a virtual host 902, a virtual standby 903, and a shared EBS volume according to the request of the user, and set the virtual host 902 and the virtual standby 903 to obtain the state information of the other party through the cloud management platform 901, respectively. And sharing EBS volumes by virtual host 902 or virtual standby
  • the virtual host 902 is configured to send a request for the associated shared EBS volume to the cloud management platform 901.
  • the cloud management platform 901 is further configured to associate the virtual host 902 with the shared EBS volume according to the received request of the associated shared EBS volume and the virtual host 902.
  • the virtual host 902 is also used to load the shared EBS volume to the local to control the shared EBS volume.
  • the cloud management platform disclosed in this embodiment can create a virtual application dual-machine and a shared EBS volume according to the request of the user, which can meet the requirements of the user to the maximum extent; and run the state information after the virtual application is started, especially in the virtual host.
  • the virtual standby machine can be managed from the cloud in time. The station obtains this information and performs corresponding operations, which avoids the situation that the dual-machine reads the shared disk at the same time, which greatly enhances the operational reliability of the virtual application dual-machine.

Landscapes

  • Engineering & Computer Science (AREA)
  • Theoretical Computer Science (AREA)
  • Physics & Mathematics (AREA)
  • Quality & Reliability (AREA)
  • General Engineering & Computer Science (AREA)
  • General Physics & Mathematics (AREA)
  • Computing Systems (AREA)
  • Mathematical Physics (AREA)
  • Hardware Redundancy (AREA)
  • Memory System Of A Hierarchy Structure (AREA)
  • Stored Programmes (AREA)

Abstract

本发明实施例提供一种云环境下虚拟应用双机的切换方法,包括:云管理平台将共享EBS卷的关联状态发送给所述虚拟备机;接收所述虚拟备机发送的解除所述虚拟主机与所述共享EBS卷的关联的请求;解除所述虚拟主机与所述共享EBS卷的关联;接收所述虚拟备机发送的关联所述共享EBS卷的请求;关联所述虚拟备机与所述共享EBS卷,以便所述虚拟备机控制所述共享EBS卷。本发明实施例同时提供相应的云管理平台及系统。采用本发明实施例公开的方法及装置,能够彻底解决脑裂问题。同时由于去除了对参考主机的依赖,能够简化应用双机部署,提高应用双机可靠性。

Description

一种云环境下虚拟应用 的切换方法、 装置及系统 技术领域
本发明涉及通信技术领域, 具体涉及云环境下的虚拟应用双机的切换方 法、 装置及系统。 背景技术
当前物理环境下的应用双机, 对于主备双机共享磁盘的模式, 通常是在两 台机器上分别安装双机软件, 通过 FC-SAN ( Fibre Channel Storage Area Network, 光纤通道存储局域网 )或 IP-SAN ( IP协议存储局域网 )划分一块共 享磁盘, 限定此磁盘只能由指定的两台物理机器访问。 将共享磁盘当成一组资 源由双机软件 (例如 Veritas Cluster Server)进行控制。 对于温备、 冷备模式的双 机应用, 双机切换时, 原主机卸载共享磁盘后, 原备机才挂载该共享磁盘, 确 保在同一时刻只能有一台机器对该共享磁盘进行操作。
现有物理双机系统由单独的组件进行管理, 当双机配置不正确时, 容易产 生脑裂(brain-split ) 问题——双机同时读取共享磁盘, 导致数据损坏。
为了解决双机系统的脑裂问题, 现有技术中存在一种方案: 在双机之外, 引入一台机器作为参考主机, 当主备机之间的心跳联系出现故障时, 为了识别 出孤岛节点, 主备机都 ping参考主机的 IP, ping失败的主动释放对磁盘的控 制。
这种方案的缺点是当主机掉电、 宕机或控制程序异常时将无法释放对磁盘 的控制, 这样备机自然无法获取对共享磁盘的控制来提供业务, 因此会造成较 长时间的业务中断。 而且这种方案需要配置参考主机, 而参考主机可能是外部 应用组件, 它本身的可靠性也难以得到保证。 发明内容
本发明实施例提供一种云环境下的虚拟应用双机的切换方法, 以解决主机 出现故障无法释放对共享磁盘的控制, 导致备机无法取得对共享磁盘的控制, 进而影响主备双机切换的问题。
本发明实施例提供一种云环境下虚拟应用双机的切换方法, 所述虚拟应 用双机包括虚拟主机和虚拟备机, 所述方法包括: 云管理平台将共享弹性块存 储 EBS卷的关联状态发送给所述虚拟备机;接收所述虚拟备机发送的解除所述 虚拟主机与所述共享 EBS卷的关联的请求;所述云管理平台解除所述虚拟主机 与所述共享 EBS卷的关联; 接收所述虚拟备机发送的关联所述共享 EBS卷的 请求; 关联所述虚拟备机与所述共享 EBS卷, 以便所述虚拟备机控制所述共享 EBS卷。
本发明实施例同时提供一种云管理平台, 用于云环境下虚拟应用双机的切 换, 包括: 发送模块, 用于将共享弹性块存储 EBS卷的关联状态发送给所述虚 拟备机; 所述接收模块还用于, 接收所述虚拟备机发送的解除所述虚拟主机与 所述共享 EBS卷的关联的请求; 去关联模块, 用于根据所述接收模块接收的所 述解除所述虚拟主机与所述共享 EBS卷的关联的请求,解除所述虚拟主机与所 述共享 EBS卷的关联; 所述接收模块还用于,接收所述虚拟备机发送的关联所 述共享 EBS卷的请求; 关联模块,用于根据所述接收模块接收的关联所述共享 EBS卷与所述虚拟备机的请求, 关联所述虚拟备机与所述共享 EBS卷, 以便 所述虚拟备机控制所述共享 EBS卷。
本发明实施例还提供一种云环境下的虚拟应用双机系统, 用于云环境下虚 拟应用双机的切换, 所述系统包括云管理平台、虚拟主机和虚拟备机, 具体地: 所述云管理平台,用于将共享弹性块存储 EBS卷的关联状态发送给所述虚拟备 机; 所述虚拟备机,还用于根据所述云管理平台发送的所述共享 EBS卷的关联 状态,检测到所述共享 EBS卷与所述虚拟主机关联, 则向所述云管理平台发送 解除所述虚拟主机与所述共享 EBS卷的关联的请求; 所述云管理平台,还用于 接收所述虚拟备机发送的解除所述虚拟主机与所述共享 EBS卷的关联的请求, 解除所述虚拟主机与所述共享 EBS卷的关联; 所述虚拟备机,还用于向所述云 管理平台发送关联所述共享 EBS卷的请求; 所述云管理平台,还用于根据所述 虚拟备机发送的关联所述共享 EBS 卷的请求, 关联所述虚拟备机与所述共享 EBS卷; 所述虚拟备机, 还用于将所述共享 EBS卷加载到本地, 以控制所述 共享 EBS卷。
采用本发明实施例公开的云环境下虚拟应用双机的切换方法、 云管理平台 以及虚拟应用双机系统, 将应用双机虚拟化, 在虚拟主机出现故障无法释放对 共享磁盘的控制时, 虚拟备机可以请求云管理平台解除虚拟主机与共享磁盘的 关联, 进而获得对共享磁盘的控制, 实现由虚拟主机到虚拟备机的切换, 提高 了应用双机运行的可靠性。 附图说明
为了更清楚地说明本发明实施例或现有技术中的技术方案, 下面将对实施 例或现有技术描述中所需要使用的附图作一筒单地介绍, 显而易见地, 下面描 述中的附图是本发明的一些实施例, 对于本领域普通技术人员来讲, 在不付出 创造性劳动的前提下, 还可以根据这些附图获得其他的附图。
图 1为本发明实施例提供的一种云环境下虚拟应用双机切换方法示意图; 图 2为本发明实施例提供的在开源 Xen虚拟化环境下为虚拟机挂载 EBS 卷的示意图;
图 3为本发明实施例提供的云环境下虚拟应用双机系统图;
图 4为本发明实施例提供的云环境下虚拟应用双机的启动步骤示意图; 图 5 为本发明实施例提供的云环境下虚拟应用双机的主动切换步骤示意 图; 图 6 为本发明实施例提供的云环境下虚拟应用双机的被动切换步骤示意 图;
图 7为本发明实施例提供的云管理平台的结构示意图;
图 8为本发明实施例提供的云管理平台的另一种结构示意图;
图 9为本发明实施例提供的云环境下虚拟应用双机系统的架构图。 具体实施方式
下面将结合本发明实施例中的附图, 对本发明实施例中的技术方案进行清 楚、 完整地描述, 显然, 所描述的实施例仅仅是本发明的一部分实施例, 而不 是全部实施例。 基于本发明中的实施例, 本领域普通技术人员在没有作出创造 性劳动前提下获得的所有其他实施例, 都属于本发明保护的范围。
图 1所示为本发明一个实施例提供的一种云环境下虚拟应用双机的切换方 法的示意图, 其中, 在本发明实施例中, 云环境下的虚拟应用双机包括虚拟主 机和虚拟备机。 结合该图, 详述该方法的各步骤如下:
步骤 101、 云管理平台将共享 EBS卷(Elastic block store, 弹性块存储) 的关联状态发送给虚拟备机;
在本发明一个实施例中,云管理平台将共享 EBS卷的关联状态发送给虚拟 备机, 可具体为: 虚拟主机发生故障时, 云管理平台接收虚拟备机发送的查询 共享 EBS卷关联状态的请求; 云管理平台根据虚拟备机发送的查询请求,将共 享 EBS卷的关联状态发送给虚拟备机。
在虚拟应用双机的运行过程中, 当虚拟主机出现故障时, 会导致虚拟主机 向虚拟备机的切换。 由于双机应用中的共享磁盘只允许同时由一台主机控制, 因此在切换之前,虚拟备机要先获取共享 EBS卷的关联状态, 以避免虚拟应用 双机同时关联该 EBS卷的情况出现。
在本发明实施例中,虚拟备机可以通过多种方式获取共享 EBS卷的关联状 态, 例如: 云管理平台定时向虚拟备机发送共享 EBS卷的关联状态信息; 在云 管理平台检测到虚拟主机发生故障(例如虚拟主机出现故障、 虚拟主机的网络 连接出现故障、 或是虚拟主机的宿主机出现故障等) 时, 向虚拟备机发送共享
EBS卷的关联状态信息; 或者由虚拟备机定时或在虚拟主机发生故障时, 向云 管理平台发送查询共享 EBS卷关联状态的请求,云管理平台根据该请求向虚拟 备机发送共享 EBS卷的关联状态等, 本发明实施例对此不作限定。
步骤 102、 云管理平台接收虚拟备机发送的解除虚拟主机与共享 EBS卷的 关联的请求;
步骤 103、 云管理平台解除虚拟主机与共享 EBS卷的关联;
若虚拟主机的故障导致其没有主动释放对共享 EBS卷的控制,则首先要由 云管理平台解除虚拟主机与共享 EBS卷的关联关系, 再将该共享 EBS卷与虚 拟备机建立关联,以避免共享 EBS卷与虚拟应用双机同时建立关联的情况的出 现。
步骤 104、 云管理平台接收虚拟备机发送的关联共享 EBS卷的请求; 步骤 105、 云管理平台关联虚拟备机与该共享 EBS卷, 以便虚拟备机控制 该共享 EBS卷。
云管理平台将共享 EBS卷与虚拟备机建立关联后,虚拟备机再通过 mount (加载 )命令将此 EBS卷加载到本地, 便能够对该 EBS卷进行控制, 像使用 本地磁盘一样使用此共享 EBS卷。
采用本发明实施例公开的云环境下虚拟应用双机的切换方案, 虚拟主机和 络等故障时, 导致某个节点不能对外提供服务, 并且不能被其他网元感知, 此 节点即称为孤岛节点) 的出现, 与此同时, 在虚拟主机发生故障不能主动释放 对共享 EBS卷的控制时,虚拟备机能够及时地获取故障信息并请求由云管理平 台解除虚拟主机对共享 EBS卷的控制,从而使得虚拟备机能够获得对共享 EBS 卷的控制, 实现由虚拟主机到虚拟备机的顺利切换。 结合上述实施例公开的云环境下虚拟应用双机的切换方法, 本实施例公开 上述方案的应用基础——云环境的详细内容。
云环境中管理着大量的计算设备和存储设备, 云管理平台通过虚拟化技 术, 将物理资源虚拟成逻辑资源, 进而向外提供虚拟计算资源(虚拟机)和虚拟 存储资源(例如 EBS卷)服务。 为了管理方便, 云管理平台将各种设备划分成多 个区域进行管理, 每个区域都拥有自己专有的计算和存储设备, 不同的区域间 不能进行资源共享。
EBS卷是云管理平台在一个指定的区域内创建的虚拟存储资源, 大小范围 可以从 1GB到 1TB, 由存储设备 NAS ( Network Attached Storage, 网络连接式 存者 )、 SAN( Storage Area Network,存者网络)或 DAS( Direct Attached Storage, 直连式存储)提供物理存储空间。 在 VMware (—种虚拟机软件, 业界一种主 流方案)虚拟化环境下, EBS卷是一个后缀为 vmdk的文件, 此文件属于某个 VMFS ( VMware Virtual Machine File System, VMware提供的虚拟机文件系统 ) 文件系统; 而在 XenServer (一种基于 linux的虚拟化服务器 )虚拟化环境下, EBS卷可以是一个文件, 也可以是一个逻辑卷。
EBS 卷创建成功后, 可以通过调用虚拟化环境的 API ( Application Programming Interface ,应用程序编程接口。例如在 VMware虚拟化环境中调用 VirtualMachine.ReconfigVM_Task; 在 XenServer 虚拟化环境 中 调用 xenapi.VBD.plug )将其与同一区域内的任意一台虚拟机建立关联, 同时也可以 从该虚拟机中将其分离。 EBS卷与虚拟机关联成功后, 即相当于为虚拟机增加 了一块磁盘, 该虚拟机可以对它进行分区、 格式化、 创建文件系统等物理磁盘 所适用的各种操作。 从使用效果来看, EBS卷相当于一块可插拔的磁盘, 类似 于 USB盘。
在 VMware虚拟化环境下一个 EBS卷可以只分配给一台虚拟机使用,也可 以分配给多台虚拟机使用; 而在 XenServer虚拟化环境下一个 EBS卷只能分配 给一台虚拟机使用。 在本发明实施例中, 由云管理平台管理 EBS卷, 可以对其 施加如下限制: 一个 EBS卷同一时刻只能分配给一台虚拟机使用, 此 EBS卷 从原虚拟机分离成功后, 才可以分配给其他虚拟机使用。
图 2所示为本发明一个实施例提供的在开源 Xen虚拟化环境下为虚拟机关 联 EBS卷的示意图。 在 VMware虚拟化环境下为虚拟机关联 EBS卷的情况与 此类似, 不再赘述。
如图所示,由 S AN存储系统提供逻辑驱动器(如图中所示 LUN1和 LUN2 ), 由云管理平台管理卷组(Volume Group ) , 将多个 LUN加入。 当创建 EBS卷 时, 在卷组之上划分逻辑卷(Logical Volume ) , —个 EBS卷对应一个逻辑卷 (如图中所示 EBS1对应逻辑卷 4, EBS2对应逻辑卷 6 ) 。 同理, 对于虚拟机 的磁盘, 也是一个磁盘对应一个逻辑卷。
如图中所示, 虚拟机 1关联了逻辑卷 1; 虚拟机 2和虚拟机 3是本发明实 施例中创建的虚拟应用双机, EBS1 是双机的共享磁盘, 根据前述实施例中提 及的对共享 EBS卷的限制条件, EBS1在同一时刻只能被虚拟机 2或虚拟机 3 单独关联, 不能同时被两个虚拟机关联; 虚拟机 4未关联磁盘。
图 2中所示各部分的编号只是用于举例, 不代表在一个区域内云管理平台 能够管理的 (虚拟)设备上限。
图 3所示为本发明实施例提供的云环境下虚拟应用双机系统图。 和物理环 境下的应用双机有两点不同: 一是在物理环境下的应用双机系统只有一台主机 和一台备机组成, 而在本发明实施例中, 在云环境下的虚拟应用双机系统中除 两台虚拟机外, 还包括了云管理平台; 二是在物理环境下的应用双机之间需要 有心跳信息保持联系, 以此来获知对方的运行情况, 而在本发明实施例中, 在 云环境下的虚拟应用双机之间不再需要心跳信息保持联系, 而是通过云管理平 台来获知对方的运行情况。
如图 3所示, 云管理平台创建的两台虚拟机包括一台虚拟主机和一台虚拟 备机, 虚拟主机和虚拟备机之间共享使用一块磁盘(EBS卷) 。 前已述及, 云 管理平台可以创建一个或多个 EBS卷, 此图中所示的一个 EBS卷用于举例, 不作为对本发明实施例的限定。 云环境下虚拟机和 EBS卷都是逻辑对象, 当虚 拟机的物理宿主机发生故障时, 虚拟机双机关系仍然保存在云管理平台中, 故 只需要指定新的物理宿主机重启虚拟机即可, 不必如现有物理环境下的双机系 统那样重新配置应用双机。
在本发明实施例中, 云环境下的虚拟应用双机之间不再需要心跳信息进行 联系, 取而代之的是, 由云管理平台提供虚拟应用双机的状态信息。 借助于云 平台对虚拟资源的全方位的监控, 本发明实施例中的云管理平台能够很方便地 获取虚拟应用双机的状态信息, 例如: 虚拟机健康状况(例如运行、 停止或故 障等) , 虚拟机挂载 EBS卷信息 (例如是否挂载、 何时挂载以及挂载的 EBS 卷标识等) , 以及虚拟机的性能数据 (例如 CPU占用率, 磁盘或网络 I/O流量 等)等。
在现有的双机方案中, 一般将待监控对象划分到某个资源组中, 由资源组 动、 停止或监控等。 具体地, 在本发明实施例中, 虚拟应用双机中的双机软件 可以通过监控脚本从云管理平台处获取到当前双机的运行状态, 为双机监控提 供准确的虚拟机状态信息。 由于虚拟应用双机中的任意一台虚拟机, 都可以通 过云管理平台查询到另一台虚拟机的状态信息, 同时由于云管理平台性能的高 可靠性, 因此能够最大限度地减少孤岛节点的出现。
结合上述实施例中公开的内容, 本实施例分别对虚拟应用双机的创建、 启 动和切换进行详细说明。
云环境下虚拟应用双机的创建:
在上述实施例公开的云环境下, 用户通过云管理平台的 portal (入口) 申 请创建虚拟应用双机, 在提出申请的同时指定共享磁盘 (即 EBS卷) 的大小。 云管理平台创建主备虚拟双机——虚拟主机和虚拟备机, 并在主备虚拟双 机上安装双机软件 (例如 Veritas Cluster Server等 )以监控双机应用。 同时设置 健康状况(例如运行、 停止或故障等), 虚拟机挂载 EBS卷信息(例如是否挂 载、 何时挂载以及挂载的 EBS卷标识等) , 以及虚拟机的性能数据 (例如 CPU 占用率, 磁盘或网络 I/O流量等)等。
云管理平台在创建虚拟应用双机的同时创建共享 EBS卷,数量可以为一个 也可以为多个,设置创建的共享 EBS卷只能被这对虚拟应用双机使用, 同时设 置 EBS卷在同一时刻只能由一台虚拟机单独控制。
云环境下虚拟应用双机的启动:
图 4所示为本发明一个实施例提供的云环境下虚拟应用双机的启动步骤示 意图, 结合该图, 详述各步骤如下: 其中,虚拟机元数据中可以包括虚拟机 ID、虚拟机可以挂载的 EBS卷 ID、 已经挂载的 EBS卷 ID、 挂载时间等信息。
具体地, 虚拟主机可以由安装其上的双机启动脚本(script )通过云管理平 台的 webserver (网页服务器)服务获取到虚拟机元数据。例如,可以通过命令: wget http://l 1.22.33.44/255/meta-data/获取到相应的数据。
步骤 402、 虚拟主机向云管理平台申请关联共享 EBS卷; 命令行界面) 工具, 以在步骤 401中获取的 EBS卷的 EBS ID ( EBS卷标识) 作为参数发起 AttachVolume (增加卷)请求, 由云管理平台为虚拟主机增加磁 盘;
其中, CLI工具由云管理平台提供, 可以运行在任何虚拟机上, 只需要与 云管理平台保持网络相通即可。 由云管理平台对 EBS 卷进行控制, 确保一个 EBS卷始终只能由一台虚拟机控制, 彻底杜绝双机应用时发生脑裂问题。 。 在现有的物理双机中, 需要挂载多块共享磁盘时, 不能指定磁盘在 OS ( Operating System, 操作系统)上的设备名称, 一般只能通过磁盘大小进行区 分, 这样对于相同大小的磁盘, 就难以区分每块磁盘的用途。
特别地,在本发明一个实施例中, 云管理平台在创建多个共享 EBS卷时可 以同时为每个 EBS卷设定名称, 这样虚拟机在请求挂载 EBS卷时, 就可以指 定 EBS卷的名称,从而解决现有物理双机中不能区分多块共享磁盘的问题, 并 且能够方便双机脚本的写作, 减少人为错误导致的问题。 例如虚拟应用双机需 要两块共享磁盘, 一块存话单, 一块存数据库文件, 在申请创建虚拟应用双机 时申请两个 EBS卷(EBS1、 EBS2 )作为共享磁盘, 并规划好卷名称, 存话单 的 EBS卷名称可以定为 /dev/sdb,存数据库文件的 EBS卷名称可以定为 /dev/sdc。
在这种情况下, 挂载 EBS卷的请求可如下所示:
cloudcli AttachEBS VM1 EBS1 /dev/sdb
mount /dev/sdb /mnt bill
cloudcli AttachEBS VM1 EBS2 /dev/sdc
mount /dev/sdc /mnt/dbfile
步骤 403、 虚拟主机将 EBS卷加载到本地;
其中,在步骤 402中云管理平台为虚拟主机关联共享 EBS卷后,虚拟主机 再通过 mount命令将此 EBS卷加载到本地,便可像使用本地磁盘一样使用此共 享 EBS卷了。
云环境下虚拟应用双机的切换:
在本发明实施例中, 云环境下虚拟应用双机的切换可以分为两种情况: 一 种情况是由虚拟主机主动发起的切换, 由虚拟主机切换到虚拟备机, 可称之为 主动切换; 另外一种情况是出现故障, 导致由虚拟主机到虚拟备机的切换, 可 称之为被动切换。 以下分别说明这两种情况下的虚拟应用双机的切换步骤。
图 5所示为本发明一个实施例提供的云环境下虚拟应用双机的主动切换步 骤示意图。 以下结合该图详述各步骤:
步骤 501、 虚拟主机卸载本地加载的共享 EBS卷;
具体地, 虚拟主机可以通过 unmount命令卸载加载到本地的共享 EBS卷。 步骤 502、 虚拟主机向云管理平台请求解除与共享 EBS卷的关联; 具体地, 虚拟主机可以通过云管理平台提供的 CLI工具以共享 EBS卷的
EBS ID作为参数向云管理平台发起 DetachVolume (分离卷)请求, 解除与此
EBS卷的关联;
云管理平台收到请求后, 解除此共享 EBS卷与虚拟主机的关联。
步骤 503、 虚拟备机向云管理平台申请关联共享 EBS卷;
步骤 504、 虚拟备机将 EBS卷加载到本地。
其中,虚拟备机经过步骤 503与 504与共享 EBS卷建立关联并加载到本地, 与前述步骤 402与 403中虚拟主机关联、加载共享 EBS卷的操作相同,此处不 再赘述。
在虚拟主机主动进行双机切换的情况下,虚拟主机先释放对共享 EBS卷的 控制, 再进行双机切换, 这样就可保证在同一时刻只会有一台虚拟机关联共享 EBS卷, 从而避免导致脑裂(brain-split ) 的出现。
此外, 在本发明的另一个实施例中, 还可以在虚拟备机申请关联共享 EBS 卷之前, 先由其向云管理平台查询此 EBS卷的关联状态, 在确定此 EBS卷没 有与其他虚拟机关联的情况下, 才会申请关联此 EBS卷。虚拟备机向云管理平 台查询 EBS卷关联状态的步骤在后续实施例中详细说明。
而在被动切换的情况下, 例如虚拟主机出现故障、 虚拟主机的网络连接出 现故障、 或是虚拟主机的宿主机出现故障时, 也需要由虚拟主机切换到虚拟备 机, 图 6所示为本发明一个实施例提供的云环境下虚拟应用双机被动切换时的 步骤示意图。 以下详述被动切换的各步骤:
步骤 601、 虚拟备机检测到需进行双机切换; 前已述及, 在虚拟应用双机中分别安装有双机软件, 双机软件通过脚本从 云管理平台处获取虚拟双机的运行状态。 具体地, 在本实施例中, 虚拟备机中 的双机软件可以通过监控脚本从云管理平台处获取虚拟主机的运行状态, 从而 检测到虚拟主机发生故障, 需要进行双机切换。 发生的故障类型包括但不限于 虚拟主机故障、虚拟主机的网络连接故障、或是虚拟虚拟主机的宿主机故障等。
步骤 602、 虚拟备机向云管理平台查询共享 EBS卷的关联状态;
在发生故障时,虚拟主机一般不会主动释放对共享 EBS卷的控制, 因而在 切换之前由虚拟备机向云管理平台查询共享 EBS卷的关联状态,并根据查询到 的情况执行相应的操作;
具体地, 虚拟备机可通过 DescribeVolume (描述卷 )命令向云管理平台查 询共享 EBS卷的关联状态。
前已述及, 在主动切换的情况下, 虚拟备机在关联共享 EBS卷之前, 也可 以实施该步骤查询共享 EBS卷的关联状态, 从而更好地避免脑裂情况的出现, 增强虚拟应用双机的可靠性。
步骤 603、 云管理平台向虚拟备机反馈共享 EBS卷的关联状态;
其中, 若共享 EBS卷还与虚拟主机关联, 则执行步骤 604; 若共享 EBS 卷未与虚拟主机关联, 则执行步骤 606。
步骤 604、虚拟备机向云管理平台请求解除虚拟主机与共享 EBS卷的关联; 具体地, 虚拟备机可以通过 CLI工具向云管理平台发起 DetachVolume请 求, 解除虚拟主机与此 EBS卷的关联。
前已述及, 云管理平台能够很方便地获取虚拟应用双机的状态信息, 在本 发明的一个实施例中, 云管理平台在收到虚拟备机发送的解除虚拟主机与共享 EBS卷的关联的请求后, 还可以先对虚拟主机的状态进行判断, 确定虚拟主机 确实发生故障后, 再解除虚拟主机与共享 EBS卷的关联。
步骤 605、 云管理平台解除虚拟主机与共享 EBS卷的关联; 步骤 606、 虚拟备机向云管理平台申请与共享 EBS卷建立关联, 云管理平 台建立虚拟备机与共享 EBS卷的关联;
步骤 607、 虚拟备机将共享 EBS卷加载到本地。
具体地, 在上述步骤 606与 607中, 虚拟备机可以通过 CLI工具向云管理 平台发起 Attach Volume请求, 由云管理平台为虚拟备机与共享 EBS卷建立关 联, 而后虚拟备机再通过 mount操作, 将此 EBS卷加载到本地。
通过本实施例公开的操作, 在虚拟主机故障的情况下, 虚拟备机可以通过 云管理平台获知共享 EBS卷的关联状态,在此基础上再进行相关操作,从而可 以有效地减少脑裂的出现, 增强虚拟应用双机的可靠性。 特别是在虚拟主机出 现故障, 无法主动释放对共享 EBS卷的控制的情况下,虚拟备机可以通过云管 理平台解除虚拟主机与共享 EBS卷的关联,这样就能保证虚拟备机对共享 EBS 卷的单独控制, 保证切换的顺利完成。
结合上述实施例公开的内容, 本实施例公开一种云管理平台, 用以实施上 述实施例公开的云环境下虚拟应用双机的切换方案。
图 7所示为本发明一个实施例提供的云管理平台的结构示意图, 以下结合 该图, 详述云管理平台的各组成部分。
如图所示, 云管理平台 700由发送模块 701、 接收模块 702、 去关联模块 703和关联模块 704组成。
其中, 发送模块 701 , 用于将共享 EBS卷的关联状态发送给虚拟备机; 在本发明一个实施例中,发送模块 701将共享 EBS卷的关联状态发送给虚 拟备机可具体为: 在虚拟主机发生故障时, 接收模块 702接收虚拟备机发送的 查询共享 EBS卷关联状态的请求;发送模块 701根据接收模块 702接收的查询 共享 EBS卷关联状态的请求, 将共享 EBS卷的关联状态发送给虚拟备机。
在虚拟应用双机的运行过程中, 当虚拟主机出现故障时, 会导致虚拟主机 向虚拟备机的切换。 由于双机应用中的共享磁盘只允许同时由一台主机控制, 因此在切换之前,虚拟备机要先获取共享 EBS卷的关联状态, 以避免虚拟应用 双机同时关联该 EBS卷的情况出现。
在本发明实施例中,虚拟备机可以通过多种方式获取共享 EBS卷的关联状 态, 例如: 云管理平台定时向虚拟备机发送共享 EBS卷的关联状态信息; 在云 管理平台检测到虚拟主机发生故障(例如虚拟主机出现故障、 虚拟主机的网络 连接出现故障、 或是虚拟主机的宿主机出现故障等) 时, 向虚拟备机发送共享 EBS卷的关联状态信息; 或者由虚拟备机定时或是在虚拟主机发生故障时, 向 云管理平台发送查询共享 EBS卷关联状态的请求,云管理平台根据该请求向虚 拟备机发送共享 EBS卷的关联状态等, 本发明实施例对此不作限定。
接收模块 702用于,接收虚拟备机发送的解除虚拟主机与共享 EBS卷的关 联的请求;
去关联模块 703, 用于根据接收模块 701接收的解除虚拟主机与共享 EBS 卷的关联的请求, 解除虚拟主机与共享 EBS卷的关联;
其中,在共享 EBS卷还与虚拟主机关联的情况下,虚拟备机要请求云管理 平台解除共享 EBS卷与虚拟主机的关联, 以便实现由虚拟备机对共享 EBS卷 的控制, 完成由虚拟主机向虚拟备机的切换。
接收模块 702还用于, 接收虚拟备机发送的关联共享 EBS卷的请求; 关联模块 704, 用于根据接收模块 702接收的关联共享 EBS卷与虚拟备机 的请求, 关联虚拟备机与共享 EBS卷, 以便虚拟备机控制共享 EBS卷。
结合图 7, 图 8所示的云管理平台中还包括创建模块 705。
其中, 创建模块 705用于, 根据用户的请求, 创建虚拟主机、 虚拟备机和 共享 EBS卷,并设置虚拟主机和虚拟备机分别通过云管理平台获取对方的状态 信息, 以及共享 EBS卷由虚拟主机或虚拟备机单独控制;
其中, 创建的共享 EBS卷可以为一个也可以为一个以上, 当创建模块 705 创建一个以上的共享 EBS卷时,创建模块 705还用于,为一个以上的共享 EBS 卷分别指定名称。
接收模块 702还用于, 接收虚拟主机发送的关联共享 EBS卷的请求; 关联模块 704还用于,根据接收模块 702接收的关联共享 EBS卷和虚拟主 机的请求, 关联虚拟主机与共享 EBS卷, 以便虚拟主机控制共享 EBS卷。
采用本实施例公开的云管理平台, 可以根据用户的请求创建虚拟应用双机 和共享 EBS卷, 能够最大限度地满足用户的需求; 在虚拟应用双机启动后运行 态信息, 特别是在虚拟主机发生故障的情况下, 虚拟备机能够及时从云管理平 台处获得该信息, 并执行相应的操作, 避免了双机同时读取共享磁盘的情况出 现, 极大增强了虚拟应用双机的运行可靠性。
图 9所示为本发明实施例提供的云环境下虚拟应用双机系统的架构图, 如 图所示, 该系统用于云环境下虚拟应用双机的切换, 其中包括云管理平台 901、 虚拟主机 902以及虚拟备机 903。 具体地:
云管理平台 901 , 用于将共享 EBS卷的关联状态发送给虚拟备机 903; 在本发明一个实施例中,云管理平台 901将共享 EBS卷的关联状态发送给 虚拟备机 903可具体为:虚拟主机发生故障时,虚拟备机 903向云管理平台 901 发送查询共享 EBS卷关联状态的请求, 响应于该请求, 云管理平台 901将共享 EBS卷的关联状态发送给虚拟备机 903。
在虚拟应用双机的运行过程中, 当虚拟主机出现故障时, 会导致虚拟主机 向虚拟备机的切换。 由于双机应用中的共享磁盘只允许同时由一台主机控制, 因此在切换之前,虚拟备机要先获取共享 EBS卷的关联状态, 以避免虚拟应用 双机同时关联该 EBS卷的情况出现。
在本发明实施例中,虚拟备机可以通过多种方式获取共享 EBS卷的关联状 态, 例如: 云管理平台定时向虚拟备机发送共享 EBS卷的关联状态信息; 在云 管理平台检测到虚拟主机发生故障(例如虚拟主机出现故障、 虚拟主机的网络 连接出现故障、 或是虚拟主机的宿主机出现故障等) 时, 向虚拟备机发送共享
EBS卷的关联状态信息; 或者由虚拟备机定时或是在虚拟主机发生故障时, 向 云管理平台发送查询共享 EBS卷关联状态的请求,云管理平台根据该请求向虚 拟备机发送共享 EBS卷的关联状态等, 本发明实施例对此不作限定。
虚拟备机 903, 用于根据云管理平台 901发送的共享 EBS卷的关联状态, 检测到共享 EBS卷与虚拟主机 902关联,则向云管理平台 901发送解除虚拟主 机 902与共享 EBS卷的关联的请求;
云管理平台 901 , 还用于接收虚拟备机 903发送的解除虚拟主机 902与共 享 EBS卷的关联的请求, 解除虚拟主机 902与共享 EBS卷的关联;
虚拟备机 903, 还用于向云管理平台 901发送关联共享 EBS卷的请求; 云管理平台 901 ,还用于根据虚拟备机 903发送的关联共享 EBS卷的请求, 关联虚拟备机 903与共享 EBS卷;
虚拟备机 903, 还用于将共享 EBS卷加载到本地, 以控制共享 EBS卷。 上述云管理平台 901还用于, 根据用户的请求, 创建虚拟主机 902、 虚拟 备机 903和共享 EBS卷,并设置虚拟主机 902和虚拟备机 903分别通过云管理 平台 901获取对方的状态信息, 以及共享 EBS卷由虚拟主机 902或虚拟备机
903单独控制;
虚拟主机 902, 用于向云管理平台 901发送关联共享 EBS卷的请求; 云管理平台 901 ,还用于根据接收的关联共享 EBS卷和虚拟主机 902的请 求, 关联虚拟主机 902与共享 EBS卷;
虚拟主机 902, 还用于将共享 EBS卷加载到本地, 以控制共享 EBS卷。 采用本实施例公开的云管理平台, 可以根据用户的请求创建虚拟应用双机 和共享 EBS卷, 能够最大限度地满足用户的需求; 在虚拟应用双机启动后运行 态信息, 特别是在虚拟主机发生故障的情况下, 虚拟备机能够及时从云管理平 台处获得该信息, 并执行相应的操作, 避免了双机同时读取共享磁盘的情况出 现, 极大增强了虚拟应用双机的运行可靠性。
通过以上的实施方式的描述可知, 本领域的技术人员可以清楚地了解到上 述实施例方法中的全部或部分步骤可借助软件加必需的通用硬件平台的方式 来实现。 基于这样的理解, 本发明的技术方案本质上或者说对现有技术做出贡 献的部分可以以软件产品的形式体现出来, 该计算机软件产品可以存储在存储 介质中, 如 ROM/RAM、 磁碟、 光盘等, 包括若干指令用以使得一台计算机设 备(可以是个人计算机, 服务器, 或者网络设备等)执行本发明各个实施例或 者实施例的某些部分所述的方法。
需要说明的是, 本说明书中的各个实施例均采用递进的方式描述, 各个实 施例之间相同相似的部分互相参见即可, 每个实施例重点说明的都是与其他实 施例的不同之处。尤其,对于装置实施例而言, 由于其基本相似于方法实施例, 所以描述的比较筒单, 各单元具体功能的执行过程参见方法实施例的部分说明 即可。 以上所描述的装置实施例仅仅是示意性的, 其中作为分离部件说明的单 元可以是或者也可以不是物理上分开的, 作为单元显示的部件可以是或者也可 以不是物理单元, 既可以位于一个地方, 或者也可以分布到多个网络单元上。 可以根据实际的需要选择其中的部分或者全部模块来实现本实施例方案的目 的。 本领域普通技术人员在不付出创造性劳动的情况下, 即可以理解并实施。
总之, 以上所述仅为本发明技术方案的较佳实施例而已, 并非用于限定本 发明的保护范围。凡在本发明的精神和原则之内, 所作的任何修改、等同替换、 改进等, 均应包含在本发明的保护范围之内。

Claims

权 利 要 求 书
1、 一种云环境下虚拟应用双机的切换方法, 其特征在于, 所述虚拟应用 双机包括虚拟主机和虚拟备机, 所述方法包括: 所述云管理平台接收所述虚拟备机发送的解除所述虚拟主机与所述共享
EBS卷的关联的请求;
所述云管理平台解除所述虚拟主机与所述共享 EBS卷的关联;
所述云管理平台接收所述虚拟备机发送的关联所述共享 EBS卷的请求; 所述云管理平台关联所述虚拟备机与所述共享 EBS卷,以便所述虚拟备机 控制所述共享 EBS卷。
2、 根据权利要求 1 所述的方法, 其特征在于, 所述云管理平台将共享弹 性块存储 EBS卷的关联状态发送给所述虚拟备机, 具体为:
所述虚拟主机发生故障时, 所述云管理平台接收所述虚拟备机发送的查询 所述共享 EBS卷关联状态的请求;
所述云管理平台根据所述虚拟备机发送的查询请求将所述共享 EBS 卷的 关联状态发送给所述虚拟备机。
3、 根据权利要求 1 所述的方法, 其特征在于, 在所述云管理平台将所述 共享 EBS卷的关联状态发送给所述虚拟备机之前, 还包括:
所述云管理平台根据用户的请求, 创建所述虚拟主机、 虚拟备机和共享 态信息, 所述共享 EBS卷由所述虚拟主机或所述虚拟备机单独控制;
接收所述虚拟主机发送的关联所述共享 EBS卷的请求;
所述云管理平台关联所述虚拟主机与所述共享 EBS卷,以便所述虚拟主机 控制所述共享 EBS卷。
4、 根据权利要求 3所述的方法, 其特征在于, 所述共享 EBS卷为一个以 上, 所述云管理平台在创建所述一个以上的共享 EBS卷的同时, 还包括: 为所述一个以上的共享 EBS卷分别指定名称。
5、 根据权利要求 4所述的方法, 其特征在于, 所述虚拟主机发送的关联 所述共享 EBS卷的请求中包括所述共享 EBS卷的名称。
6、 一种云管理平台, 用于云环境下虚拟应用双机的切换, 其特征在于, 所述虚拟应用双机包括虚拟主机和虚拟备机, 所述云管理平台包括:
发送模块, 用于将共享弹性块存储 EBS 卷的关联状态发送给所述虚拟备 机;
接收模块, 用于接收所述虚拟备机发送的解除所述虚拟主机与所述共享 EBS卷的关联的请求;
去关联模块, 用于根据所述接收模块接收的所述解除所述虚拟主机与所述 共享 EBS卷的关联的请求, 解除所述虚拟主机与所述共享 EBS卷的关联; 所述接收模块还用于,接收所述虚拟备机发送的关联所述共享 EBS卷的请 求;
关联模块,用于根据所述接收模块接收的关联所述共享 EBS卷与所述虚拟 备机的请求, 关联所述虚拟备机与所述共享 EBS卷, 以便所述虚拟备机控制所 述共享 EBS卷。
7、 根据权利要求 6所述的云管理平台, 其特征在于, 所述发送模块用于 将所述共享 EBS卷的关联状态发送给所述虚拟备机, 具体为:
在所述虚拟主机发生故障时, 所述接收模块接收所述虚拟备机发送的查询 所述共享 EBS卷关联状态的请求;
所述发送模块根据所述接收模块接收的查询所述共享 EBS 卷关联状态的 请求, 将所述共享 EBS卷的关联状态发送给所述虚拟备机。
8、 根据权利要求 6所述的云管理平台, 其特征在于, 所述云管理平台还 包括: 创建模块,用于在所述发送模块将所述共享 EBS卷的关联状态发送给所述 虚拟备机之前, 根据用户的请求, 创建所述虚拟主机、 虚拟备机和共享 EBS 息, 所述共享 EBS卷由所述虚拟主机或所述虚拟备机单独控制;
所述接收模块还用于,接收所述虚拟主机发送的关联所述共享 EBS卷的请 求;
所述关联模块还用于,根据所述接收模块接收的关联所述共享 EBS卷和所 述虚拟主机的请求, 关联所述虚拟主机与所述共享 EBS卷, 以便所述虚拟主机 控制所述共享 EBS卷。
9、 根据权利要求 8所述的云管理平台, 其特征在于, 所述共享 EBS卷为 一个以上, 所述创建模块在创建所述一个以上的共享 EBS卷的同时, 还用于, 为所述一个以上的共享 EBS卷分别指定名称。
10、一种云环境下虚拟应用双机系统,用于云环境下虚拟应用双机的切换, 其特征在于, 所述系统包括云管理平台、 虚拟主机和虚拟备机:
所述云管理平台,用于将共享弹性块存储 EBS卷的关联状态发送给所述虚 拟备机;
所述虚拟备机,用于接收所述云管理平台发送的所述共享 EBS卷的关联状 态, 向所述云管理平台发送解除所述虚拟主机与所述共享 EBS 卷的关联的请 求;
所述云管理平台, 还用于接收所述虚拟备机发送的解除所述虚拟主机与所 述共享 EBS卷的关联的请求, 解除所述虚拟主机与所述共享 EBS卷的关联; 所述虚拟备机, 还用于向所述云管理平台发送关联所述共享 EBS 卷的请 求;
所述云管理平台,还用于根据所述虚拟备机发送的关联所述共享 EBS卷的 请求, 关联所述虚拟备机与所述共享 EBS卷; 所述虚拟备机, 还用于将所述共享 EBS 卷加载到本地, 以控制所述共享 EBS卷。
11、 根据权利要求 10所述的虚拟应用双机系统, 其特征在于, 所述云管 理平台用于将所述共享 EBS卷的关联状态发送给所述虚拟备机, 具体为: 在所述虚拟主机发生故障时, 所述虚拟备机向所述云管理平台发送查询所 述共享 EBS卷关联状态的请求;
所述云管理平台根据所述虚拟备机发送的查询请求将所述共享 EBS 卷的 关联状态发送给所述虚拟备机。
12、 根据权利要求 10所述的虚拟应用双机系统, 其特征在于, 所述云管 理平台还用于, 根据用户的请求, 创建所述虚拟主机、 虚拟备机和共享 EBS 息, 所述共享 EBS卷由所述虚拟主机或所述虚拟备机单独控制;
所述虚拟主机, 用于向所述云管理平台发送关联所述共享 EBS卷的请求; 所述云管理平台,还用于根据所述接收的关联所述共享 EBS卷和所述虚拟 主机的请求, 关联所述虚拟主机与所述共享 EBS卷;
所述虚拟主机, 还用于将所述共享 EBS 卷加载到本地, 以控制所述共享
EBS卷。
PCT/CN2012/080318 2012-08-17 2012-08-17 一种云环境下虚拟应用双机的切换方法、装置及系统 WO2014026387A1 (zh)

Priority Applications (4)

Application Number Priority Date Filing Date Title
PCT/CN2012/080318 WO2014026387A1 (zh) 2012-08-17 2012-08-17 一种云环境下虚拟应用双机的切换方法、装置及系统
EP12882921.5A EP2800303B1 (en) 2012-08-17 2012-08-17 Switch method, device and system for virtual application dual machine in cloud environment
CN201280000892.4A CN102972010B (zh) 2012-08-17 2012-08-17 一种云环境下虚拟应用双机的切换方法、装置及系统
US14/464,272 US9448899B2 (en) 2012-08-17 2014-08-20 Method, apparatus and system for switching over virtual application two-node cluster in cloud environment

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
PCT/CN2012/080318 WO2014026387A1 (zh) 2012-08-17 2012-08-17 一种云环境下虚拟应用双机的切换方法、装置及系统

Related Child Applications (1)

Application Number Title Priority Date Filing Date
US14/464,272 Continuation US9448899B2 (en) 2012-08-17 2014-08-20 Method, apparatus and system for switching over virtual application two-node cluster in cloud environment

Publications (1)

Publication Number Publication Date
WO2014026387A1 true WO2014026387A1 (zh) 2014-02-20

Family

ID=47800632

Family Applications (1)

Application Number Title Priority Date Filing Date
PCT/CN2012/080318 WO2014026387A1 (zh) 2012-08-17 2012-08-17 一种云环境下虚拟应用双机的切换方法、装置及系统

Country Status (4)

Country Link
US (1) US9448899B2 (zh)
EP (1) EP2800303B1 (zh)
CN (1) CN102972010B (zh)
WO (1) WO2014026387A1 (zh)

Families Citing this family (24)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN104794028B (zh) * 2014-01-16 2017-08-08 中国移动通信集团浙江有限公司 一种容灾处理方法、装置、主用数据中心和备用数据中心
US9590901B2 (en) 2014-03-14 2017-03-07 Nicira, Inc. Route advertisement by managed gateways
KR101924746B1 (ko) * 2015-01-27 2019-02-27 닛본 덴끼 가부시끼가이샤 네트워크 기능 가상화의 관리, 및 오케스트레이션 장치, 시스템, 관리 방법 및 프로그램
US20160285957A1 (en) * 2015-03-26 2016-09-29 Avaya Inc. Server cluster profile definition in a distributed processing network
US10038628B2 (en) 2015-04-04 2018-07-31 Nicira, Inc. Route server mode for dynamic routing between logical and physical networks
US10243848B2 (en) 2015-06-27 2019-03-26 Nicira, Inc. Provisioning logical entities in a multi-datacenter environment
KR102322033B1 (ko) * 2015-07-21 2021-11-04 삼성전자주식회사 운영 체제 간 디스크 이미지를 공유하는 방법 및 디바이스
US10855515B2 (en) * 2015-10-30 2020-12-01 Netapp Inc. Implementing switchover operations between computing nodes
US10868754B2 (en) 2016-01-27 2020-12-15 Nebbiolo Technologies Inc. High availability input/output management nodes
US9954958B2 (en) * 2016-01-29 2018-04-24 Red Hat, Inc. Shared resource management
WO2017165701A1 (en) 2016-03-25 2017-09-28 Nebbiolo Technologies, Inc. Fog Computing Facilitated Flexible Factory
US10333849B2 (en) 2016-04-28 2019-06-25 Nicira, Inc. Automatic configuration of logical routers on edge nodes
WO2017209955A1 (en) 2016-05-31 2017-12-07 Brocade Communications Systems, Inc. High availability for virtual machines
CN106407045B (zh) * 2016-09-29 2019-09-24 郑州云海信息技术有限公司 一种数据灾难恢复方法、系统及服务器虚拟化系统
US10798063B2 (en) 2016-10-21 2020-10-06 Nebbiolo Technologies, Inc. Enterprise grade security for integrating multiple domains with a public cloud
US10237123B2 (en) * 2016-12-21 2019-03-19 Nicira, Inc. Dynamic recovery from a split-brain failure in edge nodes
US10616045B2 (en) 2016-12-22 2020-04-07 Nicira, Inc. Migration of centralized routing components of logical router
US10979368B2 (en) 2017-08-02 2021-04-13 Nebbiolo Technologies, Inc. Architecture for converged industrial control and real time applications
CN109672714B (zh) * 2017-10-17 2022-02-25 中移(苏州)软件技术有限公司 一种分布式存储系统的数据处理方法及分布式存储系统
CN109240799B (zh) * 2018-09-06 2022-04-15 福建星瑞格软件有限公司 大数据平台集群容灾方法、系统及计算机可读存储介质
CN111176886B (zh) * 2018-11-09 2024-04-23 杭州海康威视系统技术有限公司 一种数据库模式的切换方法、装置及电子设备
CN110515763A (zh) * 2019-07-26 2019-11-29 浪潮电子信息产业股份有限公司 一种基于OpenStack的虚拟机双机热备的方法和系统
TWI713325B (zh) * 2019-09-17 2020-12-11 宜鼎國際股份有限公司 可遠端控制電子設備的系統及方法
US11316773B2 (en) 2020-04-06 2022-04-26 Vmware, Inc. Configuring edge device with multiple routing tables

Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN1879088A (zh) * 2003-11-10 2006-12-13 诺基亚有限公司 控制计算机单元之间存储访问的计算机集群、计算机单元和方法
CN102231681A (zh) * 2011-06-27 2011-11-02 中国建设银行股份有限公司 一种高可用集群计算机系统及其故障处理方法
US20120102135A1 (en) * 2010-10-22 2012-04-26 Netapp, Inc. Seamless takeover of a stateful protocol session in a virtual machine environment

Family Cites Families (13)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US7636442B2 (en) * 2005-05-13 2009-12-22 Intel Corporation Method and apparatus for migrating software-based security coprocessors
JP4847272B2 (ja) * 2006-10-18 2011-12-28 株式会社日立製作所 論理区画ごとに電源を管理する計算機システム、ストレージ装置及びそれらの制御方法
US7945724B1 (en) * 2007-04-26 2011-05-17 Netapp, Inc. Non-volatile solid-state memory based adaptive playlist for storage system initialization operations
CA2645716C (en) * 2007-11-21 2017-05-30 Datagardens Inc. Adaptation of service oriented architecture
FR2944618B1 (fr) * 2009-04-17 2011-11-25 Gerard Weerts Systeme de mise a disposition d'une application sur un terminal utilisateur.
US8417885B2 (en) 2010-02-24 2013-04-09 Avaya Inc. Method and apparatus for high availability (HA) protection of a running virtual machine (VM)
US8688642B2 (en) * 2010-02-26 2014-04-01 Symantec Corporation Systems and methods for managing application availability
CN101807985B (zh) * 2010-03-03 2012-11-28 交通银行股份有限公司 一种数据中心集中式控制切换方法及系统
US9116731B2 (en) * 2010-04-07 2015-08-25 Accenture Global Services Limited Cloud reference model framework
CN102346779B (zh) * 2011-10-18 2013-07-31 中国联合网络通信集团有限公司 分布式文件系统和主控节点的备份方法
US9753669B2 (en) * 2014-05-13 2017-09-05 Velostrata Ltd. Real time cloud bursting
US20160048408A1 (en) * 2014-08-13 2016-02-18 OneCloud Labs, Inc. Replication of virtualized infrastructure within distributed computing environments
US20160050282A1 (en) * 2014-08-18 2016-02-18 SoftNAS, LLC Method for extending hybrid high availability cluster across network

Patent Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN1879088A (zh) * 2003-11-10 2006-12-13 诺基亚有限公司 控制计算机单元之间存储访问的计算机集群、计算机单元和方法
US20120102135A1 (en) * 2010-10-22 2012-04-26 Netapp, Inc. Seamless takeover of a stateful protocol session in a virtual machine environment
CN102231681A (zh) * 2011-06-27 2011-11-02 中国建设银行股份有限公司 一种高可用集群计算机系统及其故障处理方法

Also Published As

Publication number Publication date
CN102972010A (zh) 2013-03-13
EP2800303A1 (en) 2014-11-05
EP2800303B1 (en) 2015-11-04
US9448899B2 (en) 2016-09-20
CN102972010B (zh) 2015-03-25
US20140359343A1 (en) 2014-12-04
EP2800303A4 (en) 2015-03-11

Similar Documents

Publication Publication Date Title
WO2014026387A1 (zh) 一种云环境下虚拟应用双机的切换方法、装置及系统
US10114834B2 (en) Exogenous virtual machine synchronization and replication
JP5142678B2 (ja) デプロイ方法およびシステム
US8996477B2 (en) Multiple node/virtual input/output (I/O) server (VIOS) failure recovery in clustered partition mobility
US9753761B1 (en) Distributed dynamic federation between multi-connected virtual platform clusters
US10628273B2 (en) Node system, server apparatus, scaling control method, and program
US9747179B2 (en) Data management agent for selective storage re-caching
JP4701929B2 (ja) ブート構成変更方法、管理サーバ、及び計算機システム
US8458413B2 (en) Supporting virtual input/output (I/O) server (VIOS) active memory sharing in a cluster environment
WO2015096500A1 (zh) 一种业务迁移方法、装置和一种容灾系统
JP4572250B2 (ja) 計算機切り替え方法、計算機切り替えプログラム及び計算機システム
US20120110274A1 (en) Operating System Image Management
US10783045B2 (en) Active-active architecture for distributed ISCSI target in hyper-converged storage
US20120151095A1 (en) Enforcing logical unit (lu) persistent reservations upon a shared virtual storage device
US9602341B1 (en) Secure multi-tenant virtual control server operation in a cloud environment using API provider
US20080307254A1 (en) Information-processing equipment and system therefor
US8635391B2 (en) Systems and methods for eliminating single points of failure for storage subsystems
WO2014101211A1 (zh) 一种虚拟设备重建方法与装置
JP2012043445A (ja) 業務引き継ぎ方法、計算機システム、及び管理サーバ
JP5131336B2 (ja) ブート構成変更方法
US10193767B1 (en) Multiple available witnesses
JP6954693B2 (ja) フォールトトレラントシステム、サーバ、それらの運用方法、及びプログラム
JP6773345B1 (ja) フォールトトレラントシステム、サーバ、及びそれらの運用方法
JP5423855B2 (ja) ブート構成変更方法
CN112965790B (zh) 一种基于pxe协议的虚拟机启动方法及电子设备

Legal Events

Date Code Title Description
WWE Wipo information: entry into national phase

Ref document number: 201280000892.4

Country of ref document: CN

121 Ep: the epo has been informed by wipo that ep was designated in this application

Ref document number: 12882921

Country of ref document: EP

Kind code of ref document: A1

WWE Wipo information: entry into national phase

Ref document number: 2012882921

Country of ref document: EP

NENP Non-entry into the national phase

Ref country code: DE