In recent years, there is a trend toward large-scale systems for providing services with the use of servers via the Internet. In a large-scale system, a number of computers (servers) need to be introduced. As a result, the computer introduction costs and operation costs become very high. In view of this, attention has been recently drawn to a virtual machine (VM) technique for restricting the introduction costs and the operation costs to low values.
The virtual machine technique is a technique for virtualizing hardware and operating an operating system (OS) on the virtualized hardware. Where several sets of virtual hardware are prepared, several OSs need to be operated at the same time. Each OS operated by the virtualized hardware logically realizes a computer. The logically realized computers are called “virtual machines”.
By the virtual machine technique, one or more virtual machines can be created in a physically existing computer (a physical machine). Each virtual machine can be used as a server. Accordingly, the number of computers (physical machines) to be introduced can be made smaller. Thus, the introduction costs and the operation costs can be made lower.
Each virtual machine operates as a computer. Therefore, each virtual machine needs to be uniquely identified among virtual machines or in a connection to an external network. To realize this, a virtual network interface card (NIC) is constructed in each virtual machine, and an address is assigned to the virtual NIC. The address is normally a MAC (Media Access Control) address. A MAC address is assigned as the unique ID number to each Ethernet card (“Ethernet” is a registered trade name). MAC addresses are data that indicate the destinations of packets in the data link layer (the second layer) of the OSI (Open Systems Interconnection) reference model.
FIG. 12 illustrates the system structures of conventional physical machines (computers). The system structures in FIG. 12 illustrate the environment of each physical machine 1200 that has created virtual machines. Referring to FIG. 12, the system structure of each conventional physical machine and the assignment of MAC addresses to virtual NICs are described.
In FIG. 12, two physical machines 1200 connected to each other by a network 30 are illustrated. A physically existing NIC 1201 (hereinafter referred to as the “physical NIC 1201” to be distinguished from virtual NICs) is attached to each of the physical machines 1200. In FIG. 12, each reference numeral 1210 indicates a hypervisor (a virtual machine monitor), each reference numeral 1220 indicates a virtual machine for managing the other virtual machines, and each reference numeral 1230 indicates a virtual machine to be operated by an application program (hereinafter referred to simply as the “application”). An OS (a management OS) having a function to manage the other virtual machines is operated in the virtual machine 1220, and a guest OS is operated in each of the virtual machines 1230.
The hypervisor 1210 creates the virtual machines, and performs hardware (not illustrated) assignment dynamically and transparently. Accordingly, the virtual machines 1220 and 1230 can simultaneously operate in one physical machine.
A virtual NIC 1231 is formed in each of the virtual machines 1230, and a virtual NIC 1232 having the same MAC address as the MAC address assigned to the physical NIC 1201 is formed in the virtual machine 1220 for management (hereinafter referred to as the management virtual machine 1220). The physical NIC 1201 has its MAC address changed or is set in a promiscuous mode, so as to receive all packets. In the management virtual machine 1220, an operations management system 1221 that is a program for managing the operations of the other virtual machines 1230 exists, as well as various drivers to be used for accessing physical hardware. Assignment of a MAC address to each virtual NIC 1231 is performed directly or indirectly by the operations management system 1221.
A virtual network 1202 is formed in each of the physical machines 1200, so as to connect the virtual machines 1230 to each other or connect the virtual machines 1230 to the network 30 via the physical NIC 1201. The virtual network 1202 is formed with the use of fabricated virtual switches.
MAC addresses that can be assigned to the virtual NICs 1231 are prepared in advance. If two or more physical machines 1200 exist, the set of prepared MAC addresses is shared among the physical machines 1200. Accordingly, a MAC address selected from the set of prepared MAC addresses is assigned to each virtual NIC 1231.
By a conventional method (a direct method) for assigning a MAC address to a virtual NIC 1231, the operations management system 1221 randomly selects a MAC address from the set of MAC addresses for each physical machine 1200. By this method, however, there is a possibility that a MAC address already assigned to a virtual NIC 1231 in a physical machine 1220 is assigned to a virtual NIC 1231 in another physical machine 1200.
By another conventional method (an indirect method) for assigning a MAC address, a user (an operator) manages assignment via the console 20, so as not to cause overlapping. By this method, however, there is a possibility that the user inadvertently assigns a MAC address to two different virtual NICs 1231. Furthermore, the user is required to do complicated tasks.
In view of the above, where a set of MAC addresses are shared among conventional physical machines 1200, there is a possibility that a MAC address is assigned to two or more virtual NICs 1231. If such overlapping is caused, communications cannot be performed properly. Therefore, there has been a demand for appropriate assignment of MAC addresses without overlapping.
Overlapped assignment of a MAC address can be prevented by preparing a computer (a server) that manages the set of shared MAC address in an integrated manner. Where such a computer is prepared, however, assignment of MAC addresses cannot be performed when the computer is stopped. Furthermore, the introduction of the computer causes an increase in cost. As a result, the advantages of the virtual machine technique are reduced. Therefore, it is considered important that appropriate assignment of MAC address without overlapping is made possible without introduction of another computer or integrated management of the set of MAC addresses. Appropriate assignment of MAC addresses without overlapping is disclosed in Japanese Patent Application Laid-Open Nos. 2007-158870, 2007-193779, and 2007-316724, for example.