WO2020238891A1 - Method and device for leasing physical host, cloud platform, and readable storage medium - Google Patents

Method and device for leasing physical host, cloud platform, and readable storage medium Download PDF

Info

Publication number
WO2020238891A1
WO2020238891A1 PCT/CN2020/092305 CN2020092305W WO2020238891A1 WO 2020238891 A1 WO2020238891 A1 WO 2020238891A1 CN 2020092305 W CN2020092305 W CN 2020092305W WO 2020238891 A1 WO2020238891 A1 WO 2020238891A1
Authority
WO
WIPO (PCT)
Prior art keywords
physical host
vpc
user
physical
host
Prior art date
Application number
PCT/CN2020/092305
Other languages
French (fr)
Chinese (zh)
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 北京金山云网络技术有限公司
Publication of WO2020238891A1 publication Critical patent/WO2020238891A1/en

Links

Images

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L41/00Arrangements for maintenance, administration or management of data switching networks, e.g. of packet switching networks
    • H04L41/08Configuration management of networks or network elements
    • H04L41/0803Configuration setting
    • H04L41/0823Configuration setting characterised by the purposes of a change of settings, e.g. optimising configuration for enhancing reliability
    • 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/46Multiprogramming arrangements
    • G06F9/50Allocation of resources, e.g. of the central processing unit [CPU]
    • 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/46Multiprogramming arrangements
    • G06F9/50Allocation of resources, e.g. of the central processing unit [CPU]
    • G06F9/5005Allocation of resources, e.g. of the central processing unit [CPU] to service a request
    • G06F9/5027Allocation of resources, e.g. of the central processing unit [CPU] to service a request the resource being a machine, e.g. CPUs, Servers, Terminals
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06QINFORMATION AND COMMUNICATION TECHNOLOGY [ICT] SPECIALLY ADAPTED FOR ADMINISTRATIVE, COMMERCIAL, FINANCIAL, MANAGERIAL OR SUPERVISORY PURPOSES; SYSTEMS OR METHODS SPECIALLY ADAPTED FOR ADMINISTRATIVE, COMMERCIAL, FINANCIAL, MANAGERIAL OR SUPERVISORY PURPOSES, NOT OTHERWISE PROVIDED FOR
    • G06Q30/00Commerce
    • G06Q30/06Buying, selling or leasing transactions
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06QINFORMATION AND COMMUNICATION TECHNOLOGY [ICT] SPECIALLY ADAPTED FOR ADMINISTRATIVE, COMMERCIAL, FINANCIAL, MANAGERIAL OR SUPERVISORY PURPOSES; SYSTEMS OR METHODS SPECIALLY ADAPTED FOR ADMINISTRATIVE, COMMERCIAL, FINANCIAL, MANAGERIAL OR SUPERVISORY PURPOSES, NOT OTHERWISE PROVIDED FOR
    • G06Q30/00Commerce
    • G06Q30/06Buying, selling or leasing transactions
    • G06Q30/0645Rental transactions; Leasing transactions
    • 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]
    • H04L12/46Interconnection of networks
    • 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]
    • H04L12/46Interconnection of networks
    • H04L12/4633Interconnection of networks using encapsulation techniques, e.g. tunneling
    • 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]
    • H04L12/46Interconnection of networks
    • H04L12/4641Virtual LANs, VLANs, e.g. virtual private networks [VPN]
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L61/00Network arrangements, protocols or services for addressing or naming
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L61/00Network arrangements, protocols or services for addressing or naming
    • H04L61/50Address allocation
    • H04L61/5007Internet protocol [IP] addresses
    • H04L61/5014Internet protocol [IP] addresses using dynamic host configuration protocol [DHCP] or bootstrap protocol [BOOTP]
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L67/00Network arrangements or protocols for supporting network services or applications
    • H04L67/01Protocols
    • H04L67/02Protocols based on web technology, e.g. hypertext transfer protocol [HTTP]
    • H04L67/025Protocols based on web technology, e.g. hypertext transfer protocol [HTTP] for remote control or remote monitoring of applications
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L67/00Network arrangements or protocols for supporting network services or applications
    • H04L67/50Network services
    • H04L67/60Scheduling or organising the servicing of application requests, e.g. requests for application data transmissions using the analysis and optimisation of the required network resources
    • H04L67/63Routing a service request depending on the request content or context

