Methods for operating storage driver in container environment and storage driver apparatuses
11675628 · 2023-06-13
Assignee
Inventors
- Young Ik EOM (Suwon-si, KR)
- In Hyeok Kim (Suwon-si, KR)
- Jong Gyu PARK (Suwon-si, KR)
- Kwon Je Oh (Suwon-si, KR)
Cpc classification
G06F16/1734
PHYSICS
International classification
G06F9/50
PHYSICS
Abstract
Provided are a method for operating a storage driver in a container environment and a storage driver apparatus and a method for operating a storage driver according to an exemplary embodiment of the present disclosure includes: requesting downloading of an image for running a container; downloading a plurality of sub images associated with the requested image; allocating each of the plurality of downloaded sub images to an independent logical volume in a multi-layer based file system; and running a container using each of the plurality of allocated sub images.
Claims
1. A method for operating a storage driver, which is performed by a storage driver apparatus comprising a processor in a container environment, the method comprising: requesting, by the processor, downloading of an image for running a container; downloading, by the processor, a plurality of sub images associated with the requested image; allocating, by the processor, the plurality of sub images to a plurality of independent logical volumes included in a physical volume in a multi-layer based file system; storing, by the processor, the plurality of sub images in the plurality of independent logical volumes included in the physical volume; and running, by the processor, the container using the plurality of sub images stored in the plurality of independent logical volumes included in the physical volume, wherein the running of the container using the plurality of sub images includes: accessing each of the plurality of independent logical volumes corresponding to at least one of the plurality of sub images selected among the plurality of sub images; and running instructions of the container corresponding to at least one of the plurality of sub images stored in each of the plurality of independent logical volumes.
2. The method of claim 1, wherein in the requesting of the downloading of the image, running of a Docker is requested using a predetermined image and downloading of an image for running the container is requested through a Docker engine of the run Docker.
3. The method of claim 1, wherein in the allocating of the independent logical volume, the plurality of downloaded sub images are allocated to at least one lower layer, an upper layer, and a volume layer independently separated in the multi-layer based file system, respectively.
4. The method of claim 3, wherein in the multi-layer based file system, at least one lower layer is only readable, the upper layer is readable and writable, and the volume layer is sharable between the containers.
5. The method of claim 3, wherein the at least one lower layer, the upper layer, and the volume layer operate like one file system using a Union file system.
6. The method of claim 3, wherein in the allocating of the independent logical volume, the downloaded sub images are sequentially stored in the at least one lower layer.
7. The method of claim 3, wherein in the running of the container, a write request is stored in the upper layer, which is generated while the container is run.
8. The method of claim 3, wherein in the running of the container, a life cycle of the upper layer is managed the same as the life cycle of the container.
9. The method of claim 3, wherein in the running of the container, the volume layer is changed according to a command by a user of the storage driver.
10. The method of claim 1, wherein in the allocating of the independent logical volume, each of the plurality of downloaded sub images is allocated to the independent logical volume using a storage driver interface of the Docker.
11. A storage driver apparatus in a container environment, comprising: a storage module including an independent logical volume in a multi-layer based file system; a memory storing at least one program; and a processor connected to the storage module and the memory, wherein the processor runs the at least one program to: request downloading of an image for running a container, download a plurality of sub images associated with the requested image, allocate the plurality of sub images to a plurality of independent logical volumes included in a physical volume in a multi-layer based file system, store the plurality of sub images in the plurality of independent logical volumes included in the physical volume, and run the container using the plurality of sub images stored in the plurality of independent logical volumes included in the physical volume, and wherein the processor is configured to: access each of the plurality of independent logical volumes corresponding to at least one of the plurality of sub images selected among the plurality of sub images; and run instructions of the container corresponding to at least one of the plurality of sub images stored in each of the plurality of independent logical volumes.
12. The storage driver apparatus of claim 11, wherein the processor requests running of a Docker using a predetermined image and requests downloading of an image for running the container through a Docker engine of the run Docker.
13. The storage driver apparatus of claim 11, wherein the processor allocates the plurality of downloaded sub images to at least one lower layer, an upper layer, and a volume layer independently separated in the multi-layer based file system, respectively.
14. The storage driver apparatus of claim 13, wherein in the multi-layer based file system, at least one lower layer is only readable, the upper layer is readable and writable, and the volume layer is sharable between the containers.
15. The storage driver apparatus of claim 13, wherein the at least one lower layer, the upper layer, and the volume layer operate like one file system using a Union file system.
16. The storage driver apparatus of claim 13, wherein the processor sequentially stores the downloaded sub images in the at least one lower layer.
17. The storage driver apparatus of claim 13, wherein the processor stores a write request in the upper layer, which is generated while the container is run.
18. The storage driver apparatus of claim 13, wherein the processor manages a life cycle of the upper layer the same as the life cycle of the container.
19. The storage driver apparatus of claim 13, wherein the processor changes the volume layer according to a command by a user of the storage driver.
20. The storage driver apparatus of claim 11, wherein the processor allocates each of the plurality of downloaded sub images to the independent logical volume using a storage driver interface of the Docker.
Description
BRIEF DESCRIPTION OF THE DRAWINGS
(1)
(2)
(3)
(4)
(5)
(6)
(7)
(8)
DETAILED DESCRIPTION OF EXAMPLE EMBODIMENTS
(9) The present disclosure may be variously changed and have various exemplary embodiments and specific exemplary embodiments will be illustrated in the drawings and described in detail.
(10) However, this does not limit the present disclosure to specific exemplary embodiments, and it should be understood that the present disclosure covers all the modifications, equivalents and replacements included within the idea and technical scope of the present disclosure.
(11) Terms including as first, second, and the like are used for describing various constituent elements, but the constituent elements are not limited by the terms. The terms are used only to discriminate one constituent element from another component. For example, a first component may be referred to as a second component, and similarly, the second component may be referred to as the first component without departing from the scope of the present disclosure. A term ‘and/of’ includes a combination of a plurality of associated disclosed items or any item of the plurality of associated disclosed items.
(12) It should be understood that, when it is described that a component is “connected to” or “accesses” another component, the component may be directly connected to or access the other component or a third component may be present therebetween. In contrast, it should be understood that, when it is described that a component is “directly connected to” or “directly accesses” another component, it is understood that no element is present between the element and another element.
(13) Terms used in the present application are used only to describe specific exemplary embodiments, and are not intended to limit the present disclosure. A singular form may include a plural form if there is no clearly opposite meaning in the context. In the present application, it should be understood that term “include” or “have” indicates that a feature, a number, a step, an operation, a component, a part or the combination thereof described in the specification is present, but does not exclude a possibility of presence or addition of one or more other features, numbers, steps, operations, components, parts or combinations thereof, in advance.
(14) If not contrarily defined, all terms used herein including technological or scientific terms have the same meanings as those generally understood by a person with ordinary skill in the art. Terms which are defined in a generally used dictionary should be interpreted to have the same meaning as the meaning in the context of the related art, and are not interpreted as an ideal meaning or excessively formal meanings unless clearly defined in the present application.
(15) Hereinafter, preferred embodiments of the present disclosure will be described in more detail with reference to the accompanying drawings. In describing the present disclosure, the same reference numerals are used for the same components in the drawings and a duplicated description of the same components will be omitted for facilitating overall understanding.
(16)
(17) As shown in
(18) An exemplary embodiment of the present disclosure is divided into an only read lower layer 152 and a readable/writable upper layer 152, and a volume layer 153 which is sharable between containers and respective layers are allocated to different logical volumes and installed and then used by using the required file system 150.
(19) As a result, in an exemplary embodiment of the present disclosure, the independent logical volume 141 is allocated for each layer used in the container and the required file system 150 is installed and operated therein to perfectly remove a bottleneck phenomenon which occurs in various layers and a file system is selected, which is suitable for a feature of each layer to enable an efficient operation.
(20) A Docker which is a representative container platform provides a storage driver plug-in interface so as to manage the layer of the container in various forms. Therethrough, the read only lower layer 152 and the readable/writable upper layer 151, and the volume layer 153 which is sharable between the containers may be managed in desired forms. Therefore, in an exemplary embodiment of the present disclosure, a new form storage driver 130 is intended to be provided, which may use the required file system by allocating the independent logical volume to each layer by using the storage driver plug-in interface.
(21) In
(22) Docker running is requested using a specific image (e.g., Ubuntu ISO image file).
(23) The Docker demon (distribution) 110 requests ubuntu image downloading.
(24) The Docker demon 110 is downloaded an ubuntu image from the registry 120. Here, the ubuntu image is divided into multiple sub images. Therefore, all sub images associated with the ubuntu image are downloaded.
(25) The Docker demon 110 stores all corresponding sub images through the storage driver (graphdriver) 130.
(26) The storage driver 130 according to an exemplary embodiment of the present disclosure stores each sub image in the independent logical volume 141 included in the physical volume 140.
(27) When the storage driver 130 stores all sub images, the Docker runs a new container using the ubuntu image.
(28) Since the conventional storage driver stores all sub images in one physical volume in the step of storing the sub image, the bottleneck phenomenon occurs when accessing (reading/writing) each sub image.
(29) However, since the storage driver 130 according to an exemplary embodiment of the present disclosure stores all sub images in each logical volume 141, the bottleneck phenomenon may be fundamentally removed.
(30) In general the physical volume 140 means one storage apparatus (e.g., SSD). The logical volume 141 virtualizes the physical volume 140 as if the logical volume 141 has multiple storage apparatuses by splitting the physical volume 140 as many as necessary.
(31)
(32) As shown in
(33) The multiple lower, upper, and volume layers 151, 152, and 153 are made to be visible using a union file system like an overlay file system. The layers are actually divided into multiple layers, but shown as existing like a single layer 310.
(34)
(35) In
(36) As shown in
(37)
(38) In a method for operating a storage driver in a container environment according to an exemplary embodiment of the present disclosure, layers of respective layers of all containers are made to operate in the container environment to ensure regionality and distinctiveness.
(39) In step S101, the storage driver apparatus according to an exemplary embodiment of the present disclosure request downloading of an image for running the container.
(40) In step S102, the storage driver apparatus downloads a plurality of sub images associated with the requested image.
(41) In step S103, the storage driver apparatus allocates each of the plurality of downloaded sub images to the independent logical volume in the multiple layer based file system.
(42) In step S104, the storage driver apparatus runs the container by using the plurality of respective allocated sub images.
(43)
(44) As shown in
(45) Hereinafter, a detailed configuration and a detailed operation of each of the components of the storage driver apparatus 600 of
(46) The storage module 610 includes the independent logical volume in the multiple layer based file system.
(47) The memory 620 stores at least one program.
(48) The processor 630 is connected to the storage module 610 and the memory 620.
(49) The processor 630 runs at least one program to request downloading of the image for running the container, downloads a plurality of sub images associated with the requested image, allocates each of the plurality of downloaded sub images to the independent logical volume in the multiple layer based file system in the storage module 610, and runs the container using each of the plurality of allocated sub images.
(50) According to various exemplary embodiments, the processor 630 may request running of the Docker using a predetermined image and request downloading of the image for running the container through a Docker engine of the run Docker.
(51) According to various exemplary embodiments, the processor 630 may allocate each of the plurality of downloaded sub images to at least one lower layer, at least one upper layer, and at least one volume layer which are independently separated in the multiple layer file system.
(52) According to various exemplary embodiments, in the multiple layer based file system, at least one lower layer is only readable, the upper layer is readable and writable, and the volume layer is sharable between the containers.
(53) According to various exemplary embodiments, at least one lower layer, at least upper layer, and at least one volume layer operate like one file system using a Union file system.
(54) According to various exemplary embodiments, the processor 630 may store the downloaded sub images in at least one lower layer in sequence.
(55) According to various exemplary embodiments, the processor 630 may allocate each of the plurality of downloaded sub images to the independent logical volume using the storage driver interface of the Docker.
(56) According to various exemplary embodiments, the processor 630 may store a write request generated while the container is run in the upper layer.
(57) According to various exemplary embodiments, the processor 630 may manage the life cycle of the upper layer to be the same as the lift cycle of the container.
(58) According to various exemplary embodiments, the processor 630 may change the volume layer according to an instruction by a user of a storage driver.
(59)
(60) In all of conventional storage drivers (VFS, BTRFS, and OVERLAY) illustrated in
(61) However, since the storage driver (OVERLIT) according to an exemplary embodiment of the present disclosure stores all layers in each logical volume, the bottleneck phenomenon may be removed.
(62)
(63) In order to measure extensibility of an exemplary embodiment of the present disclosure, it is checked how performance increases when operating one to 8 containers in one server node.
(64) As shown in
(65) However, the storage driver (overlit) according to an exemplary embodiment of the present disclosure shows better extensibility by removing the bottleneck phenomenon. In particular, when a memory based file system (tmpfs) is used in the upper layer maintained only while the container is run (overtmp), extensibility in which the performance almost linearly increases is shown.
(66)
(67)
(68) As shown in
(69) In an exemplary embodiment of the present disclosure, it is expected that the bottleneck phenomenon between the containers is removed a large cloud computing environment and overall operating cost may be reduced by enabling the efficient operation. In particular, when thousands of containers simultaneously operate in a server node having high performance, it is very important to remove the bottleneck phenomenon which occurs in a file system/storage layer. The exemplary embodiment has been determined as technology suitable for a high-efficiency computing environment recently targeted by all companies that operate a large data center.
(70) The method for operating the storage driver in the container environment according to the exemplary embodiments of the present disclosure may be implemented as a computer readable code in a computer readable recording medium. The method for operating the storage driver in the container environment according to the exemplary embodiments of the present disclosure is implemented in a form of a program command which may be performed through various computer means and may be recorded in the computer readable recording medium.
(71) A non-transitory computer readable storage medium including at least one program executable by a processor may be provided and when the at least one program is executed by the processor, the non-transitory computer includes commands allowing the processor to request downloading of an image for running a container, download a plurality of sub images associated with the requested image, allocate each of the plurality of downloaded sub images to an independent logical volume in a multiple layer based file system in the storage module, and run the container using each of the plurality of allocated sub images.
(72) The method according to the present disclosure may be implemented as the computer readable code in the computer readable recording medium. The computer readable recording medium includes all kinds of recording media storing data which may be deciphered by a computer system. For example, the recording media may include a read only memory (ROM), a random access memory (RAM), a magnetic tape, a magnetic disk, a flash memory, an optical data storage device, etc. Further, the computer readable recording media may be stored and executed as codes which may be distributed in the computer system connected through a computer communication network and read by a distribution method.
(73) Hereinabove, the present disclosure has been described with reference to the drawings and exemplary embodiments, but it is not meant that the protection scope of the present disclosure is limited by the drawings or exemplary embodiments, but those skilled in the art will understand that the present disclosure can be variously modified and changed without departing from the spirit and the scope of the present disclosure which are defined in the appended claims.
(74) Specifically, described features may be executed in a digital electronic circuit, computer hardware, firmware, or combinations thereof. The features may be executed in a computer program product implemented in a storage apparatus in a machine readable storage device for execution by a programmable processor. In addition, the features may be performed by a programmable processor operating on input data and executing programs of directives for performing functions of the exemplary embodiments described by generating an output. The described features may be executed in one or more computer programs which may be executed on a programmable system including at least one programmable combined processor, at least one input device, and at least one output device in order to receive data and directives from a data storage system and in order to transmit the data and the directives to the data storage system. The computer program includes a set of directives which may be directly or indirectly used in the computer in order to perform a specific operation with respect to a predetermined result. The computer program may be written in any form among programming languages including compiled and interpreted languages and used as another unit suitable for use in a module, a device, a subroutine, or another computer environment or as any form included as an independent operable program.
(75) Appropriate processor for executing the programs of the directives include, for example, both universal and special-purpose microprocessors and a single processor or one of multiple processors of different types of computers. Further, storage devices suitable for computer program directives and data implementing the described features include all types of non-volatile memories including semiconductor memory devices such as EPROM, EEPROM, and flash memory devices, magnetic devices such as internal hard disks and removable disks, optical magnetic disks, and CD-ROM and DVD-ROM disks. The processor and the memory may be integrated in application-specific integrated circuits (ASICs) or added by the ASICs.
(76) The aforementioned present disclosure is described based on a series of functional blocks, but not limited to the aforementioned embodiments and the accompanying drawings, and it will be obvious to those skilled in the technical field to which the present disclosure pertains that various substitutions, modifications, and changes may be made within the scope without departing from the technical spirit of the present disclosure.
(77) A combination of the exemplary embodiments is not limited to the aforementioned exemplary embodiment and various forms of combinations may be provided in addition to the aforementioned exemplary embodiments according to implementation and/or a need.
(78) In the aforementioned exemplary embodiments, methods have been described based on flowcharts as a series of steps or blocks, but the methods are not limited to the order of the steps of the present disclosure and any step may occur in a step or an order different from or simultaneously as the aforementioned step or order. Further, it can be appreciated by those skilled in the art that steps shown in the flowcharts are not exclusive and other steps may be included or one or more steps do not influence the scope of the present disclosure and may be deleted.
(79) The aforementioned exemplary embodiment includes various aspects of examples. All possible combinations for showing various aspects may not be described, but those skilled in the art may recognize that different combinations are possible. Accordingly, it will be intended that the present disclosure all other replacements, modifications, and changes which belong to the following claims.