Recently trying to find a way to backup the virtual machines in Hyper-V, because the normal backup is to manually shut down the VM, then export, so waste a lot of time, and then toss, want to use the command to automate the implementation of the VM backup.
Check out the information, see an open source software can use this PowerShell Management Library command to complete most of the virtual machine management operations, here to share this site:
http://pshyperv.codeplex.com/
However, the following error occurred while import of this module:
Import-module:there were errors in loading the format data file:
Microsoft.PowerShell, C:\Program Files\modules\hyperv\hyperv.
Format.ps1xml:File skipped because of the following validation
Exception:file C:\Program Files\modules\hyperv\hyperv. Format.
Ps1xml cannot be loaded. The file C:\Program Files\modules\hyperv
\hyperv. Format.ps1xml is not digitally signed. The script would not
Execute on the system. Please "Get-help about_signing"
For more details ...
At Line:1 char:14
+ import-module <<<< ' C:\Program files\modules\hyperv '
+ categoryinfo:invalidoperation: (:) [Import-module],
RuntimeException + fullyqualifiederrorid:formatxmlupate
Exception,microsoft.powershell.commands.importmodule
Command
This is the default security setting for PowerShell the Execute script is disabled, and you need to have administrator privileges to enable this feature. , change to unrestricted with the following command:
Set-executionpolicy Unrestricted
Then imort-module the "Hyperv Library path" and enter the following command:
Get-command-module Hyperv, the help instruction for this command appears under the PowerShell command line
More Wonderful content: http://www.bianceng.cnhttp://www.bianceng.cn/OS/server/