Definitions

  • This application relates to the field of virtual network technology, and in particular to a method, device, cloud platform and readable storage medium for renting a physical host.
  • the purpose of this application is to provide a method, device, cloud platform and readable storage medium for renting a physical host to solve the above-mentioned problems.
  • an embodiment of the present application provides a method for renting a physical host, applied to a cloud platform, and the method includes:
  • the physical host is added to the designated virtual private cloud VPC to deploy the physical host as a computing node in the VPC for the user to use, wherein the VPC is also deployed As a cloud host for computing nodes.
  • acquiring the installed resources of the physical host and performing installation processing on the physical host based on the installed resources includes:
  • the network status of the physical host is set so that the physical host obtains installation configuration information through the network, and completes the installation according to the installation configuration information.
  • the method further includes:
  • adding the physical host to the designated VPC includes:
  • the switch device includes a PDN gateway and a top-of-rack switch TOR
  • the configuration information of the PDN gateway includes DHCP configuration information and VPC configuration information
  • the configuration information of the TOR includes physical interfaces and tunnels. And virtual routers.
  • the step of adding the physical host to the designated VPC further includes:
  • the communication between the uplink interface and the PDN gateway is established through the tunnel established by the virtual router, so as to realize that the uplink interface joins the virtual private cloud VPC, where the PDN gateway is used to access the VPC.
  • the method further includes:
  • the method before the receiving the lease request of the user's physical host, the method further includes:
  • the method further includes:
  • an embodiment of the present application also provides a device for renting a physical host, applied to a cloud platform, and the device includes:
  • a receiving module configured to receive a lease request of a user's physical host, wherein the physical host leased by the user is a physical host selected by the user from the physical hosts that can be sold;
  • An obtaining module configured to obtain installed resources of the physical host and perform installation processing on the physical host based on the installed resources
  • the joining module is configured to add the physical host to a designated virtual private cloud VPC after the installation process is completed, so as to deploy the physical host as a computing node in the VPC for the user to use, wherein the A cloud host as a computing node is also deployed in the VPC.
  • embodiments of the present application also provide a cloud platform, which includes a processor and a non-volatile memory storing computer instructions.
  • a cloud platform which includes a processor and a non-volatile memory storing computer instructions.
  • an embodiment of the present application also provides a readable storage medium.
  • the readable storage medium includes a computer program. When the computer program runs, the electronic device where the readable storage medium is located executes the physical Host rental method.
  • an embodiment of the present application further provides an executable program code, wherein the executable program code is configured to be executed to execute the physical host lease method in the first aspect.
  • the embodiments of the present application provide a method, device, cloud platform, and readable storage medium for renting a physical host.
  • the method is applied to the cloud platform.
  • the physical host lease request includes the physical host that can be sold selected by the user; then, the installed resources of the physical host are obtained and based on the installed capacity.
  • the resources are installed on the physical host; finally, the physical host after installation is added to the designated virtual private cloud VPC for users to use.
  • the above method can add the physical host selected by the user to the virtual private cloud VPC after installation, and can realize the rapid creation and deployment of the physical host on the public cloud platform and the virtual network configuration.
  • Figure 1a is a schematic structural diagram of a physical host leasing system provided by an embodiment of the application.
  • Figure 1b is a schematic structural diagram of a physical host joining a VPC according to an embodiment of the application
  • FIG. 2 is a schematic block diagram of a cloud platform provided by an embodiment of the application.
  • FIG. 3 is one of the schematic flowcharts of a method for renting a physical host provided by an embodiment of the application
  • FIG. 4 is a second schematic diagram of the process of a method for renting a physical host provided by an embodiment of the application
  • FIG. 5 is one of the schematic diagrams of the network configuration process of the physical host provided by the embodiment of the application.
  • FIG. 6 is the second schematic diagram of the network configuration process of the physical host provided by the embodiment of this application.
  • FIG. 7 is a large-scale deployment situation and flowchart of a cloud platform provided by an embodiment of the application.
  • FIG. 8 is one of the functional module block diagrams of the lease device of the physical host provided by this embodiment.
  • Figure 9 is the second block diagram of the functional modules of the physical host leasing device provided by this embodiment.
  • One is to deploy a set of independent physical host clusters to connect to the virtual private cloud (VPC, Virtual Private Cloud) of cloud hosts in the public cloud environment through a dedicated line or VPN (Virtual Private Network) to achieve network connectivity
  • VPC Virtual Private Cloud
  • VPN Virtual Private Network
  • the other is to plan a virtual private cloud VPC with an independent physical host cluster, and treat the physical host as a cloud host computing node to manage the corresponding functions of the virtual network.
  • Cloud hosting can be understood as virtual hosting.
  • the first method can ensure that all computing resources in the public cloud environment are reachable to each other, but the physical host cluster is not really in the virtual private cloud VPC, and many VPC features cannot be realized, such as binding elastic IP addresses and configuring security groups Wait.
  • the physical host can have the characteristics of a virtual private cloud VPC, because it is a virtual private cloud independent of the cloud host, its network connectivity is limited.
  • physical hosts need to provide flexible, secure, and reliable public cloud services like cloud hosts, and they also need to interact with modules such as resource deployment, security protection, and monitoring services to form automated, convenient and configurable services for users.
  • embodiments of the present application provide a method, device, cloud platform, and readable storage medium for renting a physical host.
  • FIG. 1a it is a schematic diagram of a physical host leasing system 1 provided by an embodiment of the present application.
  • the physical host leasing system 1 includes a physical host 10, a cloud platform 20, a router 30, a switch 40, and a PDN gateway (PGW, PDN GateWay, PDN: Packet Data Network; packet data network gateway) 50.
  • PGW Packet Data Network
  • PDN gateway Packet Data Network
  • the functions of the router 30 and the switch 40 can be realized through the same device, such as a TOR (Top of Rack, top of rack switch), and the specific device is not limited.
  • the physical host 10 communicates with the cloud platform 20, and the cloud platform 20 receives user operations.
  • the PDN gateway 50 is used to access the virtual private cloud VPC.
  • the physical host 10 is connected to the PDN gateway 50 via the router 30 and the switch 40.
  • the physical host 10 can be added to the virtual private cloud by setting the network of the router 30, the switch 40 and the PDN gateway 50 VPC.
  • the cloud platform 20 includes a rental device 210 of a physical host, a memory 220, a processor 230, and a communication unit 240.
  • the memory 220, the processor 230, and the communication unit 240 may be directly or indirectly electrically connected to each other to realize data transmission or interaction.
  • the rental device 210 of the physical host includes at least one computer program or software function module that can be stored in the memory 220 in the form of software or firmware, and the processor 230 is used to execute the executable module stored in the memory 220
  • the leasing device 210 of the physical host stored in the storage 220 can execute the leasing method of the physical host in the embodiment of the present invention.
  • the communication unit 240 is used to establish a communication connection between the physical host 10 and the cloud platform 20 and other devices through the network, and is used to receive and send data through the network.
  • the cloud platform 20 may also include more or less components than those shown in FIG. 2, and may also have a completely different configuration from that shown in FIG. 2, which is not limited in this embodiment.
  • the components shown in FIG. 2 can be implemented by software, hardware or a combination thereof.
  • the cloud platform 20 can also be implemented by hardware and/or software.
  • FIG. 3 it is a schematic flowchart of a method for renting a physical host that can be applied to the cloud platform 20 in FIG. 1a provided by an embodiment of the present application. The specific process and steps of the method are described in detail below.
  • Step S310 Receive the lease request of the user's physical host.
  • step S310 further includes:
  • step S309 the user is provided with information about the physical host that can be sold in the inventory.
  • the user can query the information of the physical host 10 through the cloud platform 20, and obtain the physical host information that can be used for sale from the inventory, and the physical host information that can be used for sale It is displayed on the cloud platform 20 to facilitate the user to select physical hosts that can be sold to generate a lease request for the physical host.
  • inventory refers to a database used to record the status of a physical host, where the status of the physical host 10 includes an unsellable status and a sellable status.
  • the inventory can be saved to the cloud platform 20, or can be saved by other cloud devices, and the cloud platform 20 obtains inventory information by accessing the cloud device.
  • the method may further include:
  • Step S311 Freeze the physical host information available for sale in the inventory, and generate an order for the requested physical host.
  • the entire inventory may be frozen, or only the physical host 10 that needs to be paid in the inventory may be frozen.
  • step S312 if it is detected that the user has completed the payment of the order, release and update the inventory of the physical host information that can be sold.
  • Step S320 Acquire installed resources of the physical host and perform installation processing on the physical host based on the installed resources.
  • the selected physical host 10 can be automatically installed.
  • the user can set the network status of the physical host 10 through the Intelligent Platform Management Interface (IPMI) on the cloud platform 20, so that the physical host 10 can obtain data (such as installed resources) through the network.
  • IPMI Intelligent Platform Management Interface
  • the physical host 10 can send a DHCP (Dynamic Host Configuration Protocol) request to obtain from the operation and maintenance management network
  • the IP address Internet Protocol, Internet Protocol
  • the IP address obtains the installation configuration information from the operation and maintenance management network, and pulls the mirror data according to the installation configuration information to start the installation.
  • the installation status of the physical host 10 needs to be monitored. Specifically, it is possible to determine whether the installation status of the physical host 10 is updated by monitoring the installation identification in the physical host 10. In an implementation manner, optionally, the installation completion status of the physical host 10 can be queried by polling.
  • the physical host 10 can be queried every preset time period whether the physical host 10 has completed the installation. If it is completed, stop the query.
  • the preset time period can be set according to the actual situation, and the specific value is not limited. In the case that the installation of the physical host is completed by polling, step S330 is entered.
  • Step S330 After the installation process is completed, the physical host is added to the designated virtual private cloud VPC.
  • step S330 may be implemented through the following steps:
  • the physical host 10 is restarted, so that the restarted physical host 10 can obtain the private IP address of the designated VPC through the switch device after the network configuration.
  • the physical host 10 can join the VPC after acquiring the private IP address of the VPC.
  • the switch device may include a PDN gateway and a top of rack switch TOR (Top of Rack), and the TOR may correspond to the router 30 and the switch 40 in FIG. 1a.
  • the configuration information of TOR includes physical interfaces, tunnels and virtual routers.
  • the configuration information of the PDN gateway includes DHCP configuration information and VPC configuration information.
  • the DHCP configuration information is used to obtain the private IP address of the VPC.
  • the VPC configuration information is similar to the TOR configuration information.
  • the administrator can input data related to TOR and the physical host 10 in the background to complete the registration of the resources of the physical host 10 on the cloud platform.
  • #2TOR datapath ip/Uplink switch data communication IP address mainly for communication with other TOR and PGW/;
  • #3TOR index range (subscript range)/The range of the port identification number of the uplink switch, the identification number range will be different for different device models/;
  • #4enabled(0or 1)/ is used to identify whether you have joined the virtual private cloud VPC, 1 means joining, 0 means not joining/.
  • #2TOR index number (one-to-one relationship with #3Downlink Physical host MAC)/The port identification number of the uplink switch, the identification id description of different types of equipment is different, and is limited to the value of the index range of the equipment/;
  • the computing resources of the registered physical host 10 can be leased and used normally.
  • the user's use of the physical host 10 is similar to the user's use of the virtual host.
  • the user selects the VPC created by himself in the cloud platform 20 to create a physical host 10 and configure network resources.
  • the user can register the physical host through the aforementioned incoming parameters.
  • the following network configuration can be performed on the TOR and PDN gateways to provide services after high-performance physical hosts are connected.
  • the configuration of DHCP and virtual private cloud VPC for the PDN gateway is similar to the configuration of the TOR for the VPC configuration of the PDN gateway.
  • a VPC usually includes: a router, at least one private network segment, and at least one switch (switch 1, switch 2, ... switch N, N represents a positive integer), the router and each switch To connect, the switch can be connected to ECS (Elastic Compute Service, cloud server), or RDS (Relational Database Service, relational database), or other cloud resources, or can also be connected to a local network.
  • ECS Elastic Compute Service, cloud server
  • RDS Relational Database Service, relational database
  • the connection between the switch and ECS, RDS, other cloud resources, and the local network is only an example and does not constitute a limitation.
  • the physical host is connected to the TOR, the TOR is connected to the PDN gateway, the PDN gateway is connected to the VPC, and the PDN gateway can be connected to the switch in the VPC.
  • the physical host can communicate with ECS, RDS, other cloud resources, local network, etc.
  • a physical host can be added to multiple VPCs.
  • Fig. 1b only shows one VPC, and Fig. 1b is only an exemplary description and does not constitute a limitation.
  • the resources listed in PGW assets are listed in neutron vpc (neutron is the core component of OpenStack to provide network services, OpenStack is an open source cloud computing management platform project, a series of The combination of software open source projects) can be correlated in related implementations, and the physical host 10 is treated as a virtual host without adding an additional database table (DB table).
  • neutron vpc neutron is the core component of OpenStack to provide network services
  • OpenStack is an open source cloud computing management platform project
  • DB table database table
  • KscTor When configuring TOR, you can add three tables, such as KscTor, KscTortunnel, and KscPhyHost to ensure data persistence.
  • Ksc means product identifier
  • Tor means top-of-rack switch
  • Tortunnel means top-of-rack switch tunnel
  • PhyHost means physical host
  • the names of these three tables are just examples and do not constitute a limitation.
  • the cloud platform administrator can create (create), delete (delete) and configure (get) the physical host through the following functional interfaces.
  • the parameters carried in the call to create_ksctor are as described above (register TOR).
  • Operations such as creation, deletion, and configuration of the physical host 10 in the virtual network are similar to those of the original virtual host, and the user has no perception.
  • the method may further include the step of recycling the physical host 10.
  • the step of recycling the physical host 10 may include:
  • the deleted physical host 10 is reclaimed; or when the lease term of the physical host 10 expires and the user does not renew the fee, the physical host 10 is reclaimed .
  • the cloud platform may apply for an elastic public network IP address for the physical host, and bind the applied elastic public network IP address with the physical host, so that the physical host can access the public network.
  • the leasing process includes a process of creating a physical host and a process of performing network configuration on the created physical host.
  • Figure 5 shows a flow chart of the physical host creation process.
  • the interactive subjects in Figure 5 include: console, physical host OpenAPI (API: Application Programming Interface), Inventory system, order system, transaction payment, physical host IPMI (Intelligent Platform Management Interface) API (application programming interface) and binding resources.
  • the bound resource can be EIP (Enterprise Information Portal, Enterprise Information Portal), or it can be other, and the specifics are not limited.
  • Each interaction subject in FIG. 5 may be a functional module provided by the cloud platform 20, and these functional modules may be distributed in different servers and executed by different servers.
  • the process of creating a physical host is as follows: the user queries the inventory system for the information of the available physical host through the console, and the inventory system feeds back the information of the available physical host that can be found to the console; then, the user submits the creation physical host information through the console to query And freeze the sellable physical host information in the inventory system; then, after the user chooses to sell the physical host 10, the physical host request is sent to the order system through the physical host OpenAPI, and the order system sends the order payment request to the transaction payment system, and the transaction payment The system returns an order payment success response, indicating that the transaction is completed. The order system returns the order information of the physical host that was successfully paid.
  • the inventory system releases and updates the inventory information; then, through the physical host OpenAPI, request the physical host IPMI API to open the physical host 10, the physical host IPMI After the API is successfully activated, it returns a response to successfully activate the physical host 10, and then requests physical host resource binding from the bound resource through the physical host OpenAPI. After returning the resource binding response, the physical host OpenAPI returns the physical host resource information to the console. .
  • FIG. 6 shows the process of network configuration of the physical host 10.
  • the interactive subjects in Figure 6 include: console, physical host OpenAPI (Open Application Programming Interface, API: Application Programming Interface), automated installation Server (server), IPMI/physical host, VPC API, EIP, and other cloud products.
  • OpenAPI Open Application Programming Interface
  • API Application Programming Interface
  • server automated installation Server
  • IPMI/physical host VPC API
  • VPC API VPC API
  • EIP EIP
  • resource installation IPMI/physical host is performed during the process of starting physical host 10 Initialize RAID (Redundant Arrays of Independent Disks), LOAD Image (load icon, or cursor, or bitmap), system installation, and finally feedback the installation status of physical host 10 to the console, and update the display of the physical host on the console 10 status.
  • Figure 7 shows the large-scale deployment of the cloud platform in this embodiment.
  • the interactive entities in Figure 7 include: open platform (open API), operation and maintenance management network (DHCP&SFTP, DHCP: Dynamic Host Configuration Protocol) , Dynamic host configuration protocol; SFTP: SSH File Transfer Protocol, SSH file transfer protocol, SSH: Secure Shell, secure shell protocol), scheduler (scheduler), intelligent platform management interface (IPMI) API, physical host, internal API (inner -API), Status Manager (Status Manager), Virtual Private Cloud (VPC), Software Defined Network/Top of Rack Switch/PDN Gateway (SDN/TOR/PGW; SDN: Software Defined Network, Software Defined Network).
  • (1) in Figure 7 means: the open platform (open API) receives the creation request and obtains an available physical host from the scheduler (scheduler); (2) means: the open platform uses the Intelligent Platform Management Interface (IPMI) API Set the physical host as network startup; (3) means: the physical host initiates a DHCP request to obtain the operation and maintenance management network IP address; (4) means: the physical host obtains the physical host's installed configuration information from the internal API (inner-API); (5) Means: the physical host obtains the mirror data from the operation and maintenance management network and starts installation; (6) Means: updates the installation status of the physical host during the installation process; (7) Means: polls the installation status of the physical host, if the installation is marked When finished, call the relevant interface of the VPC to join the VPC network; (8) means: send switch configuration information; (9) means that the physical host gets the VPC private IP address through the switch after restarting; (10) means: update the final physical host 10 status.
  • IPMI Intelligent Platform Management Interface
  • the open platform receives the creation request, obtains an available physical host 10 from the scheduler (scheduler), and the open platform sets the network startup status of the physical host 10 through the intelligent platform management interface (IPMI);
  • IPMI intelligent platform management interface
  • the physical host 10 initiates a DHCP request to obtain an IP address from the operation and maintenance management network, and the physical host 10 obtains the installation configuration information of the physical host 10 from an internal API (inner-api).
  • the physical host 10 obtains the mirrored data from the operation and maintenance management network and starts the installation; then, during the installation process, the installation status of the physical host 10 is updated.
  • the relevant interface of the VPC is called to join the VPC Network; Finally, the virtual network delivers the configuration information of the switch to the physical host 10. After the physical host 10 restarts, the VPC private IP address is obtained through the switch, and the final state of the physical host 10 is updated.
  • the physical host 10 can access the virtual network environment, and can perform the same virtual network configuration and function joint management with the cloud host, including functions such as elastic IP address, virtual gateway, and security group. In addition, higher network performance is provided between the physical host 10 and the virtual host.
  • the physical host cluster is not really in the virtual private cloud VPC, and many VPC features cannot be realized; 2. Although the physical host can have the characteristics of the virtual private cloud VPC, but Because it is a virtual private cloud independent of the cloud host, its network connectivity has limitations. Applying the embodiment shown in this application, 1. The physical host obtains the private IP address of the VPC, the physical host connects to the TOR, the TOR connects to the PDN gateway, and the PDN gateway connects to the VPC. This realizes that the physical host actually joins the VPC and can realize VPC Features; 2. The physical host has joined the VPC. The VPC includes the physical host and the cloud host. The physical host is not independent of the cloud host and has better network connectivity.
  • the embodiment of the present application also provides a rental device of a physical host, and the rental device of the physical host is a virtual device corresponding to the foregoing method. It is understandable that the specific functions of each functional module involved in the rental device of the physical host to be described below have been described in detail in the corresponding steps of the above embodiment, and the detailed content of each specific functional module can refer to the above embodiment. Description, the following only briefly describes the rental device of the physical host.
  • the leasing device 210 for a physical host may include:
  • the receiving module 2101 is configured to receive a lease request of a user's physical host, where the physical host leased by the user is a physical host selected by the user from the physical hosts that can be sold.
  • the obtaining module 2102 is configured to obtain installed resources of the physical host and perform installation processing on the physical host based on the installed resources.
  • the acquisition module 2102 is specifically set as follows:
  • the network state of the physical host is set, so that the physical host obtains installation configuration information through the network, and completes the installation according to the installation configuration information.
  • the joining module 2103 is set to add the physical host to the designated virtual private cloud VPC after the installation process is completed, so as to deploy the physical host as a computing node in the VPC for the user to use, wherein the VPC also A cloud host as a computing node is deployed.
  • the joining module 2103 is also set to:
  • the switch device includes a PDN gateway and a top-of-rack switch TOR
  • the configuration information of the PDN gateway includes DHCP configuration information and VPC configuration information
  • the configuration information of the TOR includes physical interfaces, tunnels, and virtual routers.
  • the adding module 2103 is also set to:
  • the communication between the uplink interface and the PDN gateway is established through the tunnel established by the virtual router, so as to realize that the uplink interface joins the virtual private cloud VPC, wherein the PDN gateway is set to access the VPC.
  • the leasing device 210 of the physical host may further include: an application and binding module 2104;
  • the application and binding module 2104 is configured to apply for an elastic public network IP address for the physical host, and bind the applied elastic public network IP address with the physical host, so that the physical host can access the public network.
  • the leasing device 210 of the physical host may further include:
  • the physical host recovery module 2105 is configured to recover the deleted physical host when the user deletes the physical host; or when the lease term of the physical host expires and the user has not renewed The physical host recycling.
  • the leasing device 210 of the physical host may further include: an information providing module 2106, an information freezing module 2107, and an information releasing and updating module 2108.
  • the information providing module 2106 is configured to provide the user with the information of the sellable physical host in inventory
  • the information freezing module 2107 is configured to freeze the information of the sellable physical host in the inventory after receiving the lease request of the user's physical host, and generate an order requesting the physical host;
  • the information release and update module 2108 is configured to release and update the physical host information of the inventory that can be sold if it is detected that the user completes the payment of the order.
  • the above functions are implemented in the form of software function modules and sold or used as independent products, they can be stored in a computer readable storage medium.
  • the technical solution of this application essentially or the part that contributes to the related technology or the part of the technical solution can be embodied in the form of a software product.
  • the computer software product is stored in a storage medium, including several The instructions are used to make the device execute all or part of the steps of the methods described in the various embodiments of the present application.
  • the aforementioned storage media include: U disk, mobile hard disk, read-only memory (English: Read-Only Memory, abbreviated as: ROM), random access memory (English: Random Access Memory, abbreviated as: RAM), magnetic disk or optical disk, etc.
  • the embodiments of the present application provide a method, device, cloud platform, and readable storage medium for renting a physical host.
  • the method is applied to the cloud platform.
  • the physical host lease request includes the physical host that can be sold selected by the user; then, the installed resources of the physical host are obtained and based on the installed capacity.
  • the resources are installed on the physical host; finally, the physical host after installation is added to the designated virtual private cloud VPC for users to use.
  • the above method allows the physical host to naturally access the virtual network environment, and can perform the same virtual network configuration and function joint management with the cloud host, including functions such as elastic IP address, virtual gateway, and security group. And provide higher network performance between the physical host and the virtual host.
  • each block in the flowchart or block diagram may represent a module, program segment, or part of the code, and the module, program segment, or part of the code contains one or more functions for realizing the specified logical function.
  • Executable instructions may also occur in a different order from the order marked in the drawings.
  • each block in the block diagram and/or flowchart, and the combination of the blocks in the block diagram and/or flowchart can be implemented by a dedicated hardware-based system that performs the specified functions or actions Or it can be realized by a combination of dedicated hardware and computer instructions.
  • the functional modules in the various embodiments of the present application may be integrated together to form an independent part, or each module may exist alone, or two or more modules may be integrated to form an independent part.
  • An embodiment of the present application also provides a cloud platform, which includes a processor and a non-volatile memory storing computer instructions.
  • a cloud platform which includes a processor and a non-volatile memory storing computer instructions.
  • the embodiment of the present application also provides a readable storage medium, the readable storage medium includes a computer program, and when the computer program runs, the electronic device where the readable storage medium is located executes any one of the aforementioned methods for renting a physical host.
  • An embodiment of the present application also provides an executable program code, wherein the executable program code is configured to be executed to execute any one of the aforementioned methods for renting a physical host.

