Fail to retried the package list on distribution point

X


2 Comments

  • Michael

    02-09-2021 09:47 am

    I receive an error when executing this : $PksinContentLibButNotWMI Get-ChildItem : Cannot find path '\\MYSERVER.domain.com\D$\SCCMContentLib\PkgLib' because it does not exist. At line:13 char:16 + $PkgLibList = (Get-ChildItem $PkgLibPath | Select -ExpandProperty Nam ... + ~~~~~~~~~~~~~~~~~~~~~~~~~ + CategoryInfo : ObjectNotFound: (\\MYSERVER.d...ntentLib\PkgLib:String) [Get-ChildItem], ItemNotFoundException + FullyQualifiedErrorId : PathNotFound,Microsoft.PowerShell.Commands.GetChildItemCommand Compare-Object : Cannot bind argument to parameter 'DifferenceObject' because it is null. At line:17 char:91 + ... ct -ReferenceObject $WMIPkgList -DifferenceObject $PKgLibList -PassTh ... + ~~~~~~~~~~~ + CategoryInfo : InvalidData: (:) [Compare-Object], ParameterBindingValidationException + FullyQualifiedErrorId : ParameterArgumentValidationErrorNullNotAllowed,Microsoft.PowerShell.Commands.CompareObjectCommand Compare-Object : Cannot bind argument to parameter 'DifferenceObject' because it is null. At line:19 char:91 + ... ct -ReferenceObject $WMIPkgList -DifferenceObject $PKgLibList -PassTh ... + ~~~~~~~~~~~ + CategoryInfo : InvalidData: (:) [Compare-Object], ParameterBindingValidationException + FullyQualifiedErrorId : ParameterArgumentValidationErrorNullNotAllowed,Microsoft.PowerShell.Commands.CompareObjectCommand Delete these items from WMI: Delete .INI files of these packages from the PkgLib folder:

  • Andy

    19-08-2022 10:03 am

    There's a typo: packageincontlib should be a plural: PackagesInContLib - packages not package. There are also typos in the variable name but as they're variables it's not too important. Using camelcase would make this easier to read.

Leave a Comment

x
This website is using cookies. More info. That's Fine