I'm having a similar problem. I receive a 4096 error when adding a VHD through add-vmdisk
$vm = New-VM -name “MyPC”
Set-VMMemory -vm $vm -memory 512MB
Set-VMCPUCount -vm $vm -CPUCount 1
Add-VMDrive $vm 0 0
Add-VMDisk $VM 0 0 $ "C:\MyPC.vhd"
Failed to add disk to 'MyPC', result code: 4096.
I've tried with different paths, existing and non-existing.
The add-vmdrive succeeds, but add-vmdisk fails and I'm left with an empty drive without file associated.
I've tried with clean machines, manually and with different ways of expressing the VHD path, and they all fail with the same error. I'm doing this on Windows Server 2008 R2, which could mean that there's some incompatibility. Has anyone tried adding disks
with pshyperv on an R2 host?