Landscapes

  • Engineering & Computer Science (AREA)
  • Computer Networks & Wireless Communication (AREA)
  • Signal Processing (AREA)
  • Business, Economics & Management (AREA)
  • Theoretical Computer Science (AREA)
  • Accounting & Taxation (AREA)
  • Software Systems (AREA)
  • General Physics & Mathematics (AREA)
  • Physics & Mathematics (AREA)
  • Finance (AREA)
  • General Engineering & Computer Science (AREA)
  • Development Economics (AREA)
  • Economics (AREA)
  • Marketing (AREA)
  • Strategic Management (AREA)
  • General Business, Economics & Management (AREA)
  • Computer Security & Cryptography (AREA)
  • Data Exchanges In Wide-Area Networks (AREA)
  • Management, Administration, Business Operations System, And Electronic Commerce (AREA)

Abstract

The embodiments of the present application provide a method and a device for leasing a physical host, a cloud platform, and a readable storage medium, relating to the field of virtual network technologies. The method is applied to a cloud platform. The method comprises: firstly, receiving a lease request for a physical host from a user, wherein the physical host is a leaseable physical host selected by the user; next, acquiring resources to be installed onto the physical host, and performing resource installation processing on the physical host on the basis of the resources to be installed; finally, adding the physical host, on which the resources have been installed, into a designated virtual private cloud (VPC), for the user to use. In the method above, the physical host selected by the user can be added into the VPC after resource installation, and the rapid creation and deployment of a physical host and virtual network configuration on a public cloud platform can be realized.

Description

