Global cache for container images in a clustered container host system
Abstract
Container images are managed in a clustered container host system with a shared storage device. Hosts of the system each include a virtualization software layer that supports execution of virtual machines (VMs), one or more of which are pod VMs that have implemented therein a container engine that supports execution of containers within the respective pod VM. A method of deploying containers includes determining, from pod objects published by a master device of the system and accessible by all hosts of the system, that a new pod VM is to be created, creating the new pod VM, and spinning up one or more containers in the new pod VM using images of containers previously spun up in another pod VM, wherein the images of the containers previously spun up in the other pod VM are stored in the storage device.
Claims
exact text as granted — not AI-modifiedWhat is claimed is:
1. A method of deploying containers in a clustered container host system comprising a plurality of hosts that share a storage device, said method comprising:
polling a master device of the clustered container host system by each of the hosts of the clustered container host system, wherein each of the hosts includes a virtualization software layer that supports execution of virtual machines (VMs) and the master device schedules container groups across the hosts, and wherein each of the hosts polls the master device to determine whether a new VM for running containers of a container group is to be created therein;
upon determining from said polling that the new VM is to be created in one of the hosts, creating the new VM therein, wherein the new VM has implemented therein an operating system, and a container engine that runs on top of the operating system and supports execution of containers;
determining whether or not images of the containers of the container group are stored in the storage device; and
upon determining that the images of the containers of the container group are stored in the storage device, retrieving the images of the containers of the container group from the storage device, and spinning up the containers of the container group in the new VM.
2. The method of claim 1 , wherein
an image cache for the clustered container host system is provisioned in the storage device to be accessible by the hosts, and images of containers that have been previously spun up, including the images of the containers of the container group that are spun up in the new VM, are stored in the image cache.
3. The method of claim 2 , wherein the containers of the container group are also spun up in another VM running in a host that is different from the host in which the new VM is running.
4. The method of claim 3 , wherein the new VM is in a first namespace associated with a first user and said another VM is in a second namespace associated with a second user.
5. The method of claim 4 , wherein the containers of the container group spun up in said another VM are running in said another VM.
6. The method of claim 4 , wherein the containers of the container group spun up in said another VM are no longer running in said another VM.
7. The method of claim 1 , wherein the hosts are managed as nodes of the of the clustered container host system and also as a cluster by a virtual machine management server that manages all VMs of the hosts.
8. The method of claim 7 , wherein the virtual machine management server also provisions virtual disks for the VMs in the storage device, and the images of the containers are stored in the virtual disks.
9. A non-transitory computer readable medium comprising instructions to be executed in nodes of a clustered container host system having an image cache that stores images of containers, wherein each of the nodes includes a virtualization software layer that supports execution of virtual machines (VMs) and the instructions when executed in one of the nodes cause the node to carry out a method comprising:
polling a master device of the clustered container host system, which schedules container groups across the nodes, to determine whether a new VM for running containers of a container group is to be created;
upon determining from said polling that the new VM is to be created, creating the new VM, wherein the new VM has implemented therein an operating system, and a container engine that runs on top of the operating system and supports execution of containers;
determining whether or not images of the containers of the container group are stored in the image cache; and
upon determining that the images of the containers of the container group are stored in the image cache, retrieving the images of the containers of the container group from the image cache, and spinning up the containers of the container group in the new VM.
10. The non-transitory computer readable medium of claim 9 , wherein the image cache is provisioned in a storage device that is shared by the nodes.
11. The non-transitory computer readable medium of claim 10 , wherein the containers of the container group are also spun up in another VM running in a node that is different from the node in which the new VM is running.
12. The non-transitory computer readable medium of claim 11 , wherein the new VM is in a first namespace associated with a first user and said another VM is in a second namespace associated with a second user.
13. The non-transitory computer readable medium of claim 12 , wherein the containers of the container group spun up in said another VM are running in said another VM.
14. The non-transitory computer readable medium of claim 13 , wherein the containers of the container group spun up in said another VM are no longer running in said another VM.
15. The non-transitory computer readable medium of claim 9 , wherein the nodes are managed as a cluster by a virtual machine management server that manages all VMs of the nodes.
16. The non-transitory computer readable medium of claim 15 , wherein the virtual machine management server also provisions virtual disks for the VMs in a storage device that is shared by the nodes, and the images of the containers are stored in the virtual disks.
17. A clustered container host system comprising:
a storage device; and
a plurality of hosts that share the storage device, wherein the hosts each include a virtualization software layer that supports execution of virtual machines (VMs) therein, wherein
at least one of the hosts is programmed to execute a method of deploying containers, said method comprising:
polling a master device of the clustered container host system, which schedules container groups across the hosts, to determine whether a new VM for running containers of a container group is to be created;
upon determining from said polling that the new VM is to be created, creating the new VM, wherein the new VM has implemented therein an operating system, and a container engine that runs on top of the operating system and supports execution of containers;
determining whether or not images of the containers of the container group are stored in the storage device; and
upon determining that the images of the containers of the container group are stored in the storage device, retrieving the images of the containers of the container group from the storage device, and spinning up the containers of the container group in the new VM.
18. The clustered container host system of claim 17 , wherein
an image cache for the clustered container host system is provisioned in the storage device to be accessible by the hosts, and images of containers that have been previously spun up, including the images of the containers of the container group that are spun up in the new VM, are stored in the image cache.
19. The clustered container host system of claim 18 , wherein the containers of the container group are also spun up in another VM running in a host that is different from the host in which the new VM is running.
20. The clustered container host system of claim 17 , wherein
the hosts are managed as nodes of the of the clustered container host system and also as a cluster by a virtual machine management server that manages all VMs of the hosts, and
the virtual machine management server also provisions virtual disks for the VMs in the storage device, and the images of the containers are stored in the virtual disks.Cited by (0)
No later patents cite this yet.
References (0)
No backward citations on record.