升级到WMF 5.0后,DSC似乎在安装基于自定义类的资源模块时出现问题。
PS C:\Users\alexis.coles.adm> Start-DscConfiguration -ComputerName ComputerName -Credential $autoCred -Path E:\DevResetRuntime\Mofs -Wait -Verbose -Force
VERBOSE: Perform operation 'Invoke CimMethod' with following parameters, ''methodName' = SendConfigurationApply,'className' = MSFT_DSCLocalConfigurationManager,'namespaceName' = root/Micr
osoft/Windows/DesiredStateConfiguration'.
VERBOSE: An LCM method call arrived from computer ComputerName with user sid S-1-5-21-xxxxxxxxx-3810362189-311025990-3170.
VERBOSE: [ComputerName]: LCM: [ Start Set ]
VERBOSE: [ComputerName]: [DSCEngine] Module SxDeployment_1.11.zip downloaded.
VERBOSE: [ComputerName]: [DSCEngine] Resource SxDeployment version 1.11 installed.
VERBOSE: [ComputerName]: LCM: [ End Set ]
The PowerShell DSC resource C:\Program Files\WindowsPowerShell\Modules\SxDeployment\1.11\DscResources\PsPackageProvider does not contain the corresponding MOF file C:\Program
Files\WindowsPowerShell\Modules\SxDeployment\1.11\DscResources\PsPackageProvider\PsPackageProvider.schema.mof. Could not install module dependencies needed by the configuration.
+ CategoryInfo : ObjectNotFound: (root/Microsoft/...gurationManager:String) [], CimException
+ FullyQualifiedErrorId : ProviderSchemaFileNotFound
+ PSComputerName : ComputerName
如果我在尚未升级的盒子上运行它,它安装正常,模块从资源模块管理器下载并提取到正确的位置。
但是,在升级的盒子上运行它只会在C:\ program files \ windowsPowershell \ Modules中创建一个空的SxDeployment文件夹。
如果我将好提取的文件夹从未升级的盒子复制到新盒子,配置运行正常。
有什么想法吗?
更新
我的资源zip文件名为SxDeployment_1.27.zip
它只包含以下2个文件
SxDeployment.psd1
SxDeployment.psm1
我希望将其解压缩到以下文件系统结构中:
Modules
SxDeployment
1.27
SxDeployment.psd1
SxDeployment.psm1
然而我得到的只是
Modules
SxDeployment