物理主机的租赁方法、装置、云平台及可读存储介质Lease method, device, cloud platform and readable storage medium of physical host
本申请要求于2019年5月31日提交中国专利局、申请号为201910471456.9、发明名称为“物理主机的租赁方法、装置、云平台及可读存储介质”的中国专利申请的优先权,其全部内容通过引用结合在本申请中。This application claims the priority of a Chinese patent application filed with the Chinese Patent Office on May 31, 2019, the application number is 201910471456.9, and the invention title is "Physical Host Rental Method, Device, Cloud Platform and Readable Storage Medium", all of which The content is incorporated in this application by reference.
技术领域Technical field
本申请涉及虚拟网络技术领域,具体而言,涉及一种物理主机的租赁方法、装置、云平台及可读存储介质。This application relates to the field of virtual network technology, and in particular to a method, device, cloud platform and readable storage medium for renting a physical host.
背景技术Background technique
云计算平台目前的应用已非常广泛,面对日益繁多的云计算应用场景,公有云服务商往往不仅仅提供云主机服务,还会提供物理主机的计算服务,特别是随着人工智能AI行业爆发式的增长对GPU(Graphics Processing Unit)物理主机的强烈需求,发展如何快速有效的在公有云平台创建部署物理主机并进行虚拟网络配置,成为目前公有云服务商的要解决的艰巨任务。The current application of cloud computing platforms has been very extensive. In the face of increasingly diverse cloud computing application scenarios, public cloud service providers often provide not only cloud host services, but also physical host computing services, especially with the outbreak of the artificial intelligence AI industry The rapid growth of GPU (Graphics Processing Unit) has a strong demand for physical hosts. How to quickly and effectively create and deploy physical hosts on public cloud platforms and configure virtual networks has become an arduous task for public cloud service providers.
发明内容Summary of the invention
有鉴于此,本申请的目的在于提供一种物理主机的租赁方法、装置、云平台及可读存储介质,用以解决上述问题。In view of this, the purpose of this application is to provide a method, device, cloud platform and readable storage medium for renting a physical host to solve the above-mentioned problems.
第一方面,本申请实施例提供一种物理主机的租赁方法,应用于云平台,所述方法包括:In the first aspect, an embodiment of the present application provides a method for renting a physical host, applied to a cloud platform, and the method includes:
接收用户的物理主机的租赁请求,其中,所述用户租赁的物理主机为所述用户从可售卖物理主机中选择的物理主机;Receiving a lease request of a user's physical host, where the physical host leased by the user is a physical host selected by the user from the physical hosts that can be sold;
获取所述物理主机的装机资源并基于所述装机资源对所述物理主机进行装机处理;Acquiring installed resources of the physical host and performing installation processing on the physical host based on the installed resources;
在完成装机处理后,将所述物理主机加入指定的虚拟私有云VPC中,以将所述物理主机部署为所述VPC中的计算节点供所述用户使用,其中,所述VPC中还部署有作为计算节点的云主机。After the installation process is completed, the physical host is added to the designated virtual private cloud VPC to deploy the physical host as a computing node in the VPC for the user to use, wherein the VPC is also deployed As a cloud host for computing nodes.
可选地,在本实施例中,获取所述物理主机的装机资源并基于所述装机资源对所述物理主机进行装机处理包括:Optionally, in this embodiment, acquiring the installed resources of the physical host and performing installation processing on the physical host based on the installed resources includes:
对所述物理主机网络状态进行设定,以使所述物理主机通过网络获得装 机配置信息,并根据装机配置信息完成装机。The network status of the physical host is set so that the physical host obtains installation configuration information through the network, and completes the installation according to the installation configuration information.
可选地,在本实施例中,所述方法还包括:Optionally, in this embodiment, the method further includes:
为所述物理主机申请弹性公网IP地址,并将申请到的弹性公网IP地址与所述物理主机进行绑定,以使所述物理主机能够访问公网。Apply for an elastic public network IP address for the physical host, and bind the applied elastic public network IP address with the physical host, so that the physical host can access the public network.
可选地,在本实施例中,将所述物理主机加入指定的VPC中包括:Optionally, in this embodiment, adding the physical host to the designated VPC includes:
建立所述物理主机与所述指定的VPC的绑定关系;Establishing a binding relationship between the physical host and the designated VPC;
确定所述物理主机对应的交换机配置信息,并将所述交换机配置信息下发至所述VPC中所述物理主机对应的交换机设备;Determine switch configuration information corresponding to the physical host, and deliver the switch configuration information to the switch device corresponding to the physical host in the VPC;
重启所述物理主机,以使所述物理主机获取到所述指定的VPC的私有IP地址。Restart the physical host, so that the physical host obtains the private IP address of the designated VPC.
可选地,在本实施例中,所述交换机设备包括PDN网关和架顶交换机TOR,所述PDN网关的配置信息包括DHCP配置信息及VPC配置信息,所述TOR的配置信息包括物理接口、隧道及虚拟路由器。Optionally, in this embodiment, the switch device includes a PDN gateway and a top-of-rack switch TOR, the configuration information of the PDN gateway includes DHCP configuration information and VPC configuration information, and the configuration information of the TOR includes physical interfaces and tunnels. And virtual routers.
可选地,在本实施例中,将所述物理主机加入指定的VPC中的步骤还包括:Optionally, in this embodiment, the step of adding the physical host to the designated VPC further includes:
将所述物理主机的上联接口加入所述虚拟路由器;Adding the uplink interface of the physical host to the virtual router;
通过所述虚拟路由器建立的隧道建立所述上联接口与所述PDN网关的通信,以实现所述上联接口加入所述虚拟私有云VPC,其中所述PDN网关用于接入所述VPC。The communication between the uplink interface and the PDN gateway is established through the tunnel established by the virtual router, so as to realize that the uplink interface joins the virtual private cloud VPC, where the PDN gateway is used to access the VPC.
可选地,在本实施例中,所述方法还包括:Optionally, in this embodiment, the method further includes:
在用户删除所述物理主机时,将所述删除的物理主机回收;或When the user deletes the physical host, reclaim the deleted physical host; or
在所述物理主机的租赁期限到期,且用户没有续费时,将所述物理主机回收。When the lease term of the physical host expires and the user does not renew, the physical host is recycled.
可选地,在本实施例中,在所述接收用户的物理主机的租赁请求之前,所述方法还包括:Optionally, in this embodiment, before the receiving the lease request of the user's physical host, the method further includes:
向用户提供库存的可售卖物理主机信息;Provide users with inventory of physical host information that can be sold;
在所述接收用户的物理主机的租赁请求之后,所述方法还包括:After receiving the lease request of the user's physical host, the method further includes:
冻结库存的可售卖物理主机信息,生成请求所述物理主机的订单;Freeze the physical host information in the inventory that can be sold, and generate an order requesting the physical host;
如果检测到用户完成所述订单的支付后,释放并更新库存的可售卖物理 主机信息。If it is detected that the user completes the payment of the order, release and update the inventory of the sellable physical host information.
第二方面,本申请实施例还提供一种物理主机的租赁装置,应用于云平台,所述装置包括:In the second aspect, an embodiment of the present application also provides a device for renting a physical host, applied to a cloud platform, and the device includes:
接收模块,设置为接收用户的物理主机的租赁请求,其中,所述用户租赁的物理主机为所述用户从可售卖物理主机中选择的物理主机;A receiving module, configured to receive a lease request of a user's physical host, wherein the physical host leased by the user is a physical host selected by the user from the physical hosts that can be sold;
获取模块,设置为获取所述物理主机的装机资源并基于所述装机资源对所述物理主机进行装机处理;An obtaining module, configured to obtain installed resources of the physical host and perform installation processing on the physical host based on the installed resources;
加入模块,设置为在完成装机处理后,将所述物理主机加入指定的虚拟私有云VPC中,以将所述物理主机部署为所述VPC中的计算节点供所述用户使用,其中,所述VPC中还部署有作为计算节点的云主机。The joining module is configured to add the physical host to a designated virtual private cloud VPC after the installation process is completed, so as to deploy the physical host as a computing node in the VPC for the user to use, wherein the A cloud host as a computing node is also deployed in the VPC.
第三方面,本申请实施例还提供一种云平台,该云平台包括处理器及存储有计算机指令的非易失性存储器,计算机指令被交换机执行时,实现第一方面中的物理主机的租赁方法。In the third aspect, embodiments of the present application also provide a cloud platform, which includes a processor and a non-volatile memory storing computer instructions. When the computer instructions are executed by a switch, the lease of the physical host in the first aspect is realized. method.
第四方面,本申请实施例还提供一种可读存储介质,所述可读存储介质包括计算机程序,所述计算机程序运行时控制所述可读存储介质所在电子设备执行第一方面中的物理主机的租赁方法。In a fourth aspect, an embodiment of the present application also provides a readable storage medium. The readable storage medium includes a computer program. When the computer program runs, the electronic device where the readable storage medium is located executes the physical Host rental method.
第五方面,本申请实施例还提供一种可执行程序代码,其中,所述可执行程序代码设置为被运行以执行第一方面中的物理主机的租赁方法。In a fifth aspect, an embodiment of the present application further provides an executable program code, wherein the executable program code is configured to be executed to execute the physical host lease method in the first aspect.
相较于相关技术,本申请具有以下有益效果:Compared with related technologies, this application has the following beneficial effects:
本申请实施例提供一种物理主机的租赁方法、装置、云平台及可读存储介质。其中,所述方法应用云平台,首先,接收用户的物理主机的租赁请求,其中所述物理主机的租赁请求中包括用户选择的可售卖的物理主机;接着,获取物理主机的装机资源并基于装机资源对物理主机进行装机处理;最后,将装机完成后的物理主机加入指定的虚拟私有云VPC中,以供用户使用。上述方法能够将用户选择的物理主机进行装机后加入虚拟私有云VPC中,可以实现在公有云平台快速创建部署物理主机并进行虚拟网络配置。The embodiments of the present application provide a method, device, cloud platform, and readable storage medium for renting a physical host. Wherein, the method is applied to the cloud platform. First, the user's physical host lease request is received, where the physical host lease request includes the physical host that can be sold selected by the user; then, the installed resources of the physical host are obtained and based on the installed capacity. The resources are installed on the physical host; finally, the physical host after installation is added to the designated virtual private cloud VPC for users to use. The above method can add the physical host selected by the user to the virtual private cloud VPC after installation, and can realize the rapid creation and deployment of the physical host on the public cloud platform and the virtual network configuration.
当然,实施本发明的任一产品或方法并不一定需要同时达到以上所述的所有优点。Of course, implementing any product or method of the present invention does not necessarily need to achieve all the advantages described above at the same time.
附图说明Description of the drawings
为了更清楚地说明本申请实施例和相关技术的技术方案,下面对实施例和相关技术中所需要使用的附图作简单地介绍,显而易见地,下面描述中的附图仅仅是本申请的一些实施例,对于本领域普通技术人员来讲,在不付出创造性劳动的前提下,还可以根据这些附图获得其他的附图。In order to more clearly illustrate the technical solutions of the embodiments of the present application and related technologies, the following briefly introduces the drawings that need to be used in the embodiments and related technologies. Obviously, the drawings in the following description are only of the present application. For some embodiments, those of ordinary skill in the art can obtain other drawings based on these drawings without creative work.
图1a为本申请实施例提供的一种物理主机的租赁系统的结构示意图;Figure 1a is a schematic structural diagram of a physical host leasing system provided by an embodiment of the application;
图1b为本申请实施例提供的一种物理主机加入VPC的结构示意图;Figure 1b is a schematic structural diagram of a physical host joining a VPC according to an embodiment of the application;
图2为本申请实施例提供的一种云平台的方框示意图;2 is a schematic block diagram of a cloud platform provided by an embodiment of the application;
图3为本申请实施例提供的物理主机的租赁方法的流程示意图之一;FIG. 3 is one of the schematic flowcharts of a method for renting a physical host provided by an embodiment of the application;
图4为本申请实施例提供的物理主机的租赁方法的流程示意图之二;FIG. 4 is a second schematic diagram of the process of a method for renting a physical host provided by an embodiment of the application;
图5为本申请实施例提供的物理主机的网络配置的过程示意图之一;FIG. 5 is one of the schematic diagrams of the network configuration process of the physical host provided by the embodiment of the application;
图6为本申请实施例提供的物理主机的网络配置的过程示意图之二;FIG. 6 is the second schematic diagram of the network configuration process of the physical host provided by the embodiment of this application;
图7为本申请实施例提供云平台的规模化部署情况及流程图;FIG. 7 is a large-scale deployment situation and flowchart of a cloud platform provided by an embodiment of the application;
图8为本实施例提供的物理主机的租赁装置的功能模块框图之一;FIG. 8 is one of the functional module block diagrams of the lease device of the physical host provided by this embodiment;
图9为本实施例提供的物理主机的租赁装置的功能模块框图之二。Figure 9 is the second block diagram of the functional modules of the physical host leasing device provided by this embodiment.
具体实施方式Detailed ways
为使本申请的目的、技术方案、及优点更加清楚明白,以下参照附图并举实施例,对本申请进一步详细说明。显然,所描述的实施例仅仅是本申请一部分实施例,而不是全部的实施例。基于本申请中的实施例,本领域普通技术人员在没有作出创造性劳动前提下所获得的所有其他实施例,都属于本申请保护的范围。In order to make the purpose, technical solutions, and advantages of the present application clearer, the following further describes the present application in detail with reference to the drawings and embodiments. Obviously, the described embodiments are only a part of the embodiments of the present application, rather than all the embodiments. Based on the embodiments in this application, all other embodiments obtained by those of ordinary skill in the art without creative work fall within the protection scope of this application.
相关的公有云平台提供给予虚拟网络环境的物理主机服务一般有两种方式:Related public cloud platforms generally provide physical hosting services for virtual network environments in two ways:
一种是部署一套独立的物理主机集群,通过专线或VPN(Virtual Private Network,虚拟专用网络)方式与公有云环境中的云主机的虚拟私有云(VPC,Virtual Private Cloud)打通,实现网络连通的物理主机可以与虚拟网络中云主机进行数据通信。One is to deploy a set of independent physical host clusters to connect to the virtual private cloud (VPC, Virtual Private Cloud) of cloud hosts in the public cloud environment through a dedicated line or VPN (Virtual Private Network) to achieve network connectivity The physical host can communicate with the cloud host in the virtual network.
另一种是规划独立的物理主机集群的虚拟私有云VPC,将物理主机当成云主机计算节点进行虚拟网络相应功能的管理。云主机可以理解为虚拟主机。The other is to plan a virtual private cloud VPC with an independent physical host cluster, and treat the physical host as a cloud host computing node to manage the corresponding functions of the virtual network. Cloud hosting can be understood as virtual hosting.
上述两种方式都存在缺陷:Both of the above methods have defects:
第一种方式可以保证公有云环境中所有计算资源间彼此网络可达,但物理主机集群并未真正处于虚拟私有云VPC中,许多VPC的特性无法实现,如绑定弹性IP地址,配置安全组等。第二种方式虽然物理主机可以拥有虚拟私有云VPC的特性,但是因是独立于云主机之外的虚拟私有云,其网络连通性存在限制。The first method can ensure that all computing resources in the public cloud environment are reachable to each other, but the physical host cluster is not really in the virtual private cloud VPC, and many VPC features cannot be realized, such as binding elastic IP addresses and configuring security groups Wait. In the second method, although the physical host can have the characteristics of a virtual private cloud VPC, because it is a virtual private cloud independent of the cloud host, its network connectivity is limited.
除此以外,物理主机要提供如云主机一般弹性、安全、可靠的公有云服务,还需要在资源部署、安全防护、监控服务等模块进行交互,形成自动化、便捷可配置的服务提供给用户。In addition, physical hosts need to provide flexible, secure, and reliable public cloud services like cloud hosts, and they also need to interact with modules such as resource deployment, security protection, and monitoring services to form automated, convenient and configurable services for users.
为了解决上面相关技术中存在的缺陷,本申请实施例提供一种物理主机的租赁方法、装置、云平台及可读存储介质。In order to solve the defects in the above related technologies, embodiments of the present application provide a method, device, cloud platform, and readable storage medium for renting a physical host.
如图1a所示,是本申请实施例提供的物理主机租赁系统1的示意图。所述物理主机租赁系统1包括物理主机10、云平台20、路由器30、交换机40及PDN网关(PGW,PDN GateWay,PDN:Packet Data Network;分组数据网络网关)50。举例来说,一种情况下,可以通过同一台设备,比如TOR(Top of Rack,架顶交换机),来实现路由器30和交换机40的功能,具体设备不做限定。As shown in Fig. 1a, it is a schematic diagram of a physical host leasing system 1 provided by an embodiment of the present application. The physical host leasing system 1 includes a physical host 10, a cloud platform 20, a router 30, a switch 40, and a PDN gateway (PGW, PDN GateWay, PDN: Packet Data Network; packet data network gateway) 50. For example, in one case, the functions of the router 30 and the switch 40 can be realized through the same device, such as a TOR (Top of Rack, top of rack switch), and the specific device is not limited.
物理主机10与云平台20通信,云平台20接收用户操作。The physical host 10 communicates with the cloud platform 20, and the cloud platform 20 receives user operations.
PDN网关50用于接入虚拟私有云VPC,物理主机10经由路由器30、交换机40与PDN网关50连接,通过对路由器30、交换机40及PDN网关50进行网络设置可以使物理主机10加入虚拟私有云VPC。The PDN gateway 50 is used to access the virtual private cloud VPC. The physical host 10 is connected to the PDN gateway 50 via the router 30 and the switch 40. The physical host 10 can be added to the virtual private cloud by setting the network of the router 30, the switch 40 and the PDN gateway 50 VPC.
如图2所示,是本申请实施例提供的云平台20的一种方框示意图。云平台20包括物理主机的租赁装置210、存储器220、处理器230及通信单元240。As shown in FIG. 2, it is a schematic block diagram of the cloud platform 20 provided by an embodiment of the present application. The cloud platform 20 includes a rental device 210 of a physical host, a memory 220, a processor 230, and a communication unit 240.
存储器220、处理器230及通信单元240相互之间可以直接或间接地电性连接,以实现数据的传输或交互。物理主机的租赁装置210包括至少一个可以软件(software)或固件(firmware)的形式存储在存储器220中的计算机程序或软件功能模块,处理器230用于执行存储在存储器220中的可执行模块中的可执行程序,如存储在存储器220中的物理主机的租赁装置210,该物理主机的租赁装置210可以执行本发明所示实施例的中的物理主机的租赁方 法。所述通信单元240用于通过网络建立所述物理主机10与云平台20及其他设备之间的通信连接,并用于通过网络进行数据的接收和发送。The memory 220, the processor 230, and the communication unit 240 may be directly or indirectly electrically connected to each other to realize data transmission or interaction. The rental device 210 of the physical host includes at least one computer program or software function module that can be stored in the memory 220 in the form of software or firmware, and the processor 230 is used to execute the executable module stored in the memory 220 For example, the leasing device 210 of the physical host stored in the storage 220 can execute the leasing method of the physical host in the embodiment of the present invention. The communication unit 240 is used to establish a communication connection between the physical host 10 and the cloud platform 20 and other devices through the network, and is used to receive and send data through the network.
应当理解,云平台20还可以包括比图2所示更多或更少的组件,也可以具有与图2所示完全不同的配置,本实施例对此不做限制。图2所示的组件可以通过软件、硬件或其组合实现。对应地,云平台20也可通过硬件和/或软件实现。It should be understood that the cloud platform 20 may also include more or less components than those shown in FIG. 2, and may also have a completely different configuration from that shown in FIG. 2, which is not limited in this embodiment. The components shown in FIG. 2 can be implemented by software, hardware or a combination thereof. Correspondingly, the cloud platform 20 can also be implemented by hardware and/or software.
如图3所示,是本申请实施例提供的一种可应用于图1a中云平台20的物理主机的租赁方法的流程示意图。下面对该方法的具体流程及步骤做详细阐述。As shown in FIG. 3, it is a schematic flowchart of a method for renting a physical host that can be applied to the cloud platform 20 in FIG. 1a provided by an embodiment of the present application. The specific process and steps of the method are described in detail below.
步骤S310,接收用户的物理主机的租赁请求。Step S310: Receive the lease request of the user's physical host.
请参照图4,在本申请实施例中,在步骤S310之前所述方法还包括:Referring to FIG. 4, in the embodiment of the present application, the method before step S310 further includes:
步骤S309,向用户提供库存的可售卖物理主机信息。In step S309, the user is provided with information about the physical host that can be sold in the inventory.
在用户在云平台20上选择的物理主机10之前,用户可以通过云平台20中查询物理主机10的信息,从库存中获得可以用于售卖的物理主机信息,将可以用于售卖的物理主机信息显示到云平台20,便于用户对可售卖的物理主机进行选择,以生成物理主机的租赁请求。Before the user selects the physical host 10 on the cloud platform 20, the user can query the information of the physical host 10 through the cloud platform 20, and obtain the physical host information that can be used for sale from the inventory, and the physical host information that can be used for sale It is displayed on the cloud platform 20 to facilitate the user to select physical hosts that can be sold to generate a lease request for the physical host.
在本实施例中,库存是指用于记录物理主机状态的数据库,其中,所述物理主机10的状态包括不可售卖状态和可售卖状态。其中,所述库存可以保存到云平台20,也可以由其他云端设备进行保存,云平台20通过访问云端设备获得库存信息。In this embodiment, inventory refers to a database used to record the status of a physical host, where the status of the physical host 10 includes an unsellable status and a sellable status. Wherein, the inventory can be saved to the cloud platform 20, or can be saved by other cloud devices, and the cloud platform 20 obtains inventory information by accessing the cloud device.
请再一次参照图4,在图4所示实施例中,在步骤S310之后,所述方法还可以包括:Please refer to FIG. 4 again. In the embodiment shown in FIG. 4, after step S310, the method may further include:
步骤S311,冻结库存的可售卖物理主机信息,生成请求的物理主机的订单。Step S311: Freeze the physical host information available for sale in the inventory, and generate an order for the requested physical host.
在物理主机库存冻结时,其他用户不能进行物理主机交易,防止交易出现冲突。可选地,可以将整个库存冻结,也可以只将库存中需待支付的物理主机10冻结。When the physical host inventory is frozen, other users cannot conduct physical host transactions to prevent transaction conflicts. Optionally, the entire inventory may be frozen, or only the physical host 10 that needs to be paid in the inventory may be frozen.
步骤S312,如果检测到用户完成订单的支付后,释放并更新库存的可售卖物理主机信息。In step S312, if it is detected that the user has completed the payment of the order, release and update the inventory of the physical host information that can be sold.
在完成订单的支付后,释放并更新在本次支付后库存中的可售卖物理主机状态信息。After completing the payment of the order, release and update the state information of the sellable physical host in the inventory after the payment.
步骤S320,获取物理主机的装机资源并基于装机资源对所述物理主机进行装机处理。Step S320: Acquire installed resources of the physical host and perform installation processing on the physical host based on the installed resources.
在图4所示实施例中,可以对选定的物理主机10进行自动装机。用户可以通过云平台20上的智能平台管理接口(IPMI,Intelligent Platform Management Interface)对物理主机10的网络状态进行设定,以使物理主机10可以通过网络获取数据(比如装机资源)。In the embodiment shown in FIG. 4, the selected physical host 10 can be automatically installed. The user can set the network status of the physical host 10 through the Intelligent Platform Management Interface (IPMI) on the cloud platform 20, so that the physical host 10 can obtain data (such as installed resources) through the network.
以网络为运维管理网络为例来说,在物理主机10的网络启动状态设定完成后,物理主机10可以发送DHCP(Dynamic Host Configuration Protocol,动态主机配置协议)请求从运维管理网络中获取运维管理网络的IP地址(Internet Protocol,网际互连协议)地址,基于该IP地址从运维管理网络获取装机配置信息,根据装机配置信息拉取镜像数据开始装机。在装机过程中,需对物理主机10的装机状态进行监控,具体地,可以通过监控物理主机10中的装机标识来判断物理主机10的装机状态是否更新。一种实施方式中,可选地,可以通过轮询的方式查询物理主机10的装机完成情况,例如,可以每隔预设时间段,查询物理主机10是否完成装机,如果完成,停止查询,该预设时间段可以根据实际情况进行设定,具体数值不做限定。在轮询到物理主机装机完成的情况下,进入步骤S330。Taking the network as the operation and maintenance management network as an example, after the network startup status of the physical host 10 is set, the physical host 10 can send a DHCP (Dynamic Host Configuration Protocol) request to obtain from the operation and maintenance management network The IP address (Internet Protocol, Internet Protocol) address of the operation and maintenance management network, based on the IP address, obtains the installation configuration information from the operation and maintenance management network, and pulls the mirror data according to the installation configuration information to start the installation. During the installation process, the installation status of the physical host 10 needs to be monitored. Specifically, it is possible to determine whether the installation status of the physical host 10 is updated by monitoring the installation identification in the physical host 10. In an implementation manner, optionally, the installation completion status of the physical host 10 can be queried by polling. For example, the physical host 10 can be queried every preset time period whether the physical host 10 has completed the installation. If it is completed, stop the query. The preset time period can be set according to the actual situation, and the specific value is not limited. In the case that the installation of the physical host is completed by polling, step S330 is entered.
步骤S330,在完成装机处理后,将物理主机加入指定的虚拟私有云VPC中。Step S330: After the installation process is completed, the physical host is added to the designated virtual private cloud VPC.
将物理主机加入指定的VPC之后,用户便可以使用该物理主机的资源。After adding a physical host to a designated VPC, users can use the resources of the physical host.
一种实施方式中,步骤S330可以通过以下步骤实现:In an implementation manner, step S330 may be implemented through the following steps:
首先,建立物理主机10与指定的VPC的绑定关系。First, the binding relationship between the physical host 10 and the designated VPC is established.
接着,确定物理主机10对应的交换机配置信息,并将交换机配置信息下发至VPC中物理主机10对应的交换机设备,以使所述交换机设备基于所述交换机配置信息进行网络配置。Next, determine the switch configuration information corresponding to the physical host 10, and deliver the switch configuration information to the switch device corresponding to the physical host 10 in the VPC, so that the switch device performs network configuration based on the switch configuration information.
最后,重启物理主机10,以使重启后的物理主机10通过网络配置后的交换机设备获取到指定的VPC的私有IP地址。物理主机10获取到VPC的私有 IP地址,便可以加入该VPC中。Finally, the physical host 10 is restarted, so that the restarted physical host 10 can obtain the private IP address of the designated VPC through the switch device after the network configuration. The physical host 10 can join the VPC after acquiring the private IP address of the VPC.
举例来说,交换机设备可以包括PDN网关和架顶交换机TOR(Top of Rack),TOR可以对应于图1a中的路由器30和交换机40。TOR的配置信息包括物理接口、隧道及虚拟路由器。PDN网关的配置信息包括DHCP配置信息及VPC配置信息,DHCP配置信息用于获取VPC的私有IP地址,该VPC配置信息与TOR的配置信息类似。在将物理主机10加入虚拟私有云VPC之前,需要对接入虚拟私有云VPC的接入网络设备进行配置,即对TOR及PDN网关进行配置。具体地配置可以如下:For example, the switch device may include a PDN gateway and a top of rack switch TOR (Top of Rack), and the TOR may correspond to the router 30 and the switch 40 in FIG. 1a. The configuration information of TOR includes physical interfaces, tunnels and virtual routers. The configuration information of the PDN gateway includes DHCP configuration information and VPC configuration information. The DHCP configuration information is used to obtain the private IP address of the VPC. The VPC configuration information is similar to the TOR configuration information. Before adding the physical host 10 to the virtual private cloud VPC, it is necessary to configure the access network devices that access the virtual private cloud VPC, that is, configure the TOR and the PDN gateway. The specific configuration can be as follows:
管理人员可以在后台录入TOR和物理主机10相关的数据,完成物理主机10在云平台中注册资源。The administrator can input data related to TOR and the physical host 10 in the background to complete the registration of the resources of the physical host 10 on the cloud platform.
传入参数:Incoming parameters:
#1TOR management ip/上联交换机管理IP地址,用于对TOR自动化配置和检查/;#1TOR management ip/Uplink switch management IP address, used to automatically configure and check TOR/;
#2TOR datapath ip/上联交换机数据通信IP地址,主要是和其他的TOR以及PGW的通信/;#2TOR datapath ip/Uplink switch data communication IP address, mainly for communication with other TOR and PGW/;
#3TOR index range(下标范围)/上联交换机的端口识别号的范围,设备型号不同该识别号范围会不同/;#3TOR index range (subscript range)/The range of the port identification number of the uplink switch, the identification number range will be different for different device models/;
#4enabled(0or 1)/用于标识是否已经加入到虚拟私有云VPC,1表示加入,0表示未加入/。#4enabled(0or 1)/ is used to identify whether you have joined the virtual private cloud VPC, 1 means joining, 0 means not joining/.
在TOR上注册物理主机Register the physical host on TOR
传入参数:Incoming parameters:
#1TOR mgt ip/上联交换机管理IP地址,用于对TOR自动化配置和检查/;#1TOR mgt ip/Uplink switch management IP address, used to automatically configure and check TOR/;
#2TOR index number(与#3Downlink Physical host MAC一对一关系)/上联交换机的端口识别号,不同型号设备的标识id描述不一样,以及受限于该设备的index range内取值/;#2TOR index number (one-to-one relationship with #3Downlink Physical host MAC)/The port identification number of the uplink switch, the identification id description of different types of equipment is different, and is limited to the value of the index range of the equipment/;
#3TOR Downlink Physical host MAC(与#2index number一对一的关系)/物理主机的MAC地址/#3TOR Downlink Physical host MAC (one-to-one relationship with #2index number)/MAC address of the physical host/
云平台管理员初始化后,注册后的物理主机10的计算资源能被正常租赁 使用。用户对物理主机10的使用情况与用户对虚拟主机的使用情况类似。用户在云平台20中选择自己创建好的VPC即可创建物理主机10并配置网络资源。用户在注册物理主机10时可以通过上述传入参数实现物理主机的注册。After the cloud platform administrator is initialized, the computing resources of the registered physical host 10 can be leased and used normally. The user's use of the physical host 10 is similar to the user's use of the virtual host. The user selects the VPC created by himself in the cloud platform 20 to create a physical host 10 and configure network resources. When registering the physical host 10, the user can register the physical host through the aforementioned incoming parameters.
举例来说,可以对TOR和PDN网关进行如下的网络配置,以便于高性能物理主机接入后提供服务。For example, the following network configuration can be performed on the TOR and PDN gateways to provide services after high-performance physical hosts are connected.
对TOR进行物理接口、连接隧道、虚拟路由器等配置。对PDN网关进行DHCP及虚拟私有云VPC等配置,对PDN网关进行VPC配置与对TOR的配置类似。物理机网卡对应的上联接口加入到虚拟路由器后,再通过该虚拟路由器中建立的隧道建立上联接口与PDN网关的通信,物理主机通过DHCP Client(客户端)获取到虚拟私有云VPC的私有IP地址后就能与虚拟主机所在区域、Internet以及用户私有云通信,并且可以使用负载均衡、对象和文件存储等服务。Configure TOR for physical interfaces, connection tunnels, virtual routers, etc. The configuration of DHCP and virtual private cloud VPC for the PDN gateway is similar to the configuration of the TOR for the VPC configuration of the PDN gateway. After the uplink interface corresponding to the physical machine's network card is added to the virtual router, the communication between the uplink interface and the PDN gateway is established through the tunnel established in the virtual router, and the physical host obtains the private cloud of the virtual private cloud VPC through the DHCP Client (client). After the IP address, you can communicate with the virtual host area, the Internet, and the user's private cloud, and you can use services such as load balancing, object and file storage.
一般来说,参考图1b所示,一个VPC通常包括:一个路由器、至少一个私网网段和至少一个交换机(交换机1、交换机2……交换机N,N表示正整数),该路由器与各交换机相连接,交换机可以连接ECS(Elastic Compute Service,云服务器)、或者RDS(Relational Database Service,关系型数据库)、或者其他云资源、或者也可以连接本地网络。图1b中,交换机与ECS、RDS、其他云资源、本地网络的连接情况仅为示例性说明,并不构成限定。Generally speaking, referring to Figure 1b, a VPC usually includes: a router, at least one private network segment, and at least one switch (switch 1, switch 2, ... switch N, N represents a positive integer), the router and each switch To connect, the switch can be connected to ECS (Elastic Compute Service, cloud server), or RDS (Relational Database Service, relational database), or other cloud resources, or can also be connected to a local network. In Figure 1b, the connection between the switch and ECS, RDS, other cloud resources, and the local network is only an example and does not constitute a limitation.
上述例子中,物理主机连接TOR,TOR连接PDN网关,PDN网关接入VPC,PDN网关可以接入VPC中的交换机。通过上述配置的隧道,使得物理主机与ECS、RDS、其他云资源、本地网络等进行通信。物理主机可以加入多个VPC中,图1b仅示出了一个VPC,图1b仅为示例性说明,并不构成限定。In the above example, the physical host is connected to the TOR, the TOR is connected to the PDN gateway, the PDN gateway is connected to the VPC, and the PDN gateway can be connected to the switch in the VPC. Through the above configured tunnel, the physical host can communicate with ECS, RDS, other cloud resources, local network, etc. A physical host can be added to multiple VPCs. Fig. 1b only shows one VPC, and Fig. 1b is only an exemplary description and does not constitute a limitation.
可选地,在进行PDN网关配置时,PGW assets(资源)中所列举的资源在neutron vpc(neutron是OpenStack中提供网络服务的核心组件,OpenStack是一个开源的云计算管理平台项目,是一系列软件开源项目的组合)相关实现中都能对应起来,把物理主机10当作虚拟主机来看待不需要额外添加数据库表(DB table)。Optionally, when configuring the PDN gateway, the resources listed in PGW assets (resources) are listed in neutron vpc (neutron is the core component of OpenStack to provide network services, OpenStack is an open source cloud computing management platform project, a series of The combination of software open source projects) can be correlated in related implementations, and the physical host 10 is treated as a virtual host without adding an additional database table (DB table).
在对TOR进行配置时,可以通过添加三个表,比如,KscTor、KscTortunnel、 KscPhyHost来保证数据持久化,Ksc表示产品标识,Tor表示架顶交换机,Tortunnel表示架顶交换机隧道,PhyHost表示物理主机,这三个表的名称仅为举例说明,并不构成限定。When configuring TOR, you can add three tables, such as KscTor, KscTortunnel, and KscPhyHost to ensure data persistence. Ksc means product identifier, Tor means top-of-rack switch, Tortunnel means top-of-rack switch tunnel, and PhyHost means physical host The names of these three tables are just examples and do not constitute a limitation.
在进行接口配置时,云平台管理员可以通过以下函数接口对物理主机进行创建(create)、删除(delete)及配置(get)等操作。When configuring the interface, the cloud platform administrator can create (create), delete (delete) and configure (get) the physical host through the following functional interfaces.
Create_ksctors、delete_ksctors、get_ksctorsCreate_ksctors, delete_ksctors, get_ksctors
调用create_ksctor携带的参数如上述使用说明(注册TOR)。The parameters carried in the call to create_ksctor are as described above (register TOR).
Create_phyhosts/delete/getCreate_phyhosts/delete/get
调用create_phyhosts需要传入的参数如上述使用说明(注册Physical Host)。The parameters that need to be passed in to call create_phyhosts are as described in the above instructions (register Physical Host).
物理主机10在虚拟网络中的创建、删除、配置等操作与对原有的虚拟主机操作类似,用户无感知。Operations such as creation, deletion, and configuration of the physical host 10 in the virtual network are similar to those of the original virtual host, and the user has no perception.
在本实施例中,所述方法还可以包括回收物理主机10的步骤,具体地,回收物理主机10的步骤可以包括:In this embodiment, the method may further include the step of recycling the physical host 10. Specifically, the step of recycling the physical host 10 may include:
在用户删除所述物理主机10的情况下,将所述删除的物理主机10回收;或在所述物理主机10的租赁期限到期,且用户没有续费的情况下,将所述物理主机10回收。In the case where the user deletes the physical host 10, the deleted physical host 10 is reclaimed; or when the lease term of the physical host 10 expires and the user does not renew the fee, the physical host 10 is reclaimed .
一种实施方式中,云平台可以为所述物理主机申请弹性公网IP地址,并将申请到的弹性公网IP地址与所述物理主机进行绑定,这样,物理主机能够访问公网。In an implementation manner, the cloud platform may apply for an elastic public network IP address for the physical host, and bind the applied elastic public network IP address with the physical host, so that the physical host can access the public network.
下面以将一具体物理主机进行租赁的过程为例进行说明,该租赁过程包括创建物理主机的过程和对创建的物理主机进行网络配置的过程。The following takes the process of leasing a specific physical host as an example for description. The leasing process includes a process of creating a physical host and a process of performing network configuration on the created physical host.
首先,请参照图5,图5示出了物理主机创建过程的流程图,其中,图5中的交互主体包括:控制台、物理主机OpenAPI(开放的应用编程接口,API:Application Programming Interface)、库存系统、订单系统、交易支付、物理主机IPMI(智能平台管理接口)API(应用编程接口)及绑定资源。绑定资源可以为EIP(Enterprise Information Portal,企业信息门户),或者也可以为其 他,具体不做限定。图5中的各交互主体可以为云平台20提供的功能模块,这些功能模块可以分布在不同的服务器中,由不同的服务器执行。物理主机创建过程如下:用户通过控制台从库存系统中查询可售卖物理主机信息,库存系统将查找到的可售卖物理主机信息反馈给控制台;接着,用户通过控制台提交创建物理主机信息,查询并冻结库存系统中的可售卖物理主机信息;接着,用户在选择售卖物理主机10之后,通过物理主机OpenAPI将物理主机请求发送给订单系统,订单系统将订单支付请求发送给交易支付系统,交易支付系统返回订单支付成功响应,表示完成交易,订单系统返回成功支付的物理主机订单信息,库存系统释放并更新库存信息;再接着,通过物理主机OpenAPI请求物理主机IPMI API开通物理主机10,物理主机IPMI API在成功开通后返回成功开通物理主机10的响应,再通过物理主机OpenAPI向绑定资源请求物理主机资源绑定,在返回资源绑定的响应后,物理主机OpenAPI向控制台返回物理主机资源信息。First of all, please refer to Figure 5. Figure 5 shows a flow chart of the physical host creation process. The interactive subjects in Figure 5 include: console, physical host OpenAPI (API: Application Programming Interface), Inventory system, order system, transaction payment, physical host IPMI (Intelligent Platform Management Interface) API (application programming interface) and binding resources. The bound resource can be EIP (Enterprise Information Portal, Enterprise Information Portal), or it can be other, and the specifics are not limited. Each interaction subject in FIG. 5 may be a functional module provided by the cloud platform 20, and these functional modules may be distributed in different servers and executed by different servers. The process of creating a physical host is as follows: the user queries the inventory system for the information of the available physical host through the console, and the inventory system feeds back the information of the available physical host that can be found to the console; then, the user submits the creation physical host information through the console to query And freeze the sellable physical host information in the inventory system; then, after the user chooses to sell the physical host 10, the physical host request is sent to the order system through the physical host OpenAPI, and the order system sends the order payment request to the transaction payment system, and the transaction payment The system returns an order payment success response, indicating that the transaction is completed. The order system returns the order information of the physical host that was successfully paid. The inventory system releases and updates the inventory information; then, through the physical host OpenAPI, request the physical host IPMI API to open the physical host 10, the physical host IPMI After the API is successfully activated, it returns a response to successfully activate the physical host 10, and then requests physical host resource binding from the bound resource through the physical host OpenAPI. After returning the resource binding response, the physical host OpenAPI returns the physical host resource information to the console. .
请参照图6,图6示出了物理主机10的网络配置的过程。图6中的交互主体包括:控制台、物理主机OpenAPI(开放的应用编程接口,API:Application Programming Interface)、自动化安装Server(服务器)、IPMI/物理主机、VPC API、EIP和其他云产品。在获得物理主机10资源信息后,通过控制台提交创建物理主机10的信息,以向自动化安装Server请求安装物理主机10,向VPC API请求物理主机10的VPC绑定,向EIP请求物理主机10的EIP绑定,或向其他云产品请求其他资源,将VPC API、EIP及其他云产品反馈的物理主机的资源信息反馈给控制台;在启动物理主机10的过程中进行资源安装IPMI/物理主机进行初始化RAID(Redundant Arrays of Independent Disks,磁盘阵列)、LOAD Image(装载图标、或光标、或位图)、系统安装,最后将物理主机10安装情况反馈给控制台,并更新控制台上显示物理主机10的状态。Please refer to FIG. 6, which shows the process of network configuration of the physical host 10. The interactive subjects in Figure 6 include: console, physical host OpenAPI (Open Application Programming Interface, API: Application Programming Interface), automated installation Server (server), IPMI/physical host, VPC API, EIP, and other cloud products. After obtaining the resource information of the physical host 10, submit the information for creating the physical host 10 through the console to request the installation of the physical host 10 from the automated installation server, request the VPC binding of the physical host 10 from the VPC API, and request the EIP for the physical host 10 EIP binding, or request other resources from other cloud products, and feedback the resource information of physical hosts fed back by VPC API, EIP and other cloud products to the console; resource installation IPMI/physical host is performed during the process of starting physical host 10 Initialize RAID (Redundant Arrays of Independent Disks), LOAD Image (load icon, or cursor, or bitmap), system installation, and finally feedback the installation status of physical host 10 to the console, and update the display of the physical host on the console 10 status.
请参照图7,图7给出了本实施例云平台的规模化部署情况,图7中的各交互主体包括:开放平台(open API)、运维管理网络(DHCP&SFTP,DHCP:Dynamic Host Configuration Protocol,动态主机配置协议;SFTP:SSH File Transfer Protocol,SSH文件传输协议,SSH:Secure Shell,安全外壳协议)、调度器(scheduler)、智能平台管理接口(IPMI)API、物理主机、内部 API(inner-API)、状态管理器(Status Manager)、虚拟私有云(VPC)、软件定义网络/架顶交换机/PDN网关(SDN/TOR/PGW;SDN:Software Defined Network,软件定义网络)。Please refer to Figure 7. Figure 7 shows the large-scale deployment of the cloud platform in this embodiment. The interactive entities in Figure 7 include: open platform (open API), operation and maintenance management network (DHCP&SFTP, DHCP: Dynamic Host Configuration Protocol) , Dynamic host configuration protocol; SFTP: SSH File Transfer Protocol, SSH file transfer protocol, SSH: Secure Shell, secure shell protocol), scheduler (scheduler), intelligent platform management interface (IPMI) API, physical host, internal API (inner -API), Status Manager (Status Manager), Virtual Private Cloud (VPC), Software Defined Network/Top of Rack Switch/PDN Gateway (SDN/TOR/PGW; SDN: Software Defined Network, Software Defined Network).
图7中的(1)表示:开放平台(open API)收到创建请求,从调度器(scheduler)中获取一台可用物理主机;(2)表示:开放平台通过智能平台管理接口(IPMI)API对物理主机设置为网络启动;(3)表示:物理主机发起DHCP请求,获取运维管理网络IP地址;(4)表示:物理主机从内部API(inner-API)获得物理主机的装机配置信息;(5)表示:物理主机从运维管理网络获取镜像数据开始装机;(6)表示:装机过程中更新物理主机的装机状态;(7)表示:轮询物理主机的装机状态,如果标识装机已完成,调用VPC的相关接口加入到VPC网络;(8)表示:下发交换机配置信息;(9)表示物理主机重启后通过交换机获得VPC私有IP地址;(10)表示:更新物理主机10的最终状态。(1) in Figure 7 means: the open platform (open API) receives the creation request and obtains an available physical host from the scheduler (scheduler); (2) means: the open platform uses the Intelligent Platform Management Interface (IPMI) API Set the physical host as network startup; (3) means: the physical host initiates a DHCP request to obtain the operation and maintenance management network IP address; (4) means: the physical host obtains the physical host's installed configuration information from the internal API (inner-API); (5) Means: the physical host obtains the mirror data from the operation and maintenance management network and starts installation; (6) Means: updates the installation status of the physical host during the installation process; (7) Means: polls the installation status of the physical host, if the installation is marked When finished, call the relevant interface of the VPC to join the VPC network; (8) means: send switch configuration information; (9) means that the physical host gets the VPC private IP address through the switch after restarting; (10) means: update the final physical host 10 status.
下面对该部署情况下的流程进行说明。The flow in this deployment situation is described below.
首先,开放平台(open API)收到创建请求,从调度器(scheduler)中获取一台可用物理主机10,开放平台通过智能平台管理接口(IPMI)对物理主机10的网络启动状态进行设定;接着,物理主机10发起DHCP请求从运维管理网络获取IP地址,物理主机10从内部API(inner-api)获得物理主机10的装机配置信息。物理主机10从运维管理网络获取镜像数据开始装机;再接着,在装机过程中对物理主机10的装机状态进行更新,若检测到物理主机10的装机状态更新,调用VPC的相关接口加入到VPC网络;最后,虚拟网络下发交换机的配置信息到物理主机10,物理主机10重启后通过交换机获得VPC私有IP地址,更新物理主机10的最终状态。First, the open platform (open API) receives the creation request, obtains an available physical host 10 from the scheduler (scheduler), and the open platform sets the network startup status of the physical host 10 through the intelligent platform management interface (IPMI); Next, the physical host 10 initiates a DHCP request to obtain an IP address from the operation and maintenance management network, and the physical host 10 obtains the installation configuration information of the physical host 10 from an internal API (inner-api). The physical host 10 obtains the mirrored data from the operation and maintenance management network and starts the installation; then, during the installation process, the installation status of the physical host 10 is updated. If the installation status of the physical host 10 is updated, the relevant interface of the VPC is called to join the VPC Network; Finally, the virtual network delivers the configuration information of the switch to the physical host 10. After the physical host 10 restarts, the VPC private IP address is obtained through the switch, and the final state of the physical host 10 is updated.
上述方法,物理主机10可以接入虚拟网络环境,并可与云主机进行相同的虚拟网络配置与功能联合管理,包括弹性IP地址、虚拟网关、安全组等功能。且在物理主机10与虚拟主机之间提供较高的网络性能。In the above method, the physical host 10 can access the virtual network environment, and can perform the same virtual network configuration and function joint management with the cloud host, including functions such as elastic IP address, virtual gateway, and security group. In addition, higher network performance is provided between the physical host 10 and the virtual host.
可见,相比于上面内容中相关技术的缺陷:一、物理主机集群并未真正处于虚拟私有云VPC中,许多VPC的特性无法实现;二、虽然物理主机可以拥有虚拟私有云VPC的特性,但是因是独立于云主机之外的虚拟私有云,其网络连通性存在限制。应用本申请所示实施例,一、物理主机获取到VPC的 私有IP地址,物理主机连接TOR,TOR连接PDN网关,PDN网关接入VPC,实现了物理主机真正加入了VPC中,可以实现VPC的特性;二、物理主机加入了VPC,VPC中包括物理主机和云主机,物理主机并不是独立于云主机之外,网络连通性较佳。It can be seen that compared with the related technical defects in the above content: 1. The physical host cluster is not really in the virtual private cloud VPC, and many VPC features cannot be realized; 2. Although the physical host can have the characteristics of the virtual private cloud VPC, but Because it is a virtual private cloud independent of the cloud host, its network connectivity has limitations. Applying the embodiment shown in this application, 1. The physical host obtains the private IP address of the VPC, the physical host connects to the TOR, the TOR connects to the PDN gateway, and the PDN gateway connects to the VPC. This realizes that the physical host actually joins the VPC and can realize VPC Features; 2. The physical host has joined the VPC. The VPC includes the physical host and the cloud host. The physical host is not independent of the cloud host and has better network connectivity.
本申请实施例还提供一种物理主机的租赁装置,本物理主机的租赁装置是前述方法对应的虚拟装置。可以理解的是,接下来要描述的物理主机的租赁装置中涉及的各个功能模块的具体功能在上面实施例的对应步骤中已经详尽描述过,具体各个功能模块的详尽内容可参照上面的实施例描述,下面仅对物理主机的租赁装置进行简单描述。The embodiment of the present application also provides a rental device of a physical host, and the rental device of the physical host is a virtual device corresponding to the foregoing method. It is understandable that the specific functions of each functional module involved in the rental device of the physical host to be described below have been described in detail in the corresponding steps of the above embodiment, and the detailed content of each specific functional module can refer to the above embodiment. Description, the following only briefly describes the rental device of the physical host.
请参照图8,本实施例提供的物理主机的租赁装置210可以包括:Referring to FIG. 8, the leasing device 210 for a physical host provided in this embodiment may include:
接收模块2101,设置为接收用户的物理主机的租赁请求,其中,用户租赁的物理主机为用户从可售卖物理主机中选择的物理主机。The receiving module 2101 is configured to receive a lease request of a user's physical host, where the physical host leased by the user is a physical host selected by the user from the physical hosts that can be sold.
获取模块2102,设置为获取物理主机的装机资源并基于装机资源对物理主机进行装机处理。The obtaining module 2102 is configured to obtain installed resources of the physical host and perform installation processing on the physical host based on the installed resources.
在本实施例中,获取模块2102具体设置为:In this embodiment, the acquisition module 2102 is specifically set as follows:
对所述物理主机网络状态进行设定,以使所述物理主机通过网络获得装机配置信息,并根据装机配置信息完成装机。The network state of the physical host is set, so that the physical host obtains installation configuration information through the network, and completes the installation according to the installation configuration information.
加入模块2103,设置为在完成装机处理后,将物理主机加入指定的虚拟私有云VPC中,以将物理主机部署为所述VPC中的计算节点供所述用户使用,其中,所述VPC中还部署有作为计算节点的云主机。The joining module 2103 is set to add the physical host to the designated virtual private cloud VPC after the installation process is completed, so as to deploy the physical host as a computing node in the VPC for the user to use, wherein the VPC also A cloud host as a computing node is deployed.
在本实施例中,加入模块2103还设置为:In this embodiment, the joining module 2103 is also set to:
建立所述物理主机与所述指定的VPC的绑定关系;Establishing a binding relationship between the physical host and the designated VPC;
确定所述物理主机对应的交换机配置信息,并将所述交换机配置信息下发至所述VPC中所述物理主机对应的交换机设备,以使所述交换机设备基于所述交换机配置信息进行网络配置;Determining switch configuration information corresponding to the physical host, and delivering the switch configuration information to the switch device corresponding to the physical host in the VPC, so that the switch device performs network configuration based on the switch configuration information;
重启所述物理主机,以使重启后的物理主机通过网络配置后的交换机设备获取到所述指定的VPC的私有IP地址。Restart the physical host, so that the restarted physical host obtains the private IP address of the designated VPC through the switch device after network configuration.
在本实施例中,所述交换机设备包括PDN网关和架顶交换机TOR,所述 PDN网关的配置信息包括DHCP配置信息及VPC配置信息,所述TOR的配置信息包括物理接口、隧道及虚拟路由器。In this embodiment, the switch device includes a PDN gateway and a top-of-rack switch TOR, the configuration information of the PDN gateway includes DHCP configuration information and VPC configuration information, and the configuration information of the TOR includes physical interfaces, tunnels, and virtual routers.
进一步地,在本实施例中,加入模块2103还设置为:Further, in this embodiment, the adding module 2103 is also set to:
将所述物理主机的上联接口加入所述虚拟路由器;Adding the uplink interface of the physical host to the virtual router;
通过所述虚拟路由器建立的隧道建立所述上联接口与所述PDN网关的通信,以实现所述上联接口加入所述虚拟私有云VPC,其中所述PDN网关设置为接入所述VPC。The communication between the uplink interface and the PDN gateway is established through the tunnel established by the virtual router, so as to realize that the uplink interface joins the virtual private cloud VPC, wherein the PDN gateway is set to access the VPC.
请参照图9,在本实施例中,物理主机的租赁装置210还可以包括:申请与绑定模块2104;Referring to FIG. 9, in this embodiment, the leasing device 210 of the physical host may further include: an application and binding module 2104;
申请与绑定模块2104设置为为所述物理主机申请弹性公网IP地址,并将申请到的弹性公网IP地址与所述物理主机进行绑定,以使所述物理主机能够访问公网。The application and binding module 2104 is configured to apply for an elastic public network IP address for the physical host, and bind the applied elastic public network IP address with the physical host, so that the physical host can access the public network.
进一步地,再次参照图9,物理主机的租赁装置210还可以包括:Further, referring to FIG. 9 again, the leasing device 210 of the physical host may further include:
物理主机回收模块2105,设置为在用户删除所述物理主机的情况下,将所述删除的物理主机回收;或在所述物理主机的租赁期限到期,且用户没有续费的情况下,将所述物理主机回收。The physical host recovery module 2105 is configured to recover the deleted physical host when the user deletes the physical host; or when the lease term of the physical host expires and the user has not renewed The physical host recycling.
进一步地,再次参照图9,物理主机的租赁装置210还可以包括:信息提供模块2106、信息冻结模块2107及信息释放与更新模块2108。Further, referring to FIG. 9 again, the leasing device 210 of the physical host may further include: an information providing module 2106, an information freezing module 2107, and an information releasing and updating module 2108.
信息提供模块2106设置为向用户提供库存的可售卖物理主机信息;The information providing module 2106 is configured to provide the user with the information of the sellable physical host in inventory;
信息冻结模块2107设置为在接收用户的物理主机的租赁请求之后,冻结库存的可售卖物理主机信息,生成请求所述物理主机的订单;The information freezing module 2107 is configured to freeze the information of the sellable physical host in the inventory after receiving the lease request of the user's physical host, and generate an order requesting the physical host;
信息释放与更新模块2108设置为如果检测到用户完成所述订单的支付后,释放并更新库存的可售卖物理主机信息。The information release and update module 2108 is configured to release and update the physical host information of the inventory that can be sold if it is detected that the user completes the payment of the order.
如果上述功能以软件功能模块的形式实现并作为独立的产品销售或使用时,可以存储在一个计算机可读取存储介质中。基于这样的理解,本申请的技术方案本质上或者说对相关技术做出贡献的部分或者该技术方案的部分可以以软件产品的形式体现出来,该计算机软件产品存储在一个存储介质中,包括若干指令用以使得设备执行本申请各个实施例所述方法的全部或部分步骤。而前述的存储介质包括:U盘、移动硬盘、只读存储器(英文:Read-Only  Memory,简称:ROM)、随机存取存储器(英文:Random Access Memory,简称:RAM)、磁碟或者光盘等各种可以存储程序代码的介质。If the above functions are implemented in the form of software function modules and sold or used as independent products, they can be stored in a computer readable storage medium. Based on this understanding, the technical solution of this application essentially or the part that contributes to the related technology or the part of the technical solution can be embodied in the form of a software product. The computer software product is stored in a storage medium, including several The instructions are used to make the device execute all or part of the steps of the methods described in the various embodiments of the present application. The aforementioned storage media include: U disk, mobile hard disk, read-only memory (English: Read-Only Memory, abbreviated as: ROM), random access memory (English: Random Access Memory, abbreviated as: RAM), magnetic disk or optical disk, etc. Various media that can store program codes.
综上所述,本申请实施例提供一种物理主机的租赁方法、装置、云平台及可读存储介质。其中,所述方法应用云平台,首先,接收用户的物理主机的租赁请求,其中所述物理主机的租赁请求中包括用户选择的可售卖的物理主机;接着,获取物理主机的装机资源并基于装机资源对物理主机进行装机处理;最后,将装机完成后的物理主机加入指定的虚拟私有云VPC中,以供用户使用。上述方法,可以使物理主机天然接入虚拟网络环境,并可与云主机进行相同的虚拟网络配置与功能联合管理,包括弹性IP地址、虚拟网关、安全组等功能。且在物理主机与虚拟主机之间提供较高的网络性能。In summary, the embodiments of the present application provide a method, device, cloud platform, and readable storage medium for renting a physical host. Wherein, the method is applied to the cloud platform. First, the user's physical host lease request is received, where the physical host lease request includes the physical host that can be sold selected by the user; then, the installed resources of the physical host are obtained and based on the installed capacity. The resources are installed on the physical host; finally, the physical host after installation is added to the designated virtual private cloud VPC for users to use. The above method allows the physical host to naturally access the virtual network environment, and can perform the same virtual network configuration and function joint management with the cloud host, including functions such as elastic IP address, virtual gateway, and security group. And provide higher network performance between the physical host and the virtual host.
本申请实施例所提供的几个实施例中,应该理解到,所揭露的方法和装置,也可以通过其它的方式实现。以上所描述的方法和装置实施例仅仅是示意性的,例如,附图中的流程图和框图显示了根据本申请的多个实施例的方法、装置和计算机程序产品的可能实现的体系架构、功能和操作。在这点上,流程图或框图中的每个方框可以代表一个模块、程序段或代码的一部分,所述模块、程序段或代码的一部分包含一个或多个用于实现规定的逻辑功能的可执行指令。也应当注意,在有些作为替换的实现方式中,方框中所标注的功能也可以以不同于附图中所标注的顺序发生。例如,两个连续的方框实际上可以基本并行地执行,它们有时也可以按相反的顺序执行,这依所涉及的功能而定。也要注意的是,框图和/或流程图中的每个方框、以及框图和/或流程图中的方框的组合,可以用执行规定的功能或动作的专用的基于硬件的系统来实现,或者可以用专用硬件与计算机指令的组合来实现。In the several embodiments provided in the embodiments of the present application, it should be understood that the disclosed method and device may also be implemented in other ways. The method and device embodiments described above are merely illustrative. For example, the flowcharts and block diagrams in the accompanying drawings show the possible implementation architectures of the methods, devices, and computer program products according to multiple embodiments of the present application. Function and operation. In this regard, each block in the flowchart or block diagram may represent a module, program segment, or part of the code, and the module, program segment, or part of the code contains one or more functions for realizing the specified logical function. Executable instructions. It should also be noted that in some alternative implementations, the functions marked in the block may also occur in a different order from the order marked in the drawings. For example, two consecutive blocks can actually be executed in parallel, or they can sometimes be executed in the reverse order, depending on the functions involved. It should also be noted that each block in the block diagram and/or flowchart, and the combination of the blocks in the block diagram and/or flowchart, can be implemented by a dedicated hardware-based system that performs the specified functions or actions Or it can be realized by a combination of dedicated hardware and computer instructions.
另外,在本申请各个实施例中的各功能模块可以集成在一起形成一个独立的部分,也可以是各个模块单独存在,也可以两个或两个以上模块集成形成一个独立的部分。In addition, the functional modules in the various embodiments of the present application may be integrated together to form an independent part, or each module may exist alone, or two or more modules may be integrated to form an independent part.
本申请实施例还提供一种云平台,该云平台包括处理器及存储有计算机指令的非易失性存储器,计算机指令被交换机执行时,实现上述任意一种物理主机的租赁方法。An embodiment of the present application also provides a cloud platform, which includes a processor and a non-volatile memory storing computer instructions. When the computer instructions are executed by a switch, any one of the above-mentioned methods for renting a physical host is realized.
本申请实施例还提供一种可读存储介质,所述可读存储介质包括计算机程序,所述计算机程序运行时控制所述可读存储介质所在电子设备执行上述任意一种物理主机的租赁方法。The embodiment of the present application also provides a readable storage medium, the readable storage medium includes a computer program, and when the computer program runs, the electronic device where the readable storage medium is located executes any one of the aforementioned methods for renting a physical host.
本申请实施例还提供一种可执行程序代码,其中,所述可执行程序代码设置为被运行以执行上述任意一种物理主机的租赁方法。An embodiment of the present application also provides an executable program code, wherein the executable program code is configured to be executed to execute any one of the aforementioned methods for renting a physical host.
本说明书中的各个实施例均采用相关的方式描述,各个实施例之间相同相似的部分互相参见即可,每个实施例重点说明的都是与其他实施例的不同之处。尤其,对于装置实施例、云平台实施例、可读存储介质实施例、以及计算机程序产品实施例、可执行程序代码实施例而言,由于其基本相似于方法实施例,所以描述的比较简单,相关之处参见方法实施例的部分说明即可。The various embodiments in this specification are described in a related manner, and the same or similar parts between the various embodiments can be referred to each other, and each embodiment focuses on the differences from other embodiments. In particular, for the device embodiments, cloud platform embodiments, readable storage medium embodiments, computer program product embodiments, and executable program code embodiments, since they are basically similar to method embodiments, the description is relatively simple. For related details, please refer to the partial description of the method embodiment.
以上所述仅为本申请的较佳实施例,并不用以限制本申请,凡在本申请的精神和原则之内,所做的任何修改、等同替换、改进等,均应包含在本申请保护的范围之内。The above descriptions are only preferred embodiments of this application and are not intended to limit this application. Any modification, equivalent replacement, improvement, etc. made within the spirit and principle of this application shall be included in the protection of this application. Within the range.

