[go: nahoru, domu]

CN108632118B - Intelligent pairing method and system for virtual machine and terminal - Google Patents

Intelligent pairing method and system for virtual machine and terminal Download PDF

Info

Publication number
CN108632118B
CN108632118B CN201710183242.2A CN201710183242A CN108632118B CN 108632118 B CN108632118 B CN 108632118B CN 201710183242 A CN201710183242 A CN 201710183242A CN 108632118 B CN108632118 B CN 108632118B
Authority
CN
China
Prior art keywords
icon
matched
virtual machine
terminal
moved
Prior art date
Legal status (The legal status 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 status listed.)
Active
Application number
CN201710183242.2A
Other languages
Chinese (zh)
Other versions
CN108632118A (en
Inventor
邓书芬
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
GCI Science and Technology Co Ltd
Original Assignee
GCI Science and Technology Co Ltd
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 GCI Science and Technology Co Ltd filed Critical GCI Science and Technology Co Ltd
Priority to CN201710183242.2A priority Critical patent/CN108632118B/en
Publication of CN108632118A publication Critical patent/CN108632118A/en
Application granted granted Critical
Publication of CN108632118B publication Critical patent/CN108632118B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L12/00Data switching networks
    • H04L12/28Data switching networks characterised by path configuration, e.g. LAN [Local Area Networks] or WAN [Wide Area Networks]
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F9/00Arrangements for program control, e.g. control units
    • G06F9/06Arrangements for program control, e.g. control units using stored programs, i.e. using an internal store of processing equipment to receive or retain programs
    • G06F9/44Arrangements for executing specific programs
    • G06F9/455Emulation; Interpretation; Software simulation, e.g. virtualisation or emulation of application or operating system execution engines
    • G06F9/45533Hypervisors; Virtual machine monitors
    • G06F9/45558Hypervisor-specific management and integration aspects
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F9/00Arrangements for program control, e.g. control units
    • G06F9/06Arrangements for program control, e.g. control units using stored programs, i.e. using an internal store of processing equipment to receive or retain programs
    • G06F9/44Arrangements for executing specific programs
    • G06F9/455Emulation; Interpretation; Software simulation, e.g. virtualisation or emulation of application or operating system execution engines
    • G06F9/45533Hypervisors; Virtual machine monitors
    • G06F9/45558Hypervisor-specific management and integration aspects
    • G06F2009/45595Network integration; Enabling network access in virtual machine instances

Landscapes

  • Engineering & Computer Science (AREA)
  • Software Systems (AREA)
  • Theoretical Computer Science (AREA)
  • Physics & Mathematics (AREA)
  • General Engineering & Computer Science (AREA)
  • General Physics & Mathematics (AREA)
  • Computer Networks & Wireless Communication (AREA)
  • Signal Processing (AREA)
  • User Interface Of Digital Computer (AREA)

Abstract

The invention relates to a method and a system for intelligently pairing a virtual machine and a terminal, wherein the method comprises the following steps: receiving state data packets respectively sent by a plurality of virtual machines and a plurality of terminals, and searching for the virtual machines and the terminals in an idle state according to the state data packets; selecting a virtual machine to be matched and a terminal to be matched with the virtual machine to be matched from the virtual machines and terminals in the idle state according to the input pairing information; respectively acquiring network address information of the virtual machine to be matched and the terminal to be matched according to each state data packet; and respectively sending the network address information of the virtual machine to be matched and the network address information of the terminal to be matched to a receiving end so as to connect the virtual machine to be matched and the terminal to be matched according to the received network address information. Therefore, when a user needs to designate a certain virtual machine to be paired with a certain terminal, the virtual machine and the terminal can be paired and connected by inputting corresponding pairing information through the user, and the expandability and the flexibility are strong.

Description

Intelligent pairing method and system for virtual machine and terminal
Technical Field
The invention relates to the technical field of computers, in particular to a method and a system for intelligently pairing a virtual machine and a terminal.
Background
Deployment is performed on virtual machines in a cloud operating system, and a terminal needs to be in corresponding communication connection with a plurality of virtual machines which are created in advance.
In a traditional virtual machine deployment mode, parameters are generally set for a virtual machine and a terminal manually, the terminal and the virtual machine are managed according to a set pairing relationship, the pairing relationship between the virtual machine and the terminal is fixed, when equipment needs to be added, the equipment needs to be modified according to an agreed relationship, and expansibility is poor.
Disclosure of Invention
Therefore, it is necessary to provide a method and a system for intelligently pairing a virtual machine and a terminal, which have strong expandability and flexibility, for solving the problem that the traditional pairing of the virtual machine and the terminal has poor expandability.
A virtual machine and terminal intelligent pairing method comprises the following steps:
receiving state data packets respectively sent by a plurality of virtual machines and a plurality of terminals, and searching for a virtual machine in an idle state and a terminal in the idle state according to the state data packets;
receiving input pairing information, and selecting a virtual machine to be matched and a terminal to be matched with the virtual machine to be matched from a virtual machine in an idle state and a terminal in the idle state according to the pairing information;
respectively acquiring the network address information of the virtual machine to be matched and the network address information of the terminal to be matched according to each state data packet;
and respectively sending the network address information of the virtual machine to be matched and the network address information of the terminal to be matched to a receiving end so as to connect the virtual machine to be matched and the terminal to be matched according to the received network address information.
A virtual machine and terminal intelligent pairing system comprises:
the data packet receiving module is used for receiving state data packets sent by the plurality of virtual machines and the plurality of terminals respectively and searching the virtual machines in the idle state and the terminals in the idle state according to the state data packets;
the matching selection module is used for receiving input pairing information and selecting a virtual machine to be matched and a terminal to be matched, which is matched with the virtual machine to be matched, from the virtual machine in the idle state and the terminal in the idle state according to the pairing information;
the information acquisition module is used for acquiring the network address information of the virtual machine to be matched and the network address information of the terminal to be matched according to each state data packet;
and the information sending module is used for respectively sending the network address information of the virtual machine to be matched and the network address information of the terminal to be matched to a receiving end so as to connect the virtual machine to be matched and the terminal to be matched according to the received network address information.
According to the method and the system for intelligently pairing the virtual machine and the terminal, the state data packets sent by the virtual machines and the terminals respectively are received, the virtual machine and the terminal in the idle state are searched according to the state data packets, the virtual machine to be matched and the terminal to be matched with the virtual machine to be matched are selected from the virtual machine and the terminal in the idle state according to the input pairing information, then the network address information of the virtual machine to be matched and the network address information of the terminal to be matched are obtained according to the state data packets respectively, and finally the network address information of the virtual machine to be matched and the network address information of the terminal to be matched are sent to the receiving end respectively, so that the virtual machine to be matched and the terminal to be matched are connected according to the received network address information. Therefore, when a user needs to designate a certain virtual machine to be paired with a certain terminal, corresponding pairing information is input, the corresponding virtual machine and the corresponding terminal can be searched according to the input pairing information to be paired and connected, the designated pairing can be achieved according to the user requirement, the fixed pairing relation between the virtual machine and the terminal does not need to be set, the expandability and the flexibility are strong, and the efficiency of virtual machine installation and deployment can be improved.
Drawings
Fig. 1 is a flowchart of a method for intelligently pairing a virtual machine and a terminal in a first embodiment;
fig. 2 is a flowchart of a method for intelligently pairing a virtual machine and a terminal in a second embodiment;
fig. 3 is a flowchart of a method for intelligently pairing a virtual machine and a terminal in a third embodiment;
FIG. 4 is an icon display interface diagram of a virtual machine and a terminal in an application example;
FIG. 5 is a schematic view of a first mode of operation;
FIG. 6 is a schematic view of a second mode of operation;
FIG. 7 is a diagram of an intelligently paired icon display interface corresponding to the first operation mode or the second operation mode;
FIG. 8 is a schematic view of a third mode of operation;
FIG. 9 is a diagram of an icon display interface after intelligent pairing according to a third operation mode;
fig. 10 is a block diagram of an intelligent pairing system of a virtual machine and a terminal in an embodiment.
Detailed Description
Referring to fig. 1, the virtual machine and terminal intelligent pairing method in the first embodiment is applicable to a terminal, such as a computer, for operation, and includes the following steps.
S110: and receiving state data packets respectively sent by the plurality of virtual machines and the plurality of terminals, and searching the virtual machines in the idle state and the terminals in the idle state according to the state data packets.
The status data packet includes information corresponding to a paired status or information corresponding to an idle status, where the idle status refers to a status that the pairing has not been performed yet. The virtual machines and the terminals are two ends to be paired with each other, and whether the virtual machines and the terminals are paired or not can be analyzed according to the state data packets by receiving the state data packets sent by the virtual machines and the terminals respectively, so that the virtual machines and the terminals in an idle state can be searched.
S120: and receiving input pairing information, and selecting a virtual machine to be matched and a terminal to be matched with the virtual machine to be matched from the virtual machine in the idle state and the terminal in the idle state according to the pairing information.
The pairing information is information indicating a pairing relationship between the virtual machine and the terminal, and may be manually input by a user. Specifically, the virtual machine to be paired and the terminal matched with the virtual machine can be obtained by analyzing the pairing information, and the virtual machine to be matched and the terminal to be matched are obtained respectively.
S130: and respectively acquiring the network address information of the virtual machine in the idle state and the network address information of the terminal in the idle state according to the state data packets.
Specifically, the status data packet sent by the virtual machine and the terminal further includes network address information, and the network address information is a unique identification code of the virtual machine and the terminal. Specifically, the network Address information includes a MAC (Media Access Control) Address and an IP Address (Internet Protocol Address). Further, by analyzing the status data packet sent by the virtual machine to be matched, the network address information of the virtual machine to be matched can be obtained; the network address information of the terminal to be matched can be obtained by analyzing the state data packet sent by the terminal to be matched.
S140: and respectively sending the network address information of the virtual machine to be matched and the network address information of the terminal to be matched to a receiving end so as to connect the virtual machine to be matched and the terminal to be matched according to the received network address information.
The network address information of the virtual machine to be matched and the terminal to be matched which are matched with each other is sent to the receiving end, so that the virtual machine to be matched and the terminal to be matched can search a matched party according to the received network address information to be matched for matching.
The receiving end can be a control center, and after receiving the network address information, the control center sends the network address information of the virtual machine to be matched to the terminal to be matched and sends the network address information of the terminal to be matched to the virtual machine to be matched; and the virtual machine to be matched detects that the terminal sending the connection request is the terminal to be matched corresponding to the received network address information, and the terminal to be matched is connected with the terminal to be matched after passing the verification.
Optionally, the receiving end may further include a virtual machine to be matched and a terminal to be matched, where step S140 is: and sending the network address information of the virtual machine to be matched to the terminal to be matched, and sending the network address information of the terminal to be matched to the virtual machine to be matched. Therefore, the terminal to be matched sends a connection request to the virtual machine to be matched for connection.
According to the intelligent matching method of the virtual machine and the terminal, the state data packets sent by the virtual machines and the terminals respectively are received, the virtual machine and the terminal in the idle state are searched according to the state data packets, the virtual machine to be matched and the terminal to be matched with the virtual machine to be matched are selected from the virtual machine and the terminal in the idle state according to the input matching information, then the network address information of the virtual machine to be matched and the network address information of the terminal to be matched are obtained according to the state data packets respectively, and finally the network address information of the virtual machine to be matched and the network address information of the terminal to be matched are sent to the receiving end respectively, so that the virtual machine to be matched and the terminal to be matched are connected according to the received network address information. Therefore, when a user needs to designate a certain virtual machine to be paired with a certain terminal, corresponding pairing information is input, the corresponding virtual machine and the corresponding terminal can be searched according to the input pairing information to be paired and connected, the designated pairing can be achieved according to the user requirement, the fixed pairing relation between the virtual machine and the terminal does not need to be set, the expandability and the flexibility are strong, and the efficiency of virtual machine installation and deployment can be improved.
In the second embodiment, the pairing information may be an icon movement instruction. Referring to fig. 2, step S120 includes steps S121 to S123.
S121: and displaying icons corresponding to the virtual machines in the idle state and icons corresponding to the terminals in the idle state according to a preset arrangement rule.
The preset arrangement rule may be specifically set according to actual needs, and specifically, the preset arrangement rule may be: displaying an icon of a virtual machine in an idle state in a first preset area, displaying an icon of a terminal in the idle state in the first preset area, and setting the interval between the icons in the same area as a preset interval.
S122: and receiving an icon moving instruction, and acquiring a moved icon and a selected icon matched with the moved icon in the plurality of icons according to the icon moving instruction.
S123: and searching the virtual machines and the terminals corresponding to the moved icon and the selected icon respectively as the virtual machine to be matched and the terminal to be matched, and correspondingly obtaining the pairing relation between the virtual machine to be matched and the terminal to be matched according to the matching relation between the moved icon and the selected icon.
The moved icon and the selected icon match each other. Optionally, the moved icon may be an icon of a virtual machine, and may also be an icon of a terminal; if the moved icon is the icon of the virtual machine, the selected icon is the icon of the terminal, namely the moved icon corresponds to the virtual machine to be matched, and the selected icon corresponds to the terminal to be matched; if the moved icon is the icon of the terminal, the selected icon is the icon of the virtual machine, namely, the moved icon corresponds to the terminal to be matched, and the selected icon corresponds to the virtual machine to be matched. And determining the corresponding relation between the virtual machine to be matched and the terminal to be matched according to the corresponding relation between the moved icon and the selected icon.
By adopting the method for acquiring the terminal to be matched and the virtual machine to be matched according to the icon moving instruction, a user can execute the corresponding icon moving operation to input the icon moving instruction, so that the intelligent matching of the virtual machine and the terminal is completed, and the matching operation mode is simple and flexible.
Specifically, with continued reference to fig. 2, step S122 includes steps S1220 to S1223.
S1220: and receiving an icon moving instruction, and acquiring the moved icon according to the icon moving instruction.
The number of moved icons may be one or more. That is, the user may drag an icon once or may select a plurality of icons to be dragged at the same time.
S1221: and acquiring the changed coordinate position of the moved icon and acquiring the matching coordinate range corresponding to each icon.
Wherein the pairing coordinate ranges of the icons are not overlapped with each other. The pairing coordinate range corresponding to each icon may be set in advance. Specifically, the range included by a circle with the initial coordinate position of each icon as the center of the circle and the preset value as the radius can be used as the matching coordinate range corresponding to the icon at the center of the circle, so that the circles are not overlapped with each other.
S1222: a paired coordinate range containing the changed coordinate position is searched for from a plurality of paired coordinate ranges.
And searching a matched coordinate range containing the changed coordinate position, specifically comparing whether the coordinate value of the changed coordinate position is in a coordinate area corresponding to the matched coordinate range.
S1223: and taking the icon corresponding to the searched pairing coordinate range as the selected icon matched with the moved icon.
And changing the coordinate position to be the coordinate position where the mobile icon is moved. If the matched coordinate range contains the changed coordinate position, the moved icon is located in the searched matched coordinate range after being moved, and the icon corresponding to the searched matched coordinate range is used as the selected icon matched with the moved icon. And if the number of the moved icons is multiple, respectively pairing the icon corresponding to the searched pairing coordinate range with the moved icon corresponding to the changed coordinate position contained in the pairing coordinate range one by one.
The selected icon is searched by matching the changed coordinate position after the moved icon and the matching coordinate range of each icon, and a user only needs to drag the icon to the matching coordinate range of the icon needing to be matched, so that the operation mode is simple.
Specifically, the pairing coordinate ranges corresponding to the icons of the virtual machines in the idle states all belong to a first area, the pairing ranges corresponding to the icons of the terminals in the idle states all belong to a second area, and the first area and the second area are two display areas which are not overlapped with each other. That is, the pairing coordinate range corresponding to the icon of the virtual machine and the pairing coordinate range corresponding to the icon of the terminal belong to different display areas. After step S1222 and before step S1223, step (a1) is further included.
Step (a 1): and judging whether the display area to which the searched pairing coordinate range belongs is different from the display area to which the pairing coordinate range corresponding to the moved icon belongs. If yes, go to step S1223; if not, the process returns to step S1220.
If the searched pairing coordinate range is different from the display area to which the pairing coordinate range corresponding to the moved icon belongs, the device corresponding to the searched pairing coordinate range and the device corresponding to the moved icon are different in type and respectively correspond to a virtual machine and a terminal, and at the moment, the devices can be paired with each other; otherwise, the device corresponding to the searched pairing coordinate range and the device corresponding to the moved icon are of the same type, and are both virtual machines or both terminals, and at this time, pairing is not needed.
By carrying out different detection on the searched pairing coordinate range and the pairing coordinate range corresponding to the moved icon, the matching between devices of the same type caused by user operation errors can be avoided, and the pairing accuracy is improved.
Referring to fig. 3, in the third embodiment, after step S1220, steps S1224 to S12282 are further included.
S1224: and judging whether the number of the moved icons is one or not. If the number of moved icons is one, step S1221 is performed. Otherwise, step S1225 is performed.
S1225: and respectively acquiring a first receiving time for receiving the state data packet sent by the virtual machine in each idle state and a second receiving time for receiving the state data packet sent by the terminal in each idle state.
And if the time for sending the state data packet is different, the corresponding first receiving time is different, and if the time for sending the state data packet is different, the corresponding second receiving time is different. The virtual machine and the terminal can transmit the status data packet in real time or at intervals, so that each first receiving time and each second receiving time are updated in real time or at intervals.
S1226: and judging whether each moved icon is the icon of the virtual machine. If yes, go to step S12271; otherwise, step S12281 is performed.
S12271: and sequentially selecting a number of second receiving moments equal to the number of the moved icons according to the time sequence of the second receiving moments, and taking the icon of the terminal corresponding to the selected second receiving moment as the selected icon.
The moved icon and the selected icon are respectively one of a virtual machine and a terminal. And if the moved icon is the icon of the virtual machine, the selected icon is the icon of the terminal. Specifically, the second receiving time is selected as follows: and selecting second receiving moments which are earlier in time and equal to the moved icons in number according to the time sequence of all the second receiving moments. Therefore, the selected icon can be selected according to the principle that the status data packet is sent firstly and then the matching is carried out firstly.
S12272: and searching the first receiving time of the virtual machine corresponding to each moved icon, and sequentially pairing according to the time sequence of the first receiving time corresponding to each moved icon and the second receiving time corresponding to each selected icon to obtain the selected icon matched with each moved icon.
Sequencing the moved icons according to the first receiving moment to obtain the sequencing from first to last in time; and sequencing the selected icons according to the second receiving time, and also obtaining the sequencing from first to last in time. Specifically, the moved icons and the selected icons can be sequentially paired according to the sequence numbers of the sequenced moved icons and the sequenced selected icons; for example, a moved icon with sequence number 1 matches a selected icon with sequence number 1, and so on.
S12281: and sequentially selecting the first receiving moments with the number equal to that of the moved icons according to the time sequence of the first receiving moments, and taking the icon of the virtual machine corresponding to the selected first receiving moment as the selected icon.
And if the moved icon is not the icon of the virtual machine, the moved icon is the icon of the terminal, and the selected icon is the icon of the virtual machine at the moment. Specifically, the selection manner of the first receiving time is the same as that of the second receiving time, and is not described herein again.
S12282: and searching for second receiving time of the terminal corresponding to each moved icon, and sequentially pairing according to the time sequence of the second receiving time corresponding to each moved icon and the first receiving time corresponding to each selected icon to obtain the selected icon matched with each moved icon.
Specifically, the method for sequentially pairing the moved icon and the selected icon according to the first receiving time and the second receiving time is the same as the method described in step S12272, and is not described herein again.
Referring to fig. 4, a display interface diagram of icons of a virtual machine and a terminal in an idle state of an operating terminal is shown in an application example, where the method for intelligently pairing the virtual machine and the terminal is applied, and the icon of the virtual machine and the icon of the terminal are displayed in different display areas. As shown in fig. 5 and 6, a user may drag an icon of a terminal in an idle state to be near an icon of a virtual machine in an idle state, or may drag an icon of a virtual machine to be near an icon of a terminal, so as to implement directional interconnection between the terminal and the virtual machine, and as shown in fig. 7, the icon is displayed outside an icon display area of the virtual machine in an idle state and the terminal after interconnection between the virtual machine and the terminal. Referring to fig. 8, if all idle virtual machines and terminals need to be automatically paired and interconnected, a user only needs to select all icons of the virtual machines and drag the entire icons to be near the icons of the terminals, or drag all icons of the terminals to be near the icons of the virtual machines, and the automatic combination result is as shown in fig. 9.
In a fourth embodiment, the pairing information includes a virtual machine identifier and a terminal identifier. The virtual machine identifier and the terminal identifier are unique identification information of the virtual machine and the terminal, respectively, for example, the virtual machine identifier may be a virtual machine name, and the terminal identifier may be a terminal name.
Step S120 includes step (b1) and step (b 2).
Step (b 1): receiving the input virtual machine identification and the input terminal identification, searching the corresponding virtual machine in the idle state according to the virtual machine identification, and searching the corresponding terminal in the idle state according to the terminal identification.
Step (b 2): and taking the searched virtual machine as a virtual machine to be matched, and taking the searched terminal as a terminal to be matched with the virtual machine to be matched.
The only corresponding virtual machine can be found according to the virtual machine identification, and the only corresponding terminal can be found according to the terminal identification. By adopting the mode of identifying the virtual machine identifier and the terminal identifier and correspondingly searching for matching, the user can directly input the virtual machine identifier and the terminal identifier corresponding to the virtual machine and the terminal which need to be matched in a designated mode, so that the intelligent matching of the virtual machine and the terminal is realized, the operation is simple, and the flexibility is strong.
Referring to fig. 10, in an embodiment, the virtual machine and terminal intelligent pairing system may be applied to operate a terminal, such as a computer, and includes a data packet receiving module 210, a matching selection module 220, an information obtaining module 230, and an information sending module 240.
The data packet receiving module 210 is configured to receive status data packets sent by multiple virtual machines and multiple terminals, respectively, and search for a virtual machine in an idle state and a terminal in the idle state according to the status data packets.
The matching selection module 220 is configured to receive input pairing information, and select a virtual machine to be matched and a terminal to be matched, which is matched with the virtual machine to be matched, from the virtual machine in the idle state and the terminal in the idle state according to the pairing information.
The information obtaining module 230 is configured to obtain network address information of the virtual machine to be matched and network address information of the terminal to be matched according to each status data packet.
The information sending module 240 is configured to send the network address information of the virtual machine to be matched and the network address information of the terminal to be matched to the receiving end, so that the virtual machine to be matched and the terminal to be matched are connected according to the received network address information.
The above-mentioned virtual machine and terminal intelligent pairing system receives the status data packets respectively sent by a plurality of virtual machines and a plurality of terminals through the data packet receiving module 210, searches the virtual machine and the terminal in the idle state according to the status data packets, the matching selecting module 220 selects the virtual machine to be matched and the terminal to be matched with the virtual machine to be matched from the virtual machine and the terminal in the idle state according to the input pairing information, then the information obtaining module 230 obtains the network address information of the virtual machine to be matched and the terminal to be matched respectively according to each status data packet, and finally the information sending module 240 sends the network address information of the virtual machine to be matched and the network address information of the terminal to be matched to the receiving end respectively, so that the virtual machine to be matched and the terminal to be matched are connected according to the received network address information. Therefore, when a user needs to designate a certain virtual machine to be paired with a certain terminal, corresponding pairing information is input, the corresponding virtual machine and the corresponding terminal can be searched according to the input pairing information to be paired and connected, the designated pairing can be achieved according to the user requirement, the fixed pairing relation between the virtual machine and the terminal does not need to be set, the expandability and the flexibility are strong, and the efficiency of virtual machine installation and deployment can be improved.
In an embodiment, the matching information may be an icon moving instruction, and the matching selection module 220 includes an icon display unit (not shown), an instruction reading unit (not shown), and a matching unit (not shown).
The icon display unit is used for displaying icons corresponding to the virtual machines in the idle state and icons corresponding to the terminals in the idle state according to a preset arrangement rule.
The instruction reading unit is used for receiving the icon moving instruction and acquiring a moved icon and a selected icon matched with the moved icon in the icons according to the icon moving instruction.
The searching and matching unit is used for searching the virtual machines and the terminals corresponding to the moved icon and the selected icon respectively as the virtual machines to be matched and the terminals to be matched, and correspondingly obtaining the matching relation between the virtual machines to be matched and the terminals to be matched according to the matching relation between the moved icon and the selected icon.
By adopting the method for acquiring the terminal to be matched and the virtual machine to be matched according to the icon moving instruction, a user can execute the corresponding icon moving operation to input the icon moving instruction, so that the intelligent matching of the virtual machine and the terminal is completed, and the matching operation mode is simple and flexible.
Specifically, the instruction reading unit may include an icon obtaining subunit (not shown), a coordinate obtaining subunit (not shown), a searching subunit (not shown), and a pairing subunit (not shown).
The icon acquisition subunit is used for receiving the icon movement instruction and acquiring the moved icon according to the icon movement instruction.
The coordinate acquisition subunit is used for acquiring the changed coordinate position of the moved icon and acquiring the matching coordinate range corresponding to each icon; wherein the pairing coordinate ranges of the icons are not overlapped with each other.
And the searching subunit is used for searching the pairing coordinate range containing the changed coordinate position from the plurality of pairing coordinate ranges.
And the matching subunit is used for taking the icon corresponding to the searched matching coordinate range as the selected icon matched with the moved icon.
The selected icon is searched by matching the changed coordinate position after the moved icon and the matching coordinate range of each icon, and a user only needs to drag the icon to the matching coordinate range of the icon needing to be matched, so that the operation mode is simple.
Specifically, the pairing coordinate ranges corresponding to the icons of the virtual machines in the idle states all belong to a first area, the pairing ranges corresponding to the icons of the terminals in the idle states all belong to a second area, and the first area and the second area are two display areas which are not overlapped with each other. The instruction reading unit may further include a difference analysis subunit (not shown), configured to determine whether a display area to which the found paired coordinate range belongs is different from a display area to which the paired coordinate range corresponding to the moved icon belongs, after the matching coordinate range including the changed coordinate position is found by the finding subunit and before the icon corresponding to the found paired coordinate range is taken as the selected icon matched with the moved icon by the matching subunit. And if so, executing the function of the pairing subunit, otherwise, repeatedly executing the function of the icon acquisition subunit.
By carrying out different detection on the searched pairing coordinate range and the pairing coordinate range corresponding to the moved icon, the matching between devices of the same type caused by user operation errors can be avoided, and the pairing accuracy is improved.
In an embodiment, the instruction reading unit further includes a number analysis subunit (not shown) configured to detect the number of the moved icons after the icon acquisition subunit acquires the moved icons, and perform the functions of the coordinate acquisition subunit, the search subunit, and the pairing subunit when the number of the moved icons is one.
When the number of the moved icons is multiple, the number analysis subunit respectively acquires a first receiving time for receiving the state data packet sent by each idle-state virtual machine and a second receiving time for receiving the state data packet sent by each idle-state terminal; and judging whether each moved icon is the icon of the virtual machine. If so, sequentially selecting a number of second receiving moments equal to the number of the moved icons according to the time sequence of the second receiving moments, and taking the icon of the terminal corresponding to the selected second receiving moment as the selected icon; and searching the first receiving time of the virtual machine corresponding to each moved icon, and sequentially pairing according to the time sequence of the first receiving time corresponding to each moved icon and the second receiving time corresponding to each selected icon to obtain the selected icon matched with each moved icon. If not, sequentially selecting the first receiving moments with the number equal to that of the moved icons according to the time sequence of the first receiving moments, and taking the icon of the virtual machine corresponding to the selected first receiving moment as the selected icon; and searching for second receiving time of the terminal corresponding to each moved icon, and sequentially pairing according to the time sequence of the second receiving time corresponding to each moved icon and the first receiving time corresponding to each selected icon to obtain the selected icon matched with each moved icon.
It can be understood that the matching selection module 220 may also obtain the virtual machine to be matched and the terminal to be matched in other manners. For example, in one embodiment, the matching extraction module 220 includes an identification acquisition unit (not shown) and a corresponding search unit (not shown). The identification acquisition unit is used for receiving the input virtual machine identification and the input terminal identification, searching the corresponding virtual machine in the idle state according to the virtual machine identification, and searching the corresponding terminal in the idle state according to the terminal identification. The corresponding searching unit is used for taking the searched virtual machine as a virtual machine to be matched and taking the searched terminal as a terminal to be matched with the virtual machine to be matched.
By adopting the mode of identifying the virtual machine identifier and the terminal identifier and correspondingly searching for matching, the user can directly input the virtual machine identifier and the terminal identifier corresponding to the virtual machine and the terminal which need to be matched in a designated mode, so that the intelligent matching of the virtual machine and the terminal is realized, the operation is simple, and the flexibility is strong.
The technical features of the embodiments described above may be arbitrarily combined, and for the sake of brevity, all possible combinations of the technical features in the embodiments described above are not described, but should be considered as being within the scope of the present specification as long as there is no contradiction between the combinations of the technical features.
The above-mentioned embodiments only express several embodiments of the present invention, and the description thereof is more specific and detailed, but not construed as limiting the scope of the invention. It should be noted that, for a person skilled in the art, several variations and modifications can be made without departing from the inventive concept, which falls within the scope of the present invention. Therefore, the protection scope of the present patent shall be subject to the appended claims.

Claims (8)

1. A virtual machine and terminal intelligent pairing method is characterized by comprising the following steps:
receiving state data packets respectively sent by a plurality of virtual machines and a plurality of terminals, and searching for a virtual machine in an idle state and a terminal in the idle state according to the state data packets;
receiving input pairing information, and selecting a virtual machine to be matched and a terminal to be matched with the virtual machine to be matched from a virtual machine in an idle state and a terminal in the idle state according to the pairing information;
respectively acquiring the network address information of the virtual machine to be matched and the network address information of the terminal to be matched according to each state data packet;
respectively sending the network address information of the virtual machine to be matched and the network address information of the terminal to be matched to a receiving end so as to enable the virtual machine to be matched and the terminal to be matched to be connected according to the received network address information;
the matching information is an icon moving instruction, the input matching information is received, and the virtual machine to be matched and the terminal to be matched with the virtual machine to be matched are selected from the virtual machine in the idle state and the terminal in the idle state according to the matching information, and the method comprises the following steps:
displaying icons corresponding to the virtual machines in the idle state and icons corresponding to the terminals in the idle state according to a preset arrangement rule;
receiving the icon moving instruction, and acquiring a moved icon and a selected icon matched with the moved icon in the plurality of icons according to the icon moving instruction;
and searching the virtual machines and terminals corresponding to the moved icon and the selected icon to be used as the virtual machines to be matched and the terminals to be matched respectively, and obtaining the pairing relation between the virtual machines to be matched and the terminals to be matched according to the matching relation between the moved icon and the selected icon.
2. The method for intelligently pairing the virtual machine and the terminal according to claim 1, wherein the receiving the icon moving instruction, and obtaining the moved icon and the selected icon matched with the moved icon in the plurality of icons according to the icon moving instruction comprises:
receiving the icon moving instruction, and acquiring the moved icon according to the icon moving instruction;
acquiring the changed coordinate position of the moved icon after the moved icon is moved, and acquiring the matched coordinate range corresponding to each icon, wherein the matched coordinate ranges of the icons are not overlapped with each other;
searching a pairing coordinate range containing the changed coordinate position from a plurality of pairing coordinate ranges;
and taking the icon corresponding to the searched pairing coordinate range as the selected icon matched with the moved icon.
3. The intelligent pairing method for the virtual machine and the terminal according to claim 2, wherein pairing coordinate ranges corresponding to the icons of the virtual machines in the idle states all belong to a first area, pairing ranges corresponding to the icons of the terminals in the idle states all belong to a second area, and the first area and the second area are two display areas which are not overlapped with each other;
after searching the paired coordinate range including the changed coordinate position from the paired coordinate ranges, before the icon corresponding to the searched paired coordinate range is used as the selected icon matched with the moved icon, the method further includes:
judging whether the display area to which the searched pairing coordinate range belongs is different from the display area to which the pairing coordinate range corresponding to the moved icon belongs;
if so, executing the step of taking the icon corresponding to the searched matching coordinate range as the selected icon matched with the moved icon;
if not, returning to the step of receiving the icon moving instruction and acquiring the moved icon according to the icon moving instruction.
4. The intelligent pairing method for the virtual machine and the terminal according to claim 2, wherein after receiving the icon moving instruction and acquiring the moved icon according to the icon moving instruction, the method further comprises:
if the number of the moved icons is one, executing the steps of obtaining the changed coordinate positions of the moved icons and obtaining the matching coordinate ranges corresponding to the icons;
if the number of the moved icons is multiple, respectively acquiring a first receiving time for receiving the state data packet sent by each idle-state virtual machine and a second receiving time for receiving the state data packet sent by each idle-state terminal;
judging whether each moved icon is an icon of a virtual machine or not;
if so, sequentially selecting a number of second receiving moments equal to the number of the moved icons according to the time sequence of the second receiving moments, and taking the icon of the terminal corresponding to the selected second receiving moment as the selected icon;
searching for a first receiving time of the virtual machine corresponding to each moved icon, and sequentially pairing according to the time sequence of the first receiving time corresponding to each moved icon and a second receiving time corresponding to each selected icon to obtain the selected icon matched with each moved icon;
if not, sequentially selecting a first receiving time equal to the moved icon according to the time sequence of the first receiving times, and taking the icon of the virtual machine corresponding to the selected first receiving time as the selected icon;
and searching for second receiving time of the terminal corresponding to each moved icon, and sequentially pairing according to the time sequence of the second receiving time corresponding to each moved icon and the first receiving time corresponding to each selected icon to obtain the selected icon matched with each moved icon.
5. The method according to claim 1, wherein the pairing information includes a virtual machine identifier and a terminal identifier, the receiving the input pairing information, and selecting the virtual machine to be matched and the terminal to be matched, which is matched with the virtual machine to be matched, from the virtual machine in the idle state and the terminal in the idle state according to the pairing information includes:
receiving an input virtual machine identifier and an input terminal identifier, searching a corresponding virtual machine in an idle state according to the virtual machine identifier, and searching a corresponding terminal in the idle state according to the terminal identifier;
and taking the searched virtual machine as the virtual machine to be matched, and taking the searched terminal as the terminal to be matched with the virtual machine to be matched.
6. The utility model provides a virtual machine and terminal intelligence system of pairing which characterized in that includes:
the data packet receiving module is used for receiving state data packets sent by the plurality of virtual machines and the plurality of terminals respectively and searching the virtual machines in the idle state and the terminals in the idle state according to the state data packets;
the matching selection module is used for receiving input pairing information and selecting a virtual machine to be matched and a terminal to be matched, which is matched with the virtual machine to be matched, from the virtual machine in the idle state and the terminal in the idle state according to the pairing information;
the information acquisition module is used for acquiring the network address information of the virtual machine to be matched and the network address information of the terminal to be matched according to each state data packet;
the information sending module is used for respectively sending the network address information of the virtual machine to be matched and the network address information of the terminal to be matched to a receiving end so as to enable the virtual machine to be matched and the terminal to be matched to be connected according to the received network address information;
the pairing information is an icon moving instruction, and the matching selection module comprises:
the icon display unit is used for displaying icons corresponding to the virtual machines in the idle state and icons corresponding to the terminals in the idle state according to a preset arrangement rule;
the instruction reading unit is used for receiving the icon moving instruction and acquiring a moved icon and a selected icon matched with the moved icon in the plurality of icons according to the icon moving instruction;
and the searching and matching unit is used for searching the virtual machines and the terminals corresponding to the moved icon and the selected icon to be used as the virtual machines to be matched and the terminals to be matched respectively, and obtaining the matching relationship between the virtual machines to be matched and the terminals to be matched according to the matching relationship between the moved icon and the selected icon.
7. The system of claim 6, wherein the instruction reading unit comprises:
the icon obtaining subunit is used for receiving the icon moving instruction and obtaining the moved icon according to the icon moving instruction;
the coordinate acquisition subunit is used for acquiring the changed coordinate position of the moved icon and acquiring the matched coordinate range corresponding to each icon, wherein the matched coordinate ranges of the icons are not overlapped with each other;
the searching subunit is used for searching a matched coordinate range containing the changed coordinate position from a plurality of matched coordinate ranges;
and the matching subunit is used for taking the icon corresponding to the searched matching coordinate range as the selected icon matched with the moved icon.
8. The system according to claim 7, wherein the instruction reading unit further includes a number analysis subunit configured to detect the number of the moved icons after the icon obtaining subunit obtains the moved icons, and when the number of the moved icons is one, perform the functions of the coordinate obtaining subunit, the search subunit, and the pairing subunit;
when the number of the moved icons is multiple, the number analysis subunit respectively acquires a first receiving time for receiving the state data packet sent by each idle-state virtual machine and a second receiving time for receiving the state data packet sent by each idle-state terminal; judging whether each moved icon is an icon of a virtual machine or not; if so, sequentially selecting a number of second receiving moments equal to the number of the moved icons according to the time sequence of the second receiving moments, and taking the icon of the terminal corresponding to the selected second receiving moment as the selected icon; searching for a first receiving time of the virtual machine corresponding to each moved icon, and sequentially pairing according to the time sequence of the first receiving time corresponding to each moved icon and a second receiving time corresponding to each selected icon to obtain the selected icon matched with each moved icon; if not, sequentially selecting a first receiving time equal to the moved icon according to the time sequence of the first receiving times, and taking the icon of the virtual machine corresponding to the selected first receiving time as the selected icon; and searching for second receiving time of the terminal corresponding to each moved icon, and sequentially pairing according to the time sequence of the second receiving time corresponding to each moved icon and the first receiving time corresponding to each selected icon to obtain the selected icon matched with each moved icon.
CN201710183242.2A 2017-03-24 2017-03-24 Intelligent pairing method and system for virtual machine and terminal Active CN108632118B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201710183242.2A CN108632118B (en) 2017-03-24 2017-03-24 Intelligent pairing method and system for virtual machine and terminal

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201710183242.2A CN108632118B (en) 2017-03-24 2017-03-24 Intelligent pairing method and system for virtual machine and terminal

Publications (2)

Publication Number Publication Date
CN108632118A CN108632118A (en) 2018-10-09
CN108632118B true CN108632118B (en) 2021-01-12

Family

ID=63707710

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201710183242.2A Active CN108632118B (en) 2017-03-24 2017-03-24 Intelligent pairing method and system for virtual machine and terminal

Country Status (1)

Country Link
CN (1) CN108632118B (en)

Citations (9)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN102204210A (en) * 2011-05-18 2011-09-28 华为技术有限公司 Method, server, and system for starting application
CN102202289A (en) * 2011-04-13 2011-09-28 张�林 Method and system for remote calling software and hardware resources through mobile terminal
CN102882968A (en) * 2012-09-27 2013-01-16 广东电子工业研究院有限公司 Method for dynamically distributing cloud desktops
CN103281359A (en) * 2013-05-06 2013-09-04 北京启创卓越科技有限公司 Cloud desktop system and operating method
CN103368912A (en) * 2012-03-31 2013-10-23 华为技术有限公司 Implementation method of online application, device and system
CN104317510A (en) * 2014-10-11 2015-01-28 广东欧珀移动通信有限公司 Method for sending file by mobile terminal and mobile terminal
CN104735108A (en) * 2013-12-20 2015-06-24 中国移动通信集团公司 Method and device for using cloud desktops and cloud desktop system
CN105245606A (en) * 2015-10-22 2016-01-13 中国铁路总公司 Cloud office platform
CN106506620A (en) * 2016-11-02 2017-03-15 河南智业科技发展有限公司 Cloud desktop intelligent terminal management system

Family Cites Families (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
KR101507919B1 (en) * 2011-07-01 2015-04-07 한국전자통신연구원 Method and apparatus for virtual desktop service

Patent Citations (9)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN102202289A (en) * 2011-04-13 2011-09-28 张�林 Method and system for remote calling software and hardware resources through mobile terminal
CN102204210A (en) * 2011-05-18 2011-09-28 华为技术有限公司 Method, server, and system for starting application
CN103368912A (en) * 2012-03-31 2013-10-23 华为技术有限公司 Implementation method of online application, device and system
CN102882968A (en) * 2012-09-27 2013-01-16 广东电子工业研究院有限公司 Method for dynamically distributing cloud desktops
CN103281359A (en) * 2013-05-06 2013-09-04 北京启创卓越科技有限公司 Cloud desktop system and operating method
CN104735108A (en) * 2013-12-20 2015-06-24 中国移动通信集团公司 Method and device for using cloud desktops and cloud desktop system
CN104317510A (en) * 2014-10-11 2015-01-28 广东欧珀移动通信有限公司 Method for sending file by mobile terminal and mobile terminal
CN105245606A (en) * 2015-10-22 2016-01-13 中国铁路总公司 Cloud office platform
CN106506620A (en) * 2016-11-02 2017-03-15 河南智业科技发展有限公司 Cloud desktop intelligent terminal management system

Also Published As

Publication number Publication date
CN108632118A (en) 2018-10-09

Similar Documents

Publication Publication Date Title
CN107291068B (en) Vehicle diagnostic method and vehicle diagnostic apparatus
KR101914604B1 (en) Control method and control system for iot device using cloud platform
CN104320161B (en) Method and system for rapid Bluetooth pairing
CN104580534B (en) Information processing method, device and electronic equipment
CN102710549B (en) To be established a communications link the method for relation, terminal and system by shooting
CN105407454A (en) Binding method and device for wearable device
CN102843280B (en) Method and system of communication of communication device and communication device
CN105677561B (en) The multi-platform test method of mobile product and system
CN104852937B (en) Method for network access and device for mobile application
CN104852984A (en) Method and system for transmitting data between smart terminals based on multi-screen interaction
CN113890773A (en) Cross-device control method, device and system
JP7231655B2 (en) Programs, information processing methods, and electronic devices
CN104683002A (en) Method and device for pairing Bluetooth equipment
CN108924908B (en) WiFi scanning method and device and electronic device
CN105554682B (en) A kind of information acquisition method and relevant device
CN111625793B (en) Identification, order payment and sub-face library establishment method, device and equipment and order payment system
CN112566078A (en) Device connection method and apparatus, storage medium, and electronic apparatus
TWI426808B (en) Method of piaring a computer and wireless electronic devices
CN105241443A (en) Route acquiring method and user terminal
CN104348583A (en) Information processing method and electronic equipment
CN104735687B (en) A kind of single verification service test method and device of standing
CN108632118B (en) Intelligent pairing method and system for virtual machine and terminal
CN106375551B (en) Information interaction method, device and terminal
CN105591842B (en) A kind of method and apparatus obtaining mobile terminal operating system version
CN105466439B (en) A kind of method for processing navigation information, mobile terminal, application server and system

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination
GR01 Patent grant
GR01 Patent grant