IP Library › Granted Patent US 9,852,137
Granted Patent B2
US 9,852,137 · App. 14/862,786 · Granted Dec 26, 2017

Container storage migration

Inventors: Vijay Mann (Bangalore, IN); Shripad J. Nadgowda (Bangalore, IN)
Assignee: International Business Machines Corporation
G06F17/30079G06F3/065G06F3/0619G06F3/0647G06F3/0665G06F3/0685G06F3/0604G06F3/067G06F3/0629
View Patent ↗
Loading inventors, assignments & file history…
Monitor This Case
Get email alerts when status or documents change.
Order Certified Copies
Most orders are placed with the USPTO same day — all within 24 business hours.
Order via The Patent Place →
Pre-filled with this patent's details
Quick Facts
Patent No.
US 9,852,137
App. No.
14/862,786
Granted
Dec 26, 2017
Kind
B2
Abstract

Methods, systems, and computer program products for container storage migration are provided herein. A computer-implemented method includes provisioning a copy-on-write union filesystem on the target host with (i) one or more network filesystem-mounted directories from the source host set to read-only and (ii) at least one directory set to read-write; identifying one or more files that have been (i) updated by a given container and (ii) copied over by the copy-on-write union filesystem; removing the one or more identified files from a directory path on the target host; copying, from the source host into the directory path on the target host, each of one or more files that have not been updated by the given container; merging the copy-on-write union filesystem and the directory path on the target host; and initiating the given container on the target host based on the merging.

Claims (53)

1. A computer-implemented method for migrating a container from a source host to a target host, comprising:

provisioning a copy-on-write union filesystem on the target host with (i) one or more network filesystem-mounted directories from the source host set to read-only and (ii) at least one directory set to read-write;

identifying one or more files that have been (i) updated by a given container and (ii) copied over by the copy-on-write union filesystem;

removing the one or more identified files from a directory path on the target host;

copying, from the source host into the directory path on the target host, each of one or more files that have not been updated by the given container;

merging the copy-on-write union filesystem and the directory path on the target host; and

initiating the given container on the target host based on said merging;

wherein said steps are carried out by at least one computing device.

2. The computer-implemented method of claim 1 , wherein said copying is performed as a background operation.

3. The computer-implemented method of claim 1 , comprising:

exporting at least one root filesystem directory from the source host to the target host.

4. The computer-implemented method of claim 1 , comprising:

exporting at least one data volume directory from the source host to the target host.

5. The computer-implemented method of claim 1 , comprising:

creating a directory to receive one or more write operations from the source host.

6. The computer-implemented method of claim 5 , comprising:

mounting the one or more write operations that are exported over a network filesystem on the source host into the created directory.

7. The computer-implemented method of claim 1 , wherein said provisioning comprises using an advanced multi-layered unification filesystem.

8. The computer-implemented method of claim 1 , wherein said identifying comprises using a filesystem monitoring tool.

9. The computer-implemented method of claim 1 , wherein said given container comprises a new container launched prior to said identifying.

10. The computer-implemented method of claim 1 , wherein said given container comprises a container derived from the source host that is restarted after migration from the source host.

11. The computer-implemented method of claim 10 , wherein the container derived from the source host includes the copy-on-write union filesystem as data volume.

12. The computer-implemented method of claim 1 , wherein said removing is carried out by a replicator module.

13. The computer-implemented method of claim 1 , wherein said copying is carried out by a replicator module.

14. A computer program product for migrating a container from a source host to a target host, the computer program product comprising a computer readable storage medium having program instructions embodied therewith, the program instructions executable by a device to cause the device to:

provision a copy-on-write union filesystem on the target host with (i) one or more network filesystem-mounted directories from the source host set to read-only and (ii) at least one directory set to read-write;

identify one or more files that have been (i) updated by a given container and (ii) copied over by the copy-on-write union filesystem;

remove the one or more identified files from a directory path on the target host;

copy, from the source host into the directory path on the target host, each of one or more files that have not been updated by the given container;

merge the copy-on-write union filesystem and the directory path on the target host; and

initiate the given container on the target host based on said merging.

15. The computer program product of claim 14 , wherein the program instructions executable by a computing device further cause the computing device to:

create a directory to receive one or more write operations from the source host.

16. The computer program product of claim 15 , wherein the program instructions executable by a computing device further cause the computing device to:

mount the one or more write operations that are exported over a network filesystem on the source host into the created directory.

17. The computer program product of claim 14 , wherein said given container comprises a new container launched prior to said identifying and/or a container derived from the source host that is restarted after migration from the source host.

18. A system for migrating a container from a source host to a target host comprising:

a memory; and

at least one processor coupled to the memory and configured for:

provisioning a copy-on-write union filesystem on the target host with (i) one or more network filesystem-mounted directories from the source host set to read-only and (ii) at least one directory set to read-write;

identifying one or more files that have been (i) updated by a given container and (ii) copied over by the copy-on-write union filesystem;

removing the one or more identified files from a directory path on the target host;

copying, from the source host into the directory path on the target host, each of one or more files that have not been updated by the given container;

merging the copy-on-write union filesystem and the directory path on the target host; and

initiating the given container on the target host based on said merging.

19. A computer-implemented method, comprising:

creating a write-able directory on a local filesystem;

mounting the write-able directory with a network filesystem directory exported from a host source, wherein the network filesystem directory is mounted as read-only;

creating a layered filesystem on a container, wherein the layered filesystem comprises (i) a single layer that is write-able and (ii) one or more additional layers that are each read-only;

establishing a symbolic link on the single layer that is write-able in the layered filesystem to the mounted network filesystem directory; and

instantiating the container based on said symbolic link;

wherein said steps are carried out by at least one computing device.

20. The computer-implemented method of claim 19 , wherein the network filesystem directory exported from the host source comprises a single layer that is writeable in a layered filesystem on a container in the host source.

Assignments (1)
ASSIGNMENT OF ASSIGNOR'S INTEREST Recorded Sep 23, 2015
From: MANN, VIJAY; NADGOWDA, SHRIPAD J.
To: INTERNATIONAL BUSINESS MACHINES CORPORATION
Reel/Frame 036636/0923 →
Continuity (1)
Related Publication 20170083541A1 · Mar 23, 2017