Claims (19)

  1. 一种物理主机的租赁方法,其中,应用于云平台,所述方法包括:A method for renting a physical host, which is applied to a cloud platform, and the method includes:
    接收用户的物理主机的租赁请求,其中,所述用户租赁的物理主机为所述用户从可售卖物理主机中选择的物理主机;Receiving a lease request of a user's physical host, where the physical host leased by the user is a physical host selected by the user from the physical hosts that can be sold;
    获取所述物理主机的装机资源并基于所述装机资源对所述物理主机进行装机处理;Acquiring installed resources of the physical host and performing installation processing on the physical host based on the installed resources;
    在完成装机处理后,将所述物理主机加入指定的虚拟私有云VPC中,以将所述物理主机部署为所述VPC中的计算节点供所述用户使用,其中,所述VPC中还部署有作为计算节点的云主机。After the installation process is completed, the physical host is added to the designated virtual private cloud VPC to deploy the physical host as a computing node in the VPC for the user to use, wherein the VPC is also deployed As a cloud host for computing nodes.
  2. 如权利要求1所述的方法,其中,所述获取所述物理主机的装机资源并基于所述装机资源对所述物理主机进行装机处理包括:The method according to claim 1, wherein said acquiring the installed resources of the physical host and performing installation processing on the physical host based on the installed resources comprises:
    对所述物理主机网络状态进行设定,以使所述物理主机通过网络获得装机配置信息,并根据装机配置信息完成装机。The network state of the physical host is set, so that the physical host obtains installation configuration information through the network, and completes the installation according to the installation configuration information.
  3. 如权利要求1所述的方法,其中,所述方法还包括:The method of claim 1, wherein the method further comprises:
    为所述物理主机申请弹性公网IP地址,并将申请到的弹性公网IP地址与所述物理主机进行绑定,以使所述物理主机访问公网。Apply for an elastic public network IP address for the physical host, and bind the applied elastic public network IP address with the physical host, so that the physical host can access the public network.
  4. 如权利要求2所述的方法,其中,将所述物理主机加入指定的VPC中包括:The method according to claim 2, wherein adding the physical host to a designated VPC comprises:
    建立所述物理主机与所述指定的VPC的绑定关系;Establishing a binding relationship between the physical host and the designated VPC;
    确定所述物理主机对应的交换机配置信息,并将所述交换机配置信息下发至所述VPC中所述物理主机对应的交换机设备,以使所述交换机设备基于所述交换机配置信息进行网络配置;Determining switch configuration information corresponding to the physical host, and delivering the switch configuration information to the switch device corresponding to the physical host in the VPC, so that the switch device performs network configuration based on the switch configuration information;
    重启所述物理主机,以使重启后的物理主机通过网络配置后的交换机设备获取到所述指定的VPC的私有IP地址。Restart the physical host, so that the restarted physical host obtains the private IP address of the designated VPC through the switch device after network configuration.
  5. 如权利要求4所述的方法,其中,所述交换机设备包括PDN网关和架顶交换机TOR,所述PDN网关的配置信息包括DHCP配置信息及VPC配置信息,所述TOR的配置信息包括物理接口、隧道及虚拟路由器。The method of claim 4, wherein the switch device includes a PDN gateway and a top-of-rack switch TOR, the configuration information of the PDN gateway includes DHCP configuration information and VPC configuration information, and the configuration information of the TOR includes physical interfaces, Tunnel and virtual router.
  6. 如权利要求5所述的方法,其中,所述将所述交换机配置信息下发至所述VPC中所述物理主机对应的交换机设备之后,还包括:The method according to claim 5, wherein after the delivering the switch configuration information to the switch device corresponding to the physical host in the VPC, the method further comprises:
    将所述物理主机的上联接口加入所述虚拟路由器;Adding the uplink interface of the physical host to the virtual router;
    通过所述虚拟路由器建立的隧道建立所述上联接口与所述PDN网关的通信,以实现所述上联接口加入所述虚拟私有云VPC,其中所述PDN网关用于接入所述VPC。The communication between the uplink interface and the PDN gateway is established through the tunnel established by the virtual router, so as to realize that the uplink interface joins the virtual private cloud VPC, where the PDN gateway is used to access the VPC.
  7. 如权利要求1-6中任意一项所述的方法,其中,所述方法还包括:The method according to any one of claims 1-6, wherein the method further comprises:
    在用户删除所述物理主机的情况下,将所述删除的物理主机回收;或In the case that the user deletes the physical host, reclaim the deleted physical host; or
    在所述物理主机的租赁期限到期,且用户没有续费的情况下,将所述物理主机回收。When the lease term of the physical host expires and the user does not renew the fee, the physical host is recycled.
  8. 如权利要求1-6中任意一项所述的方法,其中,在所述接收用户的物理主机的租赁请求之前,所述方法还包括:The method according to any one of claims 1-6, wherein, before the receiving the lease request of the user's physical host, the method further comprises:
    向用户提供库存的可售卖物理主机信息;Provide users with inventory of physical host information that can be sold;
    在所述接收用户的物理主机的租赁请求之后,所述方法还包括:After receiving the lease request of the user's physical host, the method further includes:
    冻结库存的可售卖物理主机信息,生成请求所述物理主机的订单;Freeze the physical host information in the inventory that can be sold, and generate an order requesting the physical host;
    在检测到用户完成所述订单的支付的情况下,释放并更新库存的可售卖物理主机信息。In the case of detecting that the user completes the payment of the order, release and update the inventory of the physical host information that can be sold.
  9. 一种物理主机的租赁装置,其中,应用于云平台,所述装置包括:A leasing device for a physical host, wherein, applied to a cloud platform, the device includes:
    接收模块,设置为接收用户的物理主机的租赁请求,其中,所述用户租赁的物理主机为所述用户从可售卖物理主机中选择的物理主机;A receiving module, configured to receive a lease request of a user's physical host, wherein the physical host leased by the user is a physical host selected by the user from the physical hosts that can be sold;
    获取模块,设置为获取所述物理主机的装机资源并基于所述装机资源对所述物理主机进行装机处理;An obtaining module, configured to obtain installed resources of the physical host and perform installation processing on the physical host based on the installed resources;
    加入模块,设置为在完成装机处理后,将所述物理主机加入指定的虚拟私有云VPC中,以将所述物理主机部署为所述VPC中的计算节点供所述用户使用,其中,所述VPC中还部署有作为计算节点的云主机。The joining module is configured to add the physical host to a designated virtual private cloud VPC after the installation process is completed, so as to deploy the physical host as a computing node in the VPC for the user to use, wherein the A cloud host as a computing node is also deployed in the VPC.
  10. 如权利要求9所述的装置,其中,所述获取模块具体设置为:The device according to claim 9, wherein the acquiring module is specifically configured to:
    对所述物理主机网络状态进行设定,以使所述物理主机通过网络获得装机配置信息,并根据装机配置信息完成装机。The network state of the physical host is set, so that the physical host obtains installation configuration information through the network, and completes the installation according to the installation configuration information.
  11. 如权利要求9所述的装置,其中,所述装置还包括申请与绑定模块;9. The device of claim 9, wherein the device further comprises an application and binding module;
    所述申请与绑定模块设置为为所述物理主机申请弹性公网IP地址,并将申请到的弹性公网IP地址与所述物理主机进行绑定,以使所述物理主机访问 公网。The application and binding module is configured to apply for an elastic public network IP address for the physical host, and bind the applied elastic public network IP address with the physical host, so that the physical host can access the public network.
  12. 如权利要求10所述的装置,其中,所述加入模块设置为:The apparatus of claim 10, wherein the joining module is configured to:
    建立所述物理主机与所述指定的VPC的绑定关系;Establishing a binding relationship between the physical host and the designated VPC;
    确定所述物理主机对应的交换机配置信息,并将所述交换机配置信息下发至所述VPC中所述物理主机对应的交换机设备,以使所述交换机设备基于所述交换机配置信息进行网络配置;Determining switch configuration information corresponding to the physical host, and delivering the switch configuration information to the switch device corresponding to the physical host in the VPC, so that the switch device performs network configuration based on the switch configuration information;
    重启所述物理主机,以使重启后的物理主机通过网络配置后的交换机设备获取到所述指定的VPC的私有IP地址。Restart the physical host, so that the restarted physical host obtains the private IP address of the designated VPC through the switch device after network configuration.
  13. 如权利要求12所述的装置,其中,所述交换机设备包括PDN网关和架顶交换机TOR,所述PDN网关的配置信息包括DHCP配置信息及VPC配置信息,所述TOR的配置信息包括物理接口、隧道及虚拟路由器。The apparatus according to claim 12, wherein the switch device includes a PDN gateway and a top-of-rack switch TOR, the configuration information of the PDN gateway includes DHCP configuration information and VPC configuration information, and the configuration information of the TOR includes physical interfaces, Tunnel and virtual router.
  14. 如权利要求13所述的装置,其中,所述加入模块还设置为:The device according to claim 13, wherein the adding module is further configured to:
    将所述物理主机的上联接口加入所述虚拟路由器;Adding the uplink interface of the physical host to the virtual router;
    通过所述虚拟路由器建立的隧道建立所述上联接口与所述PDN网关的通信,以实现所述上联接口加入所述虚拟私有云VPC,其中所述PDN网关设置为接入所述VPC。The communication between the uplink interface and the PDN gateway is established through the tunnel established by the virtual router, so as to realize that the uplink interface joins the virtual private cloud VPC, wherein the PDN gateway is set to access the VPC.
  15. 如权利要求9-14中任意一项所述的装置,其中,所述装置还包括物理主机回收模块;The device according to any one of claims 9-14, wherein the device further comprises a physical host recovery module;
    所述物理主机回收模块设置为在用户删除所述物理主机的情况下,将所述删除的物理主机回收;或The physical host recovery module is configured to recover the deleted physical host when the user deletes the physical host; or
    在所述物理主机的租赁期限到期,且用户没有续费的情况下,将所述物理主机回收。When the lease term of the physical host expires and the user does not renew the fee, the physical host is recycled.
  16. 如权利要求9-14中任意一项所述的装置,其中,所述装置还包括:信息提供模块、信息冻结模块及信息释放与更新模块;The device according to any one of claims 9-14, wherein the device further comprises: an information providing module, an information freezing module, and an information releasing and updating module;
    所述信息提供模块设置为向用户提供库存的可售卖物理主机信息;The information providing module is configured to provide the user with inventory of the physical host information that can be sold;
    所述信息冻结模块设置为在接收用户的物理主机的租赁请求之后,冻结库存的可售卖物理主机信息,生成请求所述物理主机的订单;The information freezing module is configured to freeze the information of the sellable physical host in the inventory after receiving the lease request of the user's physical host, and generate an order requesting the physical host;
    所述信息释放与更新模块设置为在检测到用户完成所述订单的支付的情况下,释放并更新库存的可售卖物理主机信息。The information release and update module is configured to release and update the physical host information that can be sold in the inventory when it is detected that the user completes the payment of the order.
  17. 一种云平台,其中,该云平台包括处理器及存储有计算机指令的非易失性存储器,计算机指令被交换机执行时,实现权利要求1-8中任意一项中的物理主机的租赁方法。A cloud platform, wherein the cloud platform includes a processor and a non-volatile memory storing computer instructions. When the computer instructions are executed by a switch, the method for renting a physical host in any one of claims 1-8 is realized.
  18. 一种可读存储介质,其中,所述可读存储介质包括计算机程序,所述计算机程序运行时控制所述可读存储介质所在电子设备执行权利要求1-8中任意一项中的物理主机的租赁方法。A readable storage medium, wherein the readable storage medium includes a computer program, and when the computer program runs, the electronic device where the readable storage medium is located executes the operation of the physical host in any one of claims 1-8. Lease method.
  19. 一种可执行程序代码,其中,所述可执行程序代码设置为被运行以执行权利要求1-8中任意一项中的物理主机的租赁方法。An executable program code, wherein the executable program code is configured to be executed to execute the method for renting a physical host in any one of claims 1-8.
