VMware Cloud Community

PowerCLI of "Reapply VM Storage Policy"


I tried using the code capture function in vCenter when I clicked "Reapply VM Storage Policy", but it showed nothing. I use vVol on Nimble arrays and have increased the number of snapshots in the new vCenter storage policy.

I used PowerCLI with "Set-SpbmEntityConfiguration -StoragePolicy $policy" to reapply the storage policy for VM and disks. For 95% of the VMs they updated and became compliant. About 5% the vCenter task completes and claims success, but the storage policy still reports "out of date" and I see in both vCenter and on the Nimble array that it has not updated with the new storage policy.

I have rerun my script multiple times, but no change for those last 5% of the VMs. When I manually in the vCenter GUI click "Reapply VM Storage Policy" it actually updates successfully, but I have about 100 VMs and don't want to click in the GUI for every one of them...

Any suggestions? Thanks 🙂

0 Kudos
0 Replies