What is the recommended procedure to upgrade the toolkit to 1.3?
I just tried ro replace the files in C:\Windows\system32\WindowsPowerShell\v1.0\Modules\DataONTAP
When I then try to run "Import-Module DataONTAP" again, I get this Error Message:
Import-Module : The following error occurred while loading the extended type data file: Microsoft.PowerShell, C:\Windows\system32\WindowsPowerShell\v1.0\Modules\DataONTAP\DataONTAP.Type.ps1xml : File skipped because it was already present from "Microsoft.PowerShell". At line:1 char:14 + Import-Module <<<< DataONTAP + CategoryInfo : InvalidOperation: (:) [Import-Module], RuntimeException + FullyQualifiedErrorId : FormatXmlUpateException,Microsoft.PowerShell.Commands.ImportModuleCommand
Have you exited & restarted powershell? Powershell doesn't support fully unloading binary modules so you will need to completely exit the process and start it back up.
Also you may want to check that you do not have a copy of DataONTAP in both "C:\Users\<username>\Documents\WindowsPowerShell\Modules" and "C:\windows\system32\WindowsPowerShell\v1.0\Modules". It should only be in one or the other.
Thanks, Eric. Although installing PowerShell v2 modules merely requires copying files, I tend to use the trivial install & uninstall scripts we offer alongside the Toolkit.
To use them for an upgrade, download the zip file and the two scripts into the same directory. Then close all PowerShell instances that may already have the Toolkit loaded, open a new PowerShell instance with administrative privileges, and do this:
PS C:\> .\Uninstall.ps1
Before continuing, please close all PowerShell instances that have the DataONTAP module loaded.
Remove directory C:\Windows\system32\WindowsPowerShell\v1.0\Modules\\DataONTAP (y/n)? [y]: y
PS C:\> .\Install.ps1 Install to directory C:\Users\Administrator.RTPRRE\Documents\WindowsPowerShell\Modules (y/n)? [y]: n Install to directory C:\Windows\system32\WindowsPowerShell\v1.0\Modules\ (y/n)? [y]: y
That's it! Eric has some ideas for improving the scripts, but we aim to keep it very simple.
To reproduce this issue, I installed a fresh copy of Windows Server 2008 R2 on a VM. Sure enough, the 1.2 Toolkit loads fine but the 1.3 Toolkit throws the reported error. To resolve the issue, add the .NET Framework 3.5.1 feature and restart PowerShell.