Is there anyway I can detach the persistant disk from the VM, using powershell or Vmware View CLI.
I tried in many sites and no command for detaching the disks.
Please help.
Thanks,
Vivek
The cmdlet is 'Get-ProfileDisk' and parameter to detach persistent disk is 'detachUdd'.
Doc: View PowerCLI cmdlet Parameters
View API - VMware API Explorer - VMware {code} > Click on 'Service Type' > Type 'Persistentdisk' and you will get all the options.
what will be the script look like.
Get-ProfileDisk - ???
Below cmd will retrieve info about persistent disk that belongs to specific user: Test it for a test account before running directly on production:
Get-ProfileDisk –Username <domain>\<username>
Getting list of detached persistent disks only:
Get-ProfileDisk –Username <domain>\<username> -Status <Detached/InUse/Archiving>
Detaching the PD:
Get-ProfileDisk –Username <domain>\<username> -detachUdd
Get-ProfileDisk –Username <domain>\<username> -detachUdd
As I checked, till this its okay.Get-ProfileDisk –Username <domain>\<username>
but there is no such parameter like -detachUdd.
Could you please reverify
Hi vivekrishna
Try with below.It should work:
Get-ProfileDisk –Username <domain>\<username> -composerTask detachUdd
check attached guide.
Hi, still the same, please find the error below
Get-Profiledisk -Username 'name' -composertask detachUdd