Question : Script adding / removing SCSI passthrough drive in Hyper-V R2

Can someone help me with a script (so I can schedule it) to make Hyper-V R2 add / remove a drive attached to a Hyper-V host (assume it is offline in the host) to an existing VM (whish has an existing virtual SCSI controller) in Windows 2008 R2?

Of course the other part to take the drive offline in the host OS would also be helpful.





Answer : Script adding / removing SCSI passthrough drive in Hyper-V R2

James O' Neill Hyper-V module for powershell be of use to you.
http://pshyperv.codeplex.com/
http://pshyperv.codeplex.com/releases/view/38769

HyperV_Install.zip is the actual module, you will need to install
PShyperv-R2.pdf is the documentation with examples on how to use it.

See if that helps you.
Regards,
Shahid
Random Solutions  
 
programming4us programming4us