locked
update-MDTDeploymentShare -or- Update-MDTMedia; "System.Management.Automation.CmdletInvocationException: The file cannot be accessed by the system. " RRS feed

  • Question

  • Starting this last week, whenever I try to either update the deployment share or try to update media content, I am receiving an error indicating that I cannot access a file. The name of the file is not given in the logs. Here is a typical log file from an attempt to update the media.

    ---------------------------- Start of Log --------------------------------------

    Starting MDT Media Update
    Opened the media deployment share.
    Folders to be copied to the media deployment share: 7
    Copied: DS001:\Applications
    Copied: DS001:\Operating Systems
    Copied: DS001:\Operating Systems\Server 2016 Trial
    Copied: DS001:\Out-of-Box Drivers
    Copied: DS001:\Packages
    Copied: DS001:\Task Sequences
    Copied: DS001:\Selection Profiles
    Copied: DS001:\Applications with Replace option
    Copied: DS001:\Operating Systems with Replace option
    Copied: DS001:\Operating Systems\Server 2016 Trial with Replace option
    Copied: DS001:\Out-of-Box Drivers with Replace option
    Copied: DS001:\Packages with Replace option
    Copied: DS001:\Task Sequences with Replace option
    Copied: DS001:\Selection Profiles with Replace option
    Copied standard folders.

    System.Management.Automation.CmdletInvocationException: The file cannot be accessed by the system.
     ---> System.IO.IOException: The file cannot be accessed by the system.

       at System.IO.__Error.WinIOError(Int32 errorCode, String maybeFullPath)
       at System.IO.FileStream.Init(String path, FileMode mode, FileAccess access, Int32 rights, Boolean useRights, FileShare share, Int32 bufferSize, FileOptions options, SECURITY_ATTRIBUTES secAttrs, String msgPath, Boolean bFromProxy, Boolean useLongPath, Boolean checkHost)
       at System.IO.FileStream..ctor(String path, FileMode mode, FileAccess access, FileShare share, Int32 bufferSize)
       at Microsoft.BDD.PSSnapIn.Utility.HashFile(String path)
       at Microsoft.BDD.PSSnapIn.Utility.ProcessHashFolder(StringBuilder listOfHashes, SHA256 hash, DirectoryInfo pathInfo)
       at Microsoft.BDD.PSSnapIn.Utility.ProcessHashFolder(StringBuilder listOfHashes, SHA256 hash, DirectoryInfo pathInfo)
       at Microsoft.BDD.PSSnapIn.Utility.HashDirectory(String path)
       at Microsoft.BDD.PSSnapIn.UpdateDeploymentPoint.AddHashes(XmlDocument theDoc, String xpath, String platform)
       at Microsoft.BDD.PSSnapIn.UpdateDeploymentPoint.UpdateBootImage(String template, String platform, String dpPath, Boolean createISO, String isoName)
       at Microsoft.BDD.PSSnapIn.UpdateDeploymentPoint.ProcessRecord()
       at System.Management.Automation.CommandProcessor.ProcessRecord()
       --- End of inner exception stack trace ---
       at System.Management.Automation.Runspaces.PipelineBase.Invoke(IEnumerable input)
       at Microsoft.BDD.Wizards.GenerateMediaProgress.WizardProcessing()
       at Microsoft.BDD.Wizards.WizardProgress.InitiateWizardProcessing()

    ---------------- End of Log --------------------------------------------------

    I have tried in vain to find what file it is looking for.

    I have cleared DISM /Cleanup-MountPoints if it was having a problem mounting WIMs but that hasn't fixed it either.

    The error always happens right after "Copied Standard Folders" 


    From: MDT Forum

    Friday, March 9, 2018 1:15 PM

All replies

  • Are you running your workbench in Administrator mode?
    Tuesday, March 13, 2018 4:16 AM
  • Yes, I am running under an Local Administrator account, and I launch it "Run as Administrator".


    From: MDT Forum

    Tuesday, March 13, 2018 3:26 PM
  • Did you ever figure this out?
    Wednesday, July 15, 2020 9:28 PM