Skip to content

Mount manager plugin for Windows #8347

@ambarve

Description

@ambarve

What is the problem you're trying to solve

As described in #8346, a new layering format called CimFS is being developed for Windows containers.

When using these CimFS layers, it is necessary to reuse a mounted volume of a CIM instead of mounting the same CIM multiple times to different volumes. Reusing the volume provides better performance. However, if the shim processes mount the container layers (i.e. mounts the CIM) during container startup, there is no way for one shim process to know if the same CIM is already mounted by some other process or not. Similarly, during cleanup the shim processes cannot decide if the CIM should be unmounted or not.

Describe the solution you'd like

To handle this, we propose adding a new "mount manager plugin" (for windows) to containerd. This plugin will expose a TTRPC API for mounting & unmounting of layers on Windows. The plugin can take care of ref counting the mounted CIM volumes and unmounting the CIMs when all containers using it have stopped. Shim processes will then call this TTRPC API to mount container rootfs instead of doing the mounts themselves.

This plugin might even be extended to solve some other issues with mounting/unmounting of legacy layers. For example, currently with legacy layers there is no easy way to unmount a layer given the target at which it is mounted. A plugin like mount manager can keep track of the layers and their mount targets and correctly handle the unmounting of such layers.

Additional context

No response

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions