-
Notifications
You must be signed in to change notification settings - Fork 524
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
provide settings for managing ephemeral disks #1209
Comments
Here's one potential approach, where we would extend
On an EC2 instance with two ephemerals, this would create the following paths:
The index path would be a symlink to the UUID path. It would maintain a local mapping of the device index to the random UUID; that means some level of locking to ensure the index was only assigned once, but otherwise the paths wouldn't be predictable enough to be used by other applications. I'd thought about encoding the index in the partition label or UUID somehow, but we want to support the case where a disk is moved between systems, where the index might already be in use. The mapping could just be the symlink in the This assumes that all the ephemeral disks are interchangeable - same size, same device type. When we run into the case of heterogenous disks, we could extend the model with Originally I'd thought to extend the proposal in #1208 to allow different host paths to be specified, and different security options to be applied to the directory, but I'm not sure it's worth it because of how it complicates the next feature. The other piece of this is configuring the container runtime storage.
If
If
We'd need a new helper in Regarding the host paths note, there are two problems. If the SELinux label for the directory is changed, we might not follow the file transition rules we rely on to protect the cache layers. And if the location is changed, then we might inadvertently bypass filtering done at a higher level, such as pod security policies. |
This also could be extended to support persistent disks, such as EBS volumes, by replacing "ephemeral" with "persistent" in the above. The key question is whether that would be sufficiently flexible to use with platforms where CSI is not currently supported, such as ECS. |
For completeness: container storage should also influence the
For the use-case where a path is specified in the ECS task definition, I think this plus #1208 is a good starting point. |
Just checking in - is this on the roadmap for completion? |
Yes it is; @arnaldo2792 is planning to pick this up after #1208. |
With #1601, we added the ability to partition, format and mount ephemeral disks using bootstrap containers. #1618 is a github discussion that shows an example on how to partition, format and mount an ephemeral disk. We still have to work on a mechanism to allow users to change the storage that containerd uses to store persistent data (like container images), this last part will be tracked in #1617. |
What I'd like:
I'd like the ability to opt-in to "managed" ephemeral disks, where the OS handles partitioning, formatting, and mounting the devices. I'd also like to be able to use this storage for the images pulled by the container runtime.
Any alternatives you've considered:
It's possible to handle some of this via orchestrated containers, since ephemerals now show up in
/dev/disk/ephemeral
, but that requires a daemonset or daemon task to handle something that could be done throughcloud-init
elsewhere.However, it's not possible to use this approach to configure storage for container images, since it has to be ready before containers run.
The text was updated successfully, but these errors were encountered: