-
Notifications
You must be signed in to change notification settings - Fork 264
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
Support for storage space data disks #998
Conversation
internal/hcsoci/hcsdoc_wcow.go
Outdated
@@ -63,18 +61,26 @@ func createMountsConfig(ctx context.Context, coi *createOptionsInternal) (*mount | |||
return nil, fmt.Errorf("failed to eval symlinks for mount source %q: %s", mount.Source, err) | |||
} | |||
mdv2.HostPath = src | |||
} else if mount.Type == "virtual-disk" || mount.Type == "physical-disk" || mount.Type == "ExtensibleVirtualDisk" { | |||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Is it ok to eliminate the existing behavior of always checking a vSMB mount first regardless of mount.Type?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think so. We currently have a bug that doesn't allow using the same host path as both scsi and vsmb mount because of this.
I think it would be more useful long-term if we can just make this feature be generic EVD support. e.g. instead of |
@kevpar I like the idea of not having to make any other changes to support other types of EVDs. I just didn't do this because I didn't know if we wanted to keep the EVD part as an implementation detail. |
5702964
to
3b963d1
Compare
This needs a rebase to grab the schema location changes (sorry 😞) |
@@ -37,9 +37,7 @@ func createMountsConfig(ctx context.Context, coi *createOptionsInternal) (*mount | |||
// TODO: Mapped pipes to add in v2 schema. | |||
var config mountsConfig | |||
for _, mount := range coi.Spec.Mounts { | |||
if mount.Type != "" { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Do we know why this check was here in the first place?
When mounting a VHD at host path `C:\data\test.vhdx` into the container over SCSI and also sharing the same VHD inside the container over VSMB the current code just shares the VHD inside the container for both mounts instead of actually SCSI mounting the VHD for one of the mounts. This change fixes that. Signed-off-by: Amit Barve <ambarve@microsoft.com>
This commit adds support in hcsshim to mount a virtual disk backed by storage spaces as a
data disk into a container. In container config the
host_path
in the mount entryshould use the format
space://{storage_space_pool_guid}{storage_space_disk_guid}
tospecify a storage space virtual disk.
Signed-off-by: Amit Barve ambarve@microsoft.com