Automation

 View Only
  • 1.  PowerCLI to rename a snapshot

    Posted Apr 27, 2014 05:14 AM

    Hi Guys,

    I have a task to query an infrastructure (around 50 folders)  for specific snapshot name and rename it.

    Let's start with a specific folder:

    Folder name = CI133

    Snapshot = InfraNew

    Renamed Snapshot = InfraOld

    Is it a hard script?

    Morris



  • 2.  RE: PowerCLI to rename a snapshot

    Posted Apr 27, 2014 06:43 AM

    It is not a hard script. You can change the snapshot name in a PowerCLI one-liner:


    Get-Folder -Name CI133 | Get-VM | Get-Snapshot -Name InfraNew | Set-Snapshot -Name InfraOld