Cannot rename because item name c://Program Files/dummName does not exist

Hello All,

I am installing docker in windows server 2019 using Power shell command.

Below are the command used to install.

1st command:
Install-Module -Name DockerMsftProvider -Repository PSGallery -Force

Found no issue:

2nd Command:
Install-Package -Name docker -ProviderName DockerMsftProvider -Force -RequiredVersion 19.03

getting error:

Install-Package : Cannot rename because item at ‘C:\Program Files\dummyName’ does not exist.
At line:1 char:1

  • Install-Package -Name docker -ProviderName DockerMsftProvider -Force …
  •   + CategoryInfo          : InvalidOperation: (Microsoft.Power....InstallPackage:InstallPackage) [Install-Package], Exception
      + FullyQualifiedErrorId : InvalidOperation,Microsoft.PowerShell.Commands.RenameItemCommand,Microsoft.PowerShell.PackageManagement.Cmdlets.InstallPackage
    
    

Please suggest to fix this issue.

Note: in windows server there is no antivirus is running.