dsccommunity / StorageDsc

DSC resource module is used to manage storage on Windows Servers.
https://dsccommunity.org
MIT License
70 stars 51 forks source link

Refresh drives after modifications #156

Closed adhodgson1 closed 6 years ago

adhodgson1 commented 6 years ago

Hi,

A few of us seem to be using the Disk resource to create/format drives, then in another part of the DSC we use cNTFSAccessControl from https://github.com/SNikalaichyk/cNtfsAccessControl to set NTFS permissions.

This always fails the first time if the disk resource has just formatted the drive and we change the NTFS access under the same DSC document. Please see the following issues:

https://github.com/SNikalaichyk/cNtfsAccessControl/issues/3

Another issue with verbose output and a script to work around the issue: https://github.com/SNikalaichyk/cNtfsAccessControl/issues/13

I was wondering if the disk resource needs to refresh the drives in PowerShell once it makes changes to the disks, rather than have a temporary solution which will continue to refresh the drives? This has reportedly caused issues with constant reads on an array (see first issue above).

Thanks. Andrew.

adhodgson1 commented 6 years ago

Sorry this is possibly open in error as I am not seeing the above behaviour on the Disk resource from StorageDSC 5.0.0.0, just on the resources I haven't moved over yet, some of them due to another issue open in this repo.