PCT/CN2020/092305 2019-05-31 2020-05-26 Method and device for leasing physical host, cloud platform, and readable storage medium WO2020238891A1 (en)

Applications Claiming Priority (2)

Application Number Priority Date Filing Date Title
CN201910471456.9 2019-05-31
CN201910471456.9A CN112019366B (en) 2019-05-31 2019-05-31 Leasing method and device of physical host, cloud platform and readable storage medium

Publications (1)

Publication Number Publication Date
WO2020238891A1 true WO2020238891A1 (en) 2020-12-03

Family

ID=73506142

Family Applications (1)

Application Number Title Priority Date Filing Date
PCT/CN2020/092305 WO2020238891A1 (en) 2019-05-31 2020-05-26 Method and device for leasing physical host, cloud platform, and readable storage medium

Country Status (2)

Country Link
CN (1) CN112019366B (en)
WO (1) WO2020238891A1 (en)

Cited By (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN112994941A (en) * 2021-02-24 2021-06-18 杭州安恒信息技术股份有限公司 Method and device for deploying anti-DDoS cloud host and anti-DDoS attack protection system
CN113904847A (en) * 2021-10-09 2022-01-07 天翼物联科技有限公司 Cloud platform binding method, system, equipment and medium of Internet of things card
CN113923115A (en) * 2021-10-09 2022-01-11 紫光云技术有限公司 VPC configuration issuing method based on RockMq

Families Citing this family (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN112968802B (en) * 2021-02-25 2023-04-18 紫光云技术有限公司 Universal method for managing IP state and relation of elastic public network
CN112968823A (en) * 2021-03-03 2021-06-15 浪潮云信息技术股份公司 VPN service realizing method

Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20130036213A1 (en) * 2011-08-02 2013-02-07 Masum Hasan Virtual private clouds
CN106354544A (en) * 2016-08-24 2017-01-25 华为技术有限公司 Virtual machine creating method and system and host
CN107135134A (en) * 2017-03-29 2017-09-05 广东网金控股股份有限公司 Private network cut-in method and system based on virtual switch and SDN technologies
CN109656686A (en) * 2018-12-17 2019-04-19 武汉烽火信息集成技术有限公司 The upper deployment container cloud method of OpenStack, storage medium, electronic equipment and system

Family Cites Families (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN104506635B (en) * 2014-12-26 2018-07-20 成都极驰科技有限公司 A kind of establishment of cloud host and matching process and system rapidly and efficiently
US20180084085A1 (en) * 2016-09-20 2018-03-22 Arrayent, Inc. Cross platform device virtualization for an iot system
CN108399106A (en) * 2018-02-28 2018-08-14 华为技术有限公司 The method and apparatus for managing physical host
CN109062683B (en) * 2018-06-29 2022-03-18 深圳信息职业技术学院 Method, apparatus and computer readable storage medium for host resource allocation
CN109218462B (en) * 2018-09-14 2022-06-10 浪潮云信息技术股份公司 IP distribution method of physical host of cloud data center

Patent Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20130036213A1 (en) * 2011-08-02 2013-02-07 Masum Hasan Virtual private clouds
CN106354544A (en) * 2016-08-24 2017-01-25 华为技术有限公司 Virtual machine creating method and system and host
CN107135134A (en) * 2017-03-29 2017-09-05 广东网金控股股份有限公司 Private network cut-in method and system based on virtual switch and SDN technologies
CN109656686A (en) * 2018-12-17 2019-04-19 武汉烽火信息集成技术有限公司 The upper deployment container cloud method of OpenStack, storage medium, electronic equipment and system

Cited By (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN112994941A (en) * 2021-02-24 2021-06-18 杭州安恒信息技术股份有限公司 Method and device for deploying anti-DDoS cloud host and anti-DDoS attack protection system
CN112994941B (en) * 2021-02-24 2022-05-17 杭州安恒信息技术股份有限公司 Method and device for deploying anti-DDoS cloud host and anti-DDoS attack protection system
CN113904847A (en) * 2021-10-09 2022-01-07 天翼物联科技有限公司 Cloud platform binding method, system, equipment and medium of Internet of things card
CN113923115A (en) * 2021-10-09 2022-01-11 紫光云技术有限公司 VPC configuration issuing method based on RockMq
CN113904847B (en) * 2021-10-09 2022-07-15 天翼物联科技有限公司 Cloud platform binding method, system, equipment and medium of Internet of things card
CN113923115B (en) * 2021-10-09 2023-08-25 紫光云技术有限公司 VPC configuration issuing method based on RocketMq

Also Published As

Publication number Publication date
CN112019366A (en) 2020-12-01
CN112019366B (en) 2022-02-01

Similar Documents

Publication Publication Date Title
WO2020238891A1 (en) Method and device for leasing physical host, cloud platform, and readable storage medium
US10986174B1 (en) Automatic discovery and configuration of server nodes
US8990374B2 (en) Method and apparatus of cloud computing subsystem
US9450813B2 (en) Automated host device virtual network configuration system
US8909758B2 (en) Physical server discovery and correlation
WO2016155394A1 (en) Method and device for establishing link between virtual network functions
US20140032753A1 (en) Computer system and node search method
US20120291028A1 (en) Securing a virtualized computing environment using a physical network switch
US9832136B1 (en) Streaming software to multiple virtual machines in different subnets
EP2731010A1 (en) Method, device, and system for migrating configuration information during live migration of virtual machine
US8423734B2 (en) Making automated use of data volume copy service targets
US9516112B1 (en) Sending alerts from cloud computing systems
US11687354B2 (en) Virtual machine management using onboarding operations and openstack control
US10771309B1 (en) Border gateway protocol routing configuration
US10678657B1 (en) Reversion operations for virtual computing environments
CN107666493B (en) Database configuration method and equipment thereof
US11546228B2 (en) Zero-touch configuration of network devices using hardware metadata
CN114070723A (en) Virtual network configuration method and system of bare metal server and intelligent network card
US8819200B2 (en) Automated cluster node configuration
US11153173B1 (en) Dynamically updating compute node location information in a distributed computing environment
CN112035062B (en) Migration method of local storage of cloud computing, computer equipment and storage medium
CN108874947B (en) Data processing system and data processing method
US20160050113A1 (en) Methods for managing storage virtual machine configuration changes in a distributed storage system and devices thereof
CN106790767A (en) A kind of method based on the automatic distribution virtual machine IP of VMware virtualizations
US20200136909A1 (en) Autoinitialization of clustered storage

Legal Events

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

Ref document number: 20814245

Country of ref document: EP

Kind code of ref document: A1

NENP Non-entry into the national phase

Ref country code: DE

122 Ep: pct application non-entry in european phase

Ref document number: 20814245

Country of ref document: EP

Kind code of ref document: A1

32PN Ep: public notification in the ep bulletin as address of the adressee cannot be established

Free format text: NOTING OF LOSS OF RIGHTS PURSUANT TO RULE 112(1) EPC (EPO FORM 1205A DATED 21/03/2022)

122 Ep: pct application non-entry in european phase

Ref document number: 20814245

Country of ref document: EP

Kind code of ref document: A1