CN107105054B - Mirror image garbage cleaning system and method for docker mirror image warehouse - Google Patents
Mirror image garbage cleaning system and method for docker mirror image warehouse Download PDFInfo
- Publication number
- CN107105054B CN107105054B CN201710347806.1A CN201710347806A CN107105054B CN 107105054 B CN107105054 B CN 107105054B CN 201710347806 A CN201710347806 A CN 201710347806A CN 107105054 B CN107105054 B CN 107105054B
- Authority
- CN
- China
- Prior art keywords
- mirror image
- request
- cleaning
- warehouse
- module
- Prior art date
- Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
- Active
Links
Classifications
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04L—TRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
- H04L67/00—Network arrangements or protocols for supporting network services or applications
- H04L67/01—Protocols
- H04L67/10—Protocols in which an application is distributed across nodes in the network
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04L—TRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
- H04L67/00—Network arrangements or protocols for supporting network services or applications
- H04L67/01—Protocols
- H04L67/06—Protocols specially adapted for file transfer, e.g. file transfer protocol [FTP]
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04L—TRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
- H04L67/00—Network arrangements or protocols for supporting network services or applications
- H04L67/01—Protocols
- H04L67/10—Protocols in which an application is distributed across nodes in the network
- H04L67/1095—Replication or mirroring of data, e.g. scheduling or transport for data synchronisation between network nodes
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04L—TRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
- H04L67/00—Network arrangements or protocols for supporting network services or applications
- H04L67/50—Network services
- H04L67/56—Provisioning of proxy services
- H04L67/568—Storing data temporarily at an intermediate stage, e.g. caching
- H04L67/5682—Policies or rules for updating, deleting or replacing the stored data
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04L—TRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
- H04L67/00—Network arrangements or protocols for supporting network services or applications
- H04L67/50—Network services
- H04L67/60—Scheduling or organising the servicing of application requests, e.g. requests for application data transmissions using the analysis and optimisation of the required network resources
Abstract
The invention discloses a mirror image garbage cleaning system and method facing a docker mirror image warehouse, which comprises the steps of firstly configuring a main mirror image warehouse and a standby mirror image warehouse which can be logically replaced with each other; caching the mirror image uploading request, the mirror image deleting request and the corresponding mirror image file, and taking a difference set of the mirror image uploading request and the mirror image deleting request in a specified time period; switching a main mirror image warehouse and a standby mirror image warehouse, executing a difference set uploading mirror image request through the standby mirror image warehouse, stopping the main mirror image warehouse and cleaning the main mirror image warehouse after the execution is finished; and finally, taking the standby mirror image warehouse as a main mirror image warehouse and the original main mirror image warehouse as a standby mirror image warehouse, repeating the logic, and performing the next mirror image garbage cleaning work. Compared with the prior art, the mirror image garbage cleaning system and method for the docker mirror image warehouse fill the blank of the mirror image cleaning technology in the docker mirror image warehouse, can effectively reduce the storage pressure of the docker mirror image warehouse, and are high in practicability.
Description
Technical Field
The invention relates to the technical field of cloud computing, in particular to a mirror image garbage cleaning system and method for a docker mirror image warehouse.
Background
In a docker mirror warehouse in the technical field of cloud computing containers, because storage of mirrors is hierarchical storage, each mirror layer only stores modified mirrors and meta information of a parent mirror storage layer depending on storage, and under the storage structure, two problems can be involved when deleting mirrors to clean up the space of the mirror warehouse: firstly, deleting the dependent mirror image layer is to judge that the dependent layer is not depended on by other mirror image layers firstly, and the dependent layer is required to be traversed, so that the mirror image can be better cleaned and the mirror image warehouse space can be better released; secondly, distributed locking is involved during deletion, and if a certain mirror image layer is deleted and a mirror image depending on the mirror image layer is uploaded at the same time, the problem that the uploaded mirror image is subsequently unavailable occurs.
Based on the problems, the invention provides a mirror image garbage cleaning system and method for a docker mirror image warehouse, and the system and method effectively solve the problems.
Disclosure of Invention
The technical task of the invention is to provide a mirror image garbage cleaning system and method for a docker mirror image warehouse aiming at the defects.
The utility model provides a mirror image rubbish clearance system towards docker mirror image warehouse, includes two mirror image warehouses and following modules: a request agent module, a message center module, a cleaning module and a cleaning agent, wherein,
the two mirror image warehouses are respectively a main mirror image warehouse and a standby mirror image warehouse, the main mirror image warehouse is responsible for uploading and downloading requests of mirror images, and the standby mirror image warehouse is responsible for storing the cleaned mirror images;
the request agent module is responsible for request and mirror image write-in storage, and executes different agent requests according to the identification information of the message center module;
the message center module provides identification information for the request agent module, the identification information comprises a cleaning start, a cleaning end, a main mirror image warehouse address and a standby mirror image warehouse address, and pushes and executes a command of cleaning the mirror image warehouse to a cleaning agent on the mirror image warehouse when the cleaning is finished;
the cleaning module executes a timing task according to the identification of the message center, acquires and deletes a difference set of the stored requests, resends the uploading request corresponding to the difference set to the current standby mirror image warehouse, and sends an identification message to the message center after the execution is finished;
and cleaning the agent, wherein the agent is requested to execute the cleaning work of the module after receiving the pushing of the message center, and after the cleaning work is finished, a cleaning finishing message is sent to the message center.
When the request agent module writes the request and the mirror image into the storage, the request storage module and the mirror image storage module are firstly configured to respectively store the request and the mirror image, the request comprises a request for uploading the mirror image and a request for deleting the mirror image, the request agent module records the request for uploading and deleting the mirror image into the request storage module, and the mirror image is put into the mirror image storage module.
The working process of the request agent module is as follows:
the request broker module looks at the current system in the message center at the stage: whether the image is a mirror image garbage cleaning stage or a non-mirror image garbage cleaning stage is judged, and a current main mirror image address and an address of a standby mirror image warehouse are obtained;
if the mirror image is not in the mirror image garbage cleaning stage, transmitting a sending request to the current main mirror image warehouse;
if the mirror image garbage cleaning stage is adopted, the mirror image uploading request is uploaded to a standby mirror image warehouse; when the mirror image is downloaded, the mirror image is downloaded through the standby mirror image warehouse, and if the mirror image is not downloaded, the mirror image is downloaded through the main mirror image warehouse.
In the message center module, when a cache mirror image is uploaded and requested to be deleted, identifiers for starting cleaning and finishing cleaning are provided to execute agent requests according to different logics, the cleaning module executes cleaning tasks according to the identifiers of the message center at regular time and writes identifiers of an execution stage into the message center, the message center sends a cleaning command to a cleaning agent according to the collected identifiers, and the logic roles of the main warehouse and the standby warehouse are switched in time according to the stage where the acquired message identifiers are located.
The message center module receives messages sent by the cleaning module and the cleaning agent, carries out identification stages and logic main and standby mirror image warehouses and pushes commands to the cleaning agent, and the specific implementation steps are as follows:
the method comprises the following steps: firstly, initializing, setting a current stage as a non-cleaning stage by a message center module, and setting a current logical main standby mirror image warehouse;
step two: when a request for cleaning a mirror image message by a cleaning module is received, setting the current stage as a mirror image cleaning stage;
step three: when receiving a message of ending retransmission of the difference set request sent by the cleaning module, sending a command of cleaning the module to a cleaning agent;
step four: and after the cleaning completion messages of all the cleaning agents are received, changing the current stage into a non-cleaning stage, and switching the logic roles of the main and standby mirror image warehouses.
The cleaning module calculates the difference of the cache request and executes the difference request to the standby mirror image warehouse according to the identification of the message center module at regular time, and the method comprises the following implementation steps:
the cleaning module is started regularly and continuously inquires whether the cleaning process in the previous stage is finished or not to the message center module;
when the inquiry is finished to the cleaning process in the previous stage, identifying the start of cleaning work in the message center module, and acquiring a main mirror image warehouse address and a standby mirror image warehouse address from the message center module;
the cleaning module acquires the stored mirror image uploading request and the mirror image deleting request from the request storage module, calculates a difference set of the uploading request and the deleting request, and acquires a mirror image corresponding to the uploading mirror image request corresponding to the difference set from the mirror image storage;
and executing the mirror image uploading request corresponding to the difference set to the standby mirror image warehouse, after the uploading request is completely executed, sending a message to the message center, and finishing the mirror image difference set uploading request by the cleaning module.
Based on the system, a mirror image garbage cleaning method facing a docker mirror image warehouse is provided with a main mirror image warehouse and a standby mirror image warehouse which can be logically replaced with each other, and the method comprises the following implementation steps:
caching the mirror image uploading request, the mirror image deleting request and the corresponding mirror image file, and taking a difference set of the mirror image uploading request and the mirror image deleting request in a specified time period;
switching a main mirror image warehouse and a standby mirror image warehouse, executing a difference set uploading mirror image request through the standby mirror image warehouse, stopping the main mirror image warehouse and cleaning the main mirror image warehouse after the execution is finished;
and finally, taking the standby mirror image warehouse as a main mirror image warehouse and the original main mirror image warehouse as a standby mirror image warehouse, repeating the logic, and performing the next mirror image garbage cleaning work.
The main mirror image warehouse is responsible for uploading and downloading requests of mirror images, and the standby mirror image warehouse is responsible for storing the cleaned mirror images.
In the step of switching the main mirror image warehouse and the standby mirror image warehouse, the main mirror image warehouse is switched to a read-only mode, the standby mirror image warehouse is switched to a read-write mode, and then a difference set uploading mirror image request is executed to the standby mirror image warehouse according to the cached uploading mirror image request and the deletion mirror image request difference set.
Before obtaining the difference between the uploading request and the mirror image deleting request, starting a request agent module to only upload the downloading request to the standby mirror image warehouse, and retransmitting the downloading request to the main mirror image warehouse when the downloading request fails; and then executing the difference request to the standby mirror image warehouse, and after the execution is finished, only the request is made to proxy the uploading and downloading request to the standby mirror image warehouse through the request proxy module.
Compared with the prior art, the mirror image garbage cleaning system and method for the docker mirror image warehouse have the following beneficial effects:
the mirror image garbage cleaning system and method for the docker mirror image warehouse fill up the blank of mirror image cleaning technology in the docker mirror image warehouse, can effectively reduce the storage pressure of the docker mirror image warehouse, and can enable the docker mirror image warehouse to effectively support frequent operation of uploading and deleting mirror images, so that mirror images are quickly cleaned and mirror image spaces are released, and the mirror image garbage cleaning system and method are high in practicability, wide in application range and good in popularization and application value.
Drawings
Fig. 1 is a schematic diagram of the implementation of the present invention.
Detailed Description
The invention is further described with reference to the following figures and specific embodiments.
As shown in fig. 1, a mirror image garbage cleaning system facing a docker mirror image warehouse includes two mirror image warehouses and the following modules: a request agent module, a message center module, a cleaning module and a cleaning agent, wherein,
the two mirror image warehouses are respectively a main mirror image warehouse and a standby mirror image warehouse, the main mirror image warehouse and the standby mirror image warehouse are used as warehouses which are logically switched with each other, the main mirror image warehouse is responsible for uploading and downloading requests of mirror images, and the standby mirror image warehouse is responsible for storing the cleaned mirror images;
the request agent module is responsible for request and mirror image write-in storage, and executes different agent requests according to the identification information of the message center module;
the message center module provides identification information for the request agent module, the identification information comprises a cleaning start, a cleaning end, a main mirror image warehouse address and a standby mirror image warehouse address, and pushes and executes a command of cleaning the mirror image warehouse to a cleaning agent on the mirror image warehouse when the cleaning is finished;
the cleaning module executes a timing task according to the identification of the message center, acquires and deletes a difference set of the stored requests, resends the uploading request corresponding to the difference set to the current standby mirror image warehouse, and sends an identification message to the message center after the execution is finished;
and cleaning the agent, wherein the agent is requested to execute the cleaning work of the module after receiving the pushing of the message center, and after the cleaning work is finished, a cleaning finishing message is sent to the message center.
When the request agent module writes the request and the mirror image into the storage, the request storage module and the mirror image storage module are firstly configured to respectively store the request and the mirror image, the request comprises a request for uploading the mirror image and a request for deleting the mirror image, the request agent module records the request for uploading and deleting the mirror image into the request storage module, and the mirror image is put into the mirror image storage module.
The specific working process of the request agent module is as follows:
when the mirror image uploading request and the mirror image deleting request come, the request agent module records the mirror image uploading request and the mirror image deleting request into the request storage, and the mirror image is put into the mirror image storage, and the mirror image uploading request and the mirror image downloading request are transmitted to the back except the mirror image deleting request;
next, the request agent module goes to the message center to check whether the current system is in a mirror image garbage cleaning stage or a normal stage, namely a non-mirror image garbage cleaning stage, and acquires the current primary mirror image address and the address of the standby mirror image warehouse;
if the current primary mirror image warehouse is in a normal stage, transmitting a sending request to the current primary mirror image warehouse;
if the mirror image garbage cleaning stage is adopted, the mirror image uploading request is uploaded to a standby mirror image warehouse; when downloading mirror image, firstly downloading the mirror image to the standby mirror image warehouse, if not, downloading the mirror image to the primary mirror image warehouse.
In the message center module, when a cache mirror image is uploaded and requested to be deleted, identifiers for starting cleaning and finishing cleaning are provided to execute agent requests according to different logics, the cleaning module executes cleaning tasks according to the identifiers of the message center at regular time and writes identifiers of an execution stage into the message center, the message center sends a cleaning command to a cleaning agent according to the collected identifiers, and the logic roles of the main warehouse and the standby warehouse are switched in time according to the stage where the acquired message identifiers are located.
The message center module receives messages sent by the cleaning module and the cleaning agent, carries out identification stages and logic main and standby mirror image warehouses and pushes commands to the cleaning agent, and the specific implementation steps are as follows:
the method comprises the following steps: firstly, initializing, setting a current stage as a non-cleaning stage by a message center module, and setting a current logical main standby mirror image warehouse;
step two: when a request for cleaning a mirror image message by a cleaning module is received, setting the current stage as a mirror image cleaning stage;
step three: when receiving a message of ending retransmission of the difference set request sent by the cleaning module, sending a command of cleaning the module to a cleaning agent;
step four: and after the cleaning completion messages of all the cleaning agents are received, changing the current stage into a non-cleaning stage, and switching the logic roles of the main and standby mirror image warehouses.
The cleaning module calculates the difference of the cache request and executes the difference request to the standby mirror image warehouse according to the identification of the message center module at regular time, and the method comprises the following implementation steps:
1) the cleaning module is started regularly and continuously inquires whether the cleaning process in the previous stage is finished or not to the message center;
2) when the inquiry is finished to the cleaning process in the previous stage, the cleaning work is identified to start in the message center, and the address of the main mirror image warehouse and the address of the standby mirror image warehouse in the current year are obtained from the message center;
3) the cleaning module acquires the stored mirror image uploading request and the mirror image deleting request from the request storage module, calculates a difference set of the uploading request and the deleting request, and acquires a mirror image corresponding to the uploading mirror image request corresponding to the difference set from the mirror image storage;
4) executing the mirror image uploading request corresponding to the difference set to the standby mirror image warehouse, after the uploading request is completely executed, sending a message to a message center, and finishing the mirror image uploading request by a cleaning module;
5) after receiving the message of finishing the request of uploading the mirror image difference set, the message center sends the message to the modules of the request storage module, the mirror image storage module and the main mirror image warehouse, and orders the modules to start executing the internal cleaning process of the modules;
6) after each cleaning agent finishes cleaning the module, the information of the module which is cleaned is sent to the information center
7) After all the message centers receive the message of completing module cleaning, the current system is changed into the cleaning work completion stage and the roles of switching the main and standby mirror image warehouses at the same time.
Based on the system, a mirror image garbage cleaning method facing a docker mirror image warehouse is provided with a main mirror image warehouse and a standby mirror image warehouse which can be logically replaced with each other, and the method comprises the following implementation steps:
caching the mirror image uploading request, the mirror image deleting request and the corresponding mirror image file, and taking a difference set of the mirror image uploading request and the mirror image deleting request in a specified time period;
switching a main mirror image warehouse and a standby mirror image warehouse, executing a difference set uploading mirror image request through the standby mirror image warehouse, stopping the main mirror image warehouse and cleaning the main mirror image warehouse after the execution is finished;
and finally, taking the standby mirror image warehouse as a main mirror image warehouse and the original main mirror image warehouse as a standby mirror image warehouse, repeating the logic, and performing the next mirror image garbage cleaning work.
The method uses two mirror image warehouses, wherein one mirror image warehouse is used as a main warehouse, the other mirror image warehouse is used as a standby warehouse, the main mirror image warehouse is responsible for uploading and downloading requests of mirror images, and the standby mirror image warehouse is responsible for storing the cleaned mirror images.
And caching the mirror image uploading request, the mirror image deleting request and the corresponding mirror image file, and taking a difference set of the mirror image uploading request and the mirror image deleting request in a specified time period.
Before the difference between the uploading request and the image deleting request is obtained, the starting request agent only uploads the downloading request to the standby image warehouse, and if the downloading request fails, the request needs to be retransmitted to the primary image warehouse.
And executing the difference set request to the standby mirror image warehouse, and after the execution is finished, switching the request proxy switch to only proxy the uploading and downloading request to the standby mirror image warehouse.
And emptying the mirror image of the main mirror image warehouse, exchanging the roles of the main mirror image warehouse and the standby mirror image warehouse, and performing the mirror image cleaning process again when a specified time period is reached.
In the step of switching the main mirror image warehouse and the standby mirror image warehouse, the main mirror image warehouse is switched to a read-only mode, the standby mirror image warehouse is switched to a read-write mode, and then a difference set uploading mirror image request is executed to the standby mirror image warehouse according to the cached uploading mirror image request and the deletion mirror image request difference set.
Before obtaining the difference between the uploading request and the mirror image deleting request, starting a request agent module to only upload the downloading request to the standby mirror image warehouse, and retransmitting the downloading request to the main mirror image warehouse when the downloading request fails; and then executing the difference request to the standby mirror image warehouse, and after the execution is finished, only the request is made to proxy the uploading and downloading request to the standby mirror image warehouse through the request proxy module.
The present invention can be easily implemented by those skilled in the art from the above detailed description. It should be understood, however, that the intention is not to limit the invention to the particular embodiments described. On the basis of the disclosed embodiments, a person skilled in the art can combine different technical features at will, thereby implementing different technical solutions.
In addition to the technical features described in the specification, the technology is known to those skilled in the art.
Claims (10)
1. The utility model provides a mirror image rubbish clearance system towards docker mirror image warehouse which characterized in that includes two mirror image warehouses and following modules: a request agent module, a message center module, a cleaning module and a cleaning agent, wherein,
the two mirror image warehouses are respectively a main mirror image warehouse and a standby mirror image warehouse, the main mirror image warehouse is responsible for uploading and downloading requests of mirror images, and the standby mirror image warehouse is responsible for storing the cleaned mirror images;
the request agent module is responsible for request and mirror image write-in storage, and executes different agent requests according to the identification information of the message center module;
the message center module provides identification information for the request agent module, the identification information comprises a cleaning start, a cleaning end, a main mirror image warehouse address and a standby mirror image warehouse address, and pushes and executes a command of cleaning the mirror image warehouse to a cleaning agent on the mirror image warehouse when the cleaning is finished;
the cleaning module executes a timing task according to the identification of the message center, acquires and deletes a difference set of the stored requests, resends the uploading request corresponding to the difference set to the current standby mirror image warehouse, and sends an identification message to the message center after the execution is finished;
and cleaning the agent, wherein the agent is requested to execute the cleaning work of the module after receiving the pushing of the message center, and after the cleaning work is finished, a cleaning finishing message is sent to the message center.
2. The system of claim 1, wherein when the request agent module writes the request and the mirror image into the storage, the request storage module and the mirror image storage module are configured to store the request and the mirror image, respectively, the request includes a request to upload the mirror image and a request to delete the mirror image, the request agent module records the request to upload the mirror image and the request to delete the mirror image into the request storage module, and places the mirror image into the mirror image storage module.
3. The mirror image garbage cleaning system for the docker mirror warehouse as claimed in claim 2, wherein the request agent module operates as follows:
the request broker module looks at the current system in the message center at the stage: whether the image is a mirror image garbage cleaning stage or a non-mirror image garbage cleaning stage is judged, and a current main mirror image address and an address of a standby mirror image warehouse are obtained;
if the mirror image is not in the mirror image garbage cleaning stage, transmitting a sending request to the current main mirror image warehouse;
if the mirror image garbage cleaning stage is adopted, the mirror image uploading request is uploaded to a standby mirror image warehouse; when the mirror image is downloaded, the mirror image is downloaded through the standby mirror image warehouse, and if the mirror image is not downloaded, the mirror image is downloaded through the main mirror image warehouse.
4. The mirror image garbage cleaning system facing a docker mirror image warehouse as claimed in claim 2, wherein in the message center module, when the cache mirror image is uploaded and deleted, the proxy requests are executed according to different logics by providing identifiers for starting cleaning and finishing cleaning, the cleaning module executes the cleaning task regularly according to the identifier of the message center and writes the identifier of the execution stage into the message center, the message center sends the cleaning command to the cleaning agent according to the collected identifier, and the logical roles of the main and standby warehouses are switched in time according to the stage where the acquired message identifier is located.
5. The docker mirror image warehouse-oriented mirror image garbage cleaning system of claim 4, wherein the message center module receives messages sent by the cleaning module and the cleaning agent, performs identification phase and logic for the main and standby mirror image warehouses and pushes commands to the cleaning agent, and the specific implementation steps are as follows:
the method comprises the following steps: firstly, initializing, setting a current stage as a non-cleaning stage by a message center module, and setting a current logical main standby mirror image warehouse;
step two: when a request for cleaning a mirror image message by a cleaning module is received, setting the current stage as a mirror image cleaning stage;
step three: when receiving a message of ending retransmission of the difference set request sent by the cleaning module, sending a command of cleaning the module to a cleaning agent;
step four: and after the cleaning completion messages of all the cleaning agents are received, changing the current stage into a non-cleaning stage, and switching the logic roles of the main and standby mirror image warehouses.
6. The mirror image garbage cleaning system facing a docker mirror warehouse as claimed in claim 4 or 5, wherein the cleaning module periodically calculates the difference of the cache requests and executes the difference request to the backup mirror warehouse according to the identifier of the message center module, and the implementation steps are as follows:
the cleaning module is started regularly and continuously inquires whether the cleaning process in the previous stage is finished or not to the message center module;
when the inquiry is finished to the cleaning process in the previous stage, identifying the start of cleaning work in the message center module, and acquiring a main mirror image warehouse address and a standby mirror image warehouse address from the message center module;
the cleaning module acquires the stored mirror image uploading request and the mirror image deleting request from the request storage module, calculates a difference set of the uploading request and the deleting request, and acquires a mirror image corresponding to the uploading mirror image request corresponding to the difference set from the mirror image storage;
and executing the mirror image uploading request corresponding to the difference set to the standby mirror image warehouse, after the uploading request is completely executed, sending a message to the message center, and finishing the mirror image difference set uploading request by the cleaning module.
7. A mirror image garbage cleaning method facing a docker mirror image warehouse, characterized in that, based on the mirror image garbage cleaning system facing the docker mirror image warehouse as claimed in any one of claims 1 to 6, the system is configured with a primary mirror image warehouse and a standby mirror image warehouse which can be logically replaced with each other, and the method is implemented by the steps of:
caching the mirror image uploading request, the mirror image deleting request and the corresponding mirror image file, and taking a difference set of the mirror image uploading request and the mirror image deleting request in a specified time period;
switching a main mirror image warehouse and a standby mirror image warehouse, executing a difference set uploading mirror image request through the standby mirror image warehouse, stopping the main mirror image warehouse and cleaning the main mirror image warehouse after the execution is finished;
and finally, taking the standby mirror image warehouse as a main mirror image warehouse and the original main mirror image warehouse as a standby mirror image warehouse, repeating the logic, and performing the next mirror image garbage cleaning work.
8. The image garbage cleaning method facing a docker image warehouse as claimed in claim 7, wherein the primary image warehouse is responsible for uploading and downloading requests of images, and the backup image warehouse is responsible for storing the cleaned images.
9. The method as claimed in claim 7, wherein in the step of switching the primary and standby mirror image warehouses, the primary mirror image warehouse is switched to a read-only mode, the standby mirror image warehouse is switched to a read-write mode, and then the difference upload mirror image request is executed to the standby mirror image warehouse according to the cached upload mirror image request and the difference of the delete mirror image request.
10. The image garbage cleaning method facing a docker image warehouse as claimed in claim 7, wherein before a difference between the upload request and the image deletion request is obtained, the start request agent module only uploads the download request to the standby image warehouse, and if the download request fails, retransmits the request to the primary image warehouse; and then executing the difference request to the standby mirror image warehouse, and after the execution is finished, only the request is made to proxy the uploading and downloading request to the standby mirror image warehouse through the request proxy module.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201710347806.1A CN107105054B (en) | 2017-05-17 | 2017-05-17 | Mirror image garbage cleaning system and method for docker mirror image warehouse |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201710347806.1A CN107105054B (en) | 2017-05-17 | 2017-05-17 | Mirror image garbage cleaning system and method for docker mirror image warehouse |
Publications (2)
Publication Number | Publication Date |
---|---|
CN107105054A CN107105054A (en) | 2017-08-29 |
CN107105054B true CN107105054B (en) | 2019-12-24 |
Family
ID=59669431
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN201710347806.1A Active CN107105054B (en) | 2017-05-17 | 2017-05-17 | Mirror image garbage cleaning system and method for docker mirror image warehouse |
Country Status (1)
Country | Link |
---|---|
CN (1) | CN107105054B (en) |
Families Citing this family (5)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN107809467B (en) * | 2017-10-10 | 2020-06-16 | 暨南大学 | Method for deleting container mirror image data in cloud environment |
CN108200155A (en) * | 2017-12-29 | 2018-06-22 | 平安科技(深圳)有限公司 | The mirror image synchronization method in Docker mirror images warehouse and mirror image synchronization system |
CN112084165A (en) * | 2019-06-12 | 2020-12-15 | 阿里巴巴集团控股有限公司 | Method and device for managing mirror image warehouse, electronic equipment and readable storage medium |
CN110442480B (en) * | 2019-07-31 | 2022-04-15 | 中国工商银行股份有限公司 | Mirror image data cleaning method, device and system |
CN112905541B (en) * | 2019-12-03 | 2024-04-05 | 北京沃东天骏信息技术有限公司 | Mirror image warehouse garbage cleaning method and device |
Citations (4)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN103116661A (en) * | 2013-03-20 | 2013-05-22 | 广东宜通世纪科技股份有限公司 | Data processing method of database |
CN103186554A (en) * | 2011-12-28 | 2013-07-03 | 阿里巴巴集团控股有限公司 | Distributed data mirroring method and data storage node |
CN105740048A (en) * | 2016-01-26 | 2016-07-06 | 华为技术有限公司 | Image management method, device and system |
CN106227579A (en) * | 2016-07-12 | 2016-12-14 | 深圳市中润四方信息技术有限公司 | A kind of Docker container construction method and Docker manage control station |
Family Cites Families (1)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
JP4345860B2 (en) * | 2007-09-14 | 2009-10-14 | 株式会社デンソー | Vehicle memory management device |
-
2017
- 2017-05-17 CN CN201710347806.1A patent/CN107105054B/en active Active
Patent Citations (4)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN103186554A (en) * | 2011-12-28 | 2013-07-03 | 阿里巴巴集团控股有限公司 | Distributed data mirroring method and data storage node |
CN103116661A (en) * | 2013-03-20 | 2013-05-22 | 广东宜通世纪科技股份有限公司 | Data processing method of database |
CN105740048A (en) * | 2016-01-26 | 2016-07-06 | 华为技术有限公司 | Image management method, device and system |
CN106227579A (en) * | 2016-07-12 | 2016-12-14 | 深圳市中润四方信息技术有限公司 | A kind of Docker container construction method and Docker manage control station |
Also Published As
Publication number | Publication date |
---|---|
CN107105054A (en) | 2017-08-29 |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
CN107105054B (en) | Mirror image garbage cleaning system and method for docker mirror image warehouse | |
CN109241185B (en) | Data synchronization method and data synchronization device | |
US8171100B2 (en) | Reducing latency of access requests in distributed storage systems having a shared data set | |
WO2017128764A1 (en) | Cache cluster-based caching method and system | |
AU2019236685A1 (en) | Distributed file system using consensus nodes | |
CN103870570A (en) | HBase (Hadoop database) data usability and durability method based on remote log backup | |
JP2017533520A (en) | Point-in-time restore from database storage snapshots | |
CN105210060A (en) | Transaction processing for database in persistent system | |
US20150067004A1 (en) | Distributed file system using consensus nodes | |
US20080148000A1 (en) | Techniques for data replication with snapshot capabilities | |
CN109145163B (en) | Block chain data capacity reduction method and device and storage medium | |
CN104461776A (en) | Application disaster tolerance method based on CDP and iSCSI virtual disk technology | |
CN103875229A (en) | Asynchronous replication method, device and system | |
CN111190547B (en) | Distributed container mirror image storage and distribution system and method | |
CN111241094B (en) | Database deleted column synchronization method and device based on log analysis | |
CN102664950B (en) | Data communication method between welding power sources and computers | |
CN113254425B (en) | Method, apparatus, system, program and storage medium for database transaction retention | |
CN104468641B (en) | A kind of business datum moving method, device and cloud storage system | |
US9489392B2 (en) | High availability data replication | |
KR101424568B1 (en) | Client and database server for resumable transaction and method thereof | |
CN111221907A (en) | Database added column synchronization method and device based on log analysis | |
CN102982033A (en) | Small documents storage method and system thereof | |
CN111917588A (en) | Edge device management method, device, edge gateway device and storage medium | |
EP3405871A1 (en) | Versioned records management using restart era | |
CN111221909B (en) | Database modification column synchronization method and device based on log analysis |
Legal Events
Date | Code | Title | Description |
---|---|---|---|
PB01 | Publication | ||
PB01 | Publication | ||
SE01 | Entry into force of request for substantive examination | ||
SE01 | Entry into force of request for substantive examination | ||
TA01 | Transfer of patent application right |
Effective date of registration: 20191126 Address after: 215100 No. 1 Guanpu Road, Guoxiang Street, Wuzhong Economic Development Zone, Suzhou City, Jiangsu Province Applicant after: Suzhou Wave Intelligent Technology Co., Ltd. Address before: 450000 Henan province Zheng Dong New District of Zhengzhou City Xinyi Road No. 278 16 floor room 1601 Applicant before: Zhengzhou Yunhai Information Technology Co. Ltd. |
|
TA01 | Transfer of patent application right | ||
GR01 | Patent grant | ||
GR01 | Patent grant |