OpticalDiskDriveLetter: If optical drive is not present, the behaviour of the ressource should change if "Ensure" is set to "Absent" #194
Labels
enhancement
The issue is an enhancement request.
in progress
The issue is being actively worked on by someone.
Details of the scenario you tried and the problem that is occurring
Sometimes you get an optical drive in a Vm deployed to Azure and sometimes not. That's why I tkink it may be handy to make sure there's no optical drive through the usage of the 'OpticalDiskDriveLetter' resource.
If the VM does not use an optical drive and the 'Ensure' parameter is set to 'Absent', the resource returns an error, which will also stop the whole DSC configuration run with an error result.
Verbose logs showing the problem
Event viewer:
DscConfigurationLog (Get-AzureRmVMDscExtensionStatus)
Suggested solution to the issue
The solution shoud handle this scenrio in a more error resistant way, e.g. checking the information in the 'Ensure' parameter before firing an exception and thus stop the whole DSC configuration run.
The DSC configuration that is used to reproduce the issue (as detailed as possible)
The operating system the target node is running
OsName : Microsoft Windows Server 2016 Datacenter
OsOperatingSystemSKU : DatacenterServerEdition
OsArchitecture : 64-bit
WindowsBuildLabEx : 14393.2791.amd64fre.rs1_release.190205-1511
OsLanguage : en-US
OsMuiLanguages : {en-US}
Version and build of PowerShell the target node is running
PSVersion 5.1.14393.2791
PSEdition Desktop
PSCompatibleVersions {1.0, 2.0, 3.0, 4.0...}
BuildVersion 10.0.14393.2791
CLRVersion 4.0.30319.42000
WSManStackVersion 3.0
PSRemotingProtocolVersion 2.3
SerializationVersion 1.1.0.1
Version of the DSC module that was used ('dev' if using current dev branch)
Manifest 4.4.0.0 StorageDsc
The text was updated successfully, but these errors were encountered: