NetApp Community Update
This site will enter Read Only mode on July 23 as we prepare to move to a new platform. You will still be able to view content, but posting and replying will be temporarily disabled.
We're excited to launch our new Community experience on July 30 and more information will follow soon.
Stay connected during the transition - Join our Discord community today.

Microsoft Virtualization Discussions

Send in the Clone(s)

BISHTECHIT
4,403 Views

Hello Script Community -

I am trying to get help with a script -

I am able to produce a report listing existing clones, but am not clear how the

  • Stop-NaClone
  • Clear-NaClone

Will allow me to remove it.

Please provide any assistance or sample scripts if you are able.

Thanks,

peter

2 REPLIES 2

JOHNGARRETT
4,403 Views

Peter,

Better late than never, right? Those cmdlets relate to lun clone operations in progress or failed lun clone operations. Is that what you're after, or are you trying to find volume clones?

If you're after vol clones, you could adapt this to your script:

$volstats = get-NaVol

foreach ($vol in $volstats) {

     if ($vol.CloneChildren -ne $null) {

     write-Host "Volumes with clones:"

     write-Host $vol.CloneChildren

     }

}

I hope that helps.

BISHTECHIT
4,403 Views

Thanks John -

To late never a helpful hand received is [Yoda]

Your script was helpful in allowing me to report on clones attached to Volumes.

Ultimately - after more reading and research - what I need is a better understanding of the clone process.

Which should allow me to know what cmdlets to use to report on the existence of a clone, the status of that clone, and when it is safe to remove that clone if it is not being removed properly by a backup process.

Public