Veeam Backup & Replication PowerShell

Veeam Backup & Replication PowerShell Version 7.0 User Guide November, 2013 Important! © 2013 Veeam Software. All rights reserved. All trademarks a...
19 downloads 6 Views 6MB Size
Veeam Backup & Replication PowerShell Version 7.0 User Guide November, 2013

Important!

© 2013 Veeam Software. All rights reserved. All trademarks are the property of their respective owners. No part of this publication may be reproduced, transmitted, transcribed, stored in a retrieval system, or translated into any language in any form by any means, without written permission from Veeam Software Inc (Veeam). The information contained in this document represents the current view of Veeam on the issue discussed as of the date of publication and is subject to change without notice. Veeam shall not be liable for technical or editorial errors or omissions contained herein. Veeam makes no warranties, express or implied, in this document. Veeam may have patents, patent applications, trademark, copyright, or other intellectual property rights covering the subject matter of this document. All other trademarks mentioned herein are the property of their respective owners. Except as expressly provided in any written license agreement from Veeam, the furnishing of this document does not give you any license to these patents, trademarks, copyrights, or other intellectual property. Please read the End User Software License Agreement before using the accompanying software program(s). Using any part of the software indicates that you accept the terms of the End User Software License Agreement.

2 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

CONTENTS CONTENTS............................................................................................................................................ 3 CONTACTING VEEAM SOFTWARE....................................................................................................... 8 ABOUT THIS GUIDE.............................................................................................................................. 9 GETTING STARTED............................................................................................................................. 10 EXAMPLES OF USE .................................................................................................................................................................13 POWERSHELL REMOTING ......................................................................................................................................................18 INTERACTIVE POWERSHELL HELP .........................................................................................................................................19 VEEAM BACKUP & REPLICATION CMDLETS ..................................................................................... 21 ADD-HP3SNAPSHOT ............................................................................................................................................................35 ADD-HP3STORAGE ..............................................................................................................................................................37 ADD-HP4SNAPSHOT ............................................................................................................................................................39 ADD-HP4STORAGE ..............................................................................................................................................................41 ADD-VBRBACKUPJOB ..........................................................................................................................................................43 ADD-VBRBACKUPREPOSITORY............................................................................................................................................45 ADD-VBRCOPYJOB ..............................................................................................................................................................48 ADD-VBRCREDENTIALS........................................................................................................................................................51 ADD-VBRESX .......................................................................................................................................................................53 ADD-VBRESXI ......................................................................................................................................................................56 ADD-VBRHVBACKUPCOPYJOB ...........................................................................................................................................58 ADD-VBRHVBACKUPJOB.....................................................................................................................................................61 ADD-VBRHVCLUSTER ..........................................................................................................................................................63 ADD-VBRHVHOST................................................................................................................................................................65 ADD-VBRHVJOBOBJECT......................................................................................................................................................67 ADD-VBRHVPROXY..............................................................................................................................................................69 ADD-VBRHVREPLICAJOB.....................................................................................................................................................71 ADD-VBRHVSCVMM ............................................................................................................................................................73 ADD-VBRJOBOBJECT ...........................................................................................................................................................75 ADD-VBRLINUX ....................................................................................................................................................................77 ADD-VBRREPLICAJOB ..........................................................................................................................................................79 ADD-VBRSMBV3CLUSTER...................................................................................................................................................82 ADD-VBRSMBV3HOST ........................................................................................................................................................85 ADD-VBRTAPEFILESJOB ......................................................................................................................................................87 ADD-VBRTAPEMEDIAPOOL ................................................................................................................................................90 ADD-VBRTAPEVMJOB.........................................................................................................................................................92 ADD-VBRVCENTER ...............................................................................................................................................................95 ADD-VBRVCLOUD ................................................................................................................................................................97 ADD-VBRVCLOUDBACKUPCOPYJOB..................................................................................................................................99 ADD-VBRVCLOUDJOB ...................................................................................................................................................... 102 ADD-VBRVCLOUDVC ....................................................................................................................................................... 104 ADD-VBRVIBACKUPCOPYJOB.......................................................................................................................................... 107 ADD-VBRVIBACKUPJOB ................................................................................................................................................... 110 ADD-VBRVIJOBOBJECT .................................................................................................................................................... 112 ADD-VBRVIPROXY ............................................................................................................................................................ 114 ADD-VBRVIREPLICAJOB ................................................................................................................................................... 116

3 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

ADD-VBRWANACCELERATOR ......................................................................................................................................... 119 ADD-VBRWINSERVER ....................................................................................................................................................... 121 ADD-VSBAPPLICATIONGROUP......................................................................................................................................... 123 ADD-VSBHVAPPLICATIONGROUP ................................................................................................................................... 125 ADD-VSBHVJOB ................................................................................................................................................................ 127 ADD-VSBHVVIRTUALLAB ................................................................................................................................................. 130 ADD-VSBJOB ..................................................................................................................................................................... 132 ADD-VSBVIAPPLICATIONGROUP ..................................................................................................................................... 135 ADD-VSBVIRTUALLAB....................................................................................................................................................... 137 CLEAR-VBRWANCACHE .................................................................................................................................................. 139 CONNECT-VSBHVVIRTUALLAB......................................................................................................................................... 141 CONNECT-VSBVIRTUALLAB .............................................................................................................................................. 143 COPY-VBRJOB.................................................................................................................................................................... 145 DISABLE-VBRHVPROXY .................................................................................................................................................... 147 DISABLE-VBRJOB ............................................................................................................................................................... 149 DISABLE-VBRJOBGUESTFSINDEXING .............................................................................................................................. 151 DISABLE-VBRJOBSCHEDULE ............................................................................................................................................. 153 DISABLE-VBRJOBVSSINTEGRATION ................................................................................................................................ 155 DISABLE-VBRVIPROXY ...................................................................................................................................................... 157 EJECT-VBRTAPEDRIVE....................................................................................................................................................... 159 EJECT-VBRTAPEMEDIUM .................................................................................................................................................. 161 ENABLE-VBRHVPROXY ..................................................................................................................................................... 163 ENABLE-VBRJOB ................................................................................................................................................................ 165 ENABLE-VBRJOBGUESTFSINDEXING ............................................................................................................................... 167 ENABLE-VBRJOBSCHEDULE .............................................................................................................................................. 169 ENABLE-VBRJOBVSSINTEGRATION.................................................................................................................................. 171 ENABLE-VBRVIPROXY ....................................................................................................................................................... 173 ERASE-VBRTAPEMEDIUM ................................................................................................................................................. 175 EXPORT-VBRBACKUP ........................................................................................................................................................ 177 EXPORT-VBRCONFIGURATION .......................................................................................................................................... 179 EXPORT-VBRLOGS ............................................................................................................................................................. 180 EXPORT-VBRTAPEMEDIUM .............................................................................................................................................. 183 FIND-VBRDATASTORE ....................................................................................................................................................... 185 FIND-VBRHVENTITY .......................................................................................................................................................... 187 FIND-VBROBJECT .............................................................................................................................................................. 189 FIND-VBRRESOURCEPOOL................................................................................................................................................ 191 FIND-VBRTAPECATALOG .................................................................................................................................................. 192 FIND-VBRTAPECATALOGVERSION ................................................................................................................................... 193 FIND-VBRVCLOUDENTITY ................................................................................................................................................. 195 FIND-VBRVIDATASTORE ................................................................................................................................................... 198 FIND-VBRVIENTITY ............................................................................................................................................................ 200 FIND-VBRVIFOLDER .......................................................................................................................................................... 203 FIND-VBRVIRESOURCEPOOL ............................................................................................................................................ 205 FIND-VSBHVVIRTUALLAB ................................................................................................................................................. 207 FIND-VSBVIRTUALLAB ...................................................................................................................................................... 209 GET-HP3SNAPSHOT .......................................................................................................................................................... 211 GET-HP3STORAGE............................................................................................................................................................. 213

4 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

GET-HP3VOLUME .............................................................................................................................................................. 214 GET-HP4CLUSTER ............................................................................................................................................................. 216 GET-HP4SNAPSHOT .......................................................................................................................................................... 218 GET-HP4STORAGE............................................................................................................................................................. 220 GET-HP4VOLUME .............................................................................................................................................................. 222 GET-VBRBACKUP ............................................................................................................................................................... 224 GET-VBRBACKUPREPOSITORY.......................................................................................................................................... 226 GET-VBRBACKUPSESSION ................................................................................................................................................ 228 GET-VBRCREDENTIALS ...................................................................................................................................................... 230 GET-VBRFILESINRESTOREPOINT ...................................................................................................................................... 231 GET-VBRHVPROXY ............................................................................................................................................................ 233 GET-VBRINSTANTRECOVERY ............................................................................................................................................ 235 GET-VBRJOB ...................................................................................................................................................................... 236 GET-VBRJOBOBJECT ......................................................................................................................................................... 238 GET-VBRJOBOBJECTVSSOPTIONS ................................................................................................................................... 240 GET-VBRJOBOPTIONS ....................................................................................................................................................... 242 GET-VBRJOBPROXY .......................................................................................................................................................... 244 GET-VBRJOBSCHEDULEOPTIONS..................................................................................................................................... 246 GET-VBRJOBVSSOPTIONS ............................................................................................................................................... 248 GET-VBRLOCALHOST ........................................................................................................................................................ 250 GET-VBRREPLICA ............................................................................................................................................................... 251 GET-VBRRESTOREPOINT ................................................................................................................................................... 252 GET-VBRRESTORESESSION ............................................................................................................................................... 254 GET-VBRSERVER ................................................................................................................................................................ 256 GET-VBRTAPEBACKUP ...................................................................................................................................................... 258 GET-VBRTAPEDRIVE.......................................................................................................................................................... 260 GET-VBRTAPEJOB ............................................................................................................................................................. 262 GET-VBRTAPELIBRARY ...................................................................................................................................................... 264 GET-VBRTAPEMEDIAPOOL .............................................................................................................................................. 266 GET-VBRTAPEMEDIUM ..................................................................................................................................................... 268 GET-VBRTASKSESSION...................................................................................................................................................... 271 GET-VBRTOOLKITDOCUMENTATION ............................................................................................................................... 273 GET-VBRVIPROXY ............................................................................................................................................................. 274 GET-VBRWANACCELERATOR .......................................................................................................................................... 276 GET-VSBAPPLICATIONGROUP.......................................................................................................................................... 278 GET-VSBHVVIRTUALLAB .................................................................................................................................................. 280 GET-VSBJOB ...................................................................................................................................................................... 282 GET-VSBJOBOPTIONS ....................................................................................................................................................... 284 GET-VSBJOBSCHEDULEOPTIONS ..................................................................................................................................... 286 GET-VSBSESSION ............................................................................................................................................................... 288 GET-VSBTASKSESSION ...................................................................................................................................................... 290 GET-VSBVIRTUALLAB ........................................................................................................................................................ 292 IMPORT-VBRBACKUP......................................................................................................................................................... 294 IMPORT-VBRCONFIGURATION .......................................................................................................................................... 296 IMPORT-VBRTAPEMEDIUM ............................................................................................................................................... 298 MOVE-VBRTAPEMEDIUM ................................................................................................................................................. 300 NEW-VBRJOBOPTIONS ..................................................................................................................................................... 302

5 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

NEW-VBRJOBSCHEDULEOPTIONS ................................................................................................................................... 304 NEW-VBRJOBVSSOPTIONS............................................................................................................................................... 305 NEW-VBRVCLOUDVAPPRESTORESETTINGS ................................................................................................................... 307 NEW-VSBJOBOPTIONS ..................................................................................................................................................... 310 REMOVE-HP3SNAPSHOT .................................................................................................................................................. 312 REMOVE-HP3STORAGE ..................................................................................................................................................... 314 REMOVE-HP4SNAPSHOT .................................................................................................................................................. 316 REMOVE-HP4STORAGE ..................................................................................................................................................... 318 REMOVE-VBRBACKUP ....................................................................................................................................................... 320 REMOVE-VBRBACKUPREPOSITORY .................................................................................................................................. 322 REMOVE-VBRBACKUPSESSION ......................................................................................................................................... 324 REMOVE-VBRCREDENTIALS .............................................................................................................................................. 326 REMOVE-VBRHVPROXY .................................................................................................................................................... 327 REMOVE-VBRJOB ............................................................................................................................................................... 329 REMOVE-VBRJOBOBJECT.................................................................................................................................................. 331 REMOVE-VBRREPLICA ....................................................................................................................................................... 332 REMOVE-VBRRESTOREPOINT ........................................................................................................................................... 334 REMOVE-VBRRESTORESESSION ........................................................................................................................................ 336 REMOVE-VBRSERVER ......................................................................................................................................................... 338 REMOVE-VBRTAPEMEDIAPOOL ....................................................................................................................................... 340 REMOVE-VBRVIPROXY ...................................................................................................................................................... 342 REMOVE-VBRWANACCELERATOR .................................................................................................................................. 344 REMOVE-VSBAPPLICATIONGROUP .................................................................................................................................. 346 REMOVE-VSBHVVIRTUALLAB ........................................................................................................................................... 348 REMOVE-VSBJOB ............................................................................................................................................................... 350 REMOVE-VSBSESSION ....................................................................................................................................................... 352 REMOVE-VSBVIRTUALLAB ................................................................................................................................................ 354 RESET-HVVMCHANGETRACKING ...................................................................................................................................... 356 RESET-VBRJOBOPTIONS ................................................................................................................................................... 358 RESET-VBRJOBSCHEDULEOPTIONS ................................................................................................................................. 360 RESET-VBRJOBVSSOPTIONS ............................................................................................................................................. 362 RESET-VSBJOBOPTIONS.................................................................................................................................................... 364 RESTART-VBRINSTANTRECOVERY..................................................................................................................................... 366 SET-VBRCREDENTIALS....................................................................................................................................................... 368 SET-VBRJOBADVANCEDBACKUPOPTIONS ...................................................................................................................... 370 SET-VBRJOBADVANCEDHVOPTIONS .............................................................................................................................. 374 SET-VBRJOBADVANCEDNOTIFICATIONOPTIONS ........................................................................................................... 376 SET-VBRJOBADVANCEDOPTIONS .................................................................................................................................... 378 SET-VBRJOBADVANCEDSTORAGEOPTIONS .................................................................................................................... 382 SET-VBRJOBADVANCEDVIOPTIONS ................................................................................................................................ 384 SET-VBRJOBOBJECTVSSOPTIONS .................................................................................................................................... 387 SET-VBRJOBOPTIONS ....................................................................................................................................................... 390 SET-VBRJOBPROXY ........................................................................................................................................................... 392 SET-VBRJOBSCHEDULE ..................................................................................................................................................... 395 SET-VBRJOBSCHEDULEOPTIONS ..................................................................................................................................... 399 SET-VBRJOBVSSOPTIONS ................................................................................................................................................. 401 SET-VSBJOBOPTIONS........................................................................................................................................................ 403

6 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

SET-VSBJOBSCHEDULE ..................................................................................................................................................... 405 SET-VSBJOBSCHEDULEOPTIONS...................................................................................................................................... 409 START-VBRHVINSTANTRECOVERY ................................................................................................................................... 411 START-VBRHVINSTANTRECOVERYMIGRATION ............................................................................................................... 414 START-VBRHVREPLICAFAILBACK ..................................................................................................................................... 416 START-VBRHVRESTOREVM .............................................................................................................................................. 418 START-VBRINSTANTRECOVERY......................................................................................................................................... 421 START-VBRJOB .................................................................................................................................................................. 424 START-VBRQUICKMIGRATION .......................................................................................................................................... 426 START-VBRREPLICAFAILOVER .......................................................................................................................................... 429 START-VBRRESTOREVM ................................................................................................................................................... 431 START-VBRRESTOREVMFILES .......................................................................................................................................... 433 START-VBRTAPECATALOG................................................................................................................................................ 435 START-VBRTAPEINVENTORY ............................................................................................................................................. 437 START-VBRTAPERESTORE ................................................................................................................................................. 439 START-VBRTAPERESTOREFILES ........................................................................................................................................ 441 START-VBRVCLOUDINSTANTRECOVERY .......................................................................................................................... 444 START-VBRVCLOUDRESTOREVAPP ................................................................................................................................. 447 START-VBRVCLOUDRESTOREVM ..................................................................................................................................... 450 START-VBRVIREPLICAFAILBACK ....................................................................................................................................... 453 START-VBRVIREPLICAFAILOVER ....................................................................................................................................... 455 START-VBRWINDOWSFILERESTORE................................................................................................................................. 458 START-VBRZIP ................................................................................................................................................................... 460 START-VSBJOB ................................................................................................................................................................... 463 STOP-VBRINSTANTRECOVERY .......................................................................................................................................... 465 STOP-VBRJOB .................................................................................................................................................................... 467 STOP-VBRREPLICAFAILOVER ............................................................................................................................................ 469 STOP-VBRVIREPLICAFAILBACK ........................................................................................................................................ 471 STOP-VBRWINDOWSFILERESTORE .................................................................................................................................. 473 STOP-VSBJOB .................................................................................................................................................................... 474 SYNC-HP3STORAGE .......................................................................................................................................................... 476 SYNC-HP3VOLUME ........................................................................................................................................................... 478 SYNC-HP4STORAGE .......................................................................................................................................................... 480 SYNC-HP4VOLUME ........................................................................................................................................................... 482 SYNC-VBRBACKUPCOPYJOB ............................................................................................................................................ 484 SYNC-VBRBACKUPREPOSITORY ....................................................................................................................................... 486

7 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

CONTACTING VEEAM SOFTWARE At Veeam Software we value the feedback from our customers. It is important not only to help you quickly with your technical issues, but it is our mission to listen to your input, and build products that incorporate your suggestions.

Customer Support Should you have a technical concern, suggestion or question, please visit our Customer Center Portal at cp.veeam.com to open a case, search our knowledge base, reference documentation, manage your license or obtain the latest product release.

Company Contacts For the most up to date information about company contacts and offices location, please visit www.veeam.com/contacts.html.

Online Support If you have any questions about Veeam Backup & Replication, you can use the following resources: •

Full documentation set: www.veeam.com/vmware-esx-backup/resources.html



Community forum at www.veeam.com/forums

8 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

ABOUT THIS GUIDE This reference provides information about Veeam Backup PowerShell extension – a snap-in to Microsoft Windows PowerShell. The document applies to version 6.5 and all subsequent versions until it is replaced with a new edition.

Intended Audience The reference is intended for anyone who wants to use the PowerShell extension in Veeam Backup & Replication. It is primarily aimed at administrators of the virtual environment, consultants, analysts and any other IT professionals who use Veeam Backup PowerShell.

Related Documentation The complete set of Veeam Backup & Replication documentation can be found on the product resources web page at www.veeam.com/vmware-esx-backup/resources.html.

Conventions In order to help you get the most out of this guide, we have used the following formatting conventions, terms and abbreviations in the document: Style Used f Style

Description

Boldface

User interface elements (names of dialog windows, buttons and so on).

Italics

Titles, special terms and general emphasis, file paths, names of files and folders.

Hyperlink

Cross reference links and external hyperlinks

Additionally, important information, notes and tips are provided in the following format: Note

This type of formatting is used for tips, notes and important information the user should pay attention to.

Document Revision History Revision #

Date

Description of Changes

Revision 1

8/15/2013

Initial version of the document for Veeam Backup PowerShell Reference 7.0

Revision 2

8/19/2013

Updated list of cmdlets for tapes

Revision 3

11/10/2013

Added descriptions for managing SMB3 hosts and configuration backup

9 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

GETTING STARTED Veeam Backup & Replication comes with PowerShell extension — a snap-in to Microsoft Windows PowerShell 2.0. Windows PowerShell is a powerful command-line tool that allows administrators to automate some Veeam Backup & Replication activities. Veeam extends functionality of Windows PowerShell 2.0, and now administrators may use PowerShell to automate Veeam backup, replication and copy job creation and editing, VMs restores, replica failover and other operations. Before installing Veeam PowerShell snap-in, make sure that Microsoft Windows PowerShell 2.0 is installed on the Veeam Backup & Replication console. To download Microsoft Windows PowerShell, use the following link: http://support.microsoft.com/kb/968929. To open Veeam PowerShell, select PowerShell in the Veeam Backup & Replication main menu. PowerShell uses cmdlets — simple single-function commands that can be run in the command-line shell. Cmdlets are specialized .NET classes that implement specific actions. Veeam PowerShell provides a set of its own cmdlets which correspond to actions you can perform via Veeam Backup & Replication UI. Please keep in mind that actions performed with PowerShell have the same force as actions performed via Veeam Backup & Replication (for example, if you delete some job with PowerShell scripts, the job will be removed from the Veeam Backup & Replication database, and you will not be able undo changes). Note:

Veeam Support team does not write PowerShell scripts on demand. Working with Veeam PowerShell cmdlets and scripts in many respects depends on your imagination, skills and expertise in Windows PowerShell 2.0. To learn more about Windows PowerShell 2.0 and its basics, use the book by Dr. Tobias Weltner: Microsoft Master-PowerShell. Cmdlets operate with objects which they can accept and return. Every object has properties describing it, and methods that can be performed on it. For example, the Get-VBRJob cmdlet has the following output:

10 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

You can filter and sort results at your discretion using the Where and Sort commands (to learn more about these commands, please refer to Windows PowerShell documentation). PS C:\Administrator> Get-VBRJob | Where {$_.Name -eq "Backup Job 3"} Job Name

Type

State

Last Result Description

Backup Job 3 Hyper-V Backup Stopped Success

Created by...

The result of filtering and sorting can be saved to a variable: PS C:\Administrator> $job = Get-VBRJob | Where {$_.Name -eq "Backup Job 3"} PS C:\Administrator> $job Job Name

Type

State

Last Result Description

Backup Job 3 Hyper-V Backup Stopped Success

Created by...

You can get detailed information about the object: PS C:\Administrator> $job | gm TypeName: Veeam.Backup.Core.CBackupJob Name

MemberType Definition

CanRunByScheduler Delete DisableScheduler EnableScheduler Equals FindInitialRepository FindLastSession FindSourceWanAccelerator FindTargetRepository FindTargetWanAccelerator GetHashCode GetHvOijs GetInitialRepository GetLastResult GetLastState GetObjectsInJob GetOptions GetProxy GetScheduleOptions GetSourceOffHostHvProxies GetSourceViProxies GetSourceWanAccelerator GetTargetHost GetTargetOffhostHvProxies GetTargetProxies GetTargetRepository GetTargetViProxies

Method Method Method Method Method Method Method Method Method Method Method Method Method Method Method Method Method Method Method Method Method Method Method Method Method Method Method

bool ISchedulableJob... void Delete() void DisableScheduler() void EnableScheduler() bool Equals(System... Veeam.Backup.Core... Veeam.Backup.Core... Veeam.Backup.Core... Veeam.Backup.Core... Veeam.Backup.Core... int GetHashCode() Veeam.Backup.Core... Veeam.Backup.Core... Veeam.Backup.Model... Veeam.Backup.Model... Veeam.Backup.Core... Veeam.Backup.Model... System.Collections... Veeam.Backup.Model... Veeam.Backup.Core... Veeam.Backup.Core... Veeam.Backup.Core... Veeam.Backup.Core... Veeam.Backup.Core... System.Collections... Veeam.Backup.Core... Veeam.Backup.Core...

11 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

And call a method or a property of the object, for example, view last session results. Note:

Since Veeam Backup & Replication v5 and v6 use Windows PowerShell 2.0, scripts that you have created with previous versions of Veeam Backup & Replication which used Windows PowerShell 1.0 may not work. Examples of Use PowerShell Remoting Interactive PowerShell Help

12 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Examples of Use In this example, we will review the full VM restore process performed by means of Veeam PowerShell script. To let you get most out of this example, each command will be illustrated by the action from the Veeam Backup & Replication UI that provides the result similar to execution of the PowerShell script. First, we get a list of all available backup jobs with the Get-VBRJob cmdlet: PS C:\Administrator> Get-VBRBackup Job Name

Type

Creation Time

Backup Job 1 Backup Job 2 Backup Job 7

VMware Backup VMware Backup VMware Backup

8/1/2013 4:47:19 AM 8/1/2013 5:00:28 AM 8/6/2013 3:15:13 AM

VM count

The similar action is performed by the Restore wizard in Veeam Backup & Replication:

13 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

1 1 1

Then, we get a list of available restore points, select the last restore point and save it into a variable: PS C:\Administrator> Get-VBRBackup -Name "Backup Job 7" | GetVBRRestorePoint VM Name

Creation Time

Type

Failoved

Backup Job 1 7/23/2013 3:15:43 AM Full Backup Job 2 7/30/2013 3:10:15 AM Increment Backup Job 7 8/6/2013 3:45:52 AM Increment

PS C:\Administrator> $restorepoint = Get-VBRBackup -Name "Backup Job 7" | Get-VBRRestorePoint | Select -Last 1 PS C:\Administrator> $restorepoint VM Name

Creation Time

Type

Failoved

Backup Job 7 8/6/2013 3:45:52 AM Increment

A similar action is performed by the Restore wizard in Veeam Backup & Replication:

To restore a VM to another location, we will need: •

ESX host to which the VM should be restored



Resource pool



Datastore on which the VM will reside

Let's get them and save into variables.

14 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Getting the ESXi host: PS C:\Administrator> $server = Get-VBRServer -Name "esx18.veeam.local" PS C:\Administrator> $server Name

Type Machine Name

Description

esx18.veeam.local ESXi esx18.veeam.local

Getting the resource pool (you need to indicate the host to look for the resource pool on): PS C:\Administrator> $pool = Get-VBRServer -Name "esx18.veeam.local" | Find-VBRViResourcePool -Name "fileservers" PS C:\Administrator> $pool ConnHo : st : Type : Refere : nce : Id : Name Path

Veeam.Backup.Core.CHost ResourcePool resgroup-14867 ebaf51b0-c972-4080-95de-b590aa6cf73b_resgroup-14867 fileservers fileservers

Similar actions are performed in the steps of the Restore wizard in Veeam Backup & Replication: Selecting the host:

15 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

And then selecting the resource pool:

Now, let's perform restore of the VM: PS C:\Administrator> Start-VBRRestoreVM -RestorePoint $restorepoint -Server $server -ResourcePool $pool Restore session Restore started Job 'WinXPx86' is working... Restore Type VM Name RestoreVm

State

End Time

WinXPx86 Stopped 8/6/2013 5:01:18 AM

16 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

You can also view the restore job result in the Veeam Backup & Replication UI:

17 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

PowerShell Remoting Veeam PowerShell supports remote execution of cmdlets and scripts. That is, you can run cmdlets and scripts directly on the Veeam Backup & Replication, or against remote computers. A remote session can be started on one remote computer, or a number of remote computers at a time. To enable PowerShell remoting: 1.

Install the WinRM Service.

2.

Enable PowerShell remoting. Start Windows PowerShell 2.0 as an administrator and type in Enable-PSRemoting

To learn more about PowerShell remoting and its configuration, see: http://blogs.msdn.com/b/powershell/archive/2008/05/10/remoting-with-powershellquickstart.aspx http://www.computerperformance.co.uk/powershell/powershell_remote.htm

18 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Interactive PowerShell Help Veeam PowerShell includes an interactive console-based help for each cmdlet. To get a cmdlet description, you can use the following commands: Get-VBRcommand displays a list of all Veeam PoweShell cmdlets that can be used. PS C:\Administrator> Get-VBRCommand CommandType Name ----------- ----

ModuleName ----------

Cmdlet Cmdlet Cmdlet Cmdlet Cmdlet Cmdlet Cmdlet Cmdlet Cmdlet Cmdlet Cmdlet Cmdlet Cmdlet Cmdlet Cmdlet Cmdlet Cmdlet Cmdlet Cmdlet Cmdlet Cmdlet Cmdlet Cmdlet Cmdlet Cmdlet Cmdlet Cmdlet Cmdlet Cmdlet Cmdlet Cmdlet

VeeamPSSnapIn VeeamPSSnapIn VeeamPSSnapIn VeeamPSSnapIn VeeamPSSnapIn VeeamPSSnapIn VeeamPSSnapIn VeeamPSSnapIn VeeamPSSnapIn VeeamPSSnapIn VeeamPSSnapIn VeeamPSSnapIn VeeamPSSnapIn VeeamPSSnapIn VeeamPSSnapIn VeeamPSSnapIn VeeamPSSnapIn VeeamPSSnapIn VeeamPSSnapIn VeeamPSSnapIn VeeamPSSnapIn VeeamPSSnapIn VeeamPSSnapIn VeeamPSSnapIn VeeamPSSnapIn VeeamPSSnapIn VeeamPSSnapIn VeeamPSSnapIn VeeamPSSnapIn VeeamPSSnapIn VeeamPSSnapIn

Add-VBRBackupJob Add-VBRBackupRepository Add-VBRCopyJob Add-VBRCredentials Add-VBRESX Add-VBRESXi Add-VBRHvBackupCopyJob Add-VBRHvBackupJob Add-VBRHvCluster Add-VBRHvHost Add-VBRHvJobObject Add-VBRHvProxy Add-VBRHvReplicaJob Add-VBRHvScvmm Add-VBRJobObject Add-VBRLinux Add-VBRReplicaJob Add-VBRSmbV3Cluster Add-VBRSmbV3Host Add-VBRTapeFilesJob Add-VBRTapeMediaPool Add-VBRTapeVMJob Add-VBRvCenter Add-VBRvCloud Add-VBRvCloudBackupCopyJob Add-VBRvCloudJob Add-VBRvCloudVC Add-VBRViBackupCopyJob Add-VBRViBackupJob Add-VBRViJobObject Add-VBRViProxy

19 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Get-Help displays a full description of the specified cmdlet along with its syntax and full parameter description. PS C:\Users\Administrator> Get-Help Get-VBRTaskSession NAME Get-VBRTaskSession SYNOPSIS Returns list of tasks performed during a specified session. SYNTAX Get-VBRTaskSession [-Session] [-Name ] [-WarningAction ] [-WarningVariable ] [] DESCRIPTION This cmdlet returns a list of all tasks performed during the specified session. You can get the tasks for backup, replication and backup copy sessions. Run Get-VSBTaskSession to get the tasks for SureBackup session. RELATED LINKS REMARKS To see the examples, type: "get-help Get-VBRTaskSession examples". For more information, type: "get-help Get-VBRTaskSession detailed". For technical information, type: "get-help Get-VBRTaskSession full".

20 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

VEEAM BACKUP & REPLICATION CMDLETS You can perform the following operations to administrate your backup infrastructure using Veeam PowerShell snap-in: Managing virtualization hosts and clusters Managing proxy servers Managing job assigned proxy servers Managing credentials Managing backup repositories Looking for virtual instances Managing vCloud Managing HP 3PAR StoreServ infrastructure Managing HP LeftHand P4000 or HP StoreVirtual VSA infrastructure Working with tapes Performing SureBackup Copying backups to a secondary location Managing backup files Managing jobs Managing job objects Managing job options Replicating Instant recovery Restoring Managing job sessions Managing restore points Performing VeeamZIP Getting help Exporting logs

21 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Managing virtualization hosts and clusters Add hosts and clusters to your Veeam Backup & Replication management console and administrate them. Operation

VMware

Hyper-V

Add various type hosts ans clusters to Veeam Backup & Replication console: Adds a Linux server

Add-VBRLinux

Add-VBRLinux

Adds a Windows server

Add-VBRWinServer

Add-VBRWinServer

Adds a vCenterServer

Add-VBRvCenter



Adds an ESX host

Add-VBRESX



Adds an ESXi host

Add-VBRESXi



Adds a Hyper-V host



Add-VBRHvHost

Adds a Hyper-V cluster



Add-VBRHvCluster

Adds a Microsoft System Center Virtual Machine Manager server (SCVMM)



Add-VBRHvScvmm

Adds an SMB3 cluster



Add-VBRSmbV3Cluster

Adds an SMB3 host



Add-VBRSmbV3Host

Get and remove hosts from your console: Looks for hosts you manage

Get-VBRServer

Get-VBRServer

Gets the host you are working on

Get-VBRLocalhost

Get-VBRLocalhost

Removes a host

Remove-VBRServer

Remove-VBRServer

Managing proxy servers Create virtual proxy servers in your Veeam Backup & Replication console and administrate them. Operation

VMware

Hyper-V

Creates a new virtual proxy

Add-VBRViProxy

Add-VBRHvProxy

Enables a disabled proxy

Enable-VBRViProxy

Enable-VBRHvProxy

Disables a proxy

Disable-VBRViProxy

Disable-VBRHvProxy

Looks for proxies you manage

Get-VBRViProxy

Get-VBRHvProxy

Removes a proxy

Remove-VBRViProxy

Remove-VBRHvProxy

Managing job assigned proxy servers Look which proxies are assigned to a job and reassign job proxies. Operation

VMware

Hyper-V

Looks for proxies assigned to a job

Get-VBRJobProxy

Get-VBRJobProxy

Reassigns job proxies

Set-VBRJobProxy

Set-VBRJobProxy

22 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Managing credentials Create and manage credentials records in your Veeam Bacup & Replication console. Operation

VMware

Hyper-V

Creates a new credentials record

Add-VBRCredentials

Add-VBRCredentials

Looks for credentials records managed with your console

Get-VBRCredentials

Get-VBRCredentials

Removes a credentials record

Remove-VBRCredentials

Remove-VBRCredentials

Edits a credentials record

Set-VBRCredentials

Set-VBRCredentials

Managing backup repositories Add VMware backup repositories in your Veeam Backup & Replication console and administrate them. Operation

VMware

Hyper-V

Adds a new backup repository

Add-VBRBackupRepository

Add-VBRBackupRepository

Looks for connected backup repositories

Get-VBRBackupRepository

Get-VBRBackupRepository

Removes a backup repository

Remove-VBRBackupRepository

Remove-VBRBackupRepository

Rescans a backup repository

Sync-VBRBackupRepository

Sync-VBRBackupRepository

Looking for virtual instances Look for the virtual objects registered in your virtual infrastructure. Operation

VMware

Hyper-V

Looks for all kinds of virtual objects

Find-VBRViEntity

Find-VBRHvEntity

Looks for datastores

Find-VBRViDatastore



Looks for folders

Find-VBRViFolder



Looks for resource pools

Find-VBRViResourcePool



Managing vCloud Add vCloud Director entities to your Veeam Backup & Replication console and administrate backup and recovery. Operation

VMware

Hyper-V

Add and remove vCloud Director servers: Adds a vCloud Director server

Add-VBRvCloud

Add-VBRvCloud

Adds vCenter Server managed by vCloud Director

Add-VBRvCloudVC

Add-VBRvCloudVC

Removes a vCloud server

Remove-VBRServer

Remove-VBRServer

Look for vCloud infrastructure objects: Looks for any kinds of vCloud

Find-VBRvCloudEntity

23 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Find-VBRvCloudEntity

Operation

VMware

Hyper-V

objects Backup and restore vCloud objects: Creates a vCloud backup job

Add-VBRvCloudJob

Add-VBRvCloudJob

Starts instant recovery of a vCloud VM

Start-VBRvCloudInstantRecovery

Start-VBRvCloudInstantRecovery

Creates an object with a set of restore parameters for a vApp restore (run StartVBRvCloudRestoreVApp to apply)

NewVBRvCloudVAppRestoreSettings

NewVBRvCloudVAppRestoreSettings

Restores vCloud vApp

Start-VBRvCloudRestoreVApp

Start-VBRvCloudRestoreVApp

Restores a vCloud VM

Start-VBRvCloudRestoreVm

Start-VBRvCloudRestoreVm

Managing HP 3PAR StoreServ infrastructure Add HP SAN entities to your Veeam Backup & Replication console and administrate them. Operation

VMware

Hyper-V

Work with SAN snapshots: Creates a SAN snapshot

Add-HP3Snapshot



Looks for created SAN snapshots

Get-HP3Snapshot



Removes a SAN snapshot

Remove-HP3Snapshot



Work with SAN storages: Adds a SAN storage

Add-HP3Storage



Looks for SAN storages

Get-HP3Storage



Removes a SAN storage

Remove-HP3Storage



Rescans a SAN storage

Sync-HP3Storage



Work with SAN volumes: Looks for SAN volumes

Get-HP3Volume



Rescans a SAN volume

Sync-HP3Volume



Managing HP LeftHand P4000 or HP StoreVirtual VSA infrastructure Add HP SAN entities to your Veeam Backup & Replication console and administrate them. Operation

VMware

Hyper-V

Work with SAN snapshots: Creates a SAN snapshot

Add-HP4Snapshot



Looks for created SAN snapshots

Get-HP4Snapshot



Removes a SAN snapshot

Remove-HP4Snapshot



24 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Operation

VMware

Hyper-V

Work with SAN storages: Adds a SAN storage

Add-HP4Storage



Looks for SAN storages

Get-HP4Storage



Removes a SAN storage

Remove-HP4Storage



Rescans a SAN storage

Sync-HP4Storage



Look for SAN clusters: Looks for SAN clusters

Get-HP4Cluster Work with SAN volumes:

Looks for SAN volumes

Get-HP4Volume



Rescans a SAN volume

Sync-HP4Volume



Working with tapes Connect physical tape libraries to your Veeam Backup & Replication console and administrate tape backup and restore by means of your console. Operation

VMware

Hyper-V

Manage your tape infrastructure: Looks for tape libraries you manage

Get-VBRTapeLibrary

Get-VBRTapeLibrary

Creates a new tape media pool

Add-VBRTapeMediaPool

Add-VBRTapeMediaPool

Looks for media pools you manage

Get-VBRTapeMediaPool

Get-VBRTapeMediaPool

Removes a media pool

Remove-VBRTapeMediaPool

Remove-VBRTapeMediaPool

Work with tapes: Looks for tapes you manage

Get-VBRTapeMedium

Get-VBRTapeMedium

Adds new tapes to tape libraries

Import-VBRTapeMedium

Import-VBRTapeMedium

Moves tapes to another media pool

Move-VBRTapeMedium

Move-VBRTapeMedium

Ejects a tape from a drive

Eject-VBRTapeMedium

Eject-VBRTapeMedium

Erases a tape

Erase-VBRTapeMedium

Erase-VBRTapeMedium

Takes tapes out of a library

Export-VBRTapeMedium

Export-VBRTapeMedium

Work with drives: Looks for drives in libraries

Get-VBRTapeDrive

Get-VBRTapeDrive

Ejects a tape from a specific drive

Eject-VBRTapeDrive

Eject-VBRTapeDrive

25 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Operation

VMware

Hyper-V

Look for backup files: Looks for backup files archived to tapes

Get-VBRTapeBackup

Get-VBRTapeBackup

Inventory your tape archive: Indexes a library or a tape

Start-VBRTapeCatalog

Start-VBRTapeCatalog

Inventories a library or a tape

Start-VBRTapeInventory

Start-VBRTapeInventory

Looks for files archived to tapes

Find-VBRTapeCatalog

Find-VBRTapeCatalog

Looks for versions (restore points) of files archived to tapes

Find-VBRTapeCatalogVersion

Find-VBRTapeCatalogVersion

Backup to tape and restore from tape: Copies VM backups to tape

Add-VBRTapeVMJob

Add-VBRTapeVMJob

Copies files to tape

Add-VBRTapeFilesJob

Add-VBRTapeFilesJob

Looks for created tape jobs

Get-VBRTapeJob

Get-VBRTapeJob

Restores VMs from tape

Start-VBRTapeRestore

Start-VBRTapeRestore

Restores files from tape

Start-VBRTapeRestoreFiles

Start-VBRTapeRestoreFiles

Performing SureBackup Create SureBackup environment to verify backups for recoverability. Operation

VMware

Hyper-V

Create SureBackup jobs: Creates a SureBackup job

Add-VSBJob

Add-VSBHvJob

Work with virtual labs: Creates a new virtual lab

Add-VSBVirtualLab

Add-VSBHvVirtualLab

Looks for virtual labs you manage

Get-VSBVirtualLab

Get-VSBHvVirtualLab

Find-VSBVirtualLab

Find-VSBHvVirtualLab

(run Connect-VSBVirtualLab to add them)

(run Connect-VSBHvVirtualLab to add them)

Adds an existing virtual lab to your console

Connect-VSBVirtualLab

Connect-VSBHvVirtualLab

Removes a virtual lab

Remove-VSBVirtualLab

Remove-VSBHvVirtualLab

Looks for virtual labs not connected to your console

Work with application groups: Creates a new application group

Add-VSBViApplicationGroup

Add-VSBHvApplicationGroup

Looks for application groups you manage

Get-VSBApplicationGroup

Get-VSBApplicationGroup

Removes an application

Remove-VSBApplicationGroup

Remove-VSBApplicationGroup

26 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Operation

VMware

Hyper-V

group Work with SureBackup jobs: Looks for created SureBackup jobs

Get-VSBJob

Get-VSBJob

Starts an existing SureBackup job

Start-VSBJob

Start-VSBJob

Stops a running SureBackup job

Stop-VSBJob

Stop-VSBJob

Removes a SureBackup job

Stop-VSBJob

Stop-VSBJob

Set options to SureBackup jobs: Looks for settings of a specific SureBackup job

Get-VSBJobOptions

Get-VSBJobOptions

Looks for schedule settings of a specific SureBackup job

Get-VSBJobScheduleOptions

Get-VSBJobScheduleOptions

Creates an object with a set of SureBackup job setting (run Set-VSBJobOptions to apply)

New-VSBJobOptions

New-VSBJobOptions

Edits setting of a specific SureBackup job

Set-VSBJobOptions

Set-VSBJobOptions

Sets default settings to a selected SureBackup job

Reset-VSBJobOptions

Reset-VSBJobOptions

Sets schedule to a selected SureBackup job

Set-VSBJobSchedule

Set-VSBJobSchedule

Edits schedule options of a specific SureBackup job

Set-VSBJobScheduleOptions

Set-VSBJobScheduleOptions

Manage SureBackup sessions: Looks for SureBackup job sesions

Get-VSBSession

Get-VSBSession

Looks for tasks performed during a specific SureBackup job session

Get-VSBTaskSession

Get-VSBTaskSession

Removes a selected SureBackup job session

Remove-VSBSession

Remove-VSBSession

Copying backups to a secondary location Copy backup files to secondary hosts using WAN acceleration technology. Operation

VMware

Hyper-V

Manage backup copy jobs: Copies VM backup files to a secondary repository

Add-VBRViBackupCopyJob

Add-VBRHvBackupCopyJob

Copies vCloud VM backup files to a secondary

Add-VBRvCloudBackupCopyJob

Add-VBRvCloudBackupCopyJob

27 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Operation

VMware

Hyper-V

repository Synchronizes source and target repository

Sync-VBRBackupCopyJob

Sync-VBRBackupCopyJob

Manage WAN accelerators: Creates a WAN accelerator

Add-VBRWANAccelerator

Add-VBRWANAccelerator

Looks for existing WAN accelerators

Get-VBRWANAccelerator

Get-VBRWANAccelerator

Removes a WAN accelerator

Remove-VBRWANAccelerator

Remove-VBRWANAccelerator

Managing backup files Import, export or remove backups. Operation

VMware

Hyper-V

Imports backup files to Veeam Backup & Replication

Import-VBRBackup

Import-VBRBackup

Exports backup files to a used-defined destination

Export-VBRBackup

Export-VBRBackup

Looks for created backup files

Get-VBRBackup

Get-VBRBackup

Removes backup files

Remove-VBRBackup

Remove-VBRBackup

Managing jobs Create, clone and administrate Veeam jobs. Operations

VMware

Hyper-V

Create backup, copy, replica, tape or SureBackup jobs: Copies a selected VM to another location

Add-VBRCopyJob

Add-VBRCopyJob

Copies vCloud VM backup files to a secondary repository

Add-VBRvCloudBackupCopyJob

Add-VBRvCloudBackupCopyJob

Creates a VM backup job

Add-VBRViBackupJob

Add-VBRHvBackupJob

Copies VM backup files to a secondary repository

Add-VBRViBackupCopyJob

Add-VBRHvBackupCopyJob

Creates a SureBackup job

Add-VSBJob

Add-VSBHvJob

Creates a replica job

Add-VBRViReplicaJob

Add-VBRHvReplicaJob

Clears change tracking data



Reset-HvVmChangeTracking

Copies files to tape

Add-VBRTapeFilesJob

Add-VBRTapeFilesJob

Copies VM backups to tape

Add-VBRTapeVMJob

Add-VBRTapeVMJob

Backs up vCloud VMs

Add-VBRvCloudJob

Add-VBRvCloudJob

Creates a VeeamZIP backup

Start-VBRZip

Start-VBRZip

28 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Operations

VMware

Hyper-V

Work with jobs: Clones an existing job

Copy-VBRJob

Copy-VBRJob

Puts a job on temporary hold

Disable-VBRJob

Disable-VBRJob

Enables a disabled job

Enable-VBRJob

Enable-VBRJob

Looks for existing jobs

Get-VBRJob

Get-VBRJob

Looks for existing SureBackup jobs

Get-VSBJob

Get-VSBJob

Starts a created job

Start-VBRJob

Start-VBRJob

Starts a created SureBackup job

Start-VSBJob

Start-VSBJob

Stops a running job

Stop-VBRJob

Stop-VBRJob

Stops a running SureBackup job

Stop-VSBJob

Stop-VSBJob

Removes a job

Remove-VBRJob

Remove-VBRJob

Removes a SureBackup job

Remove-VSBJob

Remove-VSBJob

Managing job objects Edit the jobs you have already created by adding or removing job objects: VMs, VM containers or other virtual instances. Operations

VMware

Hyper-V

Add VMs or other virtual objects to your jobs: Adds VMs or other objects to a created job

Add-VBRViJobObject

Add-VBRHvJobObject

Manage the job objects: Looks for VMs or other objects added to a job

Get-VBRJobObject

Get-VBRJobObject

Removes VMs or other objects from a job

Remove-VBRJobObject

Remove-VBRJobObject

Looks for VSS options set for a specific job object

Get-VBRJobObjectVssOptions

Get-VBRJobObjectVssOptions

Edits VSS options of a specific job object

Set-VBRJobObjectVssOptions

Set-VBRJobObjectVssOptions

Managing job options Edit general options, schedule, VSS settings or advanced options of a selected job. Operations

VMware

Hyper-V

Edit general options of backup, replication or copy jobs: Looks for settings of a selected job

Get-VBRJobOptions

29 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Get-VBRJobOptions

Operations

VMware

Hyper-V

Creates an object containing new job settings (run Set-VBRJobOptions to apply)

New-VBRJobOptions

New-VBRJobOptions

Applies new job settings to a selected job

Set-VBRJobOptions

Set-VBRJobOptions

Sets default settings to a selected job

Reset-VBRJobOptions

Reset-VBRJobOptions

Create and manage job schedule: Creates schedule for a selected job

Set-VBRJobSchedule

Set-VBRJobSchedule

Enables a job schedule (you should have a schedule preset)

Enable-VBRJobSchedule

Enable-VBRJobSchedule

Disables a job schedule (job requires manual run)

Disable-VBRJobSchedule

Disable-VBRJobSchedule

Set and manage job schedule options: Looks for schedule settings of a selected job

Get-VBRJobScheduleOptions

Get-VBRJobScheduleOptions

Creates an object containing new schedule settings (run Set-VBRJobScheduleOptions to apply)

New-VBRJobScheduleOptions

New-VBRJobScheduleOptions

Applies new schedule settings to a selected job

Set-VBRJobScheduleOptions

Set-VBRJobScheduleOptions

Sets default schedule settings to a selected job

Reset-VBRJobScheduleOptions

Reset-VBRJobScheduleOptions

Set and edit VSS (Volume Shadow Services) options of backup, replication or copy jobs: Looks for VSS settings of a selected job

Get-VBRJobVSSOptions

Get-VBRJobVSSOptions

Creates an object containing new VSS settings (run SetVBRJobVssOptions to apply)

New-VBRJobVssOptions

New-VBRJobVssOptions

Applies new VSS settings to a selected job

Set-VBRJobVssOptions

Set-VBRJobVssOptions

Sets default VSS settings to a selected job

Reset-VBRJobVssOptions

Reset-VBRJobVssOptions

Manage job VSS options and guest file system options: Disables guest file system indexing in a selected job

Disable-VBRJobGuestFSIndexing

Disable-VBRJobGuestFSIndexing

Disables VSS settings in a selected job

Disable-VBRJobVSSIntegration

Disable-VBRJobVSSIntegration

Enables guest file system indexing in a selected job

Enable-VBRJobGuestFSIndexing

Enable-VBRJobGuestFSIndexing

30 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Operations Enables VSS settings in a selected job

VMware Enable-VBRJobVSSIntegration

Hyper-V Enable-VBRJobVSSIntegration

Edit general options of SureBackup jobs: Looks for settings of a selected SureBackup job

Get-VSBJobOptions

Get-VSBJobOptions

Creates an object containing new SureBackup job settings (run Set-VSBJobOptions to apply)

New-VSBJobOptions

New-VSBJobOptions

Applies new settings to a selected SureBackup job

Set-VSBJobOptions

Set-VSBJobOptions

Sets default settings to a selected SureBackup job

Reset-VSBJobOptions

Reset-VSBJobOptions

Set advanced options to jobs: Sets special options for a selected job

Set-VBRJobAdvancedViOptions

Set-VBRJobAdvancedHvOptions

Sets advanced backup options for a selected job

SetVBRJobAdvancedBackupOptions

SetVBRJobAdvancedBackupOptions

Sets advanced notification options for a selected job

SetVBRJobAdvancedNotificationOptio ns

SetVBRJobAdvancedNotificationOptio ns

Sets advanced options for a selected job

Set-VBRJobAdvancedOptions

Set-VBRJobAdvancedOptions

Sets advanced storage options for a selected job

SetVBRJobAdvancedStorageOptions

SetVBRJobAdvancedStorageOptions

Replicating Create replication jobs and migrate to replicas in case of production host malfunction. Operations

VMware

Hyper-V

Create replica jobs: Creates a replica job

Add-VBRViReplicaJob

Add-VBRHvReplicaJob

Perform replica failover: Fail over a corrupted VM to its replica

Start-VBRViReplicaFailover

Start-VBRViReplicaFailover

Undoes the replica failover

Stop-VBRReplicaFailover

Stop-VBRReplicaFailover

Perform replica failback: Fails back to the production host

Start-VBRViReplicaFailback

Start-VBRHvReplicaFailback

Undoes the replica failback

Stop-VBRViReplicaFailback

Stop-VBRViReplicaFailback

Manage replicas: Looks for replicated VMs

Get-VBRReplica

31 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Get-VBRReplica

Operations Removes a replicated VM

VMware Remove-VBRReplica

Hyper-V Remove-VBRReplica

Instant recovery Recover VMs instantly from backup files. Operations

VMware

Hyper-V

Starts an instant recovery of a vCloud VM

Start-VBRvCloudInstantRecovery

Start-VBRvCloudInstantRecovery

Instantly recovers a VM from backup

Start-VBRInstantRecovery

Start-VBRHvInstantRecovery

Starts Quick Migration of a VM

Start-VBRQuickMigration



Migrates a recovered VM to the production host



StartVBRHvInstantRecoveryMigration

Restarts a failed instant recovery



Restart-VBRInstantRecovery

Terminates an instant recovery

Stop-VBRInstantRecovery

Stop-VBRInstantRecovery

Looks for instant recovery sessions

Get-VBRInstantRecovery

Get-VBRInstantRecovery

Restoring Restore VMs, vCloud VMs or files from backups or tape archives. Operations

VMware

Hyper-V

Restore virtual objects and files: Restores VM from tape

Start-VBRTapeRestore

Start-VBRTapeRestore

Restores files from tape

Start-VBRTapeRestoreFiles

Start-VBRTapeRestoreFiles

Restores a vCloud Director vApp

Start-VBRvCloudRestoreVApp

Start-VBRvCloudRestoreVApp

NewVBRvCloudVAppRestoreSettings

NewVBRvCloudVAppRestoreSettings

(run Start-VBRvCloudRestoreVApp to apply)

(run Start-VBRvCloudRestoreVApp to apply)

Restores a vCloud VM

Start-VBRvCloudRestoreVm

Start-VBRvCloudRestoreVm

Restores a VM

Start-VBRRestoreVM

Start-VBRHvRestoreVM

Restores VM configuration files

Start-VBRRestoreVMFiles



Recovers guest Windows OS files

Start-VBRWindowsFileRestore



Stops guest Windows OS file recovery session

Stop-VBRWindowsFileRestore



Creates an object with a set of restore parameters for a vApp restore

32 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Operations

VMware

Hyper-V

Work with restore sessions: Looks for restore sessions

Get-VBRRestoreSession

Get-VBRRestoreSession

Removes a restore session

Remove-VBRRestoreSession

Remove-VBRRestoreSession

Managing job sessions Get specific job sessions and look which tasks it contains. Operations

VMware

Hyper-V

Manage backup, replication and backup copy sessions: Looks for VM backup sessions

Get-VBRBackupSession

Get-VBRBackupSession

Looks for tasks performed during a specific session

Get-VBRTaskSession

Get-VBRTaskSession

Removes a backup session

Remove-VBRBackupSession

Remove-VBRBackupSession

Manage restore sessions: Looks for restore sessions

Get-VBRRestoreSession

Get-VBRRestoreSession

Removes a restore session

Remove-VBRRestoreSession

Remove-VBRRestoreSession

Manage SureBackup sessions: Looks for SureBackup sessions

Get-VSBSession

Get-VSBSession

Looks for tasks performed during a specific SureBackup session

Get-VSBTaskSession

Get-VSBTaskSession

Removes a SureBackup session

Remove-VSBSession

Remove-VSBSession

Managing restore points Look for restore points of your virtual instances and manage them. Operations

VMware

Hyper-V

Looks for VM restore points

Get-VBRRestorePoint

Get-VBRRestorePoint

Looks for files in a restore point

Get-VBRFilesInRestorePoint

Get-VBRFilesInRestorePoint

Removes a restore point

Remove-VBRRestorePoint

Remove-VBRRestorePoint

Performing VeeamZIP Create a VM VeeamZIP backup. Operations Creates a VeeamZIP backup

VMware Start-VBRZip

33 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Hyper-V Start-VBRZip

Getting help Open Veeam Backup & Replication help. Operations Opens Veeam Backup & Replication help

VMware Get-VBRToolkitDocumentation

Hyper-V Get-VBRToolkitDocumentation

Exporting logs Collect system logs and submit support tickets. Operations Collects system logs to export

VMware Export-VBRLogs

34 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Hyper-V Export-VBRLogs

Add-HP3Snapshot Short Description Creates a SAN snapshot.

Applies to Version: 7.0 Platform: VMware HP SAN storage system: HP 3PAR StoreServ

Syntax Add-HP3Snapshot -Volume [-Name ][Description ][]

Related Commands Get-HP3Volume

Detailed Description This cmdlet creates a snapshot of the selected HP SAN volume. See what else you can perform on HP 3PAR instances

Parameters Parameter

Description

Required

Position

Accept Pipeline Input

Accept Wildcard Characters

False

Volume

Specifies the SAN volume you want to take snapshot of.

True

Named

True (ByValue, ByProperty Name)

Name

Specifies the name you want to assign to the snapshot.

False

Named

False

False

False

Named

False

False

Specifies the description of the snapshot. Description

If not set, Veeam Backup & Replication will enter date and time of creation by default.

This cmdlet supports Microsoft PowerShell common parameters. For more information about common parameters, see http://go.microsoft.com/fwlink/p/?LinkID=113216.

35 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Example 1 This command creates a snapshot of the "Vol 01" volume. The snapshot is named "vol_SS_01". The target volume object is obtained with Get-HP3Volume and piped down. The description is "Vol 01 snapshot". Get-HP3Volume -Name "Vol 01" | Add-HP3Snapshot -Name "vol_SS_01" -Description "Vol 01 snapshot"

Example 2 This command creates a snapshot of the "Vol 01" volume. The snapshot is named "vol_SS_01". The target volume object is obtained with Get-HP3Volume and assigned to the $volume variable beforehand. The description is "Vol 01 snapshot". Add-HP3Snapshot -Volume $volume -Name "vol_SS_01" -Description "Vol 01 snapshot"

36 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Add-HP3Storage Short Description Adds HP SAN storage to Veeam Backup & Replication.

Applies to Version: 7.0 Platform: VMware HP SAN storage system: HP 3PAR StoreServ

Syntax Add-HP3Storage -UserName -Password [-Name ] [-Description ] [-Url ][] -ORAdd-HP3Storage -Credentials [-Name ] [Description ] [-Url ][]

Related Commands Get-VBRCredentials

Detailed Description This cmdlet adds the selected HP SAN storage to Veeam Backup & Replication. When you add a storage to your management console, Veeam Backup & Replication automatically rescans the storage infrastructure. To rescan the SAN infrastructure manually, run Sync-HP3Storage or Sync-HP3Volume. When adding a SAN storage, you will need to provide either username/password or credentials. This cmdlet provides syntax for both scenarios accordingly. See what else you can perform on HP 3PAR instances

Parameters Parameter

Description

Required

Position

Accept Pipeline Input

Accept Wildcard Characters

False

Named

False

False

False

Named

False

False

Specifies the user name you want to use for authenticating with the SAN storage. UserName

Password

If you use the Username/Password scenario, the -Credentials parameter must be omitted. Specifies the password you want to use for authenticating with the SAN storage. If you use the Username/Password scenario, the -Credentials parameter

37 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Parameter

Description

Required

Position

Accept Pipeline Input

Accept Wildcard Characters

True

Named

False

False

False

Named

False

False

False

Named

False

False

False

Named

False

False

must be omitted. Specifies credentials you want to use for authenticating with the SAN storage. Credentials

Name

If you use the Credentials scenario, the -User and Password parameters must be omitted. Specifies the SAN storage IP address or DNS name. Specifies the description of the SAN storage.

Description

If not set, Veeam Backup & Replication will enter date and time of creation by default. Specifies the HP 3PAR Web Services API URL.

Url

The HP 3PAR Web Services API delivers a programming interface for performing storage management tasks with HP 3PAR StoreServ storage systems.

This cmdlet supports Microsoft PowerShell common parameters. For more information about common parameters, see http://go.microsoft.com/fwlink/p/?LinkID=113216.

Example 1 This command adds a 3PAR storage with IP address 167.16.2.134 specified in the -Name parameter. The username is "Administrator" and the password is "Password". The URL is https://172.18.44.8:8080. Add-HP3Storage -UserName "Administrator" -Password "Password" Name 167.16.2.134 -Description "SAN Storage" -Url https://172.18.44.8:8080

Example 2 This command adds a 3PAR storage with IP address 167.16.2.134 specified in -Name parameter. The credentials object is obtained with Get-VBRCredentials and assigned to the $creds variable beforehand. The URL is https://172.18.44.8:8080. Add-HP3Storage -Credentials $creds -Name 167.16.2.134 Description "HP 3PAR Storage" -Url https://172.18.44.8:8080

38 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Add-HP4Snapshot Short Description Creates a SAN snapshot.

Applies to Version: 7.0 Platform: VMware HP SAN storage systems: HP LeftHand P4000, HP StoreVirtual VSA

Syntax Add-HP4Snapshot -Volume [-Name ] [Description ][-ApplicationManagedShapshot] []

Related Commands Get-HP4Volume

Detailed Description This cmdlet creates a snapshot of the selected HP SAN volume. See what else you can perform on HP LeftHand P4000 or HP StoreVirtual VSA instances

Alias Add-VBRHPSnapshot

Parameters Parameter

Description

Required

Position

Accept Pipeline Input

Accept Wildcard Characters

False

Volume

Specifies the SAN volume you want to take snapshot of.

True

Named

True (ByValue, ByProperty Name)

Name

Specifies the name you want to assign to the snapshot.

False

Named

False

False

False

Named

False

False

False

Named

False

False

Specifies the description of the snapshot. Description

Application Managed Shapshot

If not set, Veeam Backup & Replication will enter date and time of creation by default. Indicates if the VM on the target volume should be quiesced to bring VM data to a consistent state. If omitted, Veeam Backup & Replication will create a

39 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Parameter

Description

Required

Position

Accept Pipeline Input

Accept Wildcard Characters

point-in-time snapshot.

This cmdlet supports Microsoft PowerShell common parameters. For more information about common parameters, see http://go.microsoft.com/fwlink/p/?LinkID=113216.

Example 1 This command creates a snapshot of the "Vol 01" volume. The snapshot is named "vol_SS_01". The target volume object is obtained with Get-HP4Volume and piped down. The application-managed snapshot is enabled. The description is "Vol 01 snapshot". Get-HP4Volume -Name "Vol 01" | Add-HP4Snapshot -Name "vol_SS_01" -ApplicationManagedShapshot -Description "Vol 01 snapshot"

Example 2 This command creates a snapshot of the "Vol 01" volume. The snapshot is named "vol_SS_01". The target volume object is obtained with Get-HP4Volume and assigned to the $volume variable beforehand. The application-managed snapshot is enabled. The description is "Vol 01 snapshot". Add-HP4Snapshot -Volume $volume -Name "vol_SS_01" ApplicationManagedShapshot -Description "Vol 01 snapshot"

40 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Add-HP4Storage Short Description Adds HP SAN storage to Veeam Backup & Replication.

Applies to Version: 7.0 Platform: VMware HP SAN storage systems: HP LeftHand P4000, HP StoreVirtual VSA

Syntax Add-HP4Storage -DnsOrIpAddress -UserName Password [-Name ] [-Description ] [] -ORAdd-HP4Storage -DnsOrIpAddress -Credentials [-Name ] [-Description ] []

Related Commands Get-VBRCredentials

Detailed Description This cmdlet adds the selected HP SAN storage to Veeam Backup & Replication. When you add a storage to your management console, Veeam Backup & Replication automatically rescans the storage infrastructure. To rescan the SAN infrastructure manually, run Sync-HP4Storage or Sync-HP4Volume. When adding a SAN storage, you will need to provide either username/password or credentials. This cmdlet provides syntax for both scenarios accordingly. See what else you can perform on HP LeftHand P4000 or HP StoreVirtual VSA instances

Alias Add-VBRHPStorage

Parameters Parameter

Description

Required

Position

Accept Pipeline Input

Accept Wildcard Characters

False

False

DnsOr IpAddress

Specifies the string with a full DNS name or IP address of the SAN storage.

True

Named

True (ByValue, ByProperty Name)

UserName

Specifies the user name you want to use for authenticating with the SAN storage.

False

Named

False

41 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

If you use the Username/Password scenario, the -Credentials parameter must be omitted.

Password

Name

Credentials

Specifies the password you want to use for authenticating with the SAN storage. If you use the Username/Password scenario, the -Credentials parameter must be omitted. Specifies the name of the management group the storage belongs to. Specifies the credentials you want to use for authenticating with the SAN storage. If you use the Credentials scenario, the -User and Password parameters must be omitted.

False

Named

False

False

False

Named

False

False

True

Named

False

False

False

Named

False

False

Specifies the description of the SAN storage. Description

If not set, Veeam Backup & Replication will enter date and time of creation by default.

This cmdlet supports Microsoft PowerShell common parameters. For more information about common parameters, see http://go.microsoft.com/fwlink/p/?LinkID=113216.

Example 1 This command adds a SAN storage with IP address 167.16.2.134. The username is "Administrator" and the password is "Password". Add-HP4Storage -DnsOrIpAddress 167.16.2.134 -UserName "Administrator" -Password "Password" -Description SAN Storage

Example 2 This command adds a SAN storage with IP address 167.16.2.134. The credentials object is obtained with Get-VBRCredentials and assigned to the $creds variable beforehand. Add-HP4Storage -DnsOrIpAddress 167.16.2.134 -Credentials $creds Description SAN Storage

42 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Add-VBRBackupJob Short Description Creates a new backup job. Note:

In Backup & Replication v6 this cmdlet was replaced by Add-VBRViBackupJob and AddVBRHvBackupJob due to multihypervisor support introduced in the new version. The cmdlet will still work but it is advised to rewrite your scripts using new cmdlets for added benefits.

Applies to Version: 7.0 and earlier Platform: VMware

Syntax Add-VBRBackupJob [-Name] [[-Type] ] [-Server] [[-Folder] ] [-FileName ] -Objects [-Description ] [-WarningAction ] [-WarningVariable ] []

Related Commands Get-VBRServer

Detailed Description This cmdlet allows you to create a new backup job. Please note that when you create a backup job, you need to run it manually unless you enable a job schedule. Run Start-VBRJob to start the created job. Run Set-VBRJobSchedule to set schedule for the job.

Parameters Parameter

Name

Description Specifies the string with the name of the created backup job.

Required

Position

Accept Pipeline Input

Accept Wildcard Characters

True

1

False

False

False

2

False

False

Specifies the string with the type of the created backup job which defines how VM data is retrieved: Type

VDDK – Virtual Disk Development Kit (VMware vStorage API) VCB – VMware Consolidated Backup (legacy mode) NET – Network backup

43 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Parameter

Description

Required

Position

Accept Pipeline Input

Accept Wildcard Characters

(legacy mode). Server

Specifies the host where the created backup should be stored.

True

3

False

False

Folder

Specifies the string with the path to the folder where the created backup should be stored.

False

4

False

False

FileName

Specifies the string with the file name for the created backup (by default, the backup file is given the same name as the VM).

False

Named

False

False

Objects

Specifies the string with the name(s) of VM(s) that you want to back up.

True

Named

True (ByValue, ByProperty Name)

False

False

Named

False

False

Specifies the description of the new backup job. Description

If not set, Veeam Backup & Replication will enter date and time of creation by default.

This cmdlet supports Microsoft PowerShell common parameters. For more information about common parameters, see http://go.microsoft.com/fwlink/p/?LinkID=113216.

Example This example allows you to create a backup job with the following parameters: •

Name of the backup job: jobName



Data retrieval type: VDDK



Variable which contains the target host DNS name or IP address: $server



Path to the backup folder: C:\VmBackups



VMs which should be backed up: vm1, vm2

Add-VBRBackupJob –Name “jobName”–Type VDDK –Server $server – Folder "C:\VmBackups" –Objects vm1,vm2

44 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Add-VBRBackupRepository Short Description Adds a new backup repository server.

Applies to Version: 7.0 and earlier Platform: VMware

Syntax Add-VBRBackupRepository [-Name ] [-Server ] [MountServer ] -Folder -Type [-ImportIndex] [-ImportBackup] [Description ] [-MaxConcurrentJobs ] [DataRateLimit ] [-AlignDataBlocks] [-DecompressDataBlocks] [-WarningAction ] [-WarningVariable ] [] -ORAdd-VBRBackupRepository [-Name ] [-Server ] [MountServer ] -Folder -Type [-ImportIndex] [-ImportBackup] [Description ] [-UserName ] [-Password ] [-MaxConcurrentJobs ] [-DataRateLimit ] [AlignDataBlocks] [-DecompressDataBlocks] [-WarningAction ] [-WarningVariable ] [] -ORAdd-VBRBackupRepository [-Name ] [-Server ] [MountServer ] -Folder -Type [-ImportIndex] [-ImportBackup] [Description ] [-Credentials ] [MaxConcurrentJobs ] [-DataRateLimit ] [AlignDataBlocks] [-DecompressDataBlocks] [-WarningAction ] [-WarningVariable ] []

Related Commands Get-VBRServer Get-VBRCredentials

Detailed Description This cmdlet adds a new backup repository server to Veeam Backup & Replication. When adding a backup repository, you may need to provide username/password or credentials to authenticate with the source server. This cmdlet provides three scenarios for each case including no authentification. See what else you can perform on backup repositories

45 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Parameters Parameter

Description

Required

Position

Accept Pipeline Input

Accept Wildcard Characters

Name

Specifies the the name you want to assign to the new backup repository.

False

Named

False

False

Server

Specifies the host where the backup repository you want to add is located.

False

Named

False

False

Mount Server

Specifies the host where the NFS service should be installed.

False

Named

False

False

Folder

Specifies the full path to the folder where you want to store the backups.

True

Named

False

False

True

Named

False

False

Specifies the type you want to assign to the repository: Type

- CifsShare - LinuxLocal - WinLocal

Import Index

If indicated, the guest OS file system index will be imported automatically.

False

Named

False

False

Import Backup

If indicated, the existing backups located on the repository you are adding will be imported automatically. Otherwise, you will need to import the backups manually.

False

Named

False

False

False

Named

False

False

False

Named

False

False

False

Named

False

False

Specifies the description of the backup repository. Description

UserName

Password

If not set, Veeam Backup & Replication will enter date and time of creation by default. Specifies the user name you want to use for authenticating with the backup repository host. If you use the Username/Password scenario, the -Credentials parameter must be omitted. Specifies the password you want to use for authenticating with the backup repository host. If you use the Username/Password scenario, the -Credentials parameter must be omitted.

46 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Parameter

Description

Required

Position

Accept Pipeline Input

Accept Wildcard Characters

False

Named

False

False

Specifies credentials you want to use for authenticating with the backup repository host. Credentials

If you use the Credentials scenario, the -User and Password parameters must be omitted.

Max Concurrent Jobs

Specifies the maximum number of concurrent tasks for the repository. A valid range is 1-10.

False

Named

False

False

DataRate Limit

Specifies the combined data ingestion rate for the repository. A valid range is 11024 MByte/s.

False

Named

False

False

Align DataBlocks

If set, the backup blocks size will be aligned by a 4Kb block boundary. Data alignment provides better deduplication on storage systems with fixed block size.

False

Named

False

False

Decompress DataBlocks

If set, backup data blocks will be decompressed before storing the backup to the repository. Decompression helps to achieve a better deduplication ratio.

False

Named

False

False

This cmdlet supports Microsoft PowerShell common parameters. For more information about common parameters, see http://go.microsoft.com/fwlink/p/?LinkID=113216.

Example This command adds a new backup repository named "Backups Vol 01". •

The server to add is obtained with Get-VBRServer and assigned to the $server variable beforehand.



The folder that is used as the backup repository is located on "C:\Backup Repository".



The server type is set to "WinLocal".



The -ImportBackup parameter is set to adopt the existing backup files.



The Max concurrent tasks number is set to 6.



The credentials to authentificate with the source server are obtained with Get-VBRCredentials and assigned to the $Administrator variable beforehand.

Add-VBRBackupRepository -Name "Backups Vol 01" -Server $server Folder "c:\Backup Repository" -Type WinLocal -ImportBackup MaxConcurrentJobs 6 -Credentials $Administrator

47 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Add-VBRCopyJob Short Description Creates a new VM copy job.

Applies to Version: 7.0 and earlier Platform: VMware

Syntax Add-VBRCopyJob [-Name] [-Type] -Server -Folder [-FileName ] -Objects [-Description ] [-WarningAction ] [-WarningVariable ] [] -ORAdd-VBRCopyJob [-Name] [-Type] [-FileName ] -Objects [-Description ] -Repository [-WarningAction ] [WarningVariable ] []

Related Commands Get-VBRServer

Detailed Description This cmdlet creates a new job that copies the selected VM(s) to another location. With a VM copy job, you can create a fully-functioning copy of a VM that will require no manual editing and adjustments. VM copying can be helpful if you want to move your datacenter, mirror your production environment to test lab storage, etc. Please note that when you create a copy job, you need to run it manually unless you enable a job schedule. Run Start-VBRJob to start the created job. Run Set-VBRJobSchedule to set schedule for the job. Run Copy-VBRJob to create a copy of a job. See what else you can perform on jobs

48 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Parameters Parameter

Name

Description

Required

Position

Accept Pipeline Input

Accept Wildcard Characters

Specifies the name you want to assign to the new copy job.

True

1

False

False

True

2

False

False

Specifies the string with the type of the created copy job which defines how VM data is retrieved: Type

VDDK – Virtual Disk Development Kit (VMware vStorage API), VCB – VMware Consolidated Backup (legacy mode), NET – Network copy (legacy mode).

Server

Specifies the host where the created copy should be stored.

True

Named

False

False

Folder

Specifies the string with full path to the folder where the created VM copy should be stored.

True

Named

False

False

FileName

Specifies the string with the file name for the created VM copy (by default, a copied file is given the same name as the VM).

False

Named

False

False

Objects

Specifies the string with the name(s) of VM(s) that you want to copy.

True

Named

True (ByValue, ByProperty Name)

False

False

Named

False

False

Specifies the description of the copy job. Description

If not set, Veeam Backup & Replication will enter date and time of creation by default.

This cmdlet supports Microsoft PowerShell common parameters. For more information about common parameters, see http://go.microsoft.com/fwlink/p/?LinkID=113216.

49 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Example This example allows you to create a copy job with the following parameters: •

Name of a copy job: jobName



Data retrieval type: VDDK



Variable which contains the target host DNS name or IP address: $server



Path to a copy folder: C:\VmCopies



VMs which should be copied: vm1, vm2

Add-VBRCopyJob –Name “jobName”–Type VDDK –Server $server –Folder "C:\VmCopies" –Objects vm1,vm2

50 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Add-VBRCredentials Short Description Creates a credentials record.

Applies to Version: 7.0 Platform: VMware, Hyper-V

Syntax Add-VBRCredentials -User -Password [Description ] [-WarningAction ] [WarningVariable ] [] -ORAdd-VBRCredentials [-Description ] [-Credential ] [-WarningAction ] [WarningVariable ] []

Related Commands Get-VBRCredentials

Detailed Description This cmdlet creates a new credentials record for authenticating with the instances of your virtual infrastructure. You can add a new credentials record by indicating strings for user name and password (unprotected mode), or by supplying a PSCredential object. See what else you can perform on credentials

Parameters Required

Position

Accept Pipeline Input

Accept Wildcard Characters

True

Named

False

False

Password

Specifies the password you want to use for authenticating with the instances of your virtual infrastructure.

True

Named

False

False

Description

Specifies the description for the credentials record. This parameter in non-mandatory, although it is recommended to

False

Named

False

False

Parameter

User

Description Specifies the user name you want to use for authenticating with the instances of your virtual infrastructure. Please note that you should use DOMAIN\USERNAME usernames format for all hosts except ESX/ESXi hosts.

51 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Parameter

Description

Required

Position

Accept Pipeline Input

Accept Wildcard Characters

False

Named

False

False

input this value to make the credential records easily identified. Credential

Specifies the credentials you want to add.

This cmdlet supports Microsoft PowerShell common parameters. For more information about common parameters, see http://go.microsoft.com/fwlink/p/?LinkID=113216.

Example 1 This command creates a new credentials record for the administrator. Add-VBRCredentials -User Administrator -Password Password_1 Description "Administrator Credentials"

Example 2 This command adds a credentials record for the administrator. Get-Credential is used to enter the username and password in the secure mode. Get-Credential | Add-VBRCredentials -Description "Administrator Credentials"

52 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Add-VBRESX Short Description Adds an ESX host to Veeam Backup & Replication.

Applies to Version: 7.0 and earlier Platform: VMware

Syntax Add-VBRESX [-Name] [-User] [-Password] [-Port ] [-SSHUser ] [-SSHPassword ] [SSHPort ] [-SSHEnable] [-Description ] [WarningAction ] [-WarningVariable ] [] -ORAdd-VBRESX [-Name] [-Port ] [-SSHUser ] [-SSHPassword ] [-SSHPort ] [-SSHEnable] [Description ] -Credentials [-WarningAction ] [-WarningVariable ] []

Related Commands Get-VBRCredentials

Detailed Description This cmdlet adds ESX servers to the Veeam Backup & Replication managing console. ESX servers are virtual infrastructure servers hosting the virtual machines of your virtual environment. You need to add the ESX servers to Veeam Backup & Replication to be able to manage your virtual infrastructure via Veeam Backup & Replication console. You may add an ESX/ESXi host, vCenter Server or Linux server (use corresponding command for each). If you are planning to use an ESX host being a part of the vCenter hierarchy, we recommend adding the corresponding vCenter Server instead of a single ESX host to ensure more flexibility and convenience at work. When adding a new ESX server, you will need to provide either username and password or credentials. This cmdlet provides syntax for both scenarios accordingly. See what else you can perform on your virtual infrastructure instances

53 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Parameters Description

Required

Position

Accept Pipeline Input

Accept Wildcard Characters

Specifies the string with a full DNS name or IP address of the ESX host.

True

1

False

False

True

2

False

False

True

3

False

False

Port

Sets the integer specifying the number of the Web service port used to connect to the ESX host. By default, port 443 is used.

False

Named

False

False

SSHUser

Specifies the string with the user name of the account used for service console connection to the host (recommended).

False

Named

False

False

SSHPassword

Specifies the string with the password of the account used for service console connection to the host (recommended).

False

Named

False

False

SSHPort

Sets the integer specifying the number of the service console port (recommended).

False

Named

False

False

SSHEnable

Set this parameter to TRUE if you want to use service console connection for the added ESX host (recommended).

False

Named

False

False

False

Named

False

False

Parameter

Name

User

Password

Specifies the user name you want to use for authenticating with the ESX host. If you use the Username/Password scenario, the -Credentials parameter must be omitted. Specifies the password you want to use for authenticating with the ESX host. If you use the Username/Password scenario, the -Credentials parameter must be omitted.

Specifies the description of the ESX server. Description

If not set, Veeam Backup & Replication will enter date and time of creation by default.

54 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Parameter

Credentials

Description Specifies the credentials you want to use for authenticating with the ESX server. If you use the Credentials scenario, the -User and Password parameters must be omitted.

Required

Position

Accept Pipeline Input

Accept Wildcard Characters

True

Named

False

False

This cmdlet supports Microsoft PowerShell common parameters. For more information about common parameters, see http://go.microsoft.com/fwlink/p/?LinkID=113216.

Example 1 This command adds the ESX host with 172.16.11.188 IP address. The username is "root" and the password is "qwerty". Add-VBRESX –Name 172.16.11.188 –User root –Password qwerty

Example 2 This command adds the ESX host with 172.16.11.188 IP address. The credentials to authenticate with the host are obtained with Get-VBRCredentials and assigned to the $cAdministrator variable befohand. Add-VBRESX –Name 172.16.11.188 -Credentials $Administrator

55 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Add-VBRESXi Short Description Adds an ESXi host to Veeam Backup & Replication.

Applies to Version: 7.0 and earlier Platform: VMware

Syntax Add-VBRESXi [-Name] [-User] [-Password] [-Port ] [-Description ] [-WarningAction ] [-WarningVariable ] [] -ORAdd-VBRESXi [-Name] [-Port ] [-Description ] -Credentials [-WarningAction ] [-WarningVariable ] []

Related Commands Get-VBRCredentials

Detailed Description This cmdlet adds ESXi servers to the Veeam Backup & Replication managing console. ESXi servers are virtual infrastructure servers hosting the virtual machines of your virtual environment. You need to add the ESXi servers to Veeam Backup & Replication to be able to manage your virtual infrastructure via Veeam Backup & Replication console. You may add an ESX/ESXi host, vCenter Server or Linux server (use corresponding command for each). If you are planning to use an ESXi host being a part of the vCenter hierarchy, we recommend adding the corresponding vCenter Server instead of a single ESX host to ensure more flexibility and convenience at work. When adding a new ESXi server, you will need to provide either username and password or credentials. This cmdlet provides syntax for both scenarios accordingly. See what else you can perform on your virtual infrastructure instances

Parameters Parameter

Name

User

Description

Required

Position

Accept Pipeline Input

Accept Wildcard Characters

Specifies the string with a full DNS name or IP address of the ESX host.

True

1

False

False

True

2

False

False

Specifies the user name you want to use for authenticating with the ESX host. If you use the

56 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Parameter

Description

Required

Position

Accept Pipeline Input

Accept Wildcard Characters

True

3

False

False

False

Named

False

False

False

Named

False

False

True

Named

False

False

Username/Password scenario, the -Credentials parameter must be omitted. Specifies the password you want to use for authenticating with the ESX host. Password

Port

If you use the Username/Password scenario, the -Credentials parameter must be omitted. Sets the integer specifying the number of the Web service port used to connect to the ESX host. By default, port 443 is used. Specifies the description of the ESX server.

Description

If not set, Veeam Backup & Replication will enter date and time of creation by default. Specifies the credentials you want to use for authenticating with the ESX server.

Credentials

If you use the Credentials scenario, the -User and Password parameters must be omitted.

This cmdlet supports Microsoft PowerShell common parameters. For more information about common parameters, see http://go.microsoft.com/fwlink/p/?LinkID=113216.

Example 1 This command adds the ESXi host with 172.16.11.188 IP address. The username is "root" and the password is "qwerty". Add-VBRESXi –Name 172.16.11.188 –User root –Password qwerty

Example 2 This command adds the ESXi host with 172.16.11.188 IP address. The credentials to authenticate with the host are obtained with Get-VBRCredentials and assigned to the $cAdministrator variable befohand. Add-VBRESXi –Name 172.16.11.188 -Credentials $Administrator

57 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Add-VBRHvBackupCopyJob Short Description Creates a Hyper-V backup copy job.

Applies to Version: 7.0 Platform: Hyper-V For VMware, run Add-VBRViBackupCopyJob.

Syntax Add-VBRHvBackupCopyJob -SourceAccelerator TargetAccelerator [-Name ] [-Entity ][-Backup ][-BackupJob ] [Repository ][-Description ][]

Related Commands Get-VBRWANAccelerator Find-VBRHvEntity Get-VBRBackup Get-VBRJob Get-VBRBackupRepository

Detailed Description This cmdlet creates a new Hyper-V backup copy job. The backup copy job is copying backup files from the source backup repository to the target backup repository. The backup copy job runs continuously synchronizing the backup repositories in userdefined time periods. The cmdlet provides two scenarios that can be used for on-site and off-site modes: •

To transfer the data efficiently to to the off-site location, you can use the WAN accelerator technology. WAN accelerator is a backup infrastructure component that optimizes file transfer via WAN by means of data deduplication. The role of a WAN accelerator can be assigned to a dedicated Windows-based machine (physical or virtual). For best performance you should set a WAN accelerator on both source and target sides. This mode is recommended for off-site backups. To create and run a backup copy job using WAN accelerators you need to have source and target WAN accelerators created. Run Add-VBRWANAccelerator to create a WAN accelerator.



You can create a backup copy job using direct operation. With this method, the job sends the data directly to the target backup repository without performing data deduplication. This mode is recommended for on-site backups, or off-site backups using fast connections.

Please note that the backup copy job is created in disabled state. Run Enable-VBRJob to start the job running on the defined schedule. See what else you can perform on backup copy

58 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Note:

WAN optimization is available only in Veeam Backup & Replication Enterprise Plus Edition.

Parameters Parameter

Source Accelerator

Target Accelerator

Direct Operation

Name

Description

Required

Position

Accept Pipeline Input

Accept Wildcard Characters

True

Named

False

False

True

Named

False

False

True

Named

False

False

Named

True (ByValue, ByProperty Name)

False

Named

True (ByValue, ByProperty Name)

False

Named

True (ByValue, ByProperty Name)

False

Named

True (ByValue, ByProperty Name)

False

Specifies the WAN accelerator on the source side. If you select the mode using WAN accelerators, the DirectOperation parameter should be omitted. Specifies the WAN accelerator on the target side. If you select the mode using WAN accelerators, the DirectOperation parameter should be omitted. Enables the direct operation method sending the data directly to the target backup repository without performing data deduplication. If you select the direct operation mode, the TargetAccelerator and SourceAccelerator parameters should be omitted. Specifies the name you want to assign to the backup copy job.

False

You can input string up to 255 symbols.

Entity

Backup

Specifies the VM(s) you want to copy. You can assign multiple VMs to this object. Specifies the existing backup(s) from where the VMs to copy are derived.

False

False

You can assign multiple backups to this object.

BackupJob

Specifies the existing backup job(s) from where the VMs to copy are derived.

False

You can assign multiple backup jobs to this object.

59 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Parameter

Repository

Description Specifies the backup repository to where you want to copy the VM data. If not set, Veeam Backup & Replication will use the default backup repository.

Required

Position

Accept Pipeline Input

Accept Wildcard Characters

False

Named

False

False

False

Named

False

False

Specifies the description of the backup copy job. Description

If not set, Veeam Backup & Replication will enter date and time of creation by default.

This cmdlet supports Microsoft PowerShell common parameters. For more information about common parameters, see http://go.microsoft.com/fwlink/p/?LinkID=113216.

Example 1 This command creates a backup copy job named "CopyJob1" with the following parameters: •

The source and target WAN accelerators are obtained with Get-VBRWANAccelerator and assigned to $wansource and $wantarget variables accordingly beforehand,



The VMs to copy are obtained with Find-VBRHvEntity and assigned to the $vms variable beforehand,



The repository to where the VM data will be copied is obtained with GetVBRBackupRepository and assigned to the $repository variable beforehand.

Add-VBRHvBackupCopyJob -SourceAccelerator $wansource TargetAccelerator $wantarget -Name CopyJob1 -Entity $vms Repository $repository

Example 2 This command creates a direct backup copy job with the following parameters: •

The name of the job is "DC CopyJob",



The backup job named "DC Backup" with the VMs to be copied is obtained with GetVBRBackup and piped down,



The -Repository parameter is not set to copy the VMs to the default backup repository.

Get-VBRBackup -Name "DC Backup" | Add-VBRHvBackupCopyJob DirectOperation -Name "DC CopyJob"

60 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Add-VBRHvBackupJob Short Description Creates a new Hyper-V backup job.

Applies to Version: 7.0 and earlier Platform: Hyper-V For VMware, run Add-VBRViBackupJob.

Syntax Add-VBRHvBackupJob [-Name ] [-BackupRepository ] -Entity [-Description ] [-WarningAction ] [-WarningVariable ] []

Related Commands Get-VBRBackupRepository Find-VBRHvEntity

Detailed Description This cmdlet creates a new Hyper-V backup job. Please note that when you create a backup job, you need to run it manually unless you enable a job schedule. Run Start-VBRJob to start the created job. Run Set-VBRJobSchedule to set schedule for the job. See what else you can perform on jobs

Parameters Parameter

Name

Backup Repository

Entity

Description

Description

Required

Position

Accept Pipeline Input

Accept Wildcard Characters

Specifies the name you want to assign to the backup job.

False

Named

False

False

False

Named

False

False

True

Named

True (ByValue, ByProperty Name)

False

False

Named

False

False

Specifies the backup repository where the created backup should be stored. If not set, Veeam Backup & Replication will use the default backup repository. Specifies the VM(s) you want to back up. You can assign multiple VMs to this object. Specifies the description of

61 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Parameter

Description

Required

Position

Accept Pipeline Input

Accept Wildcard Characters

the backup job. If not set, Veeam Backup & Replication will enter date and time of creation by default.

This cmdlet supports Microsoft PowerShell common parameters. For more information about common parameters, see http://go.microsoft.com/fwlink/p/?LinkID=113216.

Example This command creates a backup job named "Exchange Backup". The VMs to backup are obtained with Find-VBRHvEntity and piped down. The backup repository is obtained with Get-VBRBackupRepository and assigned to the $Repository variable beforehand. the description is "Hyper-V Exchange Backup". Find-VBRHvEntity -Name Exchange* | Add-VBRHvBackupJob -Name "Exchange Backup" -BackupRepository $Repository -Description "Hyper-V Exchange Backup"

62 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Add-VBRHvCluster Short Description Adds a Hyper-V cluster to Veeam Backup & Replication.

Applies to Version: 7.0 and earlier Platform: Hyper-V

Syntax Add-VBRHvCluster -Name -User -Password [-Description ] [-WarningAction ] [WarningVariable ] [] -ORAdd-VBRHvCluster -Name [-Description ] Credentials [-WarningAction ] [WarningVariable ] []

Related Commands Get-VBRCredentials

Detailed Description This cmdlet adds Hyper-V clusters to the Veeam Backup & Replication managing console. If you include your virtual machines in clusters, you need to add the clusters to Veeam Backup & Replication to be able to manage your virtual infrastructure via Veeam Backup & Replication console. When you add a cluster, you start managing the VMs that are part of the cluster automatically. When you remove a Hyper-V cluster from Veeam Backup & Replication managing console, the VMs that are part of the cluster are removed too. If you want to manage individual VMs with Veeam Backup & Replication, you need to add them as standalone Hyper-V hosts. Run Add-VBRHvHost to add a standalone Hyper-V host to Veeam Backup & Replication. When adding a new Hyper-V cluster, you will need to provide either username and password or credentials. This cmdlet provides syntax for both scenarios accordingly. When you provide authentication with the Hyper-V cluster, you get equal rights for all clustered VMs. See what else you can perform on your virtual infrastructure instances

Parameters Parameter

Name

User

Description

Required

Position

Accept Pipeline Input

Accept Wildcard Characters

Specifies the string with the DNS name of the added HyperV cluster.

True

Named

False

False

True

Named

False

False

Specifies the user name you want to use for authenticating with the Hyper-V cluster. If you use the

63 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Parameter

Description

Required

Position

Accept Pipeline Input

Accept Wildcard Characters

True

Named

False

False

False

Named

False

False

True

Named

False

False

Username/Password scenario, the -Credentials parameter must be omitted. Specifies the password you want to use for authenticating with the Hyper-V cluster. Password

If you use the Username/Password scenario, the -Credentials parameter must be omitted. Specifies the description of the Hyper-V cluster.

Description

If not set, Veeam Backup & Replication will enter date and time of creation by default. Specifies the credentials you want to use for authenticating with the Hyper-V cluster.

Credentials

If you use the Credentials scenario, the -User and Password parameters must be omitted.

This cmdlet supports Microsoft PowerShell common parameters. For more information about common parameters, see http://go.microsoft.com/fwlink/p/?LinkID=113216.

Example 1 This command adds a new Hyper-V cluster named "HYPCLUSTER01" using username and password. The user name is "Administrator", and the password is "Password". The description is "Hyper-V Cluster 01". Add-VBRHvCluster -Name "HYPCLUSTER01" -User Administrator Password Password -Description "Hyper-V Cluster 01"

Example 2 This command adds a new Hyper-V cluster named "HYPCLUSTER01" using credentials. The credentials object is obtained with Get-VBRCredentials and assigned to the $Administrator variable beforehand. The description is "Hyper-V Cluster 01". Add-VBRHvCluster -Name "HYPCLUSTER01" -Description "Hyper-V Cluster 01" -Credentials $Administrator

64 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Add-VBRHvHost Short Description Adds a Hyper-V host to Veeam Backup & Replication.

Applies to Version: 7.0 and earlier Platform: Hyper-V

Syntax Add-VBRHvHost -Name -User -Password [Description ] [-WarningAction ] [WarningVariable ] [] -ORAdd-VBRHvHost -Name [-Description ] -Credentials [-WarningAction ] [WarningVariable ] []

Related Commands Get-VBRCredentials

Detailed Description This cmdlet adds Hyper-V host to the Veeam Backup & Replication managing console. You need to add the hosts to Veeam Backup & Replication to be able to manage your virtual infrastructure via Veeam Backup & Replication console. If a Hyper-V host is part of a cluster, add the Hyper-V cluster instead of standalone Hyper-V host. Run Add-VBRHvCluster to add a Hyper-V cluster. When adding a new Hyper-V host, you will need to provide either username and password or credentials. This cmdlet provides syntax for both scenarios accordingly. See what else you can perform on your virtual infrastructure instances

Parameters Parameter

Name

Description

Required

Position

Accept Pipeline Input

Accept Wildcard Characters

Specifies the string with the DNS name of the added HyperV cluster.

True

Named

False

False

Specifies the user name you want to use for authenticating with the Hyper-V cluster. User

If you use the Username/Password scenario, the -Credentials parameter must be omitted.

True

Named

False

False

Password

Specifies the password you

True

Named

False

False

65 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Parameter

Description

Required

Position

Accept Pipeline Input

Accept Wildcard Characters

False

Named

False

False

True

Named

False

False

want to use for authenticating with the Hyper-V cluster. If you use the Username/Password scenario, the -Credentials parameter must be omitted. Specifies the description of the Hyper-V cluster. Description

If not set, Veeam Backup & Replication will enter date and time of creation by default. Specifies the credentials you want to use for authenticating with the Hyper-V cluster.

Credentials

If you use the Credentials scenario, the -User and Password parameters must be omitted.

This cmdlet supports Microsoft PowerShell common parameters. For more information about common parameters, see http://go.microsoft.com/fwlink/p/?LinkID=113216.

Example 1 This command adds a new Hyper-V server named "HyperVExchange" using username and password. The user name is "Administrator", and the password is "Password". The description is "Hyper-V Exchange host". Add-VBRHvHost -Name "HyperVExchange" -User Administrator Password Password -Description "Hyper-V Exchange host"

Example 2 This command adds a new Hyper-V host named "HyperVExchange" using credentials. The credentials object is obtained with Get-VBRCredentials and assigned to the $Administrator variable beforehand. The description is "Hyper-V Exchange host". Add-VBRHvHost -Name "HyperVExchange" -Credentials $Administrator -Description "Hyper-V Exchange host"

66 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Add-VBRHvJobObject Short Description Adds a new object to a Hyper-V job.

Applies to Version: 7.0 Platform: Hyper-V For VMware, run Add-VBRViJobObject.

Syntax Add-VBRHvJobObject -Job -Entities [WarningAction ] [-WarningVariable ] []

Related Commands Get-VBRJob Find-VBRHvEntity

Detailed Description This cmdlet allows to add VM(s) to an existing job. You can run this cmdlet with any kind of jobs. See what else you can perform on job objects

Parameters Parameter

Job

Entities

Description Specifies the job(s) you want to add the VM(s) to. You can assign multiple backup jobs to this object. Specifies the VM(s) you want to add to the job. You can assign multiple VMs to this object.

Required

Position

Accept Pipeline Input

True

Named

False

False

Named

True (ByValue, ByProperty Name)

False

True

Accept Wildcard Characters

This cmdlet supports Microsoft PowerShell common parameters. For more information about common parameters, see http://go.microsoft.com/fwlink/p/?LinkID=113216.

67 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Example 1 This command adds a VM named "VM01" to the job represented by $job variable. First the job object is got and assigned to $"Backup Hv Job" variable. The VM object is obtained with Find-VBRHvEntity and piped down. Find-VBRHvEntity -Name VM01 | Add-VBRHvJobObject -Job $"Backup Hv Job"

Example 2 This command adds a VM represented by $Vm variable to the job represented to $"Backup Hv Job" variable. The variables are assigned beforehand. Add-VBRHvJobObject -Job $"Backup Hv Job" -Entities $Vm

68 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Add-VBRHvProxy Short Description Adds a Hyper-V backup proxy to Veeam Backup & Replication.

Applies to Version: 7.0 and earlier Platform: Hyper-V For VMware, run Add-VBRViProxy.

Syntax Add-VBRHvProxy -Server [-Description ] [-MaxTasks ] [-WarningAction ] [-WarningVariable ] []

Related Commands Get-VBRServer

Detailed Description This cmdlet adds a Hyper-V backup proxy server to Veeam Backup & Replication managing console. In the backup infrastructure, the backup proxy actually performs main data handling – retrieving data, processing it and transferring to the target destination. Use of backup proxies enables you to take the job processing off the backup server and allows for better scalability of your backup infrastructure. See what else you can perform on your virtual proxies When you add a proxy, you set a role to a server. To add a new proxy, you need to have the server added to your Veeam Backup & Replication managing console. Run Add-VBRHvHost to add a Hyper-V server.

Parameters Parameter

Server

Description

Specifies the server which will act as a Hyper-V backup proxy.

Position

Accept Pipeline Input

Accept Wildcard Characters

True

Named

True (ByValue, ByProperty Name)

False

False

Named

False

False

False

Named

False

False

Required

Specifies the description of the Hyper-V proxy. Description

MaxTasks

If not set, Veeam Backup & Replication will enter date and time of creation by default. Sets the integer specifying the number of concurrent tasks that can be assigned to the proxy simultaneously. If not set, the number of

69 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Parameter

Description

Required

Position

Accept Pipeline Input

Accept Wildcard Characters

tasks will be set to 2 by default.

This cmdlet supports Microsoft PowerShell common parameters. For more information about common parameters, see http://go.microsoft.com/fwlink/p/?LinkID=113216.

Example 1 This command adds a new proxy. The server that will act as the proxy is obtained with Get-VBRServer and piped down. The description is "Local Backup Proxy". The max concurrent tasks number is set to 6. Get-VBRServer -Name "HyperV Local Server" | Add-VBRHvProxy Description "Local Backup Proxy" -MaxTasks 6

Example 2 This command adds a new proxy. The server that will act as the proxy is obtained with Get-VBRServer and assigned to the $server variable. The description is "Local Backup Proxy". The max concurrent tasks number is not set to enable the default value. Add-VBRHvProxy -Server $server -Description "Local Backup Proxy"

70 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Add-VBRHvReplicaJob Short Description Creates a new Hyper-V replication job.

Applies to Version: 7.0 and earlier Platform: Hyper-V For VMware, run Add-VBRViReplicaJob.

Syntax Add-VBRHvReplicaJob [-Name ] -Server -Entity [-Suffix ] [-Description ] [WarningAction ] [-WarningVariable ] [] -ORAdd-VBRHvReplicaJob [-Name ] -Path Entity [-Suffix ] [-Description ] [WarningAction ] [-WarningVariable ] []

Related Commands Get-VBRServer Find-VBRHvEntity

Detailed Description This cmdlet creates a new Hyper-V replication job. Replication is a process of copying a VM from its primary location (source host) to a destination location (redundant target host). Veeam Backup & Replication creates an exact copy of a VM (replica), registers it on the target host and maintains it in sync with the original VM. Please note that when you create a replica job, you need to run it manually unless you enable a job schedule. Run Start-VBRJob to start the created job. Run Set-VBRJobSchedule to set schedule for the job. See what else you can perform on jobs See what else you can perform on replicas

71 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Parameters Description

Required

Position

Accept Pipeline Input

Accept Wildcard Characters

Name

Specifies the name you want to assign to the replication job.

False

Named

False

False

Server

Specifies the server where the created replica should be stored.

True

Named

False

False

Path

Specifies the Hyper-V volume where the created replica should be stored.

True

Named

False

False

True

Named

True (ByValue, ByProperty Name)

False

False

Named

False

False

False

Named

False

False

Parameter

Entity

Suffix

Specifies the VM(s) that you want to replicate. You can assign multiple VMs to this object. Specifies the suffix that will be appended to the name of the VM you are replicating. This name will be used to register the replicated VM on the target server. Specifies the description of the replication job.

Description

If not set, Veeam Backup & Replication will enter date and time of creation by default.

This cmdlet supports Microsoft PowerShell common parameters. For more information about common parameters, see http://go.microsoft.com/fwlink/p/?LinkID=113216.

Example This command creates the backup job named "kvm01 Backup". The VM to backup is obtained with Find-VBRHvEntity and piped down. The host to locate the replicated VM on is obtained with GetVBRServer and assigned to the $server variable beforehand. The replicated VM must have the "_replica" suffix. Find-VBRHvEntity -Name kvm01 | Add-VBRHvReplicaJob -Name "kvm01 Backup" -Server $server -Suffix "_replica"

72 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Add-VBRHvScvmm Short Description Adds a SCVMM server to Veeam Backup & Replication.

Applies to Version: 7.0 and earlier Platform: Hyper-V

Syntax Add-VBRHvScvmm -Name -User -Password [-Description ] [-WarningAction ] [WarningVariable ] [] -ORAdd-VBRHvScvmm -Name [-Description ] Credentials [-WarningAction ] [WarningVariable ] []

Related Commands Get-VBRCredentials

Detailed Description This cmdlet adds SCVMM (Microsoft System Center Virtual Machine Manager) server to the Veeam Backup & Replication managing console. When adding a new SCVMM server, you will need to provide either username and password or credentials. This cmdlet provides syntax for both scenarios accordingly. See what else you can perform on your virtual infrastructure

Parameters Parameter

Name

Description Specifies the string with the DNS name of the added SCVMM server.

Required

Position

Accept Pipeline Input

Accept Wildcard Characters

True

Named

False

False

True

Named

False

False

True

Named

False

False

Specifies the user name you want to use for authenticating with the SCVMM server. User

Password

If you use the Username/Password scenario, the -Credentials parameter must be omitted. Specifies the password you want to use for authenticating with the SCVMM server. If you use the Username/Password scenario,

73 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Parameter

Description

Required

Position

Accept Pipeline Input

Accept Wildcard Characters

True

Named

False

False

False

Named

False

False

the -Credentials parameter must be omitted. Specifies the credentials you want to use for authenticating with the SCVMM server. Credentials

If you use the Credentials scenario, the -User and Password parameters must be omitted. Specifies the description of the SCVMM server.

Description

If not set, Veeam Backup & Replication will enter date and time of creation by default.

This cmdlet supports Microsoft PowerShell common parameters. For more information about common parameters, see http://go.microsoft.com/fwlink/p/?LinkID=113216.

Example 1 This command adds the SCVMM server using a username and a password. Add-VBRHvScvmm -User "Administrator" -Password "Password" Description "SCVMM Server"

Example 2 This command adds the SCVMM server using credentials. The credentials record is obtained with GetVBRCredentials and assigned to the $"SCVMM Administrator" variable beforehand. Add-VBRHvScvmm -Description "SCVMM Server" -Credentials $"SCVMM Administrator"

74 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Add-VBRJobObject Short Description Adds VMs to existing job. Note:

In Backup & Replication v6 this cmdlet was replaced by Add-VBRViJobObject and AddVBRHvJobObject due to multihypervisor support introduced in the new version. The cmdlet will still work but it is advised to rewrite your scripts using new cmdlets for added benefits.

Applies to Version: 7.0 and earlier Platform: VMware

Syntax Add-VBRJobObject [-Job] [-Server] [-Objects] [-WarningAction ] [-WarningVariable ] [] -ORAdd-VBRJobObject [-Job] [-Server] [Entities] [-WarningAction ] [WarningVariable ] []

Related Commands Get-VBRJob Get-VBRServer Find-VBRViEntity

Detailed Description This cmdlet allows you to add VMs or VM containers to existing backup, replication or copy job. See what else you can perform on job objects

Parameters Description

Required

Position

Accept Pipeline Input

Accept Wildcard Characters

Job

Specifies the job you want to add VMs to.

True

1

False

False

Server

Specifies the host where the VMs or VM containers you want to add reside.

True

2

False

False

3

True (ByValue, ByProperty Name)

False

Parameter

Objects

Specifies the string with the name(s) of VM(s) you want to add to the job.

True

You can assign multiple VMs to this object.

75 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Parameter

Entities

Description Specifies the VM(s) or VM container(s) you want to add to the job.

Required

True

Position

Accept Pipeline Input

Accept Wildcard Characters

3

True (ByValue, ByProperty Name)

False

You can assign multiple VMs to this object.

This cmdlet supports Microsoft PowerShell common parameters. For more information about common parameters, see http://go.microsoft.com/fwlink/p/?LinkID=113216.

Example 1 This command adds a VM named "vm3" to a job represented by $job variable. The VM is located on the server represented by the $server variable. The job object and the server object are obtained with Get-VBRJob and Get-VBRServer and assigned to the variables accordingly beforehand. Add-VBRJobObject –Job $job –Server $server –Objects vm3

Example 2 This command adds a VM named "vm3" to the job represented by the $job variable. The VM is obtained with Find-VBRViEntity and piped down. The VM is located on the server represented by the $server variable. The job object and the server object are obtained with Get-VBRJob and GetVBRServer and assigned to the variables accordingly beforehand. Find-VBRViEntity -Name "vm3" | Add-VBRJobObject -Job $job -Server $server

76 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Add-VBRLinux Short Description Adds a Linux server to Veeam Backup & Replication.

Applies to Version: 7.0 and earlier Platform: VMware

Syntax Add-VBRLinux [-Name] [-SSHUser] [-SSHPassword] [-SSHPort ] [-Description ] [WarningAction ] [-WarningVariable ] [] -ORAdd-VBRLinux [-Name] [-SSHPort ] [-Description ] -Credentials [-WarningAction ] [-WarningVariable ] []

Related Commands Get-VBRCredentials

Detailed Description This cmdlet allows you to add a Linux server to Veeam Backup & Replication. The Linux server must have SSH and Perl. When adding a new Linux server, you will need to provide either username and password or credentials. This cmdlet provides syntax for both scenarios accordingly. See what else you can perform on your virtual infrastructure instances

Parameters Parameter

Name

SSHUser

SSHPassword

Description

Required

Position

Accept Pipeline Input

Accept Wildcard Characters

Specifies the string with a DNS name or IP address of the Linux server you want to add.

True

1

False

False

True

2

False

False

True

3

False

False

Specifies the user name you want to use for authenticating with the Linux server. If you use the Username/Password scenario, the -Credentials parameter must be omitted. Specifies the password you

77 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Parameter

Description

Required

Position

Accept Pipeline Input

Accept Wildcard Characters

True

Named

False

False

False

Named

False

False

False

Named

False

False

want to use for authenticating with the Linux server. If you use the Username/Password scenario, the -Credentials parameter must be omitted.

Credentials

SSHPort

Specifies the credentials you want to use for authenticating with the Linux server. If you use the Credentials scenario, the -User and Password parameters must be omitted. Provide an integer specifying the Web service port number used to connect to the Linux server console. By default, port 443 is used. Specifies the description of the Linux server.

Description

If not set, Veeam Backup & Replication will enter date and time of creation by default.

This cmdlet supports Microsoft PowerShell common parameters. For more information about common parameters, see http://go.microsoft.com/fwlink/p/?LinkID=113216.

Example 1 This command adds the Linux server with the 172.11.16.13 IP address using a username and a password. The user name is "Administrator" and the password is "Password". Add-VBRLinux -Name 172.11.16.13 -SSHUser "Administrator" SSHPassword "Password" -Description "Linux host 01"

Example 2 This command adds the Linux server with the 172.11.16.13 IP address using credentials. The credentials record is obtained with Get-VBRCredentials and assigned to the $"Linux Administrator" variable beforehand. Add-VBRLinux -Name 172.11.16.13 -Description "Linux host 01" Credentials $"Linux Administrator"

78 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Add-VBRReplicaJob Short Description Creates new replication job. Note:

In Veeam Backup & Replication v6 this cmdlet was replaced by Add-VBRViReplicaJob and AddVBRHvReplicaJob due to multihypervisor support introduced in the new version. The cmdlet will still work but it is advised to rewrite your scripts using new cmdlets for added benefits.

Applies to Version: 7.0 and earlier Platform: VMware

Syntax Add-VBRReplicaJob [-Name] [[-Type] ] [-Server] [-Datastore] -Objects [-Suffix ] [-Description ] [-WarningAction ] [-WarningVariable ] []

Related Commands Get-VBRServer Find-VBRViDatastore

Detailed Description This cmdlet allows you to create a new replication job. Replication is a process of copying a VM from its primary location (source host) to a destination location (redundant target host). Veeam Backup & Replication creates an exact copy of a VM (replica), registers it on the target host and maintains it in synch with the original VM. Please note that when you create a replica job, you need to run it manually unless you enable a job schedule. Run Start-VBRJob to start the created job. Run Set-VBRJobSchedule to set schedule for the job. See what else you can perform on replicas

79 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Parameters Parameter

Name

Description Specifies the string with the name you want to assign to the replication job.

Required

Position

Accept Pipeline Input

Accept Wildcard Characters

True

1

False

False

False

2

False

False

Specifies the string with the type of the created replication job which defines how VM data is retrieved:

Type

• VDDK – Virtual Disk Development Kit (VMware vStorage API) • VCB – VMware Consolidated Backup (legacy mode) • NET – Network replication (legacy mode)

Server

Specifies the host where the created replica should be stored.

True

3

False

False

Datastore

Specifies the datastore where the created replica should reside.

True

4

False

False

True

Named

True (ByValue, ByProperty Name)

False

False

Named

False

False

False

Named

False

False

Objects

Specifies the string with the name(s) of VM(s) that you want to replicate. You can assign multiple VMs to this object.

Suffix

Specifies the suffix that will be appended to the name of the VM you are replicating. This name will be used to register the replicated VM on the target server. Specifies the description of the replica job.

Description

If not set, Veeam Backup & Replication will enter date and time of creation by default.

80 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Example This example allows you to create a replication job with the following parameters: •

Name of a replication job: Replica1



Replication type: VDDK



Variable which contains target host DNS name or IP address: $server



Variable which contains datastore name: $datastore



Replicated VM: vm4

Add-VBRReplicaJob –Name “Replica1”–Type VDDK –Server $server – Datastore $datastore –Objects vm4

81 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Add-VBRSmbV3Cluster Short Description Adds an SMB3 cluster to Veeam Backup & Replication.

Applies to Version: 7.0 and earlier Platform: Hyper-V

Syntax Add-VBRSmbV3Cluster -Name -User -Password [-Description ] [-WarningAction ] [-WarningVariable ] [] -ORAdd-VBRSmbV3Cluster -Name [-Description ] Credentials [-WarningAction ] [WarningVariable ] []

Related Commands Get-VBRCredentials

Detailed Description This cmdlet adds an SMB3 cluster to the Veeam Backup & Replication managing console. If you include your virtual machines in clusters, you need to add the clusters to Veeam Backup & Replication to be able to manage your virtual infrastructure via Veeam Backup & Replication console. When you add a cluster, you start managing the VMs that are part of the cluster automatically. When you remove a Hyper-V cluster from Veeam Backup & Replication managing console, the VMs that are part of the cluster are removed too. If you want to manage individual VMs with Veeam Backup & Replication, you need to add them as standalone SMB3 servers. Run Add-VBRSmbV3Host to add a standalone SMB3 server to Veeam Backup & Replication. When adding a new SMB3 cluster, you will need to provide either username and password or credentials. This cmdlet provides syntax for both scenarios accordingly. When you provide authentication with the Hyper-V cluster, you get equal rights for all clustered VMs. See what else you can perform on your virtual infrastructure instances

82 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Parameters Parameter

Name

Description

Required

Position

Accept Pipeline Input

Accept Wildcard Characters

Specifies the full DNS name or IP address of the SMB3 cluster.

True

Named

False

False

True

Named

False

False

True

Named

False

False

False

Named

False

False

True

Named

False

False

Specifies the user name you want to use for authenticating with the SMB3 cluster. User

If you use the Username/Password scenario, the -Credentials parameter must be omitted. Specifies the password you want to use for authenticating with the SMB3 cluster.

Password

If you use the Username/Password scenario, the -Credentials parameter must be omitted. Specifies the description of the SMB3 cluster.

Description

If not set, Veeam Backup & Replication will enter date and time of creation by default. Specifies the credentials you want to use for authenticating with the SMB3 cluster.

Credentials

If you use the Credentials scenario, the -User and Password parameters must be omitted.

This cmdlet supports Microsoft PowerShell common parameters. For more information about common parameters, see http://go.microsoft.com/fwlink/p/?LinkID=113216.

83 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Example 1 This command adds a new SMB3 cluster named "SMBCLUSTER01" using username and password. The user name is "Administrator", and the password is "Password". The description is "Hyper-V SMB Share Cluster 01". Add-VBRSmbV3Cluster -Name "SMBCLUSTER01" -User "Administrator" Password "Password" -Description "Hyper-V SMB Share Cluster 01"

Example 2 This command adds a new SMB3 cluster named "SMBCLUSTER01" using credentials. The credentials object is obtained with Get-VBRCredentials and assigned to the $Administrator variable beforehand. The description is "Hyper-V SMB Share Cluster 01". Add-VBRHvCluster -Name "SMBCLUSTER01" -Description "Hyper-V SMB Share Cluster 01" -Credentials $Administrator

84 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Add-VBRSmbV3Host Short Description Adds an SMB3 host to Veeam Backup & Replication.

Applies to Version: 7.0 and earlier Platform: Hyper-V

Syntax Add-VBRSmbV3Host -Name -User -Password [-Description ] [-WarningAction ] [WarningVariable ] [] -ORAdd-VBRSmbV3Host -Name [-Description ] Credentials [-WarningAction ] [WarningVariable ] []

Related Commands Get-VBRCredentials

Detailed Description This cmdlet adds an SMB3 server to the Veeam Backup & Replication managing console. You need to add the hosts to Veeam Backup & Replication to be able to manage your virtual infrastructure via Veeam Backup & Replication console. If a SMB3 host is part of a cluster, add the SMB3 cluster instead of standalone SMB3 host. Run Add-VBRSmbV3Cluster to add a Hyper-V cluster. When adding a new SMB3 host, you will need to provide either username and password or credentials. This cmdlet provides syntax for both scenarios accordingly. See what else you can perform on your virtual infrastructure instances

Parameters Parameter

Name

Description

Required

Position

Accept Pipeline Input

Accept Wildcard Characters

Specifies the string with the DNS name of the added SMB3 host.

True

Named

False

False

Specifies the user name you want to use for authenticating with the SMB3 host. User

If you use the Username/Password scenario, the -Credentials parameter must be omitted.

True

Named

False

False

Password

Specifies the password you

True

Named

False

False

85 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Parameter

Description

Required

Position

Accept Pipeline Input

Accept Wildcard Characters

False

Named

False

False

True

Named

False

False

want to use for authenticating with the SMB3 host. If you use the Username/Password scenario, the -Credentials parameter must be omitted. Specifies the description of the SMB3 host. Description

If not set, Veeam Backup & Replication will enter date and time of creation by default. Specifies the credentials you want to use for authenticating with the SMB3 host.

Credentials

If you use the Credentials scenario, the -User and Password parameters must be omitted.

This cmdlet supports Microsoft PowerShell common parameters. For more information about common parameters, see http://go.microsoft.com/fwlink/p/?LinkID=113216.

Example 1 This command adds a new SMB3 host named "SMBShare010" using username and password. The user name is "Administrator", and the password is "Password". The description is "Hyper-V SMB Share Cluster 01". Add-VBRSmbV3Cluster -Name "SMBShare010" -User "Administrator" Password "Password" -Description "Hyper-V SMB Share Host 010"

Example 2 This command adds a new SMB3 host named "SMBShare010" using credentials. The credentials object is obtained with Get-VBRCredentials and assigned to the $Administrator variable beforehand. The description is "Hyper-V SMB Share Cluster 01". Add-VBRHvCluster -Name "SMBShare010" -Description "Hyper-V SMB Share Host 010" -Credentials $Administrator

86 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Add-VBRTapeFilesJob Short Description Creates a new files to tape copy job.

Applies to Version: 7.0 Platform: VMware, Hyper-V

Syntax Add-VBRTapeFilesJob [-Name ] -Server -Path -MediaPool [-MediaPoolIncremental ] [-Description ] [-Credentials ] [-Masks ] [-IgnoreCase] [-WarningAction ] [-WarningVariable ] []

Related Commands Get-VBRServer Get-VBRTapeMediaPool Get-VBRCredentials

Detailed Description This cmdlet creates a new job copying files from Veeam Backup & Replication to tape. The tape job looks for changes in the specified files that have been made from the moment of the last tape job run. Please note that when you create a copy job, you need to run it manually. Run Start-VBRJob to start the created job. See what else you can perform on tapes

Parameters Parameter

Name

Description

Required

Position

Accept Pipeline Input

Accept Wildcard Characters

Specifies the name you want to assign to the new files to tape copy job.

False

Named

False

False

True

Named

False

False

Named

True (ByValue, ByProperty Name)

False

You can input string up to 255 symbols. Server

Path

Specifies the source server where the files you need are located. Specifies the path to the folder(s) you need to copy. Use -Masks and IgnoreCase parameters to select particular files.

True

You can specify multiple

87 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Parameter

Description

Required

Position

Accept Pipeline Input

Accept Wildcard Characters

names separated by commas. MediaPool

Specifies the target media pool that will be used for full backups.

True

Named

False

False

MediaPool Incremental

Specifies the target media pool that will be used for incremental backups.

False

Named

False

False

Description

Specifies the description for the new files to tape copy job.

False

Named

False

False

Credentials

Specifies the credentials you want to use for authenticating with the source server.

False

Named

False

False

False

Named

False

False

False

Named

False

False

Masks

Used to specify search conditions for -Path paramater. Specifies masks to select files in folders.

IgnoreCase

Used to specify search conditions for -Path paramater. If set, the search by name will be non case sensitive.

This cmdlet supports Microsoft PowerShell common parameters. For more information about common parameters, see http://go.microsoft.com/fwlink/p/?LinkID=113216.

88 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Example 1 This command creates a new files to tape copy job named "Contacts Copy Job". The source server containing the files to be copied is obtained with Get-VBRServer and assigned to the $server variable. The target media pools for full backups and incremental backups are obtained with GetVBRTapeMediaPool and assigned to $full and $increment variables beforehand accordingly. The source file path is D:\Users\UserInfo\Contacts.xls. Add-VBRTapeFilesJob -Name "Contacts Copy Job" -Server $server Path "D:\Users\UserInfo\Contacts.xls" -MediaPool $full MediaPoolIncremental $increment

Example 2 This command creates a new files to tape copy job named "Agreements Copy Job" copying .pdf files from the "Signed" folder. The source server containing the files to be copied is obtained with GetVBRServer and assigned to the $server variable. The target media pools for full backups and incremental backups are obtained with Get-VBRTapeMediaPool and assigned to $full and $increment variables beforehand accordingly. The source file path is D:\Agreements\Signed. The mask for selecting files to copy is ".pdf". Add-VBRTapeFilesJob -Name "Agreements Copy Job" -Server $server Path "D:\Agreements\Signed" -MediaPool $full MediaPoolIncremental $increment -Description "Agreements File Copy Job" -Credentials $Administrator -Masks *.pdf

89 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Add-VBRTapeMediaPool Short Description Creates a new media pool.

Applies to Version: 7.0 Platform: VMware, Hyper-V

Syntax Add-VBRTapeMediaPool [-Name ] [-Medium ] [Library ] [-MoveFromFree] [-Description ] [WarningAction ] [-WarningVariable ] []

Related Commands Get-VBRTapeMedium Get-VBRTapeLibrary

Detailed Description This cmdlet creates a new custom media pool in a tape library. Media pool is a logical group of tapes. Media pools are pre-defined service pools and custom pools used as targets for backup to tape and files to tape jobs. You can assign specific media pools to certain tape jobs. It is recommended to write the full and incremental backups to separate dedicated media pools to achieve better data recoverability. You can select the replenishment strategy for the media pool. You can either choose to always refill the media pool with clean tapes from the Free media pool, or to overwrite the oldest tape recorded. To replenish the media pool, indicate the -MoveFromFree option. See what else you can perform on tapes

Parameters Parameter

Name

Medium

Description

Required

Position

Accept Pipeline Input

Accept Wildcard Characters

Specifies the name you want to assign to the media pool. If not set, the media pool name will be set by default.

False

Named

False

False

False

Named

True (ByValue, ByProperty Name)

False

False

Named

True (ByValue, ByProperty

False

Specifies the tape(s) you want to include to the media pool. You can assign multiple tapes to this object.

Library

Specifies the tape library where you want to create media pool.

90 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Parameter

Description

Required

Position

Accept Pipeline Input

Accept Wildcard Characters

Name)

Move FromFree

If set, the media pool will be refilled with tapes from Free pool automatically. Otherwise, the job will overwrite the oldest tape when the media pool is out of clean tapes.

False

Named

False

False

Description

Specifies the description for the created media pool.

False

Named

False

False

This cmdlet supports Microsoft PowerShell common parameters. For more information about common parameters, see http://go.microsoft.com/fwlink/p/?LinkID=113216.

Example 1 This command creates a media pool named "FullBackups". The tapes that should be included in the media pool are obtained with Get-VBRTapeMedium by selecting the first 10 tapes from the Free media pool, and piped down. The library object is obtained with Get-VBRTapeMediaPool and assigned to $lib variable beforehand. The description of the new media pool is "Full backups media pool". The MoveFromFree parameter is not set to enable the overwrite replenishment strategy. Get-VBRTapeMedium -Free | Select -First 10 | Add-VBRTapeMediaPool -Name "FullBackups" -Library $lib -Description "Full backups media pool"

Example 2 This command creates a media pool named FullBackups. The description of the new media pool is "Full backups media pool". First the tape and library objects are got and assigned to $tape and $lib variables accordingly. The -MoveFromFree parameter is set to enable the replenishment of media pool with the clean tapes. Add-VBRTapeMediaPool -Name FullBackups -Medium $tape -Library $lib -MoveFromFree -Description "Full backups media pool"

91 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Add-VBRTapeVMJob Short Description Creates a new backup to tape copy job.

Applies to Version: 7.0 Platform: VMware, Hyper-V

Syntax Add-VBRTapeVMJob [-Name ] [-Repository ] [-BackupJob ] -MediaPool [-MediaPoolIncremental ] [DisableIncremental] [-HardwareCompression] [-Description ] [-WarningAction ] [-WarningVariable ] []

Related Commands Get-VBRTapeMediaPool Get-VBRBackupRepository Get-VBRJob

Detailed Description This cmdlet creates a new job that copies VM backups to tape. To be able to create a backup to tape copy job, you need to have existing backups available. You can copy VM backups in two ways: •

From backup jobs: the tape job looks for backup files that have been produced by the specified backup job from the moment of the last tape job run,



From backup repository: the tape job looks for all VM backups that have written to the specified backup repository from the moment of the last tape job run.

Please note that when you create a copy job, you need to run it manually. Run Start-VBRJob to start the created job. See what else you can perform on tapes

Parameters Description

Required

Position

Accept Pipeline Input

Accept Wildcard Characters

Name

Specifies the name you want to assign to the VM to tape copy job.

False

Named

False

False

Repository

Specifies the source backup repository you want to use as the source for the VM backups.

Named

True (ByValue, ByProperty Name)

False

Parameter

False

92 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Parameter

Description

Position

Accept Pipeline Input

Accept Wildcard Characters

False

Named

True (ByValue, ByProperty Name)

False

True

Named

False

False

False

Named

False

False

False

Named

False

False

False

Named

False

False

False

Named

False

False

Required

You can assign multiple backup repositories to this object.

BackupJob

Specifies the backup job you want to use as the source for the VM backups. You can assign multiple backup jobs to this object.

MediaPool

Specifies the target media pool you want to use for full backups. You can input string up to 255 symbols.

MediaPool Incremental

Specifies the target media pool you want to use for incremental backups. If set, the tape job will copy only the full backup files. Otherwise, the incremental backups will be written to the media pool set in the MediaPoolIncremental.

Disable Incremental

Please be careful to set this parameter in case you do not want to store the incremental backups on tape. If it is not set, the incremental backups will be written to the media pool you set for the full backups. Enables hardware compression option.

Hardware Compression

Description

Please note that if you plan to use hardware compression when recording backups to tape, consider that although it decreases traffic, this option affects performance. Specifies the description of the new VM to tape copy job.

This cmdlet supports Microsoft PowerShell common parameters. For more information about common parameters, see http://go.microsoft.com/fwlink/p/?LinkID=113216.

93 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Example 1 This command creates a job named "CRM Backup Copy to Tape" copying files from the backup job named "CRM Backup" to tape. The backup job is obtained with Get-VBRJob and piped down. The target media pools for full backups and incremental backups are obtained with GetVBRTapeMediaPool and assigned to $full and $increment variables beforehand accordingly. The job description is "CRM Backup Copy to Tape". Get-VBRJob -Name "CRM Backup" | Add-VBRTapeVMJob -Name "CRM Backup Copy to Tape" - MediaPool $full -MediaPoolIncremental $increment -Description "CRM Backup Copy to Tape"

Example 2 This command creates a job named "Local Backup Copy to Tape" copying files from the backup repository named "Local Repository 01" to tape. The backup repository is obtained with GetVBRBackupRepository and piped down. The target media pools for full backups is obtained with GetVBRTapeMediaPool and assigned to $full variable beforehand. The incremental backups are not written to tape. The hardware compression option is enabled. Get-VBRBackupRepository -Name "Local Repository 01" | AddVBRTapeVMJob -Name "Local Backup Copy to Tape" - MediaPool $full -DisableIncremental -HardwareCompression

Example 3 This command creates a job named "Local Backup Copy to Tape" copying files from the backup repository represented by the $repository variable. The backup repository is obtained with GetVBRBackupRepository and assigned to the variable beforehand. The target media pools for full backups is obtained with Get-VBRTapeMediaPool and assigned to $full variable beforehand. The incremental backups are not written to tape. Add-VBRTapeVMJob -Name "Local Backup Copy to Tape" -Repository $repository -MediaPool $full -DisableIncremental

94 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Add-VBRvCenter Short Description Adds a vCenter Server to Veeam Backup & Replication.

Applies to Version: 7.0 and earlier Platform: VMware

Syntax Add-VBRvCenter [-Name] [-User] [-Password] [-Port ] [-Description ] [-WarningAction ] [-WarningVariable ] [] -ORAdd-VBRvCenter [-Name] [-Port ] [-Description ] -Credentials [-WarningAction ] [-WarningVariable ] []

Related Commands Get-VBRCredentials

Detailed Description This cmdlet allows you to add a vCenter Server to Veeam Backup & Replication. See what else you can perform on your virtual infrastructure instances

Parameters Parameter

Name

Description

Required

Position

Accept Pipeline Input

Accept Wildcard Characters

Specifies the string with a full DNS name or IP address of the vCenter Server.

True

1

False

False

True

2

False

False

True

3

False

False

Specifies the user name you want to use for authenticating with the vCenter server. User

Please note that the user name should be in "DOMAIN\USERNAME" format. If you use the Username/Password scenario, the -Credentials parameter must be omitted.

Password

Specifies the password you want to use for authenticating with the vCenter server. If you use the

95 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Parameter

Description

Required

Position

Accept Pipeline Input

Accept Wildcard Characters

True

Named

False

False

False

Named

False

False

False

Named

False

False

Username/Password scenario, the -Credentials parameter must be omitted. Specifies the credentials you want to use for authenticating with the vCenter server. Credentials

Port

If you use the Credentials scenario, the -User and Password parameters must be omitted. Sets the integer specifying the number of Web service port used to connect to the vCenter Server. By default, port 443 is used. Specifies the description of the vCenter server.

Description

If not set, Veeam Backup & Replication will enter date and time of creation by default.

This cmdlet supports Microsoft PowerShell common parameters. For more information about common parameters, see http://go.microsoft.com/fwlink/p/?LinkID=113216.

Example 1 This command adds the vCenter server named "vcdev25.domain.local" using a username and a password. The user name is "Administrator" and the password is "Password". Add-VBRvCenter -Name "vcdev25.domain.local" -User "Domain\Administrator" -Password "Password" -Description "vcdev25 vCenter Server"

Example 2 This command adds the vCenter server named "vcdev25.domain.local" using credentials. The credentials record is obtained with Get-VBRCredentials and assigned to the $"Linux Administrator" variable beforehand. Add-VBRvCenter -Name "vcdev25.domain.local" -Description "vcdev25 vCenter Server" -Credentials $"vcdev Administrator"

96 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Add-VBRvCloud Short Description Adds a vCloud Director server to Veeam Backup & Replication.

Applies to Version: 7.0 Platform: VMware

Syntax Add-VBRvCloud [-Name] [-User] [-Password] [-Url ] [-Description ][] -ORAdd-VBRvCloud [-Name] -Credentials [-Url ] [-Description ][]

Related Commands Get-VBRCredentials

Detailed Description This cmdlet adds a new vCloud Director server to Veeam Backup & Replication. When adding a new vCloud Director server you will need to provide either username/password or credentials. This cmdlet provides syntax for both scenarios accordingly. See what else you can perform on vCloud

Parameters Parameter

Name

User

Password

Description

Required

Position

Accept Pipeline Input

Accept Wildcard Characters

Specifies the full DNS name or IP address of the vCloud Director server or any cell in the vCloud Director infrastructure.

True

0

False

False

True

1

False

False

True

2

False

False

Specifies the user name you want to use for authenticating with the vCloud Director server. If you use the Username/Password scenario, the -Credentials parameter must be omitted. Specifies the password you want to use for authenticating with the vCloud Director server. If you use the

97 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Parameter

Description

Required

Position

Accept Pipeline Input

Accept Wildcard Characters

True

Named

False

False

Username/Password scenario, the -Credentials parameter must be omitted.

Credentials

Specifies the credentials you want to use for authenticating with the vCloud Director server. If you use the Credentials scenario, the -User and Password parameters must be omitted.

Url

Specifies the URL you want to connect to the vCloud Director Web API with.

False

Named

False

False

Description

Specifies the description of the new vCloud Director server. If not set, the user name who created the server and the date and time of creation will be added by default.

False

Named

False

False

This cmdlet supports Microsoft PowerShell common parameters. For more information about common parameters, see http://go.microsoft.com/fwlink/p/?LinkID=113216.

Example 1 This command creates a new server named "vCloud Director Server" having the https://vclouddirectorserver:443 URL address. The username is "Administrator" and the password is "password". Add-VBRvCloud -Name "vCloud Director Server" -User Administrator -Password password -Url https://vclouddirectorserver:443 Description "vCloud Director Server"

Example 2 This command creates a new server named "vCloud Director Server" having the https://vclouddirectorserver:443 URL address. The credentials are obtained with Get-VBRCredentials and assigned to the $Administrator variable beforehand. The -Description parameter is not set to get the default description created. Add-VBRvCloud -Name "vCloud Director Server" -Credentials $Administrator -Url https://vclouddirectorserver:443

98 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Add-VBRvCloudBackupCopyJob Short Description Creates a vCloud backup copy job.

Applies to Version: 7.0 Platform: VMware

Syntax Add-VBRvCloudBackupCopyJob [-Name ] [-Entity ] [-Backup ] [-BackupJob ][-Repository ] -SourceAccelerator TargetAccelerator [-Description ] [WarningAction ] [-WarningVariable ] [] -ORAdd-VBRvCloudBackupCopyJob [-Name ] [-Entity ] [-Backup ] [-BackupJob ][-Repository ] -DirectOperation [-Description ] [WarningAction ][-WarningVariable ] []

Related Commands Get-VBRBackup Get-VBRJob Get-VBRBackupRepository Get-VBRWANAccelerator

Detailed Description This cmdlet creates a new vCloud backup copy job. The backup copy job is copying backup files from the source backup repository to the target backup repository. The backup copy job runs continuously synchronizing the backup repositories in userdefined time periods. The cmdlet provides two scenarios that can be used for on-site and off-site modes: •

To transfer the data efficiently to to the off-site location, you can use the WAN accelerator technology. WAN accelerator is a backup infrastructure component that optimizes file transfer via WAN by means of data deduplication. The role of a WAN accelerator can be assigned to a dedicated Windows-based machine (physical or virtual). For best performance you should set a WAN accelerator on both source and target sides. This mode is recommended for off-site backups. To create and run a backup copy job using WAN accelerators you need to have source and target WAN accelerators created. Run Add-VBRWANAccelerator to create a WAN accelerator.



You can create a backup copy job using direct operation. With this method, the job sends the data directly to the target backup repository without performing data deduplication. This mode is recommended for on-site backups, or off-site backups using fast connections.

99 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Please note that the backup copy job is created in disabled state. Run Enable-VBRJob to start the job running on the defined schedule. See what else you can perform on vCloud See what else you can perform on backup copy Note:

WAN optimization is available only in Veeam Backup & Replication Enterprise Plus Edition.

Parameters Parameter

Name

Description

Required

Position

Accept Pipeline Input

Accept Wildcard Characters

Specifies the name you want to assign to the backup copy job.

False

Named

False

False

Named

True (ByValue, ByProperty Name)

False

Named

True (ByValue, ByProperty Name)

False

False

Named

True (ByValue, ByProperty Name)

False

False

Named

False

False

True

Named

False

False

True

Named

False

False

You can input string up to 255 symbols.

Entity

Backup

Specifies the VM(s) you want to copy. You can assign multiple VMs to this object. Specifies the existing backup from where the VMs to copy are derived.

False

False

You can assign multiple backups to this object.

BackupJob

Specifies the existing backup job from where the VMs to copy are derived. You can assign multiple backup jobs to this object.

Repository

Source Accelerator

Target Accelerator

Specifies the backup repository to where you want to copy the VM data. If not set, Veeam Backup & Replication will use the default backup repository. Specifies the WAN accelerator on the source side. If you select the mode using WAN accelerators, the DirectOperation parameter should be omitted. Specifies the WAN accelerator on the target side. If you select the mode using WAN accelerators, the DirectOperation parameter should be omitted.

100 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Parameter

Description

Required

Position

Accept Pipeline Input

Accept Wildcard Characters

False

Named

False

False

False

Named

False

False

Specifies the description of the backup copy job. Description

Direct Operation

If not set, Veeam Backup & Replication will enter date and time of creation by default. Enables the direst operation method sending the data directly to the target backup repository without performing data deduplication. If you select the direct operation mode, the TargetAccelerator and SourceAccelerator parameters should be omitted.

This cmdlet supports Microsoft PowerShell common parameters. For more information about common parameters, see http://go.microsoft.com/fwlink/p/?LinkID=113216.

Example 1 This command creates a backup copy job named "vCloud CopyJob1" with the following parameters: •

The source and target WAN accelerators are obtained with Get-VBRWANAccelerator and assigned to $wansource and $wantarget variables accordingly beforehand,



The VMs to copy are obtained with Find-VBRvCloudEntity and assigned to the $vms variable beforehand,



The repository to where the VM data will be copied is obtained with GetVBRBackupRepository and assigned to the $repository variable beforehand.

Add-VBRvCloudBackupCopyJob -SourceAccelerator $wansource TargetAccelerator $wantarget -Name CopyJob1 -Entity $vms Repository $repository

Example 2 This command creates a direct backup copy job with the following parameters: •

The name of the job is "DC CopyJob",



The backup job named "DC Backup" with the VMs to be copied is obtained with GetVBRBackup and piped down,



The -Repository parameter is not set to copy the VMs to the default backup repository.

Get-VBRBackup -Name "DC Backup" | Add-VBRvCloudBackupCopyJob DirectOperation -Name "DC CopyJob"

101 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Add-VBRvCloudJob Short Description Creates a vCloud Director backup job.

Applies to Version: 7.0 Platform: VMware

Syntax Add-VBRvCloudJob -Entity [-Name ] [BackupRepository ] [-Description ] []

Related Commands Find-VBRvCloudEntity Get-VBRBackupRepository

Detailed Description This cmdlet creates a new vCloud Director backup job. You should always use vCD backup jobs to back up VMs managed by vCloud Director. If you back up VMs managed by vCloud Director using a regular backup job, Veeam Backup & Replication will perform backup at the level of the underlying vCenter Server and will not capture vApp metadata. As a result, you will not let you restore a fully functioning VM to vCloud Director. Please note that when you create a backup job, you need to run it manually unless you enable a job schedule. Run Start-VBRJob to start the created job. Run Set-VBRJobSchedule to set schedule for the job. See what else you can perform on vCloud

Parameters Parameter

Entity

Name

Description Specifies the VM(s) you want to backup. You can assign multiple VMs to this object. Specifies the name you want to assign to the backup job.

Required

Position

Accept Pipeline Input

True

Named

True

False

False

Named

False

False

102 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Accept Wildcard Characters

Parameter

Description

Required

Position

Accept Pipeline Input

Accept Wildcard Characters

Backup Repository

Specifies the backup repository object where the backup files will be stored. If not set, the files will be stored in Veeam Backup & Replication default backup repository.

False

Named

False

False

Description

Specifies the description of the new backup job.

False

Named

False

False

This cmdlet supports Microsoft PowerShell common parameters. For more information about common parameters, see http://go.microsoft.com/fwlink/p/?LinkID=113216.

Example 1 This command creates a new vCloud Director backup job with the following parameters: •

Job name: "vCD Backup Job 1".



$vm: the VM to backup.



$brepository: the backup repository to store the backup files.



Description: "vCloud Director Backup Job".

Add-VBRvCloudJob -Entity $vm -Name "vCD Backup Job" BackupRepository $brepository -Description "vCloud Director Backup Job"

Example 2 This command creates a new vCloud Director backup job with the following parameters: •

Job name: "vCD Backup Job 2".



Description: "vCloud Director Backup Job".



The VM named "vCloud Server" is obtained with Find-VBRvCloudEntity and piped down.



The -BackupRepository parameter is not set to enable use of the default backup repository.

Find-VBRvCloudEntity -Name "vCloud Server" | Add-VBRvCloudJob Name "vCD Backup Job 2" -Description "vCloud Director Backup Job"

103 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Add-VBRvCloudVC Short Description Adds vCenter Server managed by vCloud Director to Veeam Backup & Replication.

Applies to Version: 7.0 Platform: VMware

Syntax Add-VBRvCloudVC [-vCloudServer] [-VCInfo] [User] [-Password] [-Name ] [-Port ] [-Description ] [] -ORAdd-VBRvCloudVC [-vCloudServer] [-VCInfo] Credentials [-Name ] [-Port ] [Description ] []

Related Commands Get-VBRServer Find-VBRvCloudEntity Get-VBRCredentials

Detailed Description This cmdlet adds a new vCenter server to Veeam Backup & Replication console. The vCenter server is registered as a part of vCloud Director . When adding a new vCenter server, you will need to provide either username and password or credentials. This cmdlet provides syntax for both scenarios accordingly. See what else you can perform on vCloud

Parameters Parameter

Description

vCloudServer

Specifies the vCloud server you want to connect a vCenter to.

VCInfo

Specifies the vCenter server you want to connect to the vCloud.

User

Specifies the user name you want to use for authenticating with the vCenter server.

Position

Accept Pipeline Input

Accept Wildcard Characters

True

0

True (ByValue, ByProperty Name)

False

True

1

False

False

True

2

False

False

Required

If you use the Username/Password

104 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Parameter

Description

Required

Position

Accept Pipeline Input

Accept Wildcard Characters

True

3

False

False

True

Named

False

False

False

Named

False

False

False

Named

False

False

False

Named

False

False

scenario, the -Credentials parameter must be omitted. Specifies the password you want to use for authenticating with the vCenter server. Password

Credentials

Name

If you use the Username/Password scenario, the -Credentials parameter must be omitted. Specifies the credentials you want to use for authenticating with the vCenter server. If you use the Credentials scenario, the -User and Password parameters must be omitted. Specifies the DNS name or IP address of the vCenter server you want to connect. Specifies the web-service port number. If not set, the default port number 443 will be used.

Port

Description

IMPORTANT: When you customize the port number, you should make sure that you set this port on the vCenter Server/ESX(i) host settings first. Specifies the description of the vCenter server. If not set, the default description containing the username of the user who created the record and date and time of creation will be used.

This cmdlet supports Microsoft PowerShell common parameters. For more information about common parameters, see http://go.microsoft.com/fwlink/p/?LinkID=113216.

105 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Example 1 This command adds a new vCenter server with the following parameters: •

The vCenter will be registered on the server with 172.16.1.13 IP address. The server object is piped to the cmdlet.



The $vc variable contains the new vCenter server object.



The username is "Administrator" and the password is "Password".



The new vCenter name is "vCenter Server 1".



The -Port parameter is not set to enable the default 443 web-service port number.



The -Description parameter is not set to enable the default description.

Get-VBRServer -Name 172.16.1.13 | Add-VBRvCloudVC -VCInfo $vc User Administrator -Password Password -Name "vCenter Server 1"

Example 2 This command adds a new vCenter server with the following parameters: •

The server where the new vCenter will be registered is represented by $s variable.



The $vc variable contains the new vCenter server object.



The $creds variable contains the Administrator credentials record.



The new vCenter name is "vCenter Server 2".



The -Port parameter is set to 456 to set the connection through web-service port number 456 instead of default 443 port.



The -Description parameter is not set to enable the default description.

Add-VBRvCloudVC -vCloudServer $s -VCInfo $vc -Credentials $creds -Name "vCenter Server 2" -Port 456

106 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Add-VBRViBackupCopyJob Short Description Creates a VMware backup copy job.

Applies to Version: 7.0 Platform: VMware For Hyper-V. run Add-VBRHvBackupCopyJob.

Syntax Add-VBRViBackupCopyJob -SourceAccelerator TargetAccelerator [-Name ][-Entity ] [-Backup ][-BackupJob ] [Repository ][-Description ][] -ORAdd-VBRViBackupCopyJob -DirectOperation [-Name ] [-Entity ] [-Backup ] [-BackupJob ] [Repository ] [-Description ] []

Related Commands Get-VBRWANAccelerator Find-VBRViEntity Get-VBRBackup Get-VBRJob Get-VBRBackupRepository

Detailed Description This cmdlet creates a new VMware backup copy job. The backup copy job is copying backup files from the source backup repository to the target backup repository. The backup copy job runs continuously synchronizing the backup repositories in userdefined time periods. The cmdlet provides two scenarios that can be used for on-site and off-site modes: •

To transfer the data efficiently to to the off-site location, you can use the WAN accelerator technology. WAN accelerator is a backup infrastructure component that optimizes file transfer via WAN by means of data deduplication. The role of a WAN accelerator can be assigned to a dedicated Windows-based machine (physical or virtual). For best performance you should set a WAN accelerator on both source and target sides. This mode is recommended for off-site backups. To create and run a backup copy job using WAN accelerators you need to have source and target WAN accelerators created. Run Add-VBRWANAccelerator to create a WAN accelerator.



You can create a backup copy job using direct operation. With this method, the job sends the data directly to the target backup repository without performing data deduplication. This mode is recommended for on-site backups, or off-site backups using fast connections.

107 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Please note that the backup copy job is created in disabled state. Run Enable-VBRJob to start the job running on the defined schedule. See what else you can perform on backup copy Note:

WAN optimization is available only in Veeam Backup & Replication Enterprise Plus Edition.

Parameters Parameter

Source Accelerator

Target Accelerator

Direct Operation

Name

Description

Required

Position

Accept Pipeline Input

Accept Wildcard Characters

True

Named

False

False

True

Named

False

False

True

Named

False

False

Named

True (ByValue, ByProperty Name)

False

Named

True (ByValue, ByProperty Name)

False

False

Named

True (ByValue, ByProperty Name)

False

False

Named

True (ByValue,

False

Specifies the WAN accelerator on the source side. If you select the mode using WAN accelerators, the DirectOperation parameter should be omitted. Specifies the WAN accelerator on the target side. If you select the mode using WAN accelerators, the DirectOperation parameter should be omitted. Enables direst operation method sending the data directly to the target backup repository without performing data deduplication. If you select the direct operation mode, the TargetAccelerator and SourceAccelerator parameters should be omitted. Specifies the name you want to assign to the backup copy job.

False

You can input string up to 255 symbols.

Entity

Backup

Specifies the VM you want to copy. You can assign multiple VMs to this object. Specifies the existing backup(s) to set the VMs you want to copy.

False

You can assign multiple backups to this object. BackupJob

Specifies the existing backup job(s) to set the VMs you

108 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Parameter

Description

Required

Position

want to copy.

Repository

If not set, Veeam Backup & Replication will use the default backup repository.

Accept Wildcard Characters

ByProperty Name)

You can assign multiple backup jobs to this object. Specifies the backup repository to where you want to copy the VM data.

Accept Pipeline Input

False

Named

False

False

False

Named

False

False

Specifies the description of the backup copy job. Description

If not set, Veeam Backup & Replication will enter date and time of creation by default.

This cmdlet supports Microsoft PowerShell common parameters. For more information about common parameters, see http://go.microsoft.com/fwlink/p/?LinkID=113216.

Example 1 This command creates a backup copy job named "CopyJob1" with the following parameters: •

The source and target WAN accelerators are obtained with Get-VBRWANAccelerator and assigned to $wansource and $wantarget variables accordingly beforehand,



The VMs to copy are obtained with Find-VBRViEntity and assigned to the $vms variable beforehand,



The repository to where the VM data will be copied is obtained with GetVBRBackupRepository and assigned to the $repository variable beforehand.

Add-VBRViBackupCopyJob -SourceAccelerator $wansource TargetAccelerator $wantarget -Name CopyJob1 -Entity $vms Repository $repository

Example 2 This command creates a direct backup copy job with the following parameters: •

The name of the job is "DC CopyJob",



The backup job named "DC Backup" with the VMs to be copied is obtained with GetVBRBackup and piped down,



The -Repository parameter is not set to copy the VMs to the default backup repository.

Get-VBRBackup -Name "DC Backup" | Add-VBRViBackupCopyJob DirectOperation -Name "DC CopyJob"

109 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Add-VBRViBackupJob Short Description Creates VMware backup job.

Applies to Version: 7.0 and earlier Platform: VMware For Hyper-V, run Add-VBRHvBackupJob.

Syntax Add-VBRViBackupJob [-Name ] [-BackupRepository ] -Entity [-Description ] [-WarningAction ] [-WarningVariable ] []

Related Commands Get-VBRBackupRepository Find-VBRViEntity

Detailed Description This cmdlet allows you to create a new VMware backup job. Please note that when you create a backup job, you need to run it manually unless you enable a job schedule. Run Start-VBRJob to start the created job. Run Set-VBRJobSchedule to set schedule for the job. See what else you can perform on jobs

Parameters Description

Required

Position

Accept Pipeline Input

Accept Wildcard Characters

Name

Specifies the string with the name of the created backup job.

False

Named

False

False

Backup Repository

Specifies the backup repository where the created backup should be stored.

False

Named

False

False

True

Named

True (ByValue, ByProperty Name)

False

False

Named

False

False

Parameter

Entity

Description

Specifies the VM(s) that you want to back up. You can assign multiple VMs to this object. Specifies the description of the backup job. If not set, Veeam Backup &

110 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Parameter

Description

Required

Position

Accept Pipeline Input

Accept Wildcard Characters

Replication will enter date and time of creation by default.

This cmdlet supports Microsoft PowerShell common parameters. For more information about common parameters, see http://go.microsoft.com/fwlink/p/?LinkID=113216.

Example This command creates a backup job named "Exchange Backup". The VMs to backup are obtained with Find-VBRViEntity and piped down. The backup repository is obtained with Get-VBRBackupRepository and assigned to the $Repository variable beforehand. the description is "VMware Exchange Backup". Find-VBRViEntity -Name Exchange* | Add-VBRHvBackupJob -Name "Exchange Backup" -BackupRepository $Repository -Description "VMware Exchange Backup"

111 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Add-VBRViJobObject Short Description Adds a VM to a job.

Applies to Version: 7.0 Platform: VMware For Hyper-V, run Add-VBRHvJobObject.

Syntax Add-VBRViJobObject -Job -Entities [WarningAction ] [-WarningVariable ] []

Related Commands Get-VBRJob Find-VBRViEntity

Detailed Description This cmdlet allows to add VM(s) to an existing job. You can run this cmdlet with any kind of jobs. See what else you can perform on job objects

Parameters Parameter

Job

Entities

Description Specifies the job you want to add the VM(s) to. You can assign multiple backup jobs to this object. Specifies the vM(s) you want to add to the job. You can assign multiple VMs to this object.

Required

Position

Accept Pipeline Input

True

Named

False

False

Named

True (ByValue, ByProperty Name)

False

True

Accept Wildcard Characters

This cmdlet supports Microsoft PowerShell common parameters. For more information about common parameters, see http://go.microsoft.com/fwlink/p/?LinkID=113216.

112 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Example 1 This command adds a VM named "VM01" to the job represented by $job variable. First the job object is got and assigned to $job variable.The VM object is piped down. Find-VBRViEntity -Name VM01 | Add-VBRHvJobObject -Job $job

Example 2 This command adds a VM represented by $Vm variable to the job represented to $job variable. The variables are assigned beforehand. Add-VBRViJobObject -Job $job -Entities $Vm

113 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Add-VBRViProxy Short Description Adds a VMware backup proxy to Veeam Backup & Replication.

Applies to Version: 7.0 and earlier Platform: VMware For Hyper-V, run Add-VBRHvProxy.

Syntax Add-VBRViProxy -Server [-Description ] [-MaxTasks ] [-WarningAction ] [-WarningVariable ] []

Related Commands Get-VBRServer

Detailed Description This cmdlet adds a VMware backup proxy server to Veeam Backup & Replication managing console. In the backup infrastructure, the backup proxy actually performs main data handling – retrieving data, processing it and transferring to the target destination. Use of backup proxies enables you to take the job processing off the backup server and allows for better scalability of your backup infrastructure. See what else you can perform on your virtual proxies When you add a proxy, you set a role to a server. To add a new proxy, you need to have the server added to your Veeam Backup & Replication managing console. Run Add-VBRESX or Add-VBRESXi to add a VMware server.

Parameters Parameter

Server

Description

Specifies the server which will act as a VMware backup proxy.

Position

Accept Pipeline Input

Accept Wildcard Characters

True

Named

True (ByValue, ByProperty Name)

False

False

Named

False

False

False

Named

False

False

Required

Specifies the description of the VMware proxy. Description

MaxTasks

If not set, Veeam Backup & Replication will enter date and time of creation by default. Sets the integer specifying the number of concurrent tasks that can be assigned to the proxy simultaneously. If not set, the number of

114 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Parameter

Description

Required

Position

Accept Pipeline Input

Accept Wildcard Characters

tasks will be set to 2 by default.

This cmdlet supports Microsoft PowerShell common parameters. For more information about common parameters, see http://go.microsoft.com/fwlink/p/?LinkID=113216.

Example 1 This command adds a new proxy. The server that will act as the proxy is obtained with Get-VBRServer and piped down. The description is "Local Backup Proxy". The max concurrent tasks number is set to 6. Get-VBRServer -Name "VMware Local Server" | Add-VBRViProxy Description "Local Backup Proxy" -MaxTasks 6

Example 2 This command adds a new proxy. The server that will act as the proxy is obtained with Get-VBRServer and assigned to the $server variable. The description is "Local Backup Proxy". The max concurrent tasks number is not set to enable the default value. Add-VBRViProxy -Server $server -Description "Local Backup Proxy"

115 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Add-VBRViReplicaJob Short Description Adds new VMware replication job.

Applies to Version: Platform: VMware For Hyper-V, run Add-VBRHvReplicaJob.

Syntax Add-VBRViReplicaJob [-Name ] -Server -Entity [-Datastore ][-ResourcePool ] [-Folder ] [-Suffix ] [-BackupRepository ] [-Description ] [-WarningAction ] [-WarningVariable ] []

Related Commands Get-VBRJob Find-VBRViEntity Find-VBRViDatastore Find-VBRViResourcePool Find-VBRViFolder Get-VBRBackupRepository

Detailed Description This cmdlet allows you to create a new VMware replication job. Replication is a process of copying a VM from its primary location (source host) to a destination location (redundant target host). Veeam Backup & Replication creates an exact copy of a VM (replica), registers it on the target host and maintains it in synch with the original VM. Please note that when you create a replica job, you need to run it manually unless you enable a job schedule. Run Start-VBRJob to start the created job. Run Set-VBRJobSchedule to set schedule for the job. See what else you can perform on jobs See what else you can perform on replicas

116 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Parameters Parameter

Description

Required

Position

Accept Pipeline Input

Accept Wildcard Characters

Name

Specifies the string with the name of the created replication job.

False

Named

False

False

Server

Specifies the host where the created replica should be stored.

True

Named

False

False

True

Named

True (ByValue, ByProperty Name)

False

Entity

Specifies the VM(s) that you want to replicate. You can assign multiple VMs to this object.

Datastore

Specifies the datastore to which you want to replicate.

False

Named

False

False

ResourcePool

Specifies the resource pool to which you want to replicate.

False

Named

False

False

Folder

Specifies the folder to which you want to replicate.

False

Named

False

False

Suffix

Specifies the suffix that will be appended to the name of the VM you are replicating. This name will be used to register the replicated VM on the target server.

False

Named

False

False

Backup Repository

Specifies the backup repository which will be used to store replica metadata files.

False

Named

False

False

False

Named

False

False

Specifies the description of the new job. Description

If not set, Veeam Backup & Replication will enter date and time of creation by default.

This cmdlet supports Microsoft PowerShell common parameters. For more information about common parameters, see http://go.microsoft.com/fwlink/p/?LinkID=113216.

117 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Example 1 This command adds a new job named "DC Replication Job" replicating a VM named "DC". The VM to replicate is obtained with Find-VBRViEntity and piped down. The server and the resource pool to locate the replica are obtained with Get-VBRServer and Find-VBRViResourcePool and assigned to the $server and $pool variables accorgingly beforehand. The replica is created with the suffix "_replica". The description of the job is "DC Replication Job". Find-VBRViEntity -Name "DC" | Add-VBRViReplicaJob -Name "DC Replication Job" -Server $server -ResourcePool $pool -Suffix "_replica"

Example 2 This command adds a new job named "DC Replication Job" replicating a VM represented by the $vm variable. The VM to replicate is obtained with Find-VBRViEntity and assigned to the variable beforehand. The server where the replica will reside is obtained with Get-VBRServer and assigned to the $server variable beforehand. The datastore and the resource pool to locate the replica are obtained with Find-VBRViDatastore and Find-VBRViResourcePool and assigned to the $datastore and $pool variables accorgingly beforehand. The replica is created with the suffix "_replica". The description of the job is "DC Replication Job". Add-VBRViReplicaJob -Name "DC Replication Job" -Server $server Entity $vm -Datastore $datastore -ResourcePool $pool -Suffix "_replica" -Description "DC Replication Job"

118 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Add-VBRWANAccelerator Short Description Creates a new WAN accelerator.

Applies to Version: 7.0 Platform: VMware, Hyper-V Note:

WAN optimization is available only in Veeam Backup & Replication Enterprise Plus Edition.

Syntax Add-VBRWANAccelerator -Server [-Description ] [CachePath ] [-CacheSize ] [-CacheSizeUnit ] [-WarningAction ] [WarningVariable ] []

Related Commands Get-VBRServer

Detailed Description This cmdlet creates a new WAN accelerator. WAN accelerator is an architecture component that optimizes file transfer via WAN by means of data deduplication. The role of a WAN accelerator can be assigned to a dedicated Windows-based machine (physical or virtual). For best performance you should set a WAN accelerator on both source and target sides. See what else you can perform on backup copy

Parameters Parameter

Description

Required

Position

Accept Pipeline Input

Accept Wildcard Characters

False

Server

Specifies the server where WAN accelerator will be created. Please note that you can create WAN accelerator on Microsoft Windows servers only.

True

Named

True (ByValue, ByProperty Name)

Description

Specifies the description of the WAN accelerator.

False

Named

False

False

CachePath

Specifies the path to the folder where WAN accelerator will be created.

False

Named

False

False

CacheSize

Specifies the cache folder capacity value in UInt32 format. Accepted values: 1 to 65535.

False

Named

False

False

119 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Parameter

CacheSize Unit

Description

Required

Position

Accept Pipeline Input

Accept Wildcard Characters

Specifies the measure unit for the cache folder capacity. The valid values are GB and TB.

False

Named

False

False

This cmdlet supports Microsoft PowerShell common parameters. For more information about common parameters, see http://go.microsoft.com/fwlink/p/?LinkID=113216.

Example This command creates a new WAN accelerator with the following parameters: •

The $s variable contains the server where the WAN accelerator will be created.



The description of the new WAN accelerator is "BackupWANAccelerator".



The -CachePath parameter sets the folder where the new WAN accelerator will be created.



The cache size capacity is set to 100GB.

Add-VBRWANAccelerator -Server $s -Description BackupWANAccelerator -CachePath "c:\wan" -CacheSize 100 CacheSizeUnit GB

120 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Add-VBRWinServer Short Description Adds Windows server to Veeam Backup & Replication.

Applies to Version: 7.0 and earlier Platform: VMware

Syntax Add-VBRWinServer -Name -User -Password [-Description ] [-WarningAction ] [WarningVariable ] [] -ORAdd-VBRWinServer -Name [-Description ] Credentials [-WarningAction ] [WarningVariable ] []

Related Commands Get-VBRCredentials

Detailed Description This cmdlet allows you to add a Windows server to Veeam Backup & Replication managing console. When adding a new Windows server, you will need to provide either username and password or credentials. This cmdlet provides syntax for both scenarios accordingly. See what else you can perform on your virtual infrastructure instances

Parameters Parameter

Name

Description Specifies the string with the DNS name of the Windows server you want to add.

Required

Position

Accept Pipeline Input

Accept Wildcard Characters

True

Named

False

False

True

Named

False

False

True

Named

False

False

Specifies the user name you want to use for authenticating with the Windows server. User

Password

If you use the Username/Password scenario, the -Credentials parameter must be omitted. Specifies the password you want to use for authenticating with the Windows server. If you use the Username/Password scenario, the -Credentials parameter

121 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Parameter

Description

Required

Position

Accept Pipeline Input

Accept Wildcard Characters

False

Named

False

False

True

Named

False

False

must be omitted. Specifies the description of the Windows server. Description

If not set, Veeam Backup & Replication will enter date and time of creation by default. Specifies the credentials you want to use for authenticating with the Windows server.

Credentials

If you use the Credentials scenario, the -User and Password parameters must be omitted.

This cmdlet supports Microsoft PowerShell common parameters. For more information about common parameters, see http://go.microsoft.com/fwlink/p/?LinkID=113216.

Example 1 This command adds a new Windows server named "WinServer" using username and password. The user name is "Administrator", and the password is "Password". The description is "Windows File Server". Add-VBRWinServer -Name "WinServer" -User Administrator -Password Password -Description "Windows File Server"

Example 2 This command adds a new Windows server named "WinServer" using credentials. The credentials object is obtained with Get-VBRCredentials and assigned to the $Administrator variable beforehand. The description is "Windows File Server". Add-VBRWinServer -Name "WinServer" -Credentials $Administrator Description "Windows File Server"

122 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Add-VSBApplicationGroup Short Description Creates a VMware application group for SureBackup job. Note:

In Backup & Replication v6 this cmdlet was replaced by Add-VSBViApplicationGroup and AddVSBHvApplicationGroup due to multihypervisor support introduced in the new version. The cmdlet will still work but it is advised to rewrite your scripts using new cmdlets for added benefits.

Applies to Version: 7.0 and earlier Platform: VMware

Syntax Add-VSBApplicationGroup [-Name] [-Vm] [WarningAction ] [-WarningVariable ] [] -ORAdd-VSBApplicationGroup [-Name] [-RestorePoint] [-WarningAction ] [-WarningVariable ] []

Related Commands Get-VBRRestorePoint

Detailed Description This cmdlet creates a new VMware application group. An application group is a component of SureBackup technology providing verification of virtual machines that need other virtual machines or services running, i.e. a domain controller, a DSN server or SQL database. To test such machines for recoverability, you need to create a SureBackup job and provide the copy of the production architecture running in a fenced-off environment that is performed by creating a virtual lab and an application group. The VMs in the application group are started first to ensure the proper testing environment for the primary VM. Please note that you can set the order the VMs in the application group will be powered on when the SureBackup job starts. This may be important if any of the applications must be started prior to other. The VMs are powered in the order they were added to the VM object in this cmdlet. See what else you can perform on SureBackup

123 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Parameters Parameter

Name

Description

Required

Position

Accept Pipeline Input

Accept Wildcard Characters

Specifies the string with the name you want to assign to the application group.

True

1

False

False

2

True (ByValue, ByProperty Name)

False

2

True (ByValue, ByProperty Name)

False

Specifies the VM(s) you want to include into the application group.

Vm

True

You can assign multiple VMs to this object.

RestorePoint

Specifies the restore points of VMs that should be added to the application group.

True

You can assign multiple restore points to this object.

This cmdlet supports Microsoft PowerShell common parameters. For more information about common parameters, see http://go.microsoft.com/fwlink/p/?LinkID=113216.

Example This example allows you to create an application group with the following parameters: •

Application group name: AppGroup



Variable which contains objects of VMs to be added to the group: $vms

Add-VSBApplicationGroup –Name “AppGroup”–VM $vms

124 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Add-VSBHvApplicationGroup Short Description Creates a Hyper-V application group for SureBackup job.

Applies to Version: 7.0 Platform: Hyper-V For VMware, run Add-VSBViApplicationGroup.

Syntax Add-VSBHvApplicationGroup [-Name ] [-VmFromBackup ] [-RestorePoint ] [-WarningAction ] [-WarningVariable ] []>]

Related Commands Find-VBRHvEntity Get-VBRRestorePoint

Detailed Description This cmdlet creates a new Hyper-V application group. An application group is a component of SureBackup technology providing verification of virtual machines that need other virtual machines or services running, i.e. a domain controller, a DSN server or SQL database. To test such machines for recoverability, you need to create a SureBackup job and provide the copy of the production architecture running in a fenced-off environment that is performed by creating a virtual lab and an application group. The VMs in the application group are started first to ensure the proper testing environment. Please note that you can set the order the VMs in the application group will be powered on when the SureBackup job starts. This may be important if any of the applications must be started prior to other. The VMs are powered in the order they were added to the VM object in this cmdlet, i.e. in order you searched for VMs with Find-VBRHvEntity. This cmdlet provides two scenarios. You can add VMs to your application group either by searching for existing VMs or by adding a restore point containing the VMs you need. Run Add-VSBHvVirtualLab to create a virtual lab. Run Add-VSBHvJob to create a SureBackup Job. See what else you can perform on SureBackup

125 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Parameters Parameter

Name

VmFrom Backup

RestorePoint

Description Specifies the name you want to assign to the application group. Specifies the VM(s) you want to add to the application group.

Required

Position

Accept Pipeline Input

Accept Wildcard Characters

False

Named

False

False

Named

True (ByValue, ByProperty Name)

False

Named

True (ByValue, ByProperty Name)

False

True

You can assign multiple VMs to this object. Specifies the restore points of the VMs you want to add to the application group. You can assign multiple restore points to this object.

True

This cmdlet supports Microsoft PowerShell common parameters. For more information about common parameters, see http://go.microsoft.com/fwlink/p/?LinkID=113216.

Example 1 This command creates a new application group named "Exchange Appgroup".The VMs that should be included into the application group are obtained with Find-VBRHvEntity and piped down. The VMs are obtained in the order they must boot when the SureBackup job starts. Find-VBRHvEntity -Name "DC", "DNSServer" | AddVSBHvApplicationGroup -Name "Exchange Appgroup"

Example 2 This command creates a new application group "MailServer Appgroup". The restore point object is obtained with Get-VBRRestorePoint and assigned to the variable beforehand. Add-VSBHvApplicationGroup -Name "MailServer Appgroup" RestorePoint $restorepoint

126 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Add-VSBHvJob Short Description Creates a Hyper-V SureBackup job.

Applies to Version: 7.0 Platform: Hyper-V For VMware, run Add-VSBJob.

Syntax Add-VSBHvJob [-Name ] -VirtualLab [AppGroup ] [-LinkedJob ] [-Description ] [-WarningAction ] [-WarningVariable ] []

Related Commands Get-VSBHvVirtualLab Get-VSBApplicationGroup Get-VBRJob

Detailed Description This cmdlet adds a new Hyper-V SureBackup job. SureBackup is a Veeam recovery verification technology providing verification of virtual machines that need other virtual machines or services running, i.e. a domain controller, a DSN server or SQL database. To test such machines for recoverability, you need to create a SureBackup job and provide the copy of the production architecture running in a fenced-off environment that is performed by creating a virtual lab and an application group. The VMs in the application group are started first to ensure the proper testing environment. Run Add-VSBHvVirtualLab to create a virtual lab. Run Add-VSBHvApplicationGroup to create an application group. You can use a linked job to bring the target VM(s) to the job, or an application group containing the required VMs, or a combination of both according to your virtual infrastructure objectives: •

If you need to verify several different VMs in same environment: create an application group that can be reused by several SureBackup jobs, providing a multi-use copy of the production environment. In this case, use the linked job to create a SureBackup job for each VM or a group of VMs that you want to verify.



If you need to verify only one VM or one group of VMs, or if each VM to verify requires its own environment: include the VM(s) you want to verify right into the application group. Within the application group, you can set the VM startup order, see AddVSBHvApplicationGroup for details.



If the VMs you want to verify do not require any specific environment: select the VM(s) to verify with the linked job, and indicate the virtual lab to use for verification. You do not need to create an application group in this case.

Please note that when you create a SureBackup job, you need to run it manually unless you enable a job schedule.

127 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Run Start-VSBJob to start the created SureBackup job. Run Set-VSBJobScheduleOptions to set schedule for the SureBackup job. See what else you can perform on SureBackup See what else you can perform on jobs

Parameters Description

Required

Position

Accept Pipeline Input

Accept Wildcard Characters

Name

Specifies the name you want to assign to the Sure Backup job.

False

Named

False

False

VirtualLab

Specifies the virtual lab you want to use for verification.

Named

True (ByValue, ByProperty Name)

False

Named

True (ByValue, ByProperty Name)

False

False

Named

True (ByValue, ByProperty Name)

False

False

Named

False

False

Parameter

AppGroup

Specifies the application group you want to use to provide the copy of the production environment of the verified VM.

True

False

If you do not use an application group, make sure that the -LinkedJob parameter is set. Specifies the backup, replication or copy job containing the VM you want to verify. LinkedJob

If you do not use a linked backup job, make sure that the -AppGroup parameter is set. You can assign multiple backup jobs to this object.

Description

Specifies the description of the new SureBackup job.

This cmdlet supports Microsoft PowerShell common parameters. For more information about common parameters, see http://go.microsoft.com/fwlink/p/?LinkID=113216.

128 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Example 1 This command creates a new Sure Backup job named "Exchange SureJob" using a virtual lab, an application group and a linked job. The VM to verify is obtained by searching for the backup job named "Exchange Backup Job" with Get-VBRJob, and piped down. The virtual lab and the application group objects are obtained with Get-VSBHvVirtualLab and Get-VSBApplicationGroup and assigned to $VLab01 and $"Exchange Appgroup" variables accordingly beforehand. Get-VBRJob -Name "Exchange Backup Job" | Add-VSBHvJob -Name "Exchange SureJob" -VirtualLab $VLab01 -AppGroup $"Exchange Appgroup"

Example 2 This command creates a new Sure Backup job named "Exchange SureJob" using a virtual lab, an application group and a linked job. The virtual lab and application group objects are obtained with Get-VSBHvVirtualLab and Get-VSBApplicationGroup and assigned to $VLab01 and $"Exchange Appgroup" variables accordingly beforehand. Add-VSBHvJob -Name "Exchange SureJob" -VirtualLab $VLab01 AppGroup $"Exchange Appgroup"

Example 3 This command creates a new Sure Backup job named "Exchange SureJob" using a virtual lab and an application group. The virtual lab object is obtained with Get-VSBHvVirtualLab and piped down. The VM to verify is included into the application group, the application group object is obtained with GetVSBApplicationGroup and assigned to the $"Exchange Appgroup" variable beforehand. Get-VSBHvVirtualLab -Name "Exchange VLab 01" | Add-VSBHvJob -Name "Exchange SureJob" -AppGroup $"Exchange Appgroup"

Example 4 This command creates a new Sure Backup job named "Exchange SureJob" using a virtual lab and a linked job. The virtual lab object is obtained with Get-VSBHvVirtualLab and assigned to $VLab01 variable beforehand. The VM to verify is obtained with Get-VBRJob and assigned to the $"Exchange Backup" variable beforehand. Add-VSBHvJob -Name "Exchange SureJob" -VirtualLab $VLab01 LinkedJob $"Exchange Backup"

129 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Add-VSBHvVirtualLab Short Description Creates a Hyper-V virtual lab.

Applies to Version: 7.0 Platform: Hyper-V For VMware, run Add-VSBVirtualLab.

Syntax Add-VSBHvVirtualLab -Name -Server -Folder [-WarningAction ] [-WarningVariable ] []

Related Commands Get-VBRServer

Detailed Description This cmdlet creates a new Hyper-V virtual lab. A virtual lab is a component of SureBackup technology providing verification of virtual machines that need other virtual machines or services running, i.e. a domain controller, a DSN server or SQL database. To test such machines for recoverability, you need to create a SureBackup job and provide the copy of the production architecture running in a fenced-off environment that is performed by creating a virtual lab and an application group. Run Add-VSBHvApplicationGroup to create an application group. Run Add-VSBHvJob to create a SureBackup job. See what else you can perform on SureBackup

Parameters Description

Required

Position

Accept Pipeline Input

Accept Wildcard Characters

Name

Specifies the name you want to assign to the virtual lab.

True

Named

False

False

Server

Specifies the Hyper-V host where the virtual lab should be created.

True

Named

False

False

Folder

Specifies the path to the folder where the redo log files of the virtual lab will be stored.

True

Named

False

False

Parameter

This cmdlet supports Microsoft PowerShell common parameters. For more information about common parameters, see http://go.microsoft.com/fwlink/p/?LinkID=113216.

130 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Example This command creates a new virtual lab named "Exchange VLab 01". The server where the virtual lab will be located is obtained with Get-VBRServer and assigned to the $server variable beforehand. The folder path to store the redo files is c:\VirtualLabs. Add-VSBHvVirtualLab -Name "Exchange VLab 01" -Server $server Folder "c:\VirtualLabs"

131 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Add-VSBJob Short Description Creates a VMware SureBackup job.

Applies to Version: 7.0 and earlier Platform: VMware For Hyper-V, run Add-VSBHvJob.

Syntax Add-VSBJob [[-Name] ] -VirtualLab [AppGroup ] [-LinkedJob ] [-Description ] [-WarningAction ] [-WarningVariable ] []

Related Commands Get-VSBVirtualLab Get-VSBApplicationGroup Get-VBRJob

Detailed Description This cmdlet creates a new VMware SureBackup job. SureBackup is a Veeam recovery verification technology providing verification of virtual machines that need other virtual machines or services running, i.e. a domain controller, a DSN server or SQL database. To test such machines for recoverability, you need to create a SureBackup job and provide the copy of the production architecture running in a fenced-off environment that is performed by creating a virtual lab and an application group. The VMs in the application group are started first to ensure the proper testing environment. Run Add-VSBVirtualLab to create a virtual lab. Run Add-VSBViApplicationGroup to create an application group. You can use a linked job to bring the target VM(s) to the job, or an application group containing the required VMs, or a combination of both according to your virtual infrastructure objectives: •

If you need to verify several different VMs in same environment: create an application group that can be reused by several SureBackup jobs, providing a multi-use copy of the production environment. In this case, use the linked job to create a SureBackup job for each VM or a group of VMs that you want to verify.



If you need to verify only one VM or one group of VMs, or if each VM to verify requires its own environment: include the VM(s) you want to verify right into the application group. Within the application group, you can set the VM startup order, see AddVSBViApplicationGroup for details.



If the VMs you want to verify do not require any specific environment: select the VM(s) to verify with the linked job, and indicate the virtual lab to use for verification. You do not need to create an application group in this case.

Please note that when you create a SureBackup job, you need to run it manually unless you enable a job schedule.

132 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Run Start-VSBJob to start the created SureBackup job. Run Set-VSBJobScheduleOptions to set schedule for the SureBackup job. See what else you can perform on SureBackup See what else you can perform on jobs

Parameters Description

Required

Position

Accept Pipeline Input

Accept Wildcard Characters

Name

Specifies the name you want to assign to the SureBackup job.

False

Named

False

False

VirtualLab

Specifies the virtual lab you want to use for verification.

Named

True (ByValue, ByProperty Name)

False

Named

True (ByValue, ByProperty Name)

False

False

Named

True (ByValue, ByProperty Name)

False

False

Named

False

False

Parameter

AppGroup

Specifies the application group you want to use to provide the copy of the production environment of the verified VM.

True

False

If you do not use an application group, make sure that the -LinkedJob parameter is set. Specifies the backup, replication or copy job containing the VM you want to verify. LinkedJob

If you do not use a linked backup job, make sure that the -AppGroup parameter is set. You can assign multiple backup jobs to this object.

Description

Specifies the description of the new SureBackup job.

This cmdlet supports Microsoft PowerShell common parameters. For more information about common parameters, see http://go.microsoft.com/fwlink/p/?LinkID=113216.

133 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Example 1 This command creates a new Sure Backup job named "Exchange SureJob" using a virtual lab, an application group and a linked job. The VM to verify is obtained by searching for the backup job named "Exchange Backup Job" with Get-VBRJob, and piped down. The virtual lab and the application group objects are obtained with Get-VSBVirtualLab and Get-VSBApplicationGroup and assigned to $VLab01 and $"Exchange Appgroup" variables accordingly beforehand. Get-VBRJob -Name "Exchange Backup Job" | Add-VSBJob -Name "Exchange SureJob" -VirtualLab $VLab01 -AppGroup $"Exchange Appgroup"

Example 2 This command creates a new Sure Backup job named "Exchange SureJob" using a virtual lab, an application group and a linked job. The virtual lab and application group objects are obtained with Get-VSBVirtualLab and Get-VSBApplicationGroup and assigned to $VLab01 and $"Exchange Appgroup" variables accordingly beforehand. Add-VSBJob -Name "Exchange SureJob" -VirtualLab $VLab01 -AppGroup $"Exchange Appgroup"

Example 3 This command creates a new Sure Backup job named "Exchange SureJob" using a virtual lab and an application group. The virtual lab object is obtained with Get-VSBVirtualLab and piped down. The VM to verify is included into the application group, the application group object is obtained with GetVSBApplicationGroup and assigned to the $"Exchange Appgroup" variable beforehand. Get-VSBVirtualLab -Name "Exchange VLab 01" | Add-VSBJob -Name "Exchange SureJob" -AppGroup $"Exchange Appgroup"

Example 4 This command creates a new Sure Backup job named "Exchange SureJob" using a virtual lab and a linked job. The virtual lab object is obtained with Get-VSBVirtualLab and assigned to $VLab01 variable beforehand. The VM to verify is obtained with Get-VBRJob and assigned to the $"Exchange Backup" variable beforehand. Add-VSBJob -Name "Exchange SureJob" -VirtualLab $VLab01 LinkedJob $"Exchange Backup"

134 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Add-VSBViApplicationGroup Short Description Creates an application group for SureBackup job.

Applies to Version: 7.0 Platform: VMware For Hyper-V, run Add-VSBHvApplicationGroup.

Syntax Add-VSBViApplicationGroup -Name -Vm [WarningAction ][-WarningVariable ] [] -ORAdd-VSBViApplicationGroup -Name -RestorePoint [-WarningAction ][-WarningVariable ] []

Related Commands Find-VBRViEntity Get-VBRRestorePoint

Detailed Description This cmdlet returnes a new application group containing virtual machines that the application server is dependent on. An application group is a component of SureBackup technology providing verification of virtual machines that need other virtual machines or services running, i.e. a domain controller, a DSN server or SQL database. To test such machines for recoverability, you need to create a SureBackup job and provide the copy of the production architecture running in a fenced-off environment that is performed by creating a virtual lab and an application group. The VMs in the application group are started first to ensure the proper testing environment. Please note that you can set the order the VMs in the application group will be powered on when the SureBackup job starts. This may be important if any of the applications must be started prior to other. The VMs are powered in the order they were added to the VM object in this cmdlet, i.e. in order you searched for VMs with Find-VBRViEntity. This cmdlet provides two scenarios. You can add VMs to your application group either by searching for existing VMs or by adding a restore point containing the VMs you need. Run Add-VSBVirtualLab to create a virtual lab. Run Add-VSBJob to create a SureBackup Job. See what else you can perform on SureBackup

135 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Parameters Parameter

Name

Vm

Description Specifies the name you want to assign to the application group. Specifies the VM(s) you want to add to the application group.

Required

Position

Accept Pipeline Input

Accept Wildcard Characters

False

Named

False

False

Named

True (ByValue, ByProperty Name)

False

Named

True (ByValue, ByProperty Name)

False

True

You can assign multiple VMs to this object.

RestorePoint

Specifies the restore points of the VMs you want to add to the application group. You can assign multiple restore points to this object.

True

This cmdlet supports Microsoft PowerShell common parameters. For more information about common parameters, see http://go.microsoft.com/fwlink/p/?LinkID=113216.

Example 1 This command creates a new application group named "Exchange Appgroup". The VMs that should be included into the application group are obtained with Find-VBRViEntity and piped down. The VMs are obtained in the order they must boot when the SureBackup job starts. Find-VBRViEntity -Name "DC", "DNSServer" | AddVSBHvApplicationGroup -Name "Exchange Appgroup"

Example 2 This command creates a new application group "MailServer Appgroup". The restore point object is obtained with Get-VBRRestorePoint and assigned to the variable beforehand. Add-VSBViApplicationGroup -Name "MailServer Appgroup" RestorePoint $restorepoint

136 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Add-VSBVirtualLab Short Description Creates a VMware virtual lab.

Applies to Version: 7.0 and earlier Platform: VMware For Hyper-V, run Add-VSBHvVirtualLab.

Syntax Add-VSBVirtualLab [-Name] [-Server] [-Datastore] [-WarningAction ] [WarningVariable ] []

Related Commands Get-VBRServer Find-VBRViDatastore

Detailed Description This cmdlet creates a new VMware virtual lab. A virtual lab is a component of SureBackup technology providing verification of virtual machines that need other virtual machines or services running, i.e. a domain controller, a DSN server or SQL database. To test such machines for recoverability, you need to create a SureBackup job and provide the copy of the production architecture running in a fenced-off environment that is performed by creating a virtual lab and an application group. Run Add-VSBViApplicationGroup to create an application group. Run Add-VSBJob to create a SureBackup job. See what else you can perform on SureBackup

Parameters Parameter

Description

Required

Position

Accept Pipeline Input

Accept Wildcard Characters

Name

Specifies the string with the name you want to assign to the virtual lab.

True

1

False

False

Server

Specifies the ESX(i) host where the virtual lab should be created.

True

2

False

False

Datastore

Specifies the datastore on which redo logs for tested VMs should be stored.

True

3

False

False

137 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

This cmdlet supports Microsoft PowerShell common parameters. For more information about common parameters, see http://go.microsoft.com/fwlink/p/?LinkID=113216.

Example This command creates a new virtual lab named "Exchange VLab 01". The server where the virtual lab will be located is obtained with Get-VBRServer and assigned to the $server variable beforehand. The datastore to store the redo files is obtained with Find-VBRViDatastore and assigned to the $datastore variable beforehand. Add-VSBVirtualLab -Name "Exchange VLab 01" -Server $server Datastore $datastore

138 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Clear-VBRWANCache Short Description Removes data from WAN accelerator global cache.

Applies to Version: 7.0 Platform: VMware, Hyper-V

Syntax Clear-VBRWANCache -Accelerator [-WarningAction ] [-WarningVariable ] []

Related Commands Get-VBRWANAccelerator

Detailed Description This cmdlet clears WAN accelerator global cache. You may need to clear the global cache in case, i.e., the data gets corrupted.

Parameters Parameter

Description

Accelerator

Specifies the WAN accelerator you want to clear the cache of.

Required

True

Position

Accept Pipeline Input

Accept Wildcard Characters

Named

True (ByValue, ByProperty Name)

False

This cmdlet supports Microsoft PowerShell common parameters. For more information about common parameters, see http://go.microsoft.com/fwlink/p/?LinkID=113216.

139 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Example 1 This command clears cache of WAN accelerator named "WAN 01". The accelerator is obtained with Get-VBRWANAccelerator and piped down. Get-VBRWANAccelerator -Name "WAN 01" | Clear-VBRWANCache

Example 2 This command clears cache of the WAN accelerator represented by the $"accelerator01" variable. The accelerator is obtained with Get-VBRWANAccelerator and assigned to the variable beforehand. Clear-VBRWANCache -Accelerator $"accelerator01"

140 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Connect-VSBHvVirtualLab Short Description Connects an existing Hyper-V virtual lab.

Applies to Version: 7.0 Platform: Hyper-V For VMware, run Connect-VSBVirtualLab.

Syntax Connect-VSBHvVirtualLab [-VirtualLab] [WarningAction ] [-WarningVariable ] []

Related Commands Find-VSBHvVirtualLab

Detailed Description This cmdlet connects an existing Hyper-V virtual lab to Veeam Backup & Replication console. When you add a new host to your Veeam Backup & Replication console, the virtual labs that are registered on it are not added automatically. Use this cmdlet to add the virtual labs to your Veeam Backup & Replication console. A virtual lab is a component of SureBackup technology providing verification of virtual machines that need other virtual machines or services running, i.e. a domain controller, a DSN server or SQL database. To test such machines for recoverability, you need to create a SureBackup job and provide the copy of the production architecture running in a fenced-off environment that is performed by creating a virtual lab and an application group. See what else you can perform on SureBackup

Parameters Parameter

Description

VirtualLab

Specifies the virtual lab you want to connect to your Veeam Backup & Replication console.

Required

True

Position

Accept Pipeline Input

Accept Wildcard Characters

1

True (ByValue, ByProperty Name)

False

This cmdlet supports Microsoft PowerShell common parameters. For more information about common parameters, see http://go.microsoft.com/fwlink/p/?LinkID=113216.

141 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Example 1 This command connects a virtual lab named "Exchange VLab 01". The virtual lab to connect is obtained with Find-VSBHvVirtualLab by looking for the specific virtual lab by name on the server represented by the $server variable. The server object is obtained with Get-VBRServer and assigned to the variable beforehand. Find-VSBHvVirtualLab -Server $server -Name "Exchange VLab 01" | Connect-VSBHvVirtualLab

Example 2 This command connects a virtual lab represented by the $VLab01 variable. The virtual lab object is obtained with Find-VSBHvVirtualLab and assigned to the variable beforehand. Connect-VSBHvVirtualLab -VirtualLab $VLab01

142 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Connect-VSBVirtualLab Short Description Connects an existing VMware virtual lab.

Applies to Version: 7.0 and earlier Platform: VMware For Hyper-V, run Connect-VSBHvVirtualLab.

Syntax Connect-VSBVirtualLab [-VirtualLab] [WarningAction ] [-WarningVariable ] []

Related Commands Find-VSBVirtualLab

Detailed Description This cmdlet connects an existing VMware virtual lab to Veeam Backup & Replication console. When you add a new host to your Veeam Backup & Replication console, the virtual labs that are registered on it are not added automatically. Use this cmdlet to add the virtual labs to your Veeam Backup & Replication console. A virtual lab is a component of SureBackup technology providing verification of virtual machines that need other virtual machines or services running, i.e. a domain controller, a DSN server or SQL database. To test such machines for recoverability, you need to create a SureBackup job and provide the copy of the production architecture running in a fenced-off environment that is performed by creating a virtual lab and an application group. See what else you can perform on SureBackup

Parameters Parameter

Description

VirtualLab

Specifies the virtual lab you want to connect.

Required

True

Position

Accept Pipeline Input

Accept Wildcard Characters

1

True (ByValue, ByProperty Name)

False

This cmdlet supports Microsoft PowerShell common parameters. For more information about common parameters, see http://go.microsoft.com/fwlink/p/?LinkID=113216.

143 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Example 1 This command connects a virtual lab named "Exchange VLab 01" to Veeam Backup & Replication. The server where the virtual lab is located is obtained with Get-VBRServer and assigned to the $server variable beforehand. Find-VSBVirtualLab -Server $server -Name "Exchange VLab 01" | Connect-VSBVirtualLab

Example 2 This command connects a virtual lab represented by the $VLab01 variable. The virtal lab object is obtained with Find-VSBVirtualLab and assigned to the variable beforehand. Connect-VSBVirtualLab -VirtualLab $VLab01

144 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Copy-VBRJob Short Description Clones an existing job.

Applies to Version: 7.0 and earlier Platform: VMware, Hyper-V

Syntax Copy-VBRJob [-Job] [-WarningAction ] [-WarningVariable ] []

Related Commands Get-VBRJob

Detailed Description This cmdlet clones an existing job. You can run this cmdlet with backup, replication and copy jobs. See what else you can perform on jobs Note:

Job cloning requires Veeam Backup & Replication Enterprise edition.

Parameters Parameter

Job

Description

Specifies the job you want to clone.

Required

True

Position

Accept Pipeline Input

Accept Wildcard Characters

0

True (ByValue, ByProperty Name)

False

This cmdlet supports Microsoft PowerShell common parameters. For more information about common parameters, see http://go.microsoft.com/fwlink/p/?LinkID=113216.

145 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Example 1 This command clones the jobs named "DHCP Replica Job" and "DHCP Backup Job". The jobs are obtained with Get-VBRJob and piped down. Get-VBRJob -Name "DHCP Replica Job", "DHCP Backup Job" | CopyVBRJob

Example 2 This command clones the job represented by the $job variable. The job is obtained with Get-VBRJob and assigned to the variable beforehand. Copy-VBRJob -Job $job

146 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Disable-VBRHvProxy Short Description Disables a Hyper-V backup proxy.

Applies to Version: 7.0 and earlier Platform: Hyper-V For VMware, run Disable-VBRViProxy.

Syntax Disable-VBRHvProxy -Proxy [-WarningAction ] [-WarningVariable ] []

Related Commands Get-VBRHvProxy

Detailed Description This cmdlet allows you to disable a Hyper-V backup proxy. The disabled proxy is not used by any job. See what else you can perform on your virtual proxies

Parameters Parameter

Proxy

Description Specifies the Hyper-V backup proxy you want to disable.

Required

True

Position

Accept Pipeline Input

Accept Wildcard Characters

Named

True (ByValue, ByProperty Name)

False

You can assign multiple proxies to this object.

This cmdlet supports Microsoft PowerShell common parameters. For more information about common parameters, see http://go.microsoft.com/fwlink/p/?LinkID=113216.

147 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Example 1 This command disables the selected Hyper-V proxy. The needed proxy object is obtained with GetVBRHvProxy by selecting the proxy with name containing "Hyper-V" and piped down. Get-VBRHvProxy -Name *Hyper-V* | Disable-VBRHvProxy

Example 2 This command disables the selected Hyper-V proxy represented by the $proxy variable. The proxy is obtained with Get-VBRHvProxy and assigned to the variable beforehand. Disable-VBRHvProxy -Proxy $proxy

148 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Disable-VBRJob Short Description Puts a selected job on hold.

Applies to Version: 7.0 Platform: VMware, Hyper-V

Syntax Disable-VBRJob -Job [-WarningAction ] [-WarningVariable ] []

Related Commands Get-VBRJob

Detailed Description This cmdlet puts a selected job on hold. The job and its settings are not deleted from Veeam Backup & Replication. You can enable the job at any time by running Enable-VBRJob. You can run this cmdlet with backup, replication and copy jobs. You cannot disable a SureBackup job. Run Stop-VBRJob to stop the job once without disabling it. See what else you can perform on jobs

Parameters Parameter

Job

Description Specifies the job you want to disable. You can assign multiple jobs to this object.

Required

True

Position

Accept Pipeline Input

Accept Wildcard Characters

Named

True (ByValue, ByProperty Name)

False

This cmdlet supports Microsoft PowerShell common parameters. For more information about common parameters, see http://go.microsoft.com/fwlink/p/?LinkID=113216.

149 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Example 1 This command disables jobs named "Backup Job 01" and "Backup Job 02".The jobs object is obtained with Get-VBRJob and piped down. Get-VBRJob -Name "Backup Job 01", "Backup Job 02" | DisableVBRJob

Example 2 This command disables the job represented by the $job variable. The job object is obtained with GetVBRJob and assigned to the variable beforehand. Disable-VBRJob -Job $job

150 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Disable-VBRJobGuestFSIndexing Short Description Disables job guest file system indexing option.

Applies to Version: 7.0 Platform: VMware, Hyper-V

Syntax Disable-VBRJobGuestFSIndexing [-Job] []

Related Commands Get-VBRJob

Detailed Description This cmdlet disables guest file system indexing in the selected job. The guest file system indexing settings are not deleted. Guest file system indexing is cataloging the guest VM files during the backup. Indexing helps you recognize files stored on guest VM. If you backup your VMs without guest file system indexing option, you will not be able to perform guest OS files restore. You can run this cmdlet with backup, replication and copy jobs. See what else you can perform on job options

Parameters Parameter

Job

Description Specifies the job you want to edit. You can assign multiple backup jobs to this object.

Required

True

Position

Accept Pipeline Input

Accept Wildcard Characters

1

True (ByValue, ByProperty Name)

False

This cmdlet supports Microsoft PowerShell common parameters. For more information about common parameters, see http://go.microsoft.com/fwlink/p/?LinkID=113216.

151 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Example 1 This command disables the guest file system indexing option in jobs named "Backup Job 01" and "Backup Job 02". The jobs object is obtained with Get-VBRJob and piped down. Get-VBRJob -Name "Backup Job 01", "Backup Job 02" | DisableVBRJobGuestFSIndexing

Example 2 This command disables the guest file system indexing option in the job represented by the $job variable. The job object is obtained with Get-VBRJob and assigned to the variable beforehand. Disable-VBRJobGuestFSIndexing -Job $job

152 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Disable-VBRJobSchedule Short Description Disables job schedule.

Applies to Version: 7.0 Platform: VMware, Hyper-V

Syntax Disable-VBRJobSchedule -Job [-WarningAction ] [-WarningVariable ][]

Related Commands Get-VBRJob

Detailed Description This cmdlet disables job schedule. The schedule settings are not deleted. When you disable a job schedule, you can launch the job manually by running Start-VBRJob. You can run this cmdlet with backup, replication and copy jobs. See what else you can perform on job options

Parameters Parameter

Job

Description Specifies the job(s) you want to disable. You can assign multiple backup jobs to this object.

Required

True

Position

Accept Pipeline Input

Accept Wildcard Characters

Named

True (ByValue, ByProperty Name)

False

This cmdlet supports Microsoft PowerShell common parameters. For more information about common parameters, see http://go.microsoft.com/fwlink/p/?LinkID=113216.

153 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Example 1 This command disables the job named "Backup Job 01". The job object is obtained with Get-VBRJob and piped down. Get-VBRJob -Name "Backup Job 01" | Disable-VBRJobSchedule

Example 2 This command disables the job represented by the $job variable. The job object is obtained with GetVBRJob and assigned to the variable beforehand. Disable-VBRJobSchedule -Job $job

154 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Disable-VBRJobVSSIntegration Short Description Disables job VSS settings.

Applies to Version: 7.0 Platform: VMware, Hyper-V

Syntax Disable-VBRJobVSSIntegration [-Job] [WarningAction ] [-WarningVariable ] []

Related Commands Get-VBRJob

Detailed Description This cmdlet disables the VSS settings in the selected job. The VSSs settings are not deleted form the job. VSS (Volume Shadow Services) is a Windows OS service allowing to copy files of running applications that can be modified at the moment of copying. The VSS-aware applications typically are Active Directory, Microsoft SQL, Microsoft Exchange, Sharepoint, etc. To create a transactionally consistent backup of a VM running VSS-aware applications without shutting them down, Veeam Backup & Replication uses application-aware image processing. It allows backup the data fully and consistently. You can run this cmdlet with backup, replication and copy jobs. See what else you can perform on job options

Parameters Parameter

Job

Description Specifies the job you want to edit. You can assign multiple jobs to this object.

Required

True

Position

Accept Pipeline Input

Accept Wildcard Characters

1

True (ByValue, ByProperty Name)

False

This cmdlet supports Microsoft PowerShell common parameters. For more information about common parameters, see http://go.microsoft.com/fwlink/p/?LinkID=113216.

155 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Example 1 This command disables the VSS options in jobs named "Backup Job 01" and "Backup Job 02". The jobs object is obtained with Get-VBRJob and piped down. Get-VBRJob -Name "Backup Job 01", "Backup Job 02" | DisableVBRJobVSSIntegration

Example 2 This command disables the VSS options in job represented by the $job variable. The job object is obtained with Get-VBRJob and assigned to the variable beforehand. Disable-VBRJobVSSIntegration -Job $job

156 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Disable-VBRViProxy Short Description Disables a VMware backup proxy.

Applies to Version: 7.0 and earlier Platform: VMware For Hyper-V, run Disable-VBRHvProxy.

Syntax Disable-VBRViProxy -Proxy [-WarningAction ] [-WarningVariable ] []

Related Commands Get-VBRViProxy

Detailed Description This cmdlet allows you to temporarily disable a VMware backup proxy. The disabled proxy is not used by any job. See what else you can perform on your virtual proxies

Parameters Parameter

Proxy

Description Specifies the VMware backup proxy you want to disable.

Required

True

Position

Accept Pipeline Input

Accept Wildcard Characters

Named

True (ByValue, ByProperty Name)

False

You can assign multiple proxies to this object.

This cmdlet supports Microsoft PowerShell common parameters. For more information about common parameters, see http://go.microsoft.com/fwlink/p/?LinkID=113216.

157 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Example 1 This command disables the selected VMware proxies named "VMware Backup Proxy 01", "VMware Backup Proxy 05". The proxies are obtained with Get-VBRViProxy by selecting by names and piped down. Get-VBRHvProxy -Name "VMware Backup Proxy 01", "VMware Backup Proxy 05" | Disable-VBRViProxy

Example 2 This command disables the selected VMware proxy represented by the $proxy variable. The proxy is obtained with Get-VBRViProxy and assigned to the variable beforehand. Disable-VBRViProxy -Proxy $proxy

158 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Eject-VBRTapeDrive Short Description Ejects tape from the selected media drive.

Applies to Version: 7.0 Platform: VMware, Hyper-V

Syntax Eject-VBRTapeDrive -Drive [-WarningAction ] [-WarningVariable ] []

Related Commands Get-VBRTapeDrive

Detailed Description This cmdlet ejects tape from the specified drive. The tape returns to its original slot. Run Eject-VBRTapeMedium to eject a specific tape from drive. Run Export-VBRTapeMedium to get a tape out of the library. See what else you can perform on tapes

Parameters Parameter

Drive

Description

Specifies the drive you want to eject.

Required

True

Position

Accept Pipeline Input

Accept Wildcard Characters

Named

True (ByValue, ByProperty Name)

False

This cmdlet supports Microsoft PowerShell common parameters. For more information about common parameters, see http://go.microsoft.com/fwlink/p/?LinkID=113216.

159 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Example 1 This command ejects the tape from the drive named "Drive01". The drive object is obtained with GetVBRTapeDrive and piped down. Get-VBRTapeDrive -Name "Drive01" | Eject-VBRTapeDrive

Example 2 This command ejects the tape from the drive represented by $drive variable. The drive object is obtained with Get-VBRTapeDrive and assigned to the variable beforehand. Eject-VBRTapeDrive -Drive $drive

160 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Eject-VBRTapeMedium Short Description Ejects tape from media drive.

Applies to Version: 7.0 Platform: VMware, Hyper-V

Syntax Eject-VBRTapeMedium -Medium [-WarningAction ] [-WarningVariable ] []

Related Commands Get-VBRTapeMedium

Detailed Description This cmdlet ejects the currently injected tape from the selected media drive. The tape returns to its original slot. Run Eject-VBRTapeDrive to eject a tape from a specific drive. See what else you can perform on tapes

Parameters Parameter

Medium

Description

Specifies the tape you want to eject.

Required

True

Position

Accept Pipeline Input

Accept Wildcard Characters

Named

True (ByValue, ByProperty Name)

False

This cmdlet supports Microsoft PowerShell common parameters. For more information about common parameters, see http://go.microsoft.com/fwlink/p/?LinkID=113216.

161 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Example 1 This command ejects the tapes containing the backup named "Fileserver Backup". The tapes containing the needed backup are obtained with Get-VBRTapeMedium and piped down. The backup is obtained with Get-VBRBackup and assigned to the $"Fileserver Backup" variable beforehand. Get-VBRTapeMedium -Backup $"Fileserver Backup" | EjectVBRTapeMedium

Example 2 This command ejects the tape represented by $tape variable. The tape object is obtained with GetVBRTapeMedium and assigned to the variable beforehand. Eject-VBRTapeMedium -Medium $tape

162 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Enable-VBRHvProxy Short Description Enables a Hyper-V backup proxy.

Applies to Version: 7.0 and earlier Platform: Hyper-V For VMware, run Enable-VBRViProxy.

Syntax Enable-VBRHvProxy -Proxy [-WarningAction ] [-WarningVariable ] []

Related Commands Get-VBRHvProxy

Detailed Description This cmdlet allows you to enable a Hyper-V backup proxy. See what else you can perform on your virtual proxies

Parameters Parameter

Proxy

Description Specifies then object of the Hyper-V backup proxy you want to enable.

Required

True

Position

Accept Pipeline Input

Accept Wildcard Characters

Named

True (ByValue, ByProperty Name)

False

You can assign multiple proxies to this object.

This cmdlet supports Microsoft PowerShell common parameters. For more information about common parameters, see http://go.microsoft.com/fwlink/p/?LinkID=113216.

163 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Example 1 This command enables all proxies with names starting with "Hyper-V Proxy 1...". The proxies are obtained with Get-VBRHvProxy by filtering with "*" search condition and piped down. Get-VBRHvProxy -Name "Hyper-V Proxy 1*" | Enable-VBRHvProxy

Example 2 This command enables the Hyper-V proxy represented by the $proxy variable. The needed proxy is obtained with Get-VBRHvProxy and assigned to the variable beforehand. Enable-VBRHvProxy -Proxy $proxy

164 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Enable-VBRJob Short Description Enables a disabled job.

Applies to Version: 7.0 Platform: VMware, Hyper-V

Syntax Enable-VBRJob -Job [-WarningAction ] [-WarningVariable ] a[]

Related Commands Get-VBRJob

Detailed Description This cmdlet enables a disabled job. When you disable a job, you put it on hold until you enable it with this cmdlet. You can disable a job by running Disable-VBRJob. You can run this cmdlet with backup, replication and copy jobs. Run Start-VBRJob to start a job once. See what else you can perform on jobs

Parameters Parameter

Job

Description Specifies the job you want to enable. You can assign multiple jobs to this object.

Required

True

Position

Accept Pipeline Input

Accept Wildcard Characters

Named

True (ByValue, ByProperty Name)

False

This cmdlet supports Microsoft PowerShell common parameters. For more information about common parameters, see http://go.microsoft.com/fwlink/p/?LinkID=113216.

165 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Example 1 This command enables the jobs named "Backup Job 01" and "Backup Job 02". The backup jobs are obtained with Get-VBRJob and piped down. Get-VBRJob -Name "Backup Job 01", "Backup Job 02" | Enable-VBRJob

Example 2 This command enables the job represented by the $job variable. The job object is obtained with GetVBRJob and assigned to the variable beforehand. Enable-VBRJob -Job $job

166 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Enable-VBRJobGuestFSIndexing Short Description Enables job guest file system indexing option.

Applies to Version: 7.0 Platform: VMware, Hyper-V

Syntax Enable-VBRJobGuestFSIndexing [-Job] [WarningAction ] [-WarningVariable ] []

Related Commands Get-VBRJob

Detailed Description This cmdlet enables guest file system indexing in the selected job. Guest file system indexing is cataloging the guest VM files during the backup. Indexing helps you recognize files stored on guest VM. If you backup your VMs without guest file system indexing option, you will not be able to perform guest OS files restore. You can enable the guest file system indexing settings in case you have these settings set beforehand. Use this cmdlet to enable the indexing option that was disabled with DisableVBRJobGuestFSIndexing. You can run this cmdlet with backup and replica jobs including vCloud jobs. See what else you can perform on job options

Parameters Parameter

Job

Description Specifies the job you want to edit. You can assign multiple jobs to this object.

Required

True

Position

Accept Pipeline Input

Accept Wildcard Characters

1

True (ByValue, ByProperty Name)

False

This cmdlet supports Microsoft PowerShell common parameters. For more information about common parameters, see http://go.microsoft.com/fwlink/p/?LinkID=113216.

167 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Example 1 This command enables the guest file system indexing option in jobs named "Backup Job 01" and "Backup Job 02". The jobs are obtained with Get-VBRJob and piped down. Get-VBRJob -Name Name "Backup Job 01", "Backup Job 02" | EnableVBRJobGuestFSIndexing

Example 2 This command enables the guest file system indexing option in the job represented by the $job variable. The job object is obtained with Get-VBRJob and assigned to the variable beforehand. Enable-VBRJobGuestFSIndexing -Job $job

168 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Enable-VBRJobSchedule Short Description Enables job schedule.

Applies to Version: 7.0 Platform: VMware, Hyper-V

Syntax Enable-VBRJobSchedule -Job [-WarningAction ][-WarningVariable ][]

Related Commands Get-VBRJob

Detailed Description This cmdlet enables job schedule. You can enable the job schedule in case you have the schedule set beforehand. Use this cmdlet to enable the job schedule that was disabled with Disable-VBRJobSchedule. You can run this cmdlet with any kind of jobs. See what else you can perform on job options

Parameters Parameter

Job

Description Specifies the job(s) you want to edit. You can assign multiple jobs to this object.

Required

True

Position

Accept Pipeline Input

Accept Wildcard Characters

Named

True (ByValue, ByProperty Name)

False

This cmdlet supports Microsoft PowerShell common parameters. For more information about common parameters, see http://go.microsoft.com/fwlink/p/?LinkID=113216.

169 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Example 1 This command enables the schedule for jobs named "Backup Job 01" and "File Copy Job 02". The jobs are obtained with Get-VBRJob and piped down. Get-VBRJob -Name "Backup Job 01", "File Copy Job 02" | EnableVBRJobSchedule

Example 2 This command enables the schedule for job represented by the $"Backup Job 01" variable. The job object is obtained with Get-VBRJob and assigned to the variable beforehand. Enable-VBRJobSchedule -Job $"Backup Job 01"

170 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Enable-VBRJobVSSIntegration Short Description Enables job VSS settings.

Applies to Version: 7.0 Platform: VMware, Hyper-V

Syntax Enable-VBRJobVSSIntegration [-Job] []

Related Commands Get-VBRJob

Detailed Description This cmdlet enables the VSS settings in the selected job. VSS (Volume Shadow Services) is a Windows OS service allowing to copy files of running applications that can be modified at the moment of copying. The VSS-aware applications typically are Active Directory, Microsoft SQL, Microsoft Exchange, Sharepoint, etc. To create a transactionally consistent backup of a VM running VSS-aware applications without shutting them down, Veeam Backup & Replication uses application-aware image processing. It allows backup the data fully and consistently. You can enable the VSS settings in case you have these settings set beforehand. Use this cmdlet to enable the VSS settings that were disabled with Disable-VBRJobVSSIntegration. You can run this cmdlet with backup and replica jobs including vCloud jobs. See what else you can perform on job options

Parameters Parameter

Job

Description Specifies the job you want to edit. You can assign multiple jobs to this object.

Required

True

Position

Accept Pipeline Input

Accept Wildcard Characters

1

True (ByValue, ByProperty Name)

False

This cmdlet supports Microsoft PowerShell common parameters. For more information about common parameters, see http://go.microsoft.com/fwlink/p/?LinkID=113216.

171 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Example 1 This command enables the VSS option in the job named "Backup Job 01" and "Backup Job 02". The jobs are obtained with Get-VBRJob and piped down. Get-VBRJob -Name "Backup Job 01", "Backup Job 02" | EnableVBRJobVSSIntegration

Example 2 This command enables the VSS option in the job represented by the $"Backup Job 01" variable. The job object is obtained with Get-VBRJob and assigned to the variable beforehand. Enable-VBRJobVSSIntegration -Job $"Backup Job 01"

172 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Enable-VBRViProxy Short Description Enables a VMware backup proxy.

Applies to Version: 7.0 and earlier Platform: VMware For Hyper-V, run Enable-VBRHvProxy.

Syntax Enable-VBRViProxy -Proxy [-WarningAction ] [-WarningVariable ] []

Related Commands Get-VBRViProxy

Detailed Description This cmdlet allows you to enable a VMware backup proxy. See what else you can perform on your virtual proxies

Parameters Parameter

Proxy

Description Specifies the VMware backup proxy you want to enable.

Required

True

Position

Accept Pipeline Input

Accept Wildcard Characters

0

True (ByValue, ByProperty Name)

False

You can assign multiple proxies to this object.

This cmdlet supports Microsoft PowerShell common parameters. For more information about common parameters, see http://go.microsoft.com/fwlink/p/?LinkID=113216.

173 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Example 1 This command enables the selected VMware proxy named "VMwareProxy". The needed proxy is obtained with Get-VBRViProxy and piped down. Get-VBRViProxy -Name "VMwareProxy" | Enable-VBRViProxy

Example 2 This command enables the selected VMware proxy represented by the $proxy variable. The needed proxy is obtained with Get-VBRViProxy and assigned to the variable beforehand. Enable-VBRViProxy -Proxy $proxy

174 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Erase-VBRTapeMedium Short Description Clears data from tape.

Applies to Version: 7.0 Platform: VMware, Hyper-V

Syntax Erase-VBRTapeMedium -Medium [-Long] [-RunAsync] []

Related Commands Get-VBRTapeMedium

Detailed Description This cmdlet clears a selected tape making it available for new recordings. By default Veeam Backup & Replication runs short erase procedure clearing only the tape headers. The remaining data is overwritten. You can enable long erase procedure to clear all data from the tape by adding "-Long" parameter to your string. The erased tape remains in the media pool it belongs to. Exceptions are predefined Unrecognized, Imported and Free media pools. If you move tape with data to the Free media pool and confirm the operation, Mark as Free will take effect and the data will be overwritten. See what else you can perform on tapes

Parameters Position

Accept Pipeline Input

Accept Wildcard Characters

True

Named

True (ByValue, ByProperty Name)

False

Long

If set, the erase procedure will clear all data from the tape. Otherwise Veeam Backup & Replication runs a short erase procedure that clears the headers only: the tape is regarded as free and the remaining data is ovewritten.

False

Named

False

False

RunAsync

Indicates that the command returns immediately without waiting for the task to complete.

False

Named

False

False

Parameter

Medium

Description Specifies the tape(s) you want to erase. You can assign multiple tapes to this object.

Required

175 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

This cmdlet supports Microsoft PowerShell common parameters. For more information about common parameters, see http://go.microsoft.com/fwlink/p/?LinkID=113216.

Example 1 This command clears the tape with barcode “00233400”. The tape to erase is obtained with GetVBRTapeMedium, selected using the Where-Object by "barcode" property and piped down. Get-VBRTapeMedium | Where-Object {$_.barcode -eq "00233400"}| Erase-VBRTapeMedium -RunAsync

Example 2 This command clears the tape represented by $tape variable. The tape is obtained with GetVBRTapeMedium and assigned to the variable beforehand. The RunAsync parameter is set to bring the process to the background. Erase-VBRTapeMedium -Tape $tape -RunAsync

176 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Export-VBRBackup Short Description Exports a backup or restore point files to a selected folder.

Applies to Version: 7.0 Platform: VMware, Hyper-V

Syntax Export-VBRBackup [-Backup] [-Dir] [WarningAction ] [-WarningVariable ] [] -ORExport-VBRBackup [-RestorePoint] [-Dir] [WarningAction ] [-WarningVariable ] []

Related Commands Get-VBRBackup Get-VBRRestorePoint

Detailed Description This cmdlet copies a selected backup files to a user-specified directory. You can copy a whole backup file or select backups for a specific job object. The job objects are VMs, VM containers, datastores or resource pools. See what else you can perform on your backup files

Parameters Parameter

Description

Required

Position

Accept Pipeline Input

Accept Wildcard Characters

Backup

Specifies the backup file you want to export.

True

1

False

False

RestorePoint

Specifies the job object (i.e. a VM) for which you want to export the backup files.

True

1

False

False

Dir

Specifies the path to the folder where you want to copy the files to.

True

2

False

False

This cmdlet supports Microsoft PowerShell common parameters. For more information about common parameters, see http://go.microsoft.com/fwlink/p/?LinkID=113216.

177 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Example 1 This command exports the backup file represented by the $"AD backup" to the folder "C:\Export". The backup file to export is obtained with Get-VBRBackup and assigned to the variable beforehand. Export-VBRBackup -Backup $"AD backup" -Dir "C:\Export"

Example 2 This command exports the backup file for a specific VM represented by the $"AD_local" to the folder "C:\Export". The backup file to export is obtained with Get-VBRRestorePoint and assigned to the variable beforehand. Export-VBRBackup -RestorePoint $"AD_local" -Dir "C:\Export"

178 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Export-VBRConfiguration Short Description Exports configuration backup file.

Applies to Version: 7.0 Platform: VMware, Hyper-V

Syntax Export-VBRConfiguration [-WarningAction ] [WarningVariable ] []

Detailed Description This cmdlet backs up current configuration of Veeam Backup & Replication server. By default, configuration backups are stored to the C:\backup\VeeamConfigBackup\%BackupServer% folder on the Veeam backup server. With configuration backup, you can store a copy of your host configuration: your virtual infrastructure, jobs configuration, Veeam Backup & Replication settings and other data. You can restore configuration in case the Veeam Backup & Replication host is failed or configuration is corrupted. Run Import-VBRConfiguration to restore your host configuration. This cmdlet supports Microsoft PowerShell common parameters. For more information about common parameters, see http://go.microsoft.com/fwlink/p/?LinkID=113216.

Example This command exports the current configuration of Veeam Backup & Replication host. Export-VBRConfiguration

179 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Export-VBRLogs Short Description Collects logs for export.

Applies to Version: 7.0 Platform: VMware, Hyper-V

Syntax Export-VBRLogs -Server -FolderPath [-Compress] [-From ] [-To ] [-WarningAction ] [-WarningVariable ] [] -ORExport-VBRLogs -Job -FolderPath [-Compress] [From ] [-To ] [-WarningAction ] [-WarningVariable ] [] -ORExport-VBRLogs -Entity -FolderPath [Compress] [-From ] [-To ] [-WarningAction ] [-WarningVariable ] [] -ORExport-VBRLogs -Backup -FolderPath [Compress] [-From ] [-To ] [-WarningAction ] [-WarningVariable ] []

Related Commands Get-VBRServer Get-VBRJob Get-VSBJob Find-VBRViEntity / Find-VBRHvEntity Get-VBRBackup

Detailed Description This cmdlet collects system logs. You can use this cmdlet to collect logs you can send to the Veeam support. The log files are written to the folder you specify in this cmdlet. This cmdlet provides syntax for getting logs for hosts, jobs, entities or backups. You can get logs for all kind of virtual host, any jobs including SureBackup jobs, all entities including datastores, clusters, replicas, etc., or any backup.

180 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Parameters Position

Accept Pipeline Input

Accept Wildcard Characters

True

Named

True (ByValue, ByProperty Name)

False

From

Specifies the start date to collect the logs for export. Enter the date in format set in your workstation Date and Time settings.

False

Named

False

False

To

Specifies the end date to collect the logs for export. Enter the date in format set in your workstation Date and Time settings.

False

Named

False

False

Named

True (ByValue, ByProperty Name)

False

Named

True (ByValue, ByProperty Name)

False

True

Named

True (ByValue, ByProperty Name)

False

Parameter

Description

Required

Specifies the server(s) from which you want to collect logs. Server

Note that selected servers must be running and reachable over the network. You can assign multiple servers to this object.

Job

Specifies the job(s) you want to collect logs for. You can get logs for all kind of jobs.

True

You can assign multiple jobs to this object.

Entity

Backup

Specifies the VM(s) you want to collect logs for. You can assign multiple VMs to this object. Specifies the backups you want to collect logs for. You can assign multiple backups to this object.

True

FolderPath

Specifies the destination folder to which the logs will be exported.

True

Named

False

False

Compress

If set, the log files will be archived.

False

Named

False

False

This cmdlet supports Microsoft PowerShell common parameters. For more information about common parameters, see http://go.microsoft.com/fwlink/p/?LinkID=113216.

181 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Example 1 This command starts collecting log files from the server represented by the $server variable. The destination path is C:\Logs. The period for collecting data is July, 21, 2013 - July, 25, 2013. The data compression is enabled. Export-VBRLogs -Server $server -FolderPath "C:\Logs" -Compress From 7/21/2013 -To 7/25/2013

Example 2 This command starts collecting log files for the SureBackup job named "DC SureJob". The job is obtained with Get-VSBJob and piped down. The destination path is C:\Logs\SureBackup Logs. The period for collecting data is not set to collect all the data for the job. The data compression is enabled. Get-VSBJob -Name "DC SureJob" | Export-VBRLogs -FolderPath "C:\Logs\SureBackup Logs" -Compress

Example 3 This command starts collecting log files for the VM named "DC" for May, 2013. The VM is obtained with Find-VBRViEntity and piped down. The destination path is C:\Logs. The data compression is enabled. Find-VBRViEntity -Name "DC" | Export-VBRLogs -FolderPath "C:\Logs" -Compress -From 6/01/2013 -To 7/01/2013

182 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Export-VBRTapeMedium Short Description Exports selected tapes from library.

Applies to Version: 7.0 Platform: VMware, Hyper-V

Syntax Export-VBRTapeMedium -Medium [-RunAsync] [WarningAction ] [-WarningVariable ] []

Related Commands Get-VBRTapeMedium

Detailed Description This cmdlet moves a selected tape to the mail slot. You can take the tape out of the mail slot manually. The mail slot is the slot through which you can put the new tapes into the library and take the tapes with data out. The mail slot is a service slot and you do not manage the tape residing inside it until it is imported to the library or after it is exported. Run Import-VBRTapeMedium to put new tapes to the library. See what else you can perform on tapes

Parameters Parameter

Medium

RunAsync

Description Specifies the tape(s) you want to export. You can assign multiple tapes to this object. Indicates that the command returns immediately without waiting for the task to complete.

Position

Accept Pipeline Input

Accept Wildcard Characters

True

Named

True (ByValue, ByProperty Name)

False

False

Named

False

False

Required

This cmdlet supports Microsoft PowerShell common parameters. For more information about common parameters, see http://go.microsoft.com/fwlink/p/?LinkID=113216.

183 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Example 1 This command exports the tapes belonging to the media pool named "Incremental Backups". The tapes are obtained with Get-VBRTapeMedium by piping the needed media pool down. The -RunAsync parameter is set to bring the process to the background. Get-VBRTapeMediaPool -Name "Incremental Backups" | GetVBRTapeMedium | Export-VBRTapeMedium -RunAsync

Example 2 This command moves the group of tapes represented by the $tapes variable to the mail slot. The tapes object is obtained with Get-VBRTapeMedium and assigned to the variable beforehand. The RunAsync parameter is set to bring the process to the background. $tapes | Export-VBRTapeMedium -RunAsync

184 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Find-VBRDatastore Short Description Returns a list of VMware datastores connected to the specified ESX(i) host. Note:

In Backup & Replication v6 this cmdlet was replaced by Find-VBRViDatastore due to multihypervisor support introduced in the new version. The cmdlet will still work but it is advised to rewrite your scripts using new cmdlets for added benefits.

Applies to Version: 7.0 and earlier Platform: VMware

Syntax Find-VBRDatastore [-Server] [-Name ] [WarningAction ] [-WarningVariable ] []

Related Commands Get-VBRServer

Detailed Description This cmdlet returns a list of all datastores connected to the specified ESX(i) host.

Parameters Parameter

Server

Name

Description

Specifies the ESX(i) host you want to get the list of the connected datastores of. Specifies the name of the datastore you want to get, or search conditions. You can specify multiple names separated by commas.

Position

Accept Pipeline Input

Accept Wildcard Characters

True

1

True (ByValue, ByProperty Name)

False

False

Named

False

True

Required

This cmdlet supports Microsoft PowerShell common parameters. For more information about common parameters, see http://go.microsoft.com/fwlink/p/?LinkID=113216.

185 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Example 1 This command looks for the datastore named "Store 04" on server named named "VMwareHost". The server object is obtained with Get-VBRServer and piped down. Get-VBRServer -Name "VMwareHost" | Find-VBRDatastore -Name "Store 04"

Example 2 This command looks for the all datastores located on server represented by the $server variable. The server object is obtained with Get-VBRServer and assigned to the variable beforehand. Find-VBRDatastore -Server $server

186 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Find-VBRHvEntity Short Description Looks for Hyper-V objects.

Applies to Version: 7.0 and earlier Platform: Hyper-V

Syntax Find-VBRHvEntity [-Server ] [-HostsAndVMs] [-Name ] [-WarningAction ] [-WarningVariable ] [] -ORFind-VBRHvEntity [-Server ] [-Hosts] [-Name ] [-WarningAction ] [-WarningVariable ] [] -ORFind-VBRHvEntity [-Server ] [-HostsAndVolumes] [-Name ] [-WarningAction ] [-WarningVariable ] []

Related Commands Get-VBRServer

Detailed Description This cmdlet returns a list of Hyper-V objects managed by Veeam Backup & Replication. You can get the list of all Hyper-V objects in your virtual environment or narrow down your search to hosts, VMs or volumes, or look for instances directly by name. Look for other virtual instances Run Get-VBRServer to get the list of the Hyper-V hosts.

Return Type CHvHostItem CHvVmItem

187 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Parameters Parameter

Server

Description Specifies the host you want to look for entities on. You can assign multiple servers to this object.

Position

Accept Pipeline Input

Accept Wildcard Characters

False

Named

True (ByValue, ByProperty Name)

False

Required

HostsAnd VMs

Views results as hosts and VMs.

False

Named

False

False

Hosts

Views results as hosts.

False

Named

False

False

HostsAnd Volumes

Views results as hosts and volumes.

False

Named

False

False

False

Named

False

True

Name

Specifies the name of the entity you want to get, or search conditions. You can specify multiple names separated by commas.

This cmdlet supports Microsoft PowerShell common parameters. For more information about common parameters, see http://go.microsoft.com/fwlink/p/?LinkID=113216.

Example 1 This command looks for all Hyper-V objects registered on server named "Hyper-V Host". The server is obtained with Get-VBRServer and piped down. Get-VBRServer -Name "HvHost" | Find-VBRHvEntity

Example 2 This command looks for Hyper-V hosts and VMs registered on Hyper-V servers named "HvHost 01" and "HvHost 02". The servers are obtained with Get-VBRServer and piped down. Get-VBRServer -Name "HvHost 01", "HvHost 02" | Find-VBRHvEntity HostsAndVMs

Example 3 This command directly looks for the Hyper-V server named "HvExchange". Find-VBRHvEntity -Name "HvExchange"

188 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Find-VBRObject Short Description Returns a list of all VMs and VM containers on the specified ESX(i) host. Note:

In Backup & Replication v6 this cmdlet was replaced by Find-VBRViEntity and Find-VBRHvEntity due to multihypervisor support introduced in the new version.

Applies to Version: 7.0 and earlier Platform: VMware

Syntax Find-VBRObject [-Server] [-Name ] [WarningAction ] [-WarningVariable ] []

Related Commands Get-VBRServer

Detailed Description This cmdlet returns a list of all VMs and VM containers on the specified ESX(i) host. Look for other virtual instances

Parameters Parameter

Server

Name

Description

Specifies the host you want to look for objects on. Specifies the name of the object you want to get, or search conditions. You can specify multiple names separated by commas.

Position

Accept Pipeline Input

Accept Wildcard Characters

True

1

True (ByValue, ByProperty Name)

False

False

Named

False

False

Required

This cmdlet supports Microsoft PowerShell common parameters. For more information about common parameters, see http://go.microsoft.com/fwlink/p/?LinkID=113216.

189 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Example 1 This command looks all objects registered on server named named "VMwareHost". The server object is obtained with Get-VBRServer and piped down. Get-VBRServer -Name "VMwareHost" | Find-VBRObject

Example 2 This command looks for VMs named "VM01" and "VM03" located on server represented by the $server variable. The server object is obtained with Get-VBRServer and assigned to the variable beforehand. Find-VBRObject -Server $server -Name "VM01", "VM03"

190 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Find-VBRResourcePool Short Description Looks for VMware resource pools. Note:

This cmdlet is obsolete. In Backup & Replication v6 this cmdlet was replaced by FindVBRViResourcePool.

Applies to Version: 7.0 and earlier Platform: VMware

Syntax Find-VBRResourcePool [-Server] [-Name ] [WarningAction ] [-WarningVariable ] []

Related Commands Get-VBRServer

Detailed Description This cmdlet returns a list of all VMware resource pools on the specified ESX(i) host. Look for other virtual instances

Parameters Parameter

Server

Name

Description

Specifies the host you want to look for resource pool on.

Specifies the name of the resource pool you want to get, or search conditions. You can specify multiple names separated by commas.

Position

Accept Pipeline Input

Accept Wildcard Characters

True

1

True (ByValue, ByProperty Name)

False

False

Named

False

False

Required

This cmdlet supports Microsoft PowerShell common parameters. For more information about common parameters, see http://go.microsoft.com/fwlink/p/?LinkID=113216.

191 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Find-VBRTapeCatalog Short Description Looks for files stored on tapes.

Applies to Version: 7.0 Platform: VMware, Hyper-V

Syntax Find-VBRTapeCatalog [-Name ] [-WarningAction ] [-WarningVariable ] []

Detailed Description This cmdlet looks for files stored on tapes that are managed by Veeam Backup & Replication. Veeam Backup & Replication stores all data about the backups that were recorded to tapes in the database, and you can view the list of files both while the tapes are online, or after they were removed from the library. The backups or files that were written to tapes with Veeam Backup & Replication are indexed automatically. Run Start-VBRTapeCatalog to index the imported tapes. You can get the list of all files that are stored on tapes or narrow down the output by file name. Run Find-VBRTapeCatalogVersion to look for list of versions of a specific file. See what else you can perform on tapes

Return Type CatalogueFile

Parameters Parameter

Name

Description Specifies the name of the file to look for or search conditions. You can specify multiple names separated by commas.

Required

Position

Accept Pipeline Input

Accept Wildcard Characters

False

Named

False

True

This cmdlet supports Microsoft PowerShell common parameters. For more information about common parameters, see http://go.microsoft.com/fwlink/p/?LinkID=113216.

Example This command looks for .vbk files. Find-VBRTapeCatalog -Name *.vbk

192 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Find-VBRTapeCatalogVersion Short Description Looks for versions of files stored on tapes.

Applies to Version: 7.0 Platform: VMware, Hyper-V

Syntax Find-VBRTapeCatalogVersion [-Name ] [-WarningAction ] [-WarningVariable ] [] -ORFind-VBRTapeCatalogVersion [-CatalogFile ] [-Name ] [-WarningAction ] [-WarningVariable ] []

Related Commands Find-VBRTapeCatalog

Detailed Description This cmdlet looks for versions of files stored on tapes that are managed by Veeam Backup & Replication. File version is used as a file restore point. You can get the list of all files and their versions that are stored on tapes or narrow down the output by file name or object of file you need. Run Find-VBRTapeCatalog to get the list of files stored on tapes. See what else you can perform on tapes

Return Type CatalogueFileVersion

Parameters Parameter

Name

CatalogFile

Description Specifies the name of the file you want to get versions for, or search conditions. You can specify multiple names separated by commas. Specifies the file you want to get versions for.

Required

Position

Accept Pipeline Input

Accept Wildcard Characters

False

Named

False

True

False

Named

True (ByValue, ByProperty

False

193 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Parameter

Description

Required

Position

Accept Pipeline Input

Accept Wildcard Characters

Name)

This cmdlet supports Microsoft PowerShell common parameters. For more information about common parameters, see http://go.microsoft.com/fwlink/p/?LinkID=113216.

Example 1 This command looks for the most recent version of file named "Payroll_Marketing.html". The file object is obtained with Find-VBRTapeCatalog and piped down. The needed version is filtered with Select method. Find-VBRTapeCatalog -Name "Payroll_Marketing.html" | FindVBRTapeCatalogVersion | Select -First 1

Example 2 This command looks for versions of file represented by $file variable. The file object is obtained with Find-VBRTapeCatalog, assigned to the variable and piped down. $file | Find-VBRTapeCatalogueVersion

194 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Find-VBRvCloudEntity Short Description Looks for vCloud Director entities.

Applies to Version: 7.0 Platform: VMware

Syntax Find-VBRvCloudEntity [-Server ][-Full][-Name ] [] Find-VBRvCloudEntity [-Server ][-VApp][-Name ] [] Find-VBRvCloudEntity [-Server ][-Template][-Name ] [] Find-VBRvCloudEntity [-Server ][-VmTemplate][-Name ] [] Find-VBRvCloudEntity [-Server ][-OrganizationVdc][-Name ] [] Find-VBRvCloudEntity [-Server ][-StorageProfile][-Name ] [] Find-VBRvCloudEntity [-Server ][-Datastore][-Name ] [] Find-VBRvCloudEntity [-Server ][-Vc][-Name ] []

Related Commands Get-VBRServer

Detailed Description This cmdlet looks for a certain entity of vCloud Director. You can get the whole list of vCloud entities, or the list of specified entities (i.e. vApps), or narrow down the output by filtering by name. See what else you can perform on vCloud

Return Type CVcdSystemItem CVcdOrganizationItem CVcdOrganizationVdcItem CVcdVappItem CVcdVmItem CVcdOrgVdcStorageProfile CVcdDatastoreRestoreInfo

195 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Parameters Parameter

Server

Description Specifies the server(s) where the entity to look for is located.

Position

Accept Pipeline Input

Accept Wildcard Characters

False

Named

True (ByValue, ByProperty Name)

False

Required

You can assign multiple servers to this object. Full

View results as the list of all vCloud entities.

False

Named

False

False

VApp

View results as vApps.

False

Named

False

False

Template

View results as vApp templates.

False

Named

False

False

VmTemplate

View results as VM templates.

False

Named

False

False

Organization Vdc

View results as Organization vDCs.

False

Named

False

False

StorageProfile

View results as storage profiles.

False

Named

False

False

Datastore

View results as datastores.

False

Named

False

False

Vc

View results as vClouds.

False

Named

False

False

False

Named

False

True

Specifies the name(s) of the entity. Name

You can specify multiple names separated by commas.

This cmdlet supports Microsoft PowerShell common parameters. For more information about common parameters, see http://go.microsoft.com/fwlink/p/?LinkID=113216.

196 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Example 1 This command looks for all vCloud entities registered on the server represented by $server variable. The server object is obtained with Get-VBRServer and assigned to the variable beforehand. Find-VBRvCloudEntity -Server $server -Full

Example 2 This command looks for the vCloud entities registered on the server with 172.16.1.13 IP address. The server object is obtained with Get-VBRServer and piped down. The output is filtered by name containing "SQL". Get-VBRServer -Name "172.16.1.13" | Find-VBRvCloudEntity -Name *SQL*

Example 3 This command looks for the vApps registered on the server named "vCloud Server". The server object is obtained with Get-VBRServer and piped down. Get-VBRServer -Name "vCloud Server" | Find-VBRvCloudEntity -VApp

Example 4 This command looks for the datastore named "Datastore 04" registered on the server represented by $server variable. The server object is obtained with Get-VBRServer and assigned to the variable beforehand. Find-VBRvCloudEntity -Server $server -Datastore -Name "Datastore 04"

197 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Find-VBRViDatastore Short Description Looks for VMware datastores connected to the specified ESX(i) host.

Applies to Version: 7.0 and earlier Platform: VMware

Syntax Find-VBRViDatastore -Server [-Name ] [WarningAction ] [-WarningVariable ] []

Related Commands Get-VBRServer

Detailed Description This cmdlet returns a list of datastores connected to the specified ESX(i) host. You can get the list of all datastores on the specified ESX(i) host or look for instances directly by name. Look for other virtual instances

Return Type CViDatastoreItem

Parameters Parameter

Server

Name

Description

Specifies the ESX(i) host to which the datastores you are looking for are connected. Specifies the name of the datastore you want to get, or search conditions. You can specify multiple names separated by commas.

Position

Accept Pipeline Input

Accept Wildcard Characters

True

Named

True (ByValue, ByProperty Name)

False

False

Named

False

True

Required

This cmdlet supports Microsoft PowerShell common parameters. For more information about common parameters, see http://go.microsoft.com/fwlink/p/?LinkID=113216.

198 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Example 1 This command looks for the list of datastores connected to the ESXi hosts. The servers are obtained with Get-VBRServer, sorted by "Type" and piped down. Get-VBRServer -Type ESXi | Find-VBRViDatastore

Example 2 This command looks for the datastores connected to the ESXi host named "ESXiHost". The server is obtained with Get-VBRServer and piped down. The list of datastores is narrowed down to the datastore named "MSExchange" and datastores with names starting with "LocalStore_0". Get-VBRServer -Name "ESXiHost" | Find-VBRViDatastore -Name "MSExchange", "LocalStore_0*"

Example 3 This command looks for the datastore named "MSExchange" connected to the server represented by the $server variable. The server object is obtained with Get-VBRServer and assigned to the variable beforehand. Find-VBRViDatastore -Server $server -Name "MSExchange"

199 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Find-VBRViEntity Short Description Looks for VMware entities.

Applies to Version: 7.0 and earlier Platform: VMware

Syntax Find-VBRViEntity [-Server ] [-HostsAndClusters] [-Name ] [-WarningAction ] [-WarningVariable ] [] -ORFind-VBRViEntity [-Server ] [-VMsAndTemplates] [-Name ] [-WarningAction ] [-WarningVariable ] [] -ORFind-VBRViEntity [-Server ] [-DatastoresAndVMs] [-Name ] [-WarningAction ] [-WarningVariable ] [] -ORFind-VBRViEntity [-Server ] [-HostsAndDatastores] [-Name ] [-WarningAction ] [-WarningVariable ] [] -ORFind-VBRViEntity [-Server ] [-ResourcePools] [-Name ] [-WarningAction ] [-WarningVariable ] [] -ORFind-VBRViEntity [-Server ] [-Servers] [-Name ] [-WarningAction ] [-WarningVariable ] []

Related Commands Get-VBRServer

Detailed Description This cmdlet returns a list of all VMware objects connected to the specified ESX(i) host. You can get the list of all VMware entities registered in your virtual VMware environment or narrow down the search results to specific objects, or look for instances directly by name. Look for other virtual instances Run Get-VBRServer to get the list of the VMware hosts.

200 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Return Type CVcItem CViFolderItem CViDatacenterItem CEsxItem CViClusterItem CViResourcePoolItem CViVmItem CViVirtualAppItem CViFolderItem CViDatacenterItem

Parameters Parameter

Description

Required

Position

Accept Pipeline Input

Accept Wildcard Characters

False

Server

Specifies the ESX(i) host you want to look for entities on.

False

Named

True (ByValue, ByProperty Name)

HostsAnd Clusters

Views results as hosts and clusters.

False

Named

False

False

VMsAnd Templates

Views results as VMs and templates.

False

Named

False

False

Datastores AndVMs

Views results as datastores and VMs.

False

Named

False

False

HostsAnd Datastores

Views results as hosts and datastores.

False

Named

False

False

ResourcePools

Views results as resource pools.

False

Named

False

False

Servers

Views results as VMware hosts.

False

Named

False

False

False

Named

True

True

Name

Specifies the name of the entity you want to get, or search conditions. You can specify multiple names separated by commas.

This cmdlet supports Microsoft PowerShell common parameters. For more information about common parameters, see http://go.microsoft.com/fwlink/p/?LinkID=113216.

201 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Example 1 This command looks for the list of hosts and clusters connected to the ESXi hosts named "ESXiHost 01" and "ESXiHost 02". The servers are obtained with Get-VBRServer and piped down. Get-VBRServer -Name "ESXiHost 01", "ESXiHost 02" | FindVBRViEntity -HostsAndClusters

Example 2 This command looks for the list of resource pools connected to the ESXi host named "ESXiHost". The server is obtained with Get-VBRServer and piped down. The list of resource pools is narrowed down to the resource pools with names starting with "Veeam". Get-VBRServer -Name "ESXiHost" | Find-VBRViEntity -ResourcePools -Name Veeam*

202 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Find-VBRViFolder Short Description Looks for list of folders on the specified ESX(i) host.

Applies to Version: 7.0 and earlier Platform: VMware

Syntax Find-VBRViFolder -Server [-Name ] [WarningAction ] [-WarningVariable ] []

Related Commands Get-VBRServer

Detailed Description This cmdlet returns a list of folders on the specified ESX(i) host. You can get the list of all folders on the specified ESX(i) host or look for instances directly by name. Look for other virtual instances

Return Type CViFolderItem

Parameters Parameter

Server

Name

Description

Specifies the ESX(i) host you want to look for folders on. Specifies the name of the folder you want to get, or search conditions. You can specify multiple names separated by commas.

Position

Accept Pipeline Input

Accept Wildcard Characters

True

Named

True (ByValue, ByProperty Name)

False

False

Named

False

True

Required

This cmdlet supports Microsoft PowerShell common parameters. For more information about common parameters, see http://go.microsoft.com/fwlink/p/?LinkID=113216.

203 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Example 1 This command looks for the list of folders located on the ESXi hosts. The servers are obtained with GetVBRServer, sorted by "Type" and piped down. Get-VBRServer -Type ESXi | Find-VBRViFolder

Example 2 This command looks for the datastores connected to the ESXi host named "ESXiHost". The server is obtained with Get-VBRServer and piped down. The list of datastores is narrowed down to the datastore named "MSExchange" and datastores with names starting with "LocalStore_0". Get-VBRServer -Name "ESXiHost" | Find-VBRViFolder -Name "MSExchange", LocalStore_0*

204 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Find-VBRViResourcePool Short Description Looks for resource pools on the specified ESX(i) host.

Applies to Version: 7.0 and earlier Platform: VMware

Syntax Find-VBRViResourcePool -Server [-Name ] [WarningAction ] [-WarningVariable ] []

Related Commands Get-VBRServer

Detailed Description This cmdlet returns a list of resource pools on the specified ESX(i) host. You can get the list of all resource pools on the specified ESX(i) host or look for instances directly by name. Look for other virtual instances

Return Type CViResourcePoolItem

Parameters Parameter

Server

Name

Description

Specifies the ESX(i) host you want to look for resource pools on. Specifies the name of the resource pool you want to get, or search conditions. You can specify multiple names separated by commas.

Position

Accept Pipeline Input

Accept Wildcard Characters

True

Named

True (ByValue, ByProperty Name)

False

False

Named

False

False

Required

This cmdlet supports Microsoft PowerShell common parameters. For more information about common parameters, see http://go.microsoft.com/fwlink/p/?LinkID=113216.

205 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Example 1 This command looks for the list of resource pools located on the ESXi hosts. The servers objects are obtained with Get-VBRServer, sorted by "Type" and piped down. Get-VBRServer -Type ESXi | Find-VBRViResourcePool

Example 2 This command looks for the resource pool named "ResourcePool_05" connected to the ESXi host named "ESXiHost". The server object is obtained with Get-VBRServer and piped down. Get-VBRServer -Name "ESXiHost" | Find-VBRViResourcePool -Name "ResourcePool_05"

206 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Find-VSBHvVirtualLab Short Description Looks for the virtual labs created on the specified Hyper-V host.

Applies to Version: 7.0 Platform: Hyper-V For VMware, run Find-VSBVirtualLab.

Syntax Find-VSBVirtualLab [-Server] [-Name ] [WarningAction ] [-WarningVariable ] []

Related Commands Get-VBRServer

Detailed Description This cmdlet returns a list of all virtual labs created on the specified Hyper-V host. A virtual lab is a component of SureBackup technology providing verification of virtual machines that need other virtual machines or services running, i.e. a domain controller, a DSN server or SQL database. To test such machines for recoverability, you need to create a SureBackup job and provide the copy of the production architecture running in a fenced-off environment that is performed by creating a virtual lab and an application group. You can get the list of all virtual labs on the specified ESX(i) host or look for instances directly by name. See what else you can perform on SureBackup

Return Type CHvSbVirtualLab

Parameters Parameter

Server

Name

Description

Specifies the server where virtual labs are registered. Specifies the name of the virtual lab or search conditions. You can specify multiple names separated by commas.

Position

Accept Pipeline Input

Accept Wildcard Characters

True

1

True (ByValue, ByProperty Name)

False

False

Named

False

True

Required

207 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

This cmdlet supports Microsoft PowerShell common parameters. For more information about common parameters, see http://go.microsoft.com/fwlink/p/?LinkID=113216.

Example 1 This command looks for the list of all virtual labs created on the Hyper-V server named "Hyper-V Host". The server object is obtained with Get-VBRServer and piped down. Get-VBRServer -Name "Hyper-V Host" | Find-VSBHvVirtualLab

Example 2 This command looks for the virtual labs with names starting with "Hv" on the server represented by the $server variable. The server object is obtained with Get-VBRServer and assigned to the variable beforehand. Find-VSBHvVirtualLab -Server $server -Name Hv*

208 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Find-VSBVirtualLab Short Description Looks for virtual labs created on the specified ESX(i) host.

Applies to Version: 7.0 and earlier Platform: VMware For Hyper-V, run Find-VSBHvVirtualLab.

Syntax Find-VSBVirtualLab [-Server] [-Name ] [WarningAction ] [-WarningVariable ] []

Related Commands Get-VBRServer

Detailed Description This cmdlet returns a list of all virtual labs created on the specified ESX(i) host. A virtual lab is a component of SureBackup technology providing verification of virtual machines that need other virtual machines or services running, i.e. a domain controller, a DSN server or SQL database. To test such machines for recoverability, you need to create a SureBackup job and provide the copy of the production architecture running in a fenced-off environment that is performed by creating a virtual lab and an application group. You can get the list of all VMware virtual labs on the specified ESX(i) host or look for instances directly by name. See what else you can perform on SureBackup

Return Type CVirtualLabDescriptor

Parameters Parameter

Server

Name

Description

Specifies the server you want to look for virtual labs on. Specifies the name of the resource pool you want to get, or search conditions. You can specify multiple names separated by commas.

Position

Accept Pipeline Input

Accept Wildcard Characters

True

1

True (ByValue, ByProperty Name)

False

False

Named

False

False

Required

209 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

This cmdlet supports Microsoft PowerShell common parameters. For more information about common parameters, see http://go.microsoft.com/fwlink/p/?LinkID=113216.

Example 1 This command looks for the list of all virtual labs located on the ESXi hosts. The servers are obtained with Get-VBRServer, sorted by "Type" and piped down. Get-VBRServer -Type ESXi | Find-VSBVirtualLab

Example 2 This command looks for the virtual lab named "MailServer_VLab" connected to the ESXi host named "ESXiHost". The server is obtained with Get-VBRServer and piped down. Get-VBRServer -Name "ESXiHost" | Find-VSBVirtualLab -Name "MailServer_VLab"

210 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Get-HP3Snapshot Short Description Returns a SAN snapshot object.

Applies to Version: 7.0 Platform: VMware HP SAN storage system: HP 3PAR StoreServ

Syntax Get-HP3Snapshot [-Name ][] -ORGet-HP3Snapshot [-Name ] [-Volume ][]

Related Commands Get-HP3Volume

Detailed Description This cmdlet returns a SAN snapshot object. You can get the list of all SAN snapshots in your storage system or narrow down the output by the snapshot name or a specific volume. See what else you can perform on HP 3PAR instances

Parameters Parameter

Description

Required

Position

Accept Pipeline Input

Accept Wildcard Characters

False

Named

False

True

Named

True (ByValue, ByProperty Name)

False

Specifies the name of the snapshot you want to get. Name

Volume

You can specify multiple names separated by commas. Specifies the volume(s) for which you want to get the snapshots.

False

You can assign multiple volumes to this object.

This cmdlet supports Microsoft PowerShell common parameters. For more information about common parameters, see http://go.microsoft.com/fwlink/p/?LinkID=113216.

211 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Example 1 This command looks for the list of all snapshots. Get-HP3Snapshot

Example 2 This command looks for snapshots of the specific volumes. The list of volumes is obtained with GetHP3Volume, the first three volumes are selected and piped down. Get-HP3Volume | Select -First 3 | Get-HP3Snapshot

212 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Get-HP3Storage Short Description Returns a SAN storage object.

Applies to Version: 7.0 Platform: VMware HP SAN storage system: HP 3PAR StoreServ

Syntax Get-HP3Storage [-Name ][]

Detailed Description This cmdlet returns SAN storage object. You can get the list of all SAN snapshots in your storage system or narrow down the output by the storage name. See what else you can perform on HP 3PAR instances

Parameters Parameter

Name

Description

Required

Position

Accept Pipeline Input

Accept Wildcard Characters

False

Named

False

True

Specifies the name of the storage you want to get. You can specify multiple names separated by commas.

This cmdlet supports Microsoft PowerShell common parameters. For more information about common parameters, see http://go.microsoft.com/fwlink/p/?LinkID=113216.

Example 1 This command looks for the list of all SAN storages. Get-HP3Storage

Example 2 This command looks for the list of storages with names starting with "HP Store". Get-HP3Storage -Name "HP Store*"

213 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Get-HP3Volume Short Description Returns a SAN volume object.

Applies to Version: 7.0 Platform: VMware HP SAN storage system: HP 3PAR StoreServ

Syntax Get-HP3Volume -Storage [-Name ][]

Related Commands Get-HP3Storage

Detailed Description This cmdlet returns SAN volume object. You can get the list of all SAN volumes in your storage system, narrow down the output by the volume name or specify a cluster or a storage within which you want to look for the volumes. See what else you can perform on HP 3PAR instances

Parameters Parameter

Storage

Description Specifies the storage(s) within which you want to look for the volumes.

Position

Accept Pipeline Input

Accept Wildcard Characters

True

Named

True (ByValue, ByProperty Name)

False

False

Named

False

True

Required

You can assign multiple storages to this object. Specifies the name of the volume you want to get. Name

You can specify multiple names separated by commas.

This cmdlet supports Microsoft PowerShell common parameters. For more information about common parameters, see http://go.microsoft.com/fwlink/p/?LinkID=113216.

214 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Example 1 This command looks for the volume named "HP Store" in the storage named "HP Store 01". The storage object is obtained with Get-HP3Storage and piped down. Get-HP3Storage -Name "HP Store 01" | Get-HP3Volume -Name "HP Store"

Example 2 This command looks for the volume named "HP Store" in the storage represented by the $"SAN storage" variable. The storage object is obtained with Get-HP3Storage and assigned to the variable beforahand. Get-HP3Volume -Storage $"SAN storage" -Name "HP Store"

215 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Get-HP4Cluster Short Description Returns a SAN cluster object.

Applies to Version: 7.0 Platform: VMware HP SAN storage systems: HP LeftHand P4000, HP StoreVirtual VSA

Syntax Get-HP4Cluster -Storage [-Name ][]

Related Commands Get-HP4Storage

Detailed Description This cmdlet returns SAN cluster object. You can get the list of all SAN clusters in your storage system, or narrow down the output by the cluster name or a specific storage. See what else you can perform on HP LeftHand P4000 or HP StoreVirtual VSA instances

Alias Get-VBRHPCluster

Parameters Parameter

Storage

Description Specifies the storage within which you want to look for the clusters.

Position

Accept Pipeline Input

Accept Wildcard Characters

True

Named

True (ByValue, ByProperty Name)

False

False

Named

False

True

Required

You can assign multiple storages to this object. Specifies the name of the cluster you want to get. Name

You can specify multiple names separated by commas.

This cmdlet supports Microsoft PowerShell common parameters. For more information about common parameters, see http://go.microsoft.com/fwlink/p/?LinkID=113216.

216 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Example 1 This command looks for the list of clusters in the storage named "HP Store 01". The storage object is obtained with Get-HP4Storage and piped down. Get-HP4Storage -Name "HP Store 01" | Get-HP4Cluster

Example 2 This command looks for the list of clusters in the storage named "HP Store 01". The storage object is obtained with Get-HP4Storage and assigned to the variable beforehand. Get-HP4Cluster -Storage $"HP Store 01"

217 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Get-HP4Snapshot Short Description Returns a SAN snapshot object.

Applies to Version: 7.0 Platform: VMware HP SAN storage systems: HP LeftHand P4000, HP StoreVirtual VSA

Syntax Get-HP4Snapshot [-Name ][] -ORGet-HP4Snapshot [-Name ] [-Volume ][]

Related Commands Get-HP4Volume

Detailed Description This cmdlet returns SAN snapshot object. You can get the list of all SAN snapshots in your storage system, or narrow down the output by the snapshot name or a specific volume. See what else you can perform on HP LeftHand P4000 or HP StoreVirtual VSA instances

Alias Get-VBRHPSnapshot

Parameters Parameter

Description

Required

Position

Accept Pipeline Input

Accept Wildcard Characters

False

Named

False

True

Named

True (ByValue, ByProperty Name)

False

Specifies the name of the snapshot you want to get. Name

Volume

You can specify multiple names separated by commas. Specifies the volume(s) you want to get the snapshots of.

False

You can assign multiple volumes to this object.

218 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

This cmdlet supports Microsoft PowerShell common parameters. For more information about common parameters, see http://go.microsoft.com/fwlink/p/?LinkID=113216.

Example 1 This command looks for snapshots of the volume named "HP Vol01". The volume is obtained with GetHP4Volume and piped down. Get-HP4Volume -Name "HP Vol01" | Get-HP4Snapshot

Example 2 This command looks for the snapshots of the volume represented by the $vol variable. The volume is obtained with Get-HP4Volume and assigned to the variable beforehand. Get-HP4Snapshot

219 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Get-HP4Storage Short Description Returns a SAN storage object.

Applies to Version: 7.0 Platform: VMware HP SAN storage systems: HP LeftHand P4000, HP StoreVirtual VSA

Syntax Get-HP4Storage [-Name ] []

Detailed Description This cmdlet returns a SAN storage object. You can get the list of all SAN snapshots in your storage system, or narrow down the output by the storage name. See what else you can perform on HP LeftHand P4000 or HP StoreVirtual VSA instances

Alias Get-VBRHPStorage

Parameters Parameter

Name

Description Specifies the name of the storage you want to get. You can specify multiple names separated by commas.

Required

Position

Accept Pipeline Input

Accept Wildcard Characters

False

Named

False

True

This cmdlet supports Microsoft PowerShell common parameters. For more information about common parameters, see http://go.microsoft.com/fwlink/p/?LinkID=113216.

220 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Example 1 This command looks for the list of all storages. Get-HP4Storage

Example 2 This command looks for the list of storages with names starting with "HP Store". Get-HP4Storage -Name "HP Store*"

221 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Get-HP4Volume Short Description Returns a SAN volume object.

Applies to Version: 7.0 Platform: VMware HP SAN storage systems: HP LeftHand P4000, HP StoreVirtual VSA

Syntax Get-HP4Volume [-Name ] [] -ORGet-HP4Volume -Cluster [-Name ] [] -ORGet-HP4Volume -Storage [-Name ] []

Related Commands Get-HP4Storage Get-HP4Cluster

Detailed Description This cmdlet returns a SAN volume object. You can get the list of all SAN volumes in your storage system,narrow down the output by the volume name, or specify a cluster or a storage within which you want to look for the volumes. See what else you can perform on HP LeftHand P4000 or HP StoreVirtual VSA instances

Alias Get-VBRHPVolume

Parameters Parameter

Description

Required

Position

Accept Pipeline Input

Accept Wildcard Characters

False

Named

False

True

Named

True (ByValue, ByProperty Name)

False

Specifies the name of the volume you want to get. Name

Cluster

You can specify multiple names separated by commas. Specifies the cluster within which you want to look for the volumes.

True

You can assign multiple

222 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Parameter

Description

Required

Position

Accept Pipeline Input

Accept Wildcard Characters

Named

True (ByValue, ByProperty Name)

False

clusters to this object.

Storage

Specifies the storage within which you want to look for the volumes.

True

You can assign multiple storages to this object.

This cmdlet supports Microsoft PowerShell common parameters. For more information about common parameters, see http://go.microsoft.com/fwlink/p/?LinkID=113216.

Example 1 This command looks for the list of volumes with names starting with "HP Store" within the cluster named "Cluster 1". The cluster object is obtained with Get-HP4Cluster and piped down. Get-HP4Cluster -Name "Cluster 1" | Get-HP4Volume -Name "HP Store*"

Example 2 This command looks for all volumes in the storage named "HP Store 01". The storage object is obtained with Get-HP4Storage and piped down. Get-HP4Storage -Name "HP Store 01" | Get-HP4Volume

Example 3 This command looks for volume named "HP Vol01" in the storage represented by the $storage variable. The storage object is obtained with Get-HP4Storage and assigned to the variable beforehand. Get-HP4Volume -Storage $storage -Name "HP Vol01"

223 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Get-VBRBackup Short Description Returns the list of backup files.

Applies to Version: 7.0 and earlier Platform: VMware, Hyper-V

Syntax Get-VBRBackup [-Name ] [-WarningAction ] [-WarningVariable ] []

Detailed Description This cmdlet returns a list of all backups stored in the Veeam Backup & Replication database. By default, the backup files are named by backup jobs names. You can get the list of all backup files or look for instances directly by name. See what else you can perform on your backup files Run Get-VBRJob to get the list of backup, replication or copy jobs.

Return Type CBackup

Parameters Parameter

Name

Description

Required

Position

Accept Pipeline Input

Accept Wildcard Characters

Specifies the name of the backup file you want to get, or search conditions.

False

Named

False

False

You can specify multiple names separated by commas.

This cmdlet supports Microsoft PowerShell common parameters. For more information about common parameters, see http://go.microsoft.com/fwlink/p/?LinkID=113216.

224 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Example 1 This command looks for all backups stored in the database. Get-VBRBackup

Example 2 This command looks for the backups named "vCloud Webservices Backup" and "Exchange Backup_imported". Get-VBRBackup -Name "vCloud Webservices Backup", "Exchange Backup_imported"

225 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Get-VBRBackupRepository Short Description Returns the list of all backup repositories.

Applies to Version: 7.0 and earlier Platform: VMware

Syntax Get-VBRBackupRepository [-Name ] [-WarningAction ] [-WarningVariable ] []

Detailed Description This cmdlet returns a list of all backup repositories managed by Veeam Backup & Replication. You can get the list of all backup repositories or look for instances directly by name. See what else you can perform on backup repositories

Return Type CBackupRepository

Parameters Parameter

Name

Description

Required

Position

Accept Pipeline Input

Accept Wildcard Characters

Specifies the name of the backup repository you want to get, or search conditions.

False

Named

False

True

You can specify multiple names separated by commas.

This cmdlet supports Microsoft PowerShell common parameters. For more information about common parameters, see http://go.microsoft.com/fwlink/p/?LinkID=113216.

226 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Example 1 This command looks for the list of all backup repositories managed by Veeam Backup & Replication. Get-VBRBackupRepository

Example 2 This command looks for the backup repositories named "Backups Vol2" and for backup repositories with names starting with "Local". Get-VBRBackupRepository -Name "Backups Vol2", "*Local"

227 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Get-VBRBackupSession Short Description Returns a list of backup sessions that have been run.

Applies to Version: 7.0 and earlier Platform: VMware

Syntax Get-VBRBackupSession [-Name ] [-WarningAction ] [-WarningVariable ] []

Detailed Description This cmdlet returns a list of all backup, replication and backup copy sessions that have been run. You can get the list of all backup, replication and backup copy sessions, or look for instances directly by name. Run Get-VBRTaskSession to get the list of all tasks performed during the specific backup, replication or backup copy session. Run Get-VSBSession to get the list of SureBackup sessions that have been run. See what else you can perform on sessions

Return Type CBackupSession

Parameters Parameter

Description

Required

Position

Accept Pipeline Input

Accept Wildcard Characters

False

Named

False

True

Specifies the name of the backup session you want to get, or search conditions. Name

The name of the session is a name of the job. You can specify multiple names separated by commas.

This cmdlet supports Microsoft PowerShell common parameters. For more information about common parameters, see http://go.microsoft.com/fwlink/p/?LinkID=113216.

228 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Example 1 This command looks for the list of all backup sessions. Get-VBRBackupSession

Example 2 This command looks for all backup copy sessions. Get-VBRBackupSession -Name *Copy Job*

229 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Get-VBRCredentials Short Description Returnes a list of credentials records.

Applies to Version: 7.0 Platform: VMware, Hyper-V

Syntax Get-VBRCredentials [-Name ] [-WarningAction ] [-WarningVariable ] []

Detailed Description This cmdlet returns a list of credentials managed by Veeam Backup & Replication. You can get the list of all credentials or look for instances directly by name. See what else you can perform on credentials

Return Type CCredentials

Parameters Parameter

Name

Description Specifies the user name or search conditions. You can specify multiple names separated by commas.

Required

Position

Accept Pipeline Input

Accept Wildcard Characters

False

Named

False

True

This cmdlet supports Microsoft PowerShell common parameters. For more information about common parameters, see http://go.microsoft.com/fwlink/p/?LinkID=113216.

Example This command gets the list of credentials records containing "Administrator" in the account name. Get-VBRCredentials -Name *Administrator*

230 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Get-VBRFilesInRestorePoint Short Description Returns a list of all files for the selected restore point.

Applies to Version: 7.0 and earlier Platform: VMware

Syntax Get-VBRFilesInRestorePoint [-RestorePoint] [-Name ] [-WarningAction ] [-WarningVariable ] []

Related Commands Get-VBRRestorePoint

Detailed Description This cmdlet returns a list of all files for the selected restore point. You can get the list of all files in a selected restore point or look for instances directly by name. See what else you can perform on restore points

Return Type COIBFileInfo

Parameters Parameter

Description

RestorePoint

Specifies the restore points for which you want to get the list of files.

Name

Specifies the name of the file(s) you want to get, or search conditions. You can specify multiple names separated by commas.

Position

Accept Pipeline Input

Accept Wildcard Characters

True

1

True (ByValue, ByProperty Name)

False

False

Named

False

True

Required

This cmdlet supports Microsoft PowerShell common parameters. For more information about common parameters, see http://go.microsoft.com/fwlink/p/?LinkID=113216.

231 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Example 1 This command gets the list of files in the last restore point of the backup named "Webservices Backup". The restore point is obtained with Get-VBRRestorePoint and piped down. Get-VBRRestorePoint -Name "Webservices Backup" | Select -Last 1 | Get-VBRFilesInRestorePoint

Example 2 This command gets the list of files in the restore point represented by the $restorepoint variable. The restore point is obtained with Get-VBRRestorePoint and assigned to the variable beforehand. Get-VBRFilesInRestorePoint -RestorePoint $restorepoint

232 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Get-VBRHvProxy Short Description Returns a list of Hyper-V backup proxies.

Applies to Version: 7.0 and earlier Platform: Hyper-V For VMware, run Get-VBRViProxy.

Syntax Get-VBRHvProxy [-Name ] [-WarningAction ] [-WarningVariable ] []

Detailed Description This cmdlet returns a list of all Hyper-V backup proxies managed by Veeam Backup & Replication. You can get the list of all Hyper-V backup proxies or look for instances directly by name. See what else you can perform on your virtual proxies Run Get-VBRJobProxy to get the list of proxies assigned to a specific job.

Return Type CHvProxy

Parameters Parameter

Name

Description

Required

Position

Accept Pipeline Input

Accept Wildcard Characters

Specifies the name of the Hyper-V proxy server you want to get, or search conditions.

False

Named

False

True

You can specify multiple names separated by commas.

This cmdlet supports Microsoft PowerShell common parameters. For more information about common parameters, see http://go.microsoft.com/fwlink/p/?LinkID=113216.

233 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Example 1 This command looks for the list of all Hyper-V proxies. Get-VBRHvProxy

Example 2 This command gets the Hyper-V proxies with names containing "Local". Get-VBRHvProxy -Name *Local*

234 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Get-VBRInstantRecovery Short Description Returns the instant VM recovery session running at the moment.

Applies to Version: 7.0 Platform: VMware

Syntax Get-VBRInstantRecovery [-Full] [-WarningAction ] [-WarningVariable ] []

Detailed Description This cmdlet returns the instant VM recovery session running at the moment. You can get the information about the instant recovery sessions in short or detailed view. See what else you can perform on instant recovery

Return Type InstantRecoveryDetails

Parameters Parameter

Full

Description Specifies the information on sessions and history returned in detailed view.

Required

Position

Accept Pipeline Input

Accept Wildcard Characters

False

Named

False

False

This cmdlet supports Microsoft PowerShell common parameters. For more information about common parameters, see http://go.microsoft.com/fwlink/p/?LinkID=113216.

Example This command gets the list of the instant recovery sessions in detailed view. Get-VBRInstantRecovery -Full

235 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Get-VBRJob Short Description Returns a list of created jobs.

Applies to Version: 7.0 and earlier Platform: VMware, Hyper-V

Syntax Get-VBRJob [-Name ] [-WarningAction ] [-WarningVariable ] []

Detailed Description This cmdlet returns a list of jobs stored in Veeam Backup & Replication database. With this cmdlet, you can get the following jobs: •

Backup Jobs



Replication Jobs



Backup Copy Jobs



VM Copy Jobs



File Copy Jobs

You can get the list of all jobs or look for instances directly by name. Run Get-VBRBackupSession or Get-VBRTaskSession to get the information on job session or session tasks. Run Get-VBRTapeJob to get the list of tape jobs. Run Get-VSBJob to get the list of SureBackup jobs. See what else you can perform on jobs

Return Type CBackupJob

Parameters Parameter

Name

Description Specifies the name of the job you want to get, or search conditions.

Required

Position

Accept Pipeline Input

Accept Wildcard Characters

False

Named

False

True

You can specify multiple names separated by commas.

This cmdlet supports Microsoft PowerShell common parameters. For more information about common parameters, see http://go.microsoft.com/fwlink/p/?LinkID=113216.

236 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Example This command gets the list of backup copy jobs. Get-VBRJob -Name *Backup Copy Job*

237 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Get-VBRJobObject Short Description Returns the list of objects in the specified job.

Applies to Version: 7.0 and earlier Platform: VMware, Hyper-V

Syntax Get-VBRJobObject [-Job] [-Name ] [WarningAction ] [-WarningVariable ] []

Related Commands Get-VBRJob

Detailed Description This cmdlet returns a list of objects in the specified job. The job objects are VMs, VM containers, datastores or resource pools. You can run this cmdlet for backup, replication, backup copy, VM copy or file copy jobs. See what else you can perform on job objects

Return Type CObjectInJob

Parameters Parameter

Job

Name

Description

Specifies the job you want to get the objects of. Specifies the name of the job object (i.e. a VM) you want to get, or search conditions. You can specify multiple names separated by commas.

Position

Accept Pipeline Input

Accept Wildcard Characters

True

1

True (ByValue, ByProperty Name)

False

False

Named

False

True

Required

This cmdlet supports Microsoft PowerShell common parameters. For more information about common parameters, see http://go.microsoft.com/fwlink/p/?LinkID=113216.

238 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Example 1 This command looks for the SharePoint VMs in the job named "VM Copy Job 01". The job is obtained with Get-VBRJob and piped down. Get-VBRJob -Name "VM Copy Job 01" | Get-VBRJobObject -Name *SharePoint*

Example 2 This command looks for the VM named "SharePoint" in the job represented by the $job variable. The job is obtained with Get-VBRJob and assigned to the variable beforehend. Get-VBRJobObject -Job $job -Name "SharePoint"

239 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Get-VBRJobObjectVssOptions Short Description Returns a list of VSS settings set for specific VM in job.

Applies to Version: 7.0 and earlier Platform: VMware

Syntax Get-VBRJobObjectVssOptions [-ObjectInJob] [WarningAction ] [-WarningVariable ] []

Related Commands Get-VBRJobObject

Detailed Description This cmdlet returns a list of VSS settings set for specific VM in the job. VSS (Volume Shadow Services) is a Windows OS service allowing to copy files of running applications that can be modified at the moment of copying. The VSS-aware applications typically are Active Directory, Microsoft SQL, Microsoft Exchange, Sharepoint, etc. To create a transactionally consistent backup of a VM running VSS-aware applications without shutting them down, Veeam Backup & Replication uses application-aware image processing. It allows backup the data fully and consistently. Run Get-VBRJobVSSOptions to get the list of VSS options of a specific job. See what else you can perform on job objects

Return Type CVssOptions

Parameters Parameter

ObjectInJob

Description

Specifies the VMs or VM containers for which you want to get VSS options.

Required

True

Position

Accept Pipeline Input

Accept Wildcard Characters

1

True (ByValue, ByProperty Name)

False

This cmdlet supports Microsoft PowerShell common parameters. For more information about common parameters, see http://go.microsoft.com/fwlink/p/?LinkID=113216.

240 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Example 1 This command looks for the VSS settings of the first VM included in job named "Exchange Backup Copy". The job to look for the VM in is obtained with Get-VBRJob and piped down. The VM is obtained with Get-VBRJobObject by selecting the first VM in the job object list and piped down. Get-VBRJob -Name "Exchange Backup Copy" | Get-VBRJobObject | Select -First 1 | Get-VBRJobObjectVssOptions

Example 2 This command looks for the VSS settings of the VM represented by the $vm variable. The VM is obtained with Get-VBRJobObject and assigned to the variable beforehand. Get-VBRJobObjectVssOptions -ObjectInJob $vm

241 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Get-VBRJobOptions Short Description Returns a list of job settings.

Applies to Version: 7.0 and earlier Platform: VMware

Syntax Get-VBRJobOptions [-Job] [-WarningAction ] [-WarningVariable ] []

Related Commands Get-VBRJob

Detailed Description This cmdlet returns a list of job settings for a selected job. See what else you can perform on job options

Return Type CJobOptions

Parameters Parameter

Job

Description

Specifies the job you want to get the options of.

Required

True

Position

Accept Pipeline Input

Accept Wildcard Characters

1

True (ByValue, ByProperty Name)

False

This cmdlet supports Microsoft PowerShell common parameters. For more information about common parameters, see http://go.microsoft.com/fwlink/p/?LinkID=113216.

242 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Example 1 This command looks for the list of options of the job named "Fileserver Replica". The job is obtained with Get-VBRJob and piped down. Get-VBRJob -Name "Fileserver Replica" | Get-VBRJobOptions

Example 2 This command looks for the list of options of the job represented by the $"Fileserver Replica" variable. The job is obtained with Get-VBRJobObject and assigned to the variable beforehand. Get-VBRJobOptions -Job $"Fileserver Replica Job"

243 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Get-VBRJobProxy Short Description Returns the list of proxy servers assigned to a selected job.

Applies to Version: 7.0 Platform: VMware, Hyper-V

Syntax Get-VBRJobProxy -Job [-Target] [-WarningAction ] [-WarningVariable ] []

Related Commands Get-VBRJob

Detailed Description This cmdlet returns the list of source or target proxy servers assigned to a selected job. You will see the notification if the automatic proxy selection is enabled. See what else you can perform on job assigned proxies Run Get-VBRViProxy or Get-VBRHvProxy to get a list of all VMware or Hyper-V proxies managed by Veeam Backup & Replication.

Return Type CViProxy or CHvProxy

Parameters Parameter

Job

Description Specifies the job for which you want to get the list proxies.

Position

Accept Pipeline Input

Accept Wildcard Characters

True

Named

True (ByValue, ByProperty Name)

False

False

Named

False

False

Required

You can assign multiple backup jobs to this object.

Target

If set, the command returns the list of target proxy servers. If omitted, the command returns the list of source proxy servers.

This cmdlet supports Microsoft PowerShell common parameters. For more information about common parameters, see http://go.microsoft.com/fwlink/p/?LinkID=113216.

244 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Example 1 This command looks for the list of target proxies assigned to the job named "Backup Job 01". The job object is obtained with Get-VBRJob and piped down. Get-VBRJob -Name "Backup Job 01" | Get-VBRJobProxy -Target

Example 2 This command looks for the list of source proxies assigned to the job named "Backup Job 01". The job object is obtained with Get-VBRJob and piped down. Get-VBRJob -Name "Backup Job 01" | Get-VBRJobProxy

Example 3 This command looks for the list of target proxies represented by the $"Job 1" variable. The job object is obtained with Get-VBRJob and assigned to the variable beforehand. Get-VBRJobProxy -Job $"Job 1"

245 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Get-VBRJobScheduleOptions Short Description Returns a list of scheduling settings for a selected job.

Applies to Version: 7.0 and earlier Platform: VMware

Syntax Get-VBRJobScheduleOptions [-Job] [-WarningAction ] [-WarningVariable ] []

Related Commands Get-VBRJob

Detailed Description This cmdlet returns a list of job scheduling options for a selected job. See what else you can perform on job options

Return Type ScheduleOptions

Parameters Parameter

Job

Description

Specifies the job you want to get the scheduling options of.

Required

True

Position

Accept Pipeline Input

Accept Wildcard Characters

1

True (ByValue, ByProperty Name)

False

This cmdlet supports Microsoft PowerShell common parameters. For more information about common parameters, see http://go.microsoft.com/fwlink/p/?LinkID=113216.

246 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Example 1 This command looks for the list of schedulling options of the job named "ActiveDirectory Copy Job". The job is obtained with Get-VBRJob and piped down. Get-VBRJob -Name "ActiveDirectory Copy Job" | GetVBRJobScheduleOptions

Example 2 This command looks for the list of options of the job represented by the $"ActiveDirectory Copy Job" variable. The job is obtained with Get-VBRJobObject and assigned to the variable beforehand. Get-VBRJobScheduleOptions -Job $"ActiveDirectory Copy Job"

247 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Get-VBRJobVSSOptions Short Description Returns a list of VSS settings for a selected job.

Applies to Version: 7.0 and earlier Platform: VMware

Syntax Get-VBRJobVSSOptions [-Job] [-WarningAction ] [-WarningVariable ] []

Related Commands Get-VBRJob

Detailed Description This cmdlet returns a list of VSS settings for a selected job. See what else you can perform on job options Run Get-VBRJobObjectVssOptions to get the list of VSS options set for specific objects in a job.

Return Type CVssOptions

Parameters Parameter

Job

Description

Specifies the job you want to get the VSS options of.

Required

True

Position

Accept Pipeline Input

Accept Wildcard Characters

1

True (ByValue, ByProperty Name)

False

This cmdlet supports Microsoft PowerShell common parameters. For more information about common parameters, see http://go.microsoft.com/fwlink/p/?LinkID=113216.

248 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Example 1 This command looks for the list of VSS options of the job named "ActiveDirectory Backup". The job is obtained with Get-VBRJob and piped down. Get-VBRJob -Name "ActiveDirectory Backup" | Get-VBRJobVSSOptions

Example 2 This command looks for the list of options of the job represented by the $ad_backup variable. The job is obtained with Get-VBRJobObject and assigned to the variable beforehand. Get-VBRJobVSSOptions -Job $ad_backup

249 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Get-VBRLocalhost Short Description Returns returns the local server Veeam Backup & Replication is installed on.

Applies to Version: 7.0 and earlier Platform: VMware

Syntax Get-VBRLocalhost [-WarningAction ] [WarningVariable ] []

Detailed Description This cmdlet returns the local server Veeam Backup & Replication is installed on. See what else you can perform on your virtual infrastructure instances

Return Type CHost This cmdlet supports Microsoft PowerShell common parameters. For more information about common parameters, see http://go.microsoft.com/fwlink/p/?LinkID=113216.

Example This command looks for the local Veeam Backup & Replication server. Get-VBRLocalhost

250 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Get-VBRReplica Short Description Returns the list of replicated VMs.

Applies to Version: 7.0 and earlier Platform: VMware, Hyper-V

Syntax Get-VBRReplica [-Name ] [-WarningAction ] [-WarningVariable ] []

Detailed Description This cmdlet returns the list of replicated VMs managed by Veeam Backup & Replication. See what else you can perform on replicas

Return Type CBackup

Parameters Description

Required

Position

Accept Pipeline Input

Accept Wildcard Characters

Specifies the name of the replication job you want to get, or search conditions.

False

Named

False

True

Parameter

Name

You can specify multiple names separated by commas.

This cmdlet supports Microsoft PowerShell common parameters. For more information about common parameters, see http://go.microsoft.com/fwlink/p/?LinkID=113216.

Example 1 This command looks for all replicas managed by Veeam Backup & Replication. Get-VBRReplica

Example 2 This command looks for the replicas with names starting with "DC". Get-VBRReplica -Name DC*

251 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Get-VBRRestorePoint Short Description Returns the list of restore points.

Applies to Version: 7.0 and earlier Platform: VMware, Hyper-V

Syntax Get-VBRRestorePoint [[-Backup] ] [-Name ] [WarningAction ] [-WarningVariable ] []

Related Commands Get-VBRBackup

Detailed Description This cmdlet returns a list of restore points stored in Veeam Backup & Replication database. You can get the list of restore points of all VMs managed by Veeam Backup & Replication, or get the restore points for a specific backup or for a specific VM. See what else you can perform on restore points

Return Type COib

Parameters Parameter

Backup

Description Specifies the backup for which you want to get the restore points.

Position

Accept Pipeline Input

Accept Wildcard Characters

False

1

True (ByValue, ByProperty Name)

False

False

Named

False

True

Required

You can assign multiple backups to this object.

Name

Specifies the name of the VM for which you want to get the restore points, or search conditions. You can specify multiple names separated by commas.

This cmdlet supports Microsoft PowerShell common parameters. For more information about common parameters, see http://go.microsoft.com/fwlink/p/?LinkID=113216.

252 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Example 1 This command looks for the latest restore point of the VM named "MSExchange02" in the backup named "MSExchange Backup". The backup is obtained with Get-VBRBackup and piped down. The restore points of the VM are filtered with Sort-Object method by the "creationtime" property to get the most recent one. Get-VBRBackup -Name "MSExchange Backup" | Get-VBRRestorePoint Name *MSExchange02* | Sort-Object $_.creationtime -Descending | Select -First 1

Example 2 This command looks for the restore points of the backup represented by the variable $backup. The backup to look the restore points in is obtained with Get-VBRBackup and assigned to the variable beforehand. Get-VBRRestorePoint -Backup $backup

253 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Get-VBRRestoreSession Short Description Returns the list of restore sessions.

Applies to Version: 7.0 and earlier Platform: VMware, Hyper-V

Syntax Get-VBRRestoreSession [-Name ] [-WarningAction ] [-WarningVariable ] []

Detailed Description This cmdlet returns a list of all restore sessions stored in Veeam Backup & Replication database. You can get the list of all restore sessions or get the restore sessions of a specific VM or VM(s). See what else you can perform on restore See what else you can perform on sessions

Return Type CRestoreSession

Parameters Parameter

Name

Description Specifies the name of the VM you want to get the restore session of, or search conditions.

Required

Position

Accept Pipeline Input

Accept Wildcard Characters

False

Named

False

True

You can specify multiple names separated by commas.

This cmdlet supports Microsoft PowerShell common parameters. For more information about common parameters, see http://go.microsoft.com/fwlink/p/?LinkID=113216.

254 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Example 1 This command looks for all restore sessions stored in the database. Get-VBRRestoreSession

Example 2 This command looks for the restore sessions of the VMs named "Hv_DNS" and "Hv_DC". Get-VBRRestoreSession -Name "Hv_DNS", "Hv_DC"

255 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Get-VBRServer Short Description This cmdlet returns a list of all hosts connected to Veeam Backup & Replication.

Applies to Version: 7.0 and earlier Platform: VMware, Hyper-V

Syntax Get-VBRServer [-Type ] [-Name ] [WarningAction ] [-WarningVariable ] []

Detailed Description This cmdlet returns a list of all hosts connected to Veeam Backup & Replication. You can get the list of all hosts or narrow down the output to the servers of specific type, or search for instances directly by name. Run Find-VBRViEntity or Find-VBRHvEntity to look for VMware or Hyper-V virtual objects registered on these hosts. See what else you can perform on your virtual infrastructure instances

Return Type CHost

Parameters Parameter

Description

Required

Position

Accept Pipeline Input

Accept Wildcard Characters

False

Named

False

False

Specifies the server type: - BackupServer - ESX - ESXi - HvCluster - HvServer Type

- Linux - Local - SanHost - Scvmm - SmbCluster - SmbServer - VC - VcdSystem

256 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Parameter

Description

Required

Position

Accept Pipeline Input

Accept Wildcard Characters

False

Named

False

True

- Windows

Name

Specifies the name of the server you want to get, or search conditions. You can specify multiple names separated by commas.

This cmdlet supports Microsoft PowerShell common parameters. For more information about common parameters, see http://go.microsoft.com/fwlink/p/?LinkID=113216.

Example 1 This command looks for the servers named "Active_Directory". Get-VBRServer -Name "Active_Directory"

Example 2 This command looks for the VM named "Hv_DNS" registered on a Hyper-V server. Get-VBRServer -Type HvServer -Name "Hv_DNS"

257 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Get-VBRTapeBackup Short Description Returns the list of backups recorded to tape.

Applies to Version: 7.0 Platform: VMware, Hyper-V

Syntax Get-VBRTapeBackup [-Name ] [-WarningAction ] [-WarningVariable ] []

Detailed Description This cmdlet returns the list of backups recorded to tape. Veeam Backup & Replication stores all data about the backups that were recorded to tapes in the database, and you can view the list of files both while the tapes are online, or after they were removed from the library. The backups or files that were written to tapes with Veeam Backup & Replication are indexed automatically. Run Start-VBRTapeCatalog to index the imported tapes. Run Get-VBRTapeJob to get the list of the copy to tape jobs. See what else you can perform on tapes

Return Type Cbackup

Parameters Parameter

Name

Description Specifies the name(s) of the backup or search conditions. You can specify multiple names separated by commas.

Required

Position

Accept Pipeline Input

Accept Wildcard Characters

False

Named

False

True

This cmdlet supports Microsoft PowerShell common parameters. For more information about common parameters, see http://go.microsoft.com/fwlink/p/?LinkID=113216.

258 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Example 1 This command looks for all backups recorded to tapes. Get-VBRTapeBackup

Example 2 This command looks for backups named "VM01" and "VM05". Get-VBRTapeBackup -Name "VM01", "VM05"

259 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Get-VBRTapeDrive Short Description Returns the list of tape drives.

Applies to Version: 7.0 Platform: VMware, Hyper-V

Syntax Get-VBRTapeDrive [-Library ] [-Name ] [WarningAction ] [-WarningVariable ] []

Related Commands Get-VBRTapeLibrary

Detailed Description This cmdlet returns the list of tape recording drives. You can also view the model name, the state of the drive and whether it is enabled or disabled. You can get the whole list of drives throughout all libraries, or the list of drives within specified library, or search for instances directly by name. See what else you can perform on tapes

Return Type TapeDrive

Parameters Parameter

Library

Name

Description

Specifies the tape medium library that the tape drive belongs to. Specifies the tape drive name(s), or search conditions. You can specify multiple names separated by commas.

Position

Accept Pipeline Input

Accept Wildcard Characters

False

Named

True (ByValue, ByProperty Name)

False

False

Named

False

True

Required

This cmdlet supports Microsoft PowerShell common parameters. For more information about common parameters, see http://go.microsoft.com/fwlink/p/?LinkID=113216.

260 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Example 1 This command gets a tape drive named "Drive 01" in the library named "Lib HP01". The library object is obtained with Get-VBRTapeLibrary and piped down. Get-VBRTapeLibrary -Name "Lib HP01" | Get-VBRTapeDrive –Name "Drive 01"

Example 2 This command gets a tape drive named "Drive 01" in the library represented by the $"Lib HP01" variable. The library object is obtained with Get-VBRTapeLibrary and assigned to the variable beforehand. Get-VBRTapeDrive -Library $"Lib HP01" -Name "Drive 01"

261 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Get-VBRTapeJob Short Description Returns the list of copy to tape jobs.

Applies to Version: 7.0 Platform: VMware, Hyper-V

Syntax Get-VBRTapeJob [-Name ] [-WarningAction ] [-WarningVariable ] []

Detailed Description This cmdlet returns the list of copy to tape jobs registered in Veeam Backup & Replication database. Run Get-VBRTapeBackup to get the list of backups recorded to tape. See what else you can perform on tapes

Return Type CBackupJob

Parameters Parameter

Name

Description Specifies the name(s) of the tape job, or search conditions. You can specify multiple names separated by commas.

Required

Position

Accept Pipeline Input

Accept Wildcard Characters

False

Named

False

True

This cmdlet supports Microsoft PowerShell common parameters. For more information about common parameters, see http://go.microsoft.com/fwlink/p/?LinkID=113216.

262 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Example 1 This command looks for the list of all tape jobs registered in Veeam Backup & Replication database. Get-VBRTapeJob

Example 2 This command looks for tape jobs named "Fileserver 2Tape Backup Job" and "ActiveDirectory 2Tape Backup Job". Get-VBRTapeJob -Name "Fileserver 2Tape Backup Job", "ActiveDirectory 2Tape Backup Job"

263 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Get-VBRTapeLibrary Short Description Returns a list of tape libraries.

Applies to Version: 7.0 Platform: VMware, Hyper-V

Syntax Get-VBRTapeLibrary [-Name ] [-WarningAction ] [-WarningVariable ] []

Detailed Description This cmdlet returns a list of tape media libraries connected to Veeam Backup & Replication. You can get the list of all tape libraries, or search for instances directly by name. Run Start-VBRTapeInventory to rescan the list of tape entities managed by Veeam Backup & Replication. See what else you can perform on tapes

Return Type TapeLibrary

Parameters Parameter

Name

Description

Required

Position

Accept Pipeline Input

Accept Wildcard Characters

Specifies the name of the tape media library, or search conditions.

False

Named

False

True

You can specify multiple names separated by commas.

This cmdlet supports Microsoft PowerShell common parameters. For more information about common parameters, see http://go.microsoft.com/fwlink/p/?LinkID=113216.

264 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Example 1 This command gets a list of all tape media libraries connected to Veeam Backup & Replication. Get-VBRTapeLibrary

Example 2 This command gets a list of tape media libraries filtering the output by name starting with "HP...". Get-VBRTapeLibrary -Name HP*

265 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Get-VBRTapeMediaPool Short Description Returns a list of tape media pools.

Applies to Version: 7.0 Platform: VMware, Hyper-V

Syntax Get-VBRTapeMediaPool [-Library ] [-Name ] [-WarningAction ] [-WarningVariable ] []

Related Commands Get-VBRTapeLibrary

Detailed Description This cmdlet returns a list of tape media pools managed by Veeam Backup & Replication. Media pools are logical groups of tapes within a tape media library which may have predefined or custom names based on purpose, recorded data, and so on. You can get the list of media pools within specified library, or search for instances directly by name. Run Start-VBRTapeInventory to rescan the list of tape entities managed by Veeam Backup & Replication. See what else you can perform on tapes

Return Type MediaPool

Parameters Parameter

Library

Name

Description

Specifies the library that the media pool belongs to. Specifies the name(s) of the tape media library the media pool belongs to. You can specify multiple names separated by commas.

Position

Accept Pipeline Input

Accept Wildcard Characters

False

Named

True (ByValue, ByProperty Name)

False

False

Named

False

True

Required

This cmdlet supports Microsoft PowerShell common parameters. For more information about common parameters, see http://go.microsoft.com/fwlink/p/?LinkID=113216.

266 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Example 1 This command looks for the list of media pools in the "Lib HP01" library. The library object is obtained with Get-VBRTapeLibrary and piped down. Get-VBRTapeLibrary -Name "Lib HP01" | Get-VBRTapeMediaPool

Example 2 This command looks for the media pool named "Incremental Backups" in the library represented by the $"Lib HP01" variable. The library object is obtained with Get-VBRTapeLibrary and assigned to the variable beforehand. Get-VBRTapeMediaPool -Library $"Lib HP01" -Name "Incremental Backups'

267 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Get-VBRTapeMedium Short Description Returns a list of tapes.

Applies to Version: 7.0 Platform: VMware, Hyper-V

Syntax Get-VBRTapeMedium [-Name ] [-WarningAction ] [-WarningVariable ] [] Get-VBRTapeMedium [-Free] [-Name ] [-WarningAction ] [-WarningVariable ] [] Get-VBRTapeMedium [-Unrecognized] [-Name ] [WarningAction ] [-WarningVariable ] [] Get-VBRTapeMedium [-Offline] [-Name ] [-WarningAction ] [-WarningVariable ] [] Get-VBRTapeMedium [-Online] [-Name ] [-WarningAction ] [-WarningVariable ] [] Get-VBRTapeMedium -Backup [-Name ] [WarningAction ] [-WarningVariable ] [] Get-VBRTapeMedium -MediaPool [-Name ] [WarningAction ] [-WarningVariable ] [] Get-VBRTapeMedium -Library [-Name ] [WarningAction ] [-WarningVariable ] []

Related Commands Get-VBRBackup Get-VBRTapeMediaPool Get-VBRTapeLibrary

Detailed Description This cmdlet returns a list of tapes managed by Veeam Backup & Replication. You can get the full list of tapes or narrow down the output by name, by type (Free, Unrecognized,Offline, Online), by media pool or by tape library, or look for tapes containing a specific backup. Run Start-VBRTapeInventory to rescan the list of tape entities managed by Veeam Backup & Replication.

268 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

See what else you can perform on tapes

Return Type TapeMedium

Parameters Parameter

Description

Required

Position

Accept Pipeline Input

Accept Wildcard Characters

False

Named

False

True

Specifies the name of tape you want to get. Name

You can specify multiple names separated by commas.

Free

Narrows down your search conditions to the Free tapes.

False

Named

False

False

Unrecognized

Narrows down your search conditions to the Unrecognized tapes.

False

Named

False

False

Offline

Narrows down your search conditions to the Offline tapes.

False

Named

False

False

Online

Narrows down your search conditions to the Online tapes.

False

Named

False

False

Backup

Specifies the backup you want to get. You will get a tape or a list of tapes where the backup data is stored.

Named

True (ByValue, ByProperty Name)

False

MediaPool

Specifies the media pool within which you want to look for the tapes.

Named

True (ByValue, ByProperty Name)

False

Library

Specifies the tape library within which you want to look for the tapes.

Named

True (ByValue, ByProperty Name)

False

True

True

True

This cmdlet supports Microsoft PowerShell common parameters. For more information about common parameters, see http://go.microsoft.com/fwlink/p/?LinkID=113216.

269 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Example 1 The following command gets a tape named "00110001". Get-VBRTapeMedium -Name "00110001"

Example 2 The following command gets a tape with the barcode "00233400". Get-VBRTapeMedium | Where-Object {$_.barcode -eq "00233400"}

Example 3 This command looks for the list of tapes belonging to the media pool named "Incremental Backups". The media pool is obtained with Get-VBRTapeMediaPool and piped down. Get-VBRTapeMediaPool -Name "Incremental Backups" | GetVBRTapeMedium

270 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Get-VBRTaskSession Short Description Returns list of tasks performed during a specified session.

Applies to Version: 7.0 and earlier Platform: VMware

Syntax Get-VBRTaskSession [-Session] [-Name ] [-WarningAction ] [-WarningVariable ] []

Related Commands Get-VBRBackupSession

Detailed Description This cmdlet returns a list of all tasks performed during the specified session. You can get the tasks for backup, replication and backup copy sessions. Run Get-VSBTaskSession to get the tasks for SureBackup session. See what else you can perform on sessions

Return Type CBackupTaskSession

Parameters Parameter

Session

Name

Description

Specifies the session the tasks of which you want to get. Specifies the name of the job object within the session you indicated in -Session parameter the tasks for which you want to get.

Position

Accept Pipeline Input

Accept Wildcard Characters

True

1

True (ByValue, ByProperty Name)

False

False

Named

False

True

Required

You can specify multiple names separated by commas.

This cmdlet supports Microsoft PowerShell common parameters. For more information about common parameters, see http://go.microsoft.com/fwlink/p/?LinkID=113216.

271 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Example 1 This command gets the list of tasks performed for the VMs named "DC" and "DNS" in the backup job session named "Exchange Backup". The backup session is obtained with Get-VBRBackupSession and piped down. Get-VBRBackupSession -Name "Exchange Backup" | Get-VBRTaskSession -Name "DC", "DNS"

Example 2 This command gets the list of tasks performed for the VMs named "DC" and "DNS" in the backup job session represented by the $"Exchange Session" variable. The backup session is obtained with GetVBRBackupSession and assigned to the variable beforehand. Get-VBRTaskSession -Session $"Exchange Session" -Name "DC", "DNS"

272 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Get-VBRToolkitDocumentation Short Description Opens Veeam Backup & Replication Help.

Applies to Version: 7.0 and earlier Platform: VMware, Hyper-V

Syntax Get-VBRToolkitDocumentation

Detailed Description This cmdlet opens Veeam Backup & Replication Help in a separate window.

273 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Get-VBRViProxy Short Description Returns VMware backup proxies.

Applies to Version: 7.0 and earlier Platform: VMware For Hyper-V, run Get-VBRHvProxy.

Syntax Get-VBRViProxy [-Name ] [-WarningAction ] [-WarningVariable ] []

Detailed Description This cmdlet returns a list of all VMware backup proxies managed by Veeam Backup & Replication. See what else you can perform on your virtual proxies Run Get-VBRJobProxy to get the list of proxies assigned to a specific job.

Return Type CViProxy

Parameters Parameter

Name

Description

Required

Position

Accept Pipeline Input

Accept Wildcard Characters

Specifies the name of the VMware proxy you want to get, or search conditions.

False

Named

False

True

You can specify multiple names separated by commas.

This cmdlet supports Microsoft PowerShell common parameters. For more information about common parameters, see http://go.microsoft.com/fwlink/p/?LinkID=113216.

274 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Example 1 This command looks for the list of all VMware proxies. Get-VBRViProxy

Example 2 This command looks for the proxy named "LocalProxy". Get-VBRViProxy -Name "LocalProxy"

275 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Get-VBRWANAccelerator Short Description Returnes the list of WAN accelerators.

Applies to Version: 7.0 Platform: VMware, Hyper-V Note:

WAN optimization is available only in Veeam Backup & Replication Enterprise Plus Edition.

Syntax Get-VBRWANAccelerator [-Name ] [-WarningAction ] [-WarningVariable ] []

Detailed Description This cmdlet gets the list of WAN accelerators managed by Veeam Backup & Replication. WAN accelerator is an architecture component that optimizes file transfer via WAN by means of data deduplication. The role of a WAN accelerator can be assigned to a dedicated Windows-based machine (physical or virtual). For best performance you should set a WAN accelerator on both source and target sides. You can get the list of all WAN accelerators, or search for instances directly by name. See what else you can perform on backup copy

Return Type CwanAccelerator

Parameters Parameter

Name

Description Specifies the name(s) of the WAN accelerator, or search conditions.

Required

Position

Accept Pipeline Input

Accept Wildcard Characters

False

Named

False

True

You can specify multiple names separated by commas.

This cmdlet supports Microsoft PowerShell common parameters. For more information about common parameters, see http://go.microsoft.com/fwlink/p/?LinkID=113216.

276 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Example 1 This command looks for the list of all WAN accelerators. Get-VBRWANAccelerator

Example 2 This command looks for WAN accelerators with the names starting with "WAN". Get-VBRWANAccelerator -Name WAN*

277 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Get-VSBApplicationGroup Short Description Returns the list of application groups.

Applies to Version: 7.0 Platform: VMware, Hyper-V

Syntax Get-VSBApplicationGroup [-Name ] [-WarningAction ] [-WarningVariable ] []

Detailed Description This cmdlet returns the list of all created application groups. An application group is a component of SureBackup technology providing verification of virtual machines that need other virtual machines or services running, i.e. a domain controller, a DSN server or SQL database.To test such machines for recoverability, you need to create a SureBackup job and provide the copy of the production architecture running in a fenced-off environment that is performed by creating a virtual lab and an application group. The VMs in the application group are started first to ensure the proper testing environment for the primary VM. You can get the list of all application groups, or search for instances directly by name. See what else you can perform on SureBackup

Return Type CSbAppGroup

Parameters Parameter

Name

Description

Required

Position

Accept Pipeline Input

Accept Wildcard Characters

Specifies the name of the application group you want to get, or search conditions.

False

Named

False

True

You can specify multiple names separated by commas.

This cmdlet supports Microsoft PowerShell common parameters. For more information about common parameters, see http://go.microsoft.com/fwlink/p/?LinkID=113216.

278 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Example 1 This command looks for the list of all application groups. Get-VSBApplicationGroup

Example 2 This command looks for the application group named "MailServer Appgroup". Get-VSBApplicationGroup -Name "MailServer Appgroup"

279 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Get-VSBHvVirtualLab Short Description Returns a list of Hyper-V virtual labs.

Applies to Version: 7.0 Platform: Hyper-V For VMware, run Get-VSBVirtualLab.

Syntax Get-VSBVirtualLab [-Name ] [-WarningAction ] [-WarningVariable ] []

Detailed Description This cmdlet returns all Hyper-V virtual labs that are connected to Veeam Backup & Replication console. A virtual lab is a component of SureBackup technology providing verification of virtual machines that need other virtual machines or services running, i.e. a domain controller, a DSN server or SQL database.To test such machines for recoverability, you need to create a SureBackup job and provide the copy of the production architecture running in a fenced-off environment that is performed by creating a virtual lab and an application group. Please note, that when you add a new host to your Veeam Backup & Replication console, the virtual labs that are registered on it are not added automatically. Run Connect-VSBHvVirtualLab to add the virtual labs to your Veeam Backup & Replication console. You can get the list of all virtual labs, or search for instances directly by name. See what else you can perform on SureBackup

Return Type CHvSbVirtualLab

Parameters Parameter

Name

Description Specifies the name(s) of the virtual lab, or search conditions.

Required

Position

Accept Pipeline Input

Accept Wildcard Characters

False

1

False

True

You can specify multiple names separated by commas.

This cmdlet supports Microsoft PowerShell common parameters. For more information about common parameters, see http://go.microsoft.com/fwlink/p/?LinkID=113216.

280 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Example 1 This command looks for the list of all virtual labs created or connected to Veeam Backup & Replication. Get-VSBHvVirtualLab

Example 2 This command looks for the list of virtual labs with names starting with "Exchange". Get-VSBHvVirtualLab -Name Exchange*

281 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Get-VSBJob Short Description Returns a list of SureBackup jobs.

Applies to Version: 7.0 and earlier Platform: VMware, Hyper-V

Syntax Get-VSBJob [-Name ] [-WarningAction ] [-WarningVariable ] []

Detailed Description This cmdlet returns a list of all created SureBackup jobs. SureBackup is a Veeam recovery verification technology providing verification of virtual machines that need other virtual machines or services running, i.e. a domain controller, a DSN server or SQL database. To test such machines for recoverability, you need to create a SureBackup job and provide the copy of the production architecture running in a fenced-off environment that is performed by creating a virtual lab and an application group. You can get the list of all SureBackup jobs or look for specific jobs directly by name. Run Get-VSBSession or Get-VSBTaskSession to get the information on SureBackup session or session tasks. Run Get-VBRJob to look for backup, replication or copy jobs. See what else you can perform on SureBackup See what else you can perform on jobs

Return Type CSbJob

Parameters Parameter

Name

Description Specifies the name of the SureBackup job you want to get, or search conditions.

Required

Position

Accept Pipeline Input

False

Named

False

Accept Wildcard Characters

True

You can specify multiple names separated by commas.

This cmdlet supports Microsoft PowerShell common parameters. For more information about common parameters, see http://go.microsoft.com/fwlink/p/?LinkID=113216.

282 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Example 1 This command looks for the list of all created SureBackup jobs. Get-VSBJob

Example 2 This command looks for the SureBackup jobs named "SureJob 01" and "SureJob 02". Get-VSBJob -Name "SureJob 01", "SureJob 02"

283 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Get-VSBJobOptions Short Description Returns a list of settings of a selected SureBackup job.

Applies to Version: 7.0 and earlier Platform: VMware, Hyper-V

Syntax Get-VSBJobOptions [-Job] [-WarningAction ] [-WarningVariable ] []

Related Commands Get-VSBJob

Detailed Description This cmdlet returns a list of job settings for the specified SureBackup job. See what else you can perform on job options See what else you can perform on SureBackup

Return Type CDRJobOptions

Parameters Parameter

Job

Description

Specifies the SureBackup job you want to get the settings of.

Required

True

Position

Accept Pipeline Input

Accept Wildcard Characters

1

True (ByValue, ByProperty Name)

False

This cmdlet supports Microsoft PowerShell common parameters. For more information about common parameters, see http://go.microsoft.com/fwlink/p/?LinkID=113216.

284 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Example 1 This command looks for the list of job settings for the SureBackup job named "SureJob 02". The SureBackup job is obtained with Get-VSBJob and piped down. Get-VSBJob -Name "SureJob 02" | Get-VSBJobOptions

Example 2 This command looks for the list of job settings for the SureBackup job represented by the $SureJob variable. The SureBackup job is obtained with Get-VSBJob and assigned to the variable beforehand. Get-VSBJobOptions -Job $SureJob

285 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Get-VSBJobScheduleOptions Short Description Returns a list of scheduling settings of a selected SureBackup job.

Applies to Version: 7.0 and earlier Platform: VMware, Hyper-V

Syntax Get-VSBJobScheduleOptions [-Job] [-WarningAction ] [-WarningVariable ] []

Related Commands Get-VSBJob

Detailed Description This cmdlet returns a list of job scheduling options for the specified SureBackup job. See what else you can perform on job options See what else you can perform on SureBackup

Return Type ScheduleOptions

Parameters Parameter

Job

Description

Specifies the SureBackup job you want to get the scheduling settings of.

Required

True

Position

Accept Pipeline Input

Accept Wildcard Characters

1

True (ByValue, ByProperty Name)

False

This cmdlet supports Microsoft PowerShell common parameters. For more information about common parameters, see http://go.microsoft.com/fwlink/p/?LinkID=113216.

286 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Example 1 This command looks for the list of job settings for the SureBackup job named "SureJob 02". The SureBackup job is obtained with Get-VSBJob and piped down. Get-VSBJob -Name "SureJob 02" | Get-VSBJobScheduleOptions

Example 2 This command looks for the list of job settings for the SureBackup job represented by the $SureJob variable. The SureBackup job is obtained with Get-VSBJob and assigned to the variable beforehand. Get-VSBJobScheduleOptions -Job $SureJob

287 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Get-VSBSession Short Description Returns a list of SureBackup sessions that have been run.

Applies to Version: 7.0 and earlier Platform: VMware, Hyper-V

Syntax Get-VSBSession [-Name ] [-WarningAction ] [-WarningVariable ] []

Detailed Description This cmdlet returns a list of all SureBackup sessions that have been run. Run Get-VSBTaskSession to get the list of all tasks performed during the specific SureBackup session. Run Get-VBRBackupSession to get list of backup sessions that have been run. See what else you can perform on SureBackup See what else you can perform on sessions

Return Type CSbSession

Parameters Parameter

Description

Required

Position

Accept Pipeline Input

Accept Wildcard Characters

False

Named

False

True

Specifies the name of the SureBackup session you want to get, or search conditions. Name

The name of the SureBackup session is a name of the SureBackup job. You can specify multiple names separated by commas.

This cmdlet supports Microsoft PowerShell common parameters. For more information about common parameters, see http://go.microsoft.com/fwlink/p/?LinkID=113216.

288 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Example 1 This command looks for the list of all backup sessions. Get-VSBSession

Example 2 This command looks for the SureBackup session named "Winserver SureJob". Get-VSBSession -Name *Winserver SureJob*

289 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Get-VSBTaskSession Short Description Returns a list of all tasks performed during the specified SureBackup session.

Applies to Version: 7.0 and earlier Platform: VMware, Hyper-V

Syntax Get-VSBTaskSession [-Session] [-Name ] [WarningAction ] [-WarningVariable ] []

Related Commands Get-VSBSession

Detailed Description This cmdlet returns a list of all tasks performed during the specified SureBackup session. Run Get-VBRTaskSession to get the tasks for backup, replication and backup copy sessions. See what else you can perform on SureBackup See what else you can perform on sessions

Return Type CSbTaskSession

Parameters Parameter

Session

Name

Description

Specifies the SureBackup session the tasks of which you want to get. Specifies the name of the SureBackup job object within the session you indicated in Session parameter the tasks for which you want to get.

Position

Accept Pipeline Input

Accept Wildcard Characters

True

1

True (ByValue, ByProperty Name)

False

False

Named

False

True

Required

You can specify multiple names separated by commas.

This cmdlet supports Microsoft PowerShell common parameters. For more information about common parameters, see http://go.microsoft.com/fwlink/p/?LinkID=113216.

290 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Example 1 This command gets the list of tasks performed for the VMs named "DC" and "DNS" in the SureBackup job session named "Exchange SureJob". The SureBackup session is obtained with Get-VSBSession and piped down. Get-VSBSession -Name "Exchange SureJob" | Get-VBRTaskSession Name "DC", "DNS"

Example 2 This command gets the list of tasks performed for the VMs named "DC" and "DNS" in the SureBackup job session represented by the $"Exchange SureJob" variable. The SureBackup session is obtained with Get-VSBSession and assigned to the variable beforehand. Get-VSBTaskSession -Session $"Exchange SureJob" -Name "DC", "DNS"

291 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Get-VSBVirtualLab Short Description Returns the list of VMware virtual labs.

Applies to Version: 7.0 and earlier Platform: VMware For Hyper-V, run Get-VSBHvVirtualLab.

Syntax Get-VSBVirtualLab [-Name ] [-WarningAction ] [-WarningVariable ] []

Detailed Description This cmdlet returns the list of all created VMware virtual labs. A virtual lab is a component of SureBackup technology providing verification of virtual machines that need other virtual machines or services running, i.e. a domain controller, a DSN server or SQL database. To test such machines for recoverability, you need to create a SureBackup job and provide the copy of the production architecture running in a fenced-off environment that is performed by creating a virtual lab and an application group. Please note, that when you add a new host to your Veeam Backup & Replication console, the virtual labs that are registered on it are not added automatically. Run Connect-VSBVirtualLab to add the virtual labs to your Veeam Backup & Replication console. You can get the list of all virtual labs, or search for instances directly by name. See what else you can perform on SureBackup

Return Type CViSbVirtualLab

Parameters Parameter

Name

Description

Required

Position

Accept Pipeline Input

Accept Wildcard Characters

Specifies the name of the VMware virtual lab you want to get, or search conditions.

False

Named

False

True

You can specify multiple names separated by commas.

This cmdlet supports Microsoft PowerShell common parameters. For more information about common parameters, see http://go.microsoft.com/fwlink/p/?LinkID=113216.

292 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Example 1 This command looks for the list of all virtual labs. Get-VSBVirtualLab

Example 2 This command looks for the virtual labs named "MailServer VLab 01" and "MailServer VLab 05". Get-VSBVirtualLab -Name "MailServer VLab 01", "MailServer VLab 05"

293 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Import-VBRBackup Short Description Imports backup files to Veeam Backup & Replication.

Applies to Version: 7.0 and earlier Platform: VMware, Hyper-V

Syntax Import-VBRBackup [-Server] [-FileName] [WarningAction ] [-WarningVariable ] []

Related Commands Get-VBRServer

Detailed Description This cmdlet imports backup files to Veeam Backup & Replication. You can import backups, i.e. from a server that is not managed by Veeam Backup & Replication or after adding a new backup repository. See what else you can perform on your backup files

Parameters Parameter

Description

Required

Position

Accept Pipeline Input

Accept Wildcard Characters

False

False

Server

Specifies the target server where you want to store the imported backups.

True

1

True (ByValue, ByProperty Name)

FileName

Specifies the path to the backup file you want to import.

True

2

False

This cmdlet supports Microsoft PowerShell common parameters. For more information about common parameters, see http://go.microsoft.com/fwlink/p/?LinkID=113216.

294 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Example 1 This command imports the folder with SureBackup files to the server named "Fileserver". The target server is obtained with Get-VBRServer and piped down. The file path is ESX17.Veeam.Local\C:\Backups\SureBackups. Get-VBRServer -Name "Fileserver" | Import-VBRBackup -FileName "ESX17.Veeam.Local\C:\Backups\SureBackups"

Example 2 This command imports the folder with SureBackup files to the server represented by the $server variable. The target server is obtained with Get-VBRServer and assigned to the variable beforehand. The file path is ESX17.Veeam.Local\C:\Backups\SureBackups. Import-VBRBackup -Server $server -FileName "ESX17.Veeam.Local\C:\Backups\SureBackups"

295 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Import-VBRConfiguration Short Description Imports backup of Veeam Backup & Replication server configuration file.

Applies to Version: 7.0 Platform: VMware, Hyper-V

Syntax Import-VBRConfiguration -FileName [-DatabaseName ] [-WarningAction ] [-WarningVariable ] []

Detailed Description This cmdlet imports configuration file of Veeam Backup & Replication that was previously backed up. With configuration backup, you can store a copy of your host configuration: your virtual infrastructure, jobs configuration, Veeam Backup & Replication settings and other data. You can restore configuration in case the Veeam Backup & Replication host is failed or configuration is corrupted. By default, configuration backups are stored to the C:\backup\VeeamConfigBackup\%BackupServer% folder on the Veeam backup server. You can select any configuration file to restore to. You can restore configuration data to the default Veeam Backup & Replication SQL database or to another database. If you restore to the default database, it is recommended to backup the database first. Run Export-VBRConfiguration to retrieve and export your current configuration.

Parameters Description

Required

Position

Accept Pipeline Input

Accept Wildcard Characters

Specifies the configuration file path you want to restore.

True

Named

False

False

False

Named

False

False

Parameter

FileName

DatabaseName

Specifies the name of the database into which data from the configuration backup should be imported. If not set, the data will be restored to the Veeam Backup & Replication database set by default.

This cmdlet supports Microsoft PowerShell common parameters. For more information about common parameters, see http://go.microsoft.com/fwlink/p/?LinkID=113216.

296 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Example 1 This command imports a configuration backup file named "VEEAMBACKUP-10-06-2013" to the default database. Import-VBRConfiguration -FileName "C:\backup\VeeamConfigBackup\VEEAMBACKUP\VEEAMBACKUP-10-06-2013"

Example 2 This command imports a configuration backup file named "VEEAMBACKUP-10-06-2013" to the database named "ConfigBackup". Import-VBRConfiguration -FileName "C:\backup\VeeamConfigBackup\VEEAMBACKUP\VEEAMBACKUP-10-06-2013" -DatabaseName "ConfigBackup"

297 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Import-VBRTapeMedium Short Description Moves new tape to library.

Applies to Version: 7.0 Platform: VMware, Hyper-V

Syntax Import-VBRTapeMedium [-RunAsync] [-WarningAction ] [-WarningVariable ] [] -ORImport-VBRTapeMedium [-Library ] [-RunAsync] [WarningAction ] [-WarningVariable ] []

Related Commands Get-VBRTapeLibrary

Detailed Description This cmdlet moves tapes that are inserted in the mail slot to an available slot in a library. You need to put the new tapes to the mail slot manually. The slot to put the tape in is selected automatically. The mail slot is the slot through which you can put the new tapes into the library and take the tapes with data out. The mail slot is a service slot and you do not manage the tape residing inside it until it is imported to the library or after it is exported. You can move new tapes to a free slot selected automatically or to a specific library. This cmdlet provides two scenarios for each case. Use Export-VBRTapeMedium cmdlet to move tapes to the mail slot to take them out of the library. See what else you can perform on tapes

Parameters Parameter

Description

Required

Position

Accept Pipeline Input

Accept Wildcard Characters

False

False

Library

Specifies the library you want to move the tapes to.

False

Named

True (ByValue, ByProperty Name)

RunAsync

Indicates that the command returns immediately without waiting for the task to complete.

False

Named

False

298 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

This cmdlet supports Microsoft PowerShell common parameters. For more information about common parameters, see http://go.microsoft.com/fwlink/p/?LinkID=113216.

Example 1 This command moves the tapes from the mail slot to an automatically selected free slot. The RunAsync parameter is set to bring the process to the background. Import-VBRTapeMedium -RunAsync

Example 2 This command moves the tape from the mail slot to the library with name containing "HP Lib003". The library object is obtained with Get-VBRTapeLibrary and piped down. The -RunAsync parameter is set to bring the process to the background. Get-VBRTapeLibrary -Name "HP Lib003" | Import-VBRTapeMedium RunAsync

299 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Move-VBRTapeMedium Short Description Moves a tape to another tape media pool.

Applies to Version: 7.0 Platform: VMware, Hyper-V

Syntax Move-VBRTapeMedium -Medium -MediaPool []

Related Commands Get-VBRTapeMedium Get-VBRTapeMediaPool

Detailed Description This cmdlet moves a selected tape to specified tape media pool. If you move tape with data to the Free media pool and confirm the operation, Mark as Free will take effect and the data will be overwritten. See what else you can perform on tapes Important! If a tape media is used by an existing tape\file backup job, it will be removed only after the job is finished. In case you definitely have to disable this pool, you should first modify the corresponding job to target another media pool.

Parameters Parameter

Medium

MediaPool

Description Specifies the tape(s) you want to move. You can assign multiple tapes to this object. Specifies the target media pool where you want to move the tape(s) to.

Required

True

True

Position

Accept Pipeline Input

Accept Wildcard Characters

Named

True (ByValue, ByProperty Name)

False

Named

True (ByValue, ByProperty Name)

False

This cmdlet supports Microsoft PowerShell common parameters. For more information about common parameters, see http://go.microsoft.com/fwlink/p/?LinkID=113216.

300 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Example 1 This command moves the tapes from the Unrecognized media pool to the media pool represented by the $pool variable. The tapes object is obtained with Get-VBRTapeMedium by selecting the tapes by Unrecognized parameter, and piped down. The target media pool is obtained with GetVBRTapeMediaPool and assigned to the variable beforehand. Get-VBRTapeMedium -Unrecognized | Move-VBRTapeMedium -MediaPool $pool

Example 2 This command moves the tape represented by the $tape variable to the media pool represented by the $pool variable. The tape object and the media pool object are obtained with Get-VBRTapeMedium and Get-VBRTapeMediaPool accordingly and assigned to the variables beforehand. Move-VBRTapeMedium -Medium $tape -MediaPool $pool

301 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

New-VBRJobOptions Short Description Sets job options.

Applies to Version: 7.0 Platform: VMware, Hyper-V

Syntax New-VBRJobOptions [-WarningAction ] [WarningVariable ] [] -ORNew-VBRJobOptions [-ForBackupJob] [-WarningAction ] [-WarningVariable ] [] -ORNew-VBRJobOptions [-ForReplicaJob] [-WarningAction ] [-WarningVariable ] []

Detailed Description This cmdlet lets you edit job settings of backup jobs, replication jobs or selected VMs. This cmdlet returns the CJobOptions object containing the default settings of the job you want to edit. You can customize any setting that you want to apply to the job. This object is then used in the Set-VBRJobOptions cmdlet. You can edit settings of jobs (including vCloud backup jobs), VMs or replication jobs by running this cmdlet with -ForJob, -ForObject or -ForReplicaJob parameters respectively. See what else you can perform on job options

Parameters Parameter

Description

Required

Position

Accept Pipeline Input

Accept Wildcard Characters

ForBackupJob

Returns the list of the default settings for backup job.

False

Named

False

False

ForReplicaJob

Returns the list of the default settings for replication job.

False

Named

False

False

This cmdlet supports Microsoft PowerShell common parameters. For more information about common parameters, see http://go.microsoft.com/fwlink/p/?LinkID=113216.

302 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Example This command schedules the job named "Backup Job 1" to running every 2 hours. • The object with scheduling settings is assigned to the $NewScheduleOption variable. The "OptionsPeriodically" parameter is set to &True and its value is set to 120 (minutes). • The job to apply the schedule is obtained with Get-VBRJob and assigned to the $job variable. • The object is then applied to the job by running Set-VBRJobScheduleOptions with these two variables. $NewScheduleOption = New-VBRJobScheduleOptions $NewScheduleOption.OptionsPeriodically.Enabled = $True $NewScheduleOption.OptionsPeriodically.FullPeriod = 120 $Job = Get-VBRJob -Name "Backup Job 1" Set-VBRJobScheduleOptions -Job $Job -Options $NewScheduleOption

303 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

New-VBRJobScheduleOptions Short Description Sets job schedule options.

Applies to Version: 7.0 Platform: VMware, Hyper-V

Syntax New-VBRJobScheduleOptions [-WarningAction ] [WarningVariable ] []

Detailed Description This cmdlet lets you edit scheduling settings of jobs. This cmdlet returns the ScheduleOptions object containing the default scheduling settings of the job you want to edit. You can customize any setting that you want to apply to the job. This object is then used in the Set-VBRJobScheduleOptions cmdlet. You can use the ScheduleOptions object with backup, replication or copy jobs. See what else you can perform on job options

304 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

New-VBRJobVssOptions Short Description Sets job VSS options.

Applies to Version: 7.0 Platform: VMware, Hyper-V

Syntax New-VBRJobVssOptions [-ForJob] [-WarningAction ] [-WarningVariable ] [] -ORNew-VBRJobVssOptions [-ForObject] [-WarningAction ] [-WarningVariable ] [] -ORNew-VBRJobVssOptions [-ForReplicaJob] [-WarningAction ] [-WarningVariable ] []

Detailed Description This cmdlet lets you edit VSS settings of backup jobs, replication jobs or selected VMs. VSS (Volume Shadow Services) is a Windows OS service allowing to copy files of running applications that can be modified at the moment of copying. The VSS-aware applications typically are Active Directory, Microsoft SQL, Microsoft Exchange, Sharepoint, etc. To create a transactionally consistent backup of a VM running VSS-aware applications without shutting them down, Veeam Backup & Replication uses application-aware image processing. It allows backup the data fully and consistently. This cmdlet returns the CVssOptions object containing the VSS settings of the job you want to edit. You can customize any setting that you want to apply to the job. This object is then used in the SetVBRJobVssOptions cmdlet. You can edit settings of backup jobs (including vCloud backup jobs), Vms or replication jobs by running this cmdlet with -ForJob, -ForObject or -ForReplicaJob parameters respectively. See what else you can perform on job options

305 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Parameters Required

Position

Accept Pipeline Input

Accept Wildcard Characters

ForJob

Returns the list of the default VSS settings for backup, replication or copy job.

False

Named

False

False

ForObject

Returns the list of the default VSS settings for VMs.

False

Named

False

False

ForReplicaJob

Returns the list of the default VSS settings for replication job.

False

Named

False

False

Parameter

Description

This cmdlet supports Microsoft PowerShell common parameters. For more information about common parameters, see http://go.microsoft.com/fwlink/p/?LinkID=113216.

Example This example helps you get the CVssOptions object with customized VSS settings for a backup job. •

The Enable setting is set to True,



The GuestFSIndexingType setting is set to "Everyfolders",



The TransactionLogsTruncation setting is set to Always.

PS C:\PS> New-VBRJobVssOptions Enabled Is Credentials GuestFS Indexing ------- --------------- ---------------False False None Never

Transaction Logs ----------------

PS C:\PS> $o=New-VBRJobVssOptions PS C:\PS> $o.Enabled=$true PS C:\PS> $o.GuestFSIndexingType="Everyfolders" PS C:\PS> $o.TransactionLogsTruncation="Always" PS C:\PS> $o Enabled Is Credentials GuestFS Indexing ------- --------------- ---------------True False Everyfolders Always

Transaction Logs ----------------

306 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

New-VBRvCloudVAppRestoreSettings Short Description Creates a set of vApp restore parameters.

Applies to Version: 7.0 Platform: VMware

Syntax New-VBRvCloudVAppRestoreSettings [-RestorePoint] [vAppName ] [-OrgVdc ] [-PowerUp] [-Reason ] [-WarningAction ] [-WarningVariable ] []

Related Commands Get-VBRRestorePoint Find-VBRvCloudEntity ([-OrganizationVdc])

Detailed Description This cmdlet is an assistant command creating a CVcdVAppRestoreSettings object that is further used in the Start-VBRvCloudRestoreVApp cmdlet. This object gathers the parameters of a selected vApp that will be needed for restore. The vApp that you want to restore and its parameters are derived from the specified restore point data. Use the -OrgVdc parameter to set another organization where you want to restore the vApp to. You can customize any of the parameters that are derived from the restore point. For more information, see the Advanced Setup below.

Advanced Setup The restore parameters include the settings of the vApp, namely restore point, vApp name, Organization vDC, and VMs included, as well as the settings of the VM: restore point, storage profile, datastore and template. Each of these settings can be reset to user settings allowing to restore the vApp i.e. to another organization, or with another vApp name, or apply other storage profiles to the VMs. When applying different restore settings, it is recommended to set "null" to all VM settings that you leave unchanged to avoid conflicts when restoring the vApp to another infrastructure. For example, if the target organization has no access to the datastore that is originally set for the vApp, PowerShell will terminate your vApp restore job. If you set "null" to all VM settings, Veeam Backup & Replication will apply the default settings of the target organization. Please make sure that you set the parameters for all VMs that belong to the vApp, otherwise you will not be able to run the restore job. See what else you can perform on vCloud See what else you can perform on restore

307 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Parameters Parameter

Description

Required

Position

Accept Pipeline Input

Accept Wildcard Characters

RestorePoint

Specifies the restore point of the vApp you want to restore the vApp to.

True

1

True (ByValue, ByProperty Name)

False

vAppName

Specifies the name of the restored vApp. Use this parameter in case you want to restore the vApp with different name.

False

Named

False

False

OrgVdc

Specifies the Organization vDC you want to restore the vApp to. If not set, the vApp will be restored to the original Organization vDC.

False

Named

False

False

PowerUp

If set to True, the vApp will be powered up right after it is restored. Otherwise, you will need to power up the vApp manually.

False

Named

False

False

False

Named

False

False

Specifies the reason for performing restore of the selected vApp. Reason

The information you provide will be saved in the session history so that you can reference it later.

308 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

This cmdlet supports Microsoft PowerShell common parameters. For more information about common parameters, see http://go.microsoft.com/fwlink/p/?LinkID=113216.

Example This command creates settings for the future restore of the vApp in another Organization vDC. •

The $restorepoint variable contains the restore point of the vApp. The restore point is obtained with Get-VBRRestorePoint and assigned to the variable beforehand.



The $vdc variable contains the Organization vDC object where the vApp will be restored. The vDC object is obtained with Find-VBRvCloudEntity ([-OrganizationVdc]) and assigned to the variable beforehand.



The PowerUp parameter is set to True to start the vApp automatically right after the restore.

$restoreparams = New-VBRvCloudVAppRestoreSettings -RestorePoint $restorepoint -vAppName "vApp01" -OrgVdc $Org Here you get the $restorepoint variable containing the vApp settings: •

vAppOib - the restore point of the vApp,



OrgVdc - the organization vDataCenter where the vApp is registered,



Vms - the list of VMs whithin the vApp,



vAppName - the name of the vApp.

vAppOib OrgVdc Vms vAppName --------------------Veeam.Bacvup.. Veeam.Backup... {Veeam.Backup...

vApp01

You can view the properties of the VMs within the vApp by typing "$restoreparams.vms": •

VmOib - the VM restorepoint,



StorageProfile - the VM storage profile,



vCloudDatastore - the datastore that the VM uses,



VmTemplate - the VM template.

VmOib StorageProfile vCloudDatastore VmTemplate ------------------ -----------------------Veeam... Name: 'Storag... Veeam.Backup.CV... You need to specify the new organization to where you want to restore the vApp. The new organization object is assigned to the $org variable. All other VM parameters are set to null. $restoreparams = New-VBRvCloudVAppRestoreSettings -RestorePoint $restorepoint -OrgVdc $Org $restoreparams.vms[0].vCloudDatastore=$null $restoreparams.vms[0].StorageProfile=$null $restoreparams.vms[0].VmTemplate=$null The $restoreparams variable now contains the data needed for the restore and can be used in the Start-VBRvCloudRestoreVApp cmdlet.

309 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

New-VSBJobOptions Short Description Sets SureBackup job options.

Applies to Version: 7.0 Platform: VMware, Hyper-V

Syntax New-VSBJobOptions [-WarningAction ] [WarningVariable ] []

Detailed Description This cmdlet lets you edit job settings of SureBackup jobs. This cmdlet returns the CDRJobOptions object containing the default settings of the SureBackup job you want to edit. You can customize any setting that you want to apply. This object is then used in the Set-VSBJobOptions cmdlet. See what else you can perform on job options See what else you can perform on SureBackup This cmdlet supports Microsoft PowerShell common parameters. For more information about common parameters, see http://go.microsoft.com/fwlink/p/?LinkID=113216.

310 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Example This command creates a CDRJobOptions object with the following settings: •

The EmailNotification is enabled,



The EmailNotificationAddresses is set to [email protected],



The RunningVmsNumber is set to 6,



The other settings are left by default.

PS C:\PS> $sureoptions = New-VSBJobOptions PS C:\PS> $sureoptions.EmailNotification = "True" PS C:\PS> $sureoptions.EmailNotificationAddresses = "[email protected]" PS C:\PS> $sureoptions.RunningVmsNumber = 6 PS C:\PS> $sureoptions RunManually : True ShutdownTestVms : True EmailNotification : True EmailNotificationAddresses : [email protected] SnmpNotification : False LinkWithJobs : False RunningVmsNumber : 6 Validation : False SkipValidationForAppGroup : True

311 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Remove-HP3Snapshot Short Description Removes a SAN snapshot.

Applies to Version: 7.0 Platform: VMware HP SAN storage system: HP 3PAR StoreServ

Syntax Remove-HP3Snapshot -Snapshot []

Related Commands Get-HP3Snapshot

Detailed Description This cmdlet permanently removes the selected SAN snapshot from your storage system. See what else you can perform on HP 3PAR instances

Parameters Parameter

Snapshot

Description Specifies the snapshot(s) you want to remove. You can assign multiple snapshots to this object.

Required

True

Position

Accept Pipeline Input

Accept Wildcard Characters

Named

True (ByValue, ByProperty Name)

False

This cmdlet supports Microsoft PowerShell common parameters. For more information about common parameters, see http://go.microsoft.com/fwlink/p/?LinkID=113216.

312 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Example 1 This command removes the snapshot named "vol1_SS_1". The snapshot object is obtained with GetHP3Snapshot and piped down. Get-HP3Snapshot -Name "vol1_SS_1" | Remove-HP3Snapshot

Example 2 This command removes the snapshot represented by the $"snapshot1" variable. The snapshot object is obtained with Get-HP3Snapshot and assigned to the variable beforehand. Remove-HP3Snapshot -Snapshot $"snapshot1"

313 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Remove-HP3Storage Short Description Removes a SAN storage from Veeam Backup & Replication.

Applies to Version: 7.0 Platform: VMware HP SAN storage system: HP 3PAR StoreServ

Syntax Remove-HP3Storage -Storage []

Related Commands Get-HP3Storage

Detailed Description This cmdlet removes the selected SAN storage from Veeam Backup & Replication. The SAN storage is not deleted from server. When you remove a SAN storage, you stop managing it via your Veeam Backup & Replication console. See what else you can perform on HP 3PAR instances

Parameters Parameter

Storage

Description

Specifies the storage you want to remove.

Required

True

Position

Accept Pipeline Input

Accept Wildcard Characters

Named

True (ByValue, ByProperty Name)

False

This cmdlet supports Microsoft PowerShell common parameters. For more information about common parameters, see http://go.microsoft.com/fwlink/p/?LinkID=113216.

314 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Example 1 This command removes the storage named "HP Store 01". The storage object is obtained with GetHP3Storage and piped down. Get-HP3Storage -Name "HP Store 01" | Remove-HP3Storage

Example 2 This command removes the storage represented by the $"store01" variable. The storage object is obtained with Get-HP3Storage and assigned to the variable beforehand. Remove-HP3Storage -Storage $"store01"

315 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Remove-HP4Snapshot Short Description Removes a SAN snapshot.

Applies to Version: 7.0 Platform: VMware HP SAN storage systems: HP LeftHand P4000, HP StoreVirtual VSA

Syntax Remove-HP4Snapshot -Snapshot []

Related Commands Get-HP4Snapshot

Detailed Description This cmdlet permanently removes the selected SAN snapshot from your storage system. See what else you can perform on HP LeftHand P4000 or HP StoreVirtual VSA instances

Alias Remove-VBRHPSnapshot

Parameters Parameter

Snapshot

Description Specifies the snapshot(s) you want to remove. You can assign multiple snapshots to this object.

Required

True

Position

Accept Pipeline Input

Accept Wildcard Characters

Named

True (ByValue, ByProperty Name)

False

This cmdlet supports Microsoft PowerShell common parameters. For more information about common parameters, see http://go.microsoft.com/fwlink/p/?LinkID=113216.

316 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Example 1 This command removes the snapshot named "vol1_SS_1". The snapshot object is obtained with GetHP4Snapshot and piped down. Get-HP4Snapshot -Name "vol1_SS_1" | Remove-HP4Snapshot

Example 2 This command removes the snapshot represented by the $"snapshot1" variable. The snapshot object is obtained with Get-HP4Snapshot and assigned to the variable beforehand. Remove-HP4Snapshot -Snapshot $"snapshot1"

317 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Remove-HP4Storage Short Description Removes a SAN storage from Veeam Backup & Replication.

Applies to Version: 7.0 Platform: VMware HP SAN storage systems: HP LeftHand P4000, HP StoreVirtual VSA

Syntax Remove-HP4Storage -Storage []

Related Commands Get-HP4Storage

Detailed Description This cmdlet removes the selected SAN storage from Veeam Backup & Replication. The SAN storage is not deleted from server. When you remove a SAN storage, you stop managing it via your Veeam Backup & Replication console. See what else you can perform on HP LeftHand P4000 or HP StoreVirtual VSA instances

Alias Remove-VBRHPStorage

Parameters Parameter

Storage

Description

Specifies the storage you want to remove.

Required

True

Position

Accept Pipeline Input

Accept Wildcard Characters

Named

True (ByValue, ByProperty Name)

False

This cmdlet supports Microsoft PowerShell common parameters. For more information about common parameters, see http://go.microsoft.com/fwlink/p/?LinkID=113216.

318 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Example 1 This command removes the storage named "HP Store 01". The storage object is obtained with GetHP4Storage and piped down. Get-HP4Storage -Name "HP Store 01" | Remove-HP4Storage

Example 2 This command removes the storage represented by the $"store01" variable. The storage object is obtained with Get-HP4Storage and assigned to the variable beforehand. Remove-HP4Storage -Storage $"store01"

319 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Remove-VBRBackup Short Description Removes a selected backup.

Applies to Version: 7.0 and earlier Platform: VMware, Hyper-V

Syntax Remove-VBRBackup [-Backup] [-FromDisk] [WarningAction ] [-WarningVariable ] [WhatIf] [-Confirm] []

Related Commands Get-VBRBackup

Detailed Description This cmdlet removes a selected backup. You can remove the backup file completely from disk, or only delete the backup information from Veeam Backup & Replication database. This cmdlet provides syntax for both scenarios accordingly. Please note that you should remove the backup files carefully considering the subsequent backup jobs that may fail to produce valid backup. See what else you can perform on your backup files

Parameters Parameter

Backup

FromDisk

Description Specifies the backup you want to remove. You can assign multiple backups to this object. If indicated, the backup file will be permanently removed from disk. Otherwise, only the information about the backup is deleted from database.

Position

Accept Pipeline Input

Accept Wildcard Characters

True

1

True (ByValue, ByProperty Name)

False

False

Named

False

False

Required

This cmdlet supports Microsoft PowerShell common parameters. For more information about common parameters, see http://go.microsoft.com/fwlink/p/?LinkID=113216.

320 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Example 1 This command removes the backups named "Backup Job 01" and "Backup Job 02" from database only. The backups are obtained with Get-VBRBackup and piped down. Get-VBRBackup -Name "Backup Job 01", "Backup Job 02" | RemoveVBRBackup

Example 2 This command removes the backups with names ending with "2012" from disk. The backups are obtained with Get-VBRBackup and piped down. Get-VBRBackup -Name *2012 | Remove-VBRBackup -FromDisk

Example 3 This command removes the backup represented by the $backup variable from disk. The backup is obtained with Get-VBRBackup and assigned to the variable beforehand. Remove-VBRBackup $backup -FromDisk

321 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Remove-VBRBackupRepository Short Description Removes a specified backup repository from Veeam Backup & Replication.

Applies to Version: 7.0 and earlier Platform: VMware

Syntax Remove-VBRBackupRepository -Repository [WarningAction ] [-WarningVariable ] [WhatIf] [-Confirm] []

Related Commands Get-VBRBackup

Detailed Description This cmdlet allows you to remove the specified backup repository from Veeam Backup & Replication. When you remove a backup repository, Veeam Backup & Replication unassigns the repository role from the server, so it is no longer used as a backup destination. The actual server remains connected to Veeam Backup & Replication. See what else you can perform on backup repositories

Parameters Parameter

Repository

Description

Specifies the backup repository you want to remove.

Required

True

Position

Accept Pipeline Input

Accept Wildcard Characters

Named

True (ByValue, ByProperty Name)

False

This cmdlet supports Microsoft PowerShell common parameters. For more information about common parameters, see http://go.microsoft.com/fwlink/p/?LinkID=113216.

322 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Example 1 This command removes the backup repository named "Local Repository 01". The repository is obtained with Get-VBRBackupRepository and piped down. Get-VBRBackupRepository -Name "Local Repository 01" | RemoveVBRBackupRepository

Example 2 This command removes the backup repository represented by the $repository variable. The repository is obtained with Get-VBRBackupRepository and assigned to the variable beforehand. Remove-VBRBackupRepository $repository

323 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Remove-VBRBackupSession Short Description Removes a specified backup session.

Applies to Version: 7.0 and earlier Platform: VMware

Syntax Remove-VBRBackupSession [-Session] [WarningAction ] [-WarningVariable ] [WhatIf] [-Confirm] []

Related Commands Get-VBRBackupSession

Detailed Description This cmdlet removes specified backup session from Veeam Backup & Replication. See what else you can perform on sessions

Parameters Parameter

Session

Description Specifies the backup session you want to remove. You can assign multiple sessions to this object.

Required

True

Position

Accept Pipeline Input

Accept Wildcard Characters

1

True (ByValue, ByProperty Name)

False

This cmdlet supports Microsoft PowerShell common parameters. For more information about common parameters, see http://go.microsoft.com/fwlink/p/?LinkID=113216.

324 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Example 1 This command removes the backup session named "Fileserver Backup". The backup session is obtained with Get-VBRBackupSession and piped down. Get-VBRBackupSession -Name "Fileserver Backup" | RemoveVBRBackupSession

Example 2 This command removes the backup session named "Fileserver Backup". The backup session is obtained with Get-VBRBackupSession and assigned to the variable beforehand. Remove-VBRBackupSession -Session $"Fileserver Backup"

325 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Remove-VBRCredentials Short Description Removes a credentials record from Veeam Backup & Replication.

Applies to Version: 7.0 Platform: VMware, Hyper-V

Syntax Remove-VBRCredentials -Credential []

Related Commands Get-VBRCredentials

Detailed Description This cmdlet permanently removes the selected credentials from the database. See what else you can perform on credentials

Parameters Parameter

Description

Credential

Specifies the credentials you want to remove.

Required

True

Position

Accept Pipeline Input

Accept Wildcard Characters

Named

True (ByValue, ByProperty Name)

False

This cmdlet supports Microsoft PowerShell common parameters. For more information about common parameters, see http://go.microsoft.com/fwlink/p/?LinkID=113216.

Example 1 This command permanently removes the credentials record with name "Administrator". The credentials object is obtained with Get-VBRCredentials and piped down. Get-VBRCredentials -Name “Administrator” | Remove-VBRCredentials

Example 2 This command removes the credentials record. The credentials object is obtained with GetVBRCredentials and assigned to $c variable beforehand. Remove-VBRCredentials -Credential $c

326 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Remove-VBRHvProxy Short Description Removes a specified Hyper-V backup proxy from Veeam Backup & Replication.

Applies to Version: 7.0 and earlier Platform: Hyper-V For VMware, run Remove-VBRViProxy.

Syntax Remove-VBRHvProxy -Proxy [-WarningAction ] [-WarningVariable ] [-WhatIf] [Confirm] []

Related Commands Get-VBRHvProxy

Detailed Description This cmdlet allows you to remove the specified Hyper-V backup proxy from Veeam Backup & Replication. When you remove a backup proxy, Veeam Backup & Replication unassigns the proxy role from the server, so it is no longer used as a backup proxy. The actual server remains connected to Veeam Backup & Replication. See what else you can perform on your virtual proxies Note:

You cannot remove a backup proxy that is explicitly selected in any backup, replication or VM copy job. To remove such a proxy, you need to delete all job references to it first. Run Disable-VBRHvProxy to disable a Hyper-V proxy.

Parameters Parameter

Proxy

Description

Specifies the Hyper-V backup proxy you want to remove.

Required

True

Position

Accept Pipeline Input

Accept Wildcard Characters

Named

True (ByValue, ByProperty Name)

False

This cmdlet supports Microsoft PowerShell common parameters. For more information about common parameters, see http://go.microsoft.com/fwlink/p/?LinkID=113216.

327 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Example 1 This command removes the proxies named "Proxy 01" and "Proxy 03". The proxies are obtained with Get-VBRHvProxy and piped down. Get-VBRHvProxy -Name "Proxy 01", "Proxy 03"| Remove-VBRHvProxy

Example 2 This command removes the proxy represented by the $proxy variable. The proxy is obtained with GetVBRHvProxy and assigned to the variable beforehand. Remove-VBRHvProxy -Proxy $proxy

328 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Remove-VBRJob Short Description Removes a selected backup, replication or backup copy job.

Applies to Version: 7.0 and earlier Platform: VMware, Hyper-V

Syntax Remove-VBRJob [-Job] [-WarningAction ] [-WarningVariable ] [-WhatIf] [Confirm] []

Related Commands Get-VBRJob

Detailed Description This cmdlet removes a selected backup, replication or backup copy job from Veeam Backup & Replication console and database. Run Remove-VSBJob to remove SureBackup jobs. See what else you can perform on jobs

Parameters Parameter

Job

Description Specifies the job you want to remove. You can assign multiple jobs to this object.

Required

True

Position

Accept Pipeline Input

Accept Wildcard Characters

1

True (ByValue, ByProperty Name)

False

This cmdlet supports Microsoft PowerShell common parameters. For more information about common parameters, see http://go.microsoft.com/fwlink/p/?LinkID=113216.

329 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Example 1 This command removes the file copy jobs. The jobs to remove are obtained with Get-VBRJob and piped down. Get-VBRJob -Name "File Copy*" | Remove-VBRJob

Example 2 This command removes the job represented by the $job variable. The job is obtained with Get-VBRJob and assigned to the variable beforehand. Remove-VBRJob -Job $job

330 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Remove-VBRJobObject Short Description Removes VMs or VM containers from the specified job.

Applies to Version: 7.0 and earlier Platform: VMware

Syntax Remove-VBRJobObject [-Objects]

Related Commands Get-VBRJobObject

Detailed Description This cmdlet allows you to remove VMs or VM containers from existing backup, replication or copy job. See what else you can perform on job objects

Parameters Parameter

Objects

Description

Specifies objects (VMs and VM containers) you want to remove.

Required

True

Position

Accept Pipeline Input

Accept Wildcard Characters

2

True (ByValue, ByProperty Name)

False

This cmdlet supports Microsoft PowerShell common parameters. For more information about common parameters, see http://go.microsoft.com/fwlink/p/?LinkID=113216.

331 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Remove-VBRReplica Short Description Removes a selected replica.

Applies to Version: 7.0 and earlier Platform: VMware, Hyper-V

Syntax Remove-VBRReplica [-Backup] [-FromDisk] [WarningAction ] [-WarningVariable ] [WhatIf] [-Confirm] []

Related Commands Get-VBRReplica

Detailed Description This cmdlet removes a selected replicated VM. You can delete the replica completely, or only remove it from Veeam Backup & Replication managing console. In the latter case, you will not delete the VM but only stop managing it with Veeam Backup & Replication; the replica VM will stay on target host. When replica is created, Veeam Backup & Replication maintains it in sync with the original VM by running the replication job. When you delete a replica from your managing console, it is no longer synchronized. To stop synchronizing a replica without deleting it from the console, you need to stop or delete the corresponding replication job. Run Stop-VBRJob or Remove-VBRJob to stop or remove a replication job. See what else you can perform on replicas Note:

When you remove a replica from Veeam Backup & Replication console, you can not bring it back by means of PowerShell. Use replica seeding option in Veeam Backup & Replication console interface to restore a removed replica in your managing console.

332 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Parameters Parameter

Backup

FromDisk

Description Specifies the replica you want to remove. You can assign multiple replicas to this object. If indicated, the replicated VM will be permanently removed from disk. Otherwise, you only exclude the replica from processing with Veeam Backup & Replication.

Position

Accept Pipeline Input

Accept Wildcard Characters

True

1

True (ByValue, ByProperty Name)

False

False

Named

False

False

Required

This cmdlet supports Microsoft PowerShell common parameters. For more information about common parameters, see http://go.microsoft.com/fwlink/p/?LinkID=113216.

Example 1 This command removes the replicas named "DC_replica01" and "DC_replica02" from Veeam Backup & Replication. The replicated VMs are obtained with Get-VBRReplica and piped down. Get-VBRReplica -Name "DC_replica01", "DC_replica02" | RemoveVBRReplica

Example 2 This command removes the replicas named "DC_replica01" and "DC_replica02" from disk. The replicated VMs are obtained with Get-VBRReplica and piped down. Get-VBRReplica -Name "DC_replica01", "DC_replica02" | RemoveVBRReplica -FromDisk

Example 3 This command removes the replicated VM represented by the $replica variable from disk. The replicated VM is obtained with Get-VBRReplica and assigned to the variable beforehand. $replica | Remove-VBRReplica -FromDisk

333 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Remove-VBRRestorePoint Short Description Removes a restore point.

Applies to Version: 7.0 and earlier Platform: VMware, Hyper-V

Syntax Remove-VBRRestorePoint [-Oib] [-Name ] [WarningAction ] [-WarningVariable ] [WhatIf] [-Confirm] []

Related Commands Get-VBRRestorePoint

Detailed Description This cmdlet allows you to remove restore points from Veeam Backup & Replication. See what else you can perform on restore points

Parameters Parameter

Oib

Name

Description Specifies the restore point(s) you want to remove. You can assign multiple restore point to this object. Specifies the name of the VM the restore points of which you want to remove, or search conditions.

Position

Accept Pipeline Input

Accept Wildcard Characters

True

1

True (ByValue, ByProperty Name)

False

False

Named

False

Truse

Required

You can specify multiple names separated by commas.

This cmdlet supports Microsoft PowerShell common parameters. For more information about common parameters, see http://go.microsoft.com/fwlink/p/?LinkID=113216.

334 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Example 1 This command removes the increment restore points from all backups with names containing "Fileserver". The restore points are obtained with Get-VBRRestorePoint and piped down. Get-VBRRestorePoint -Name *Fileserver* | Where {$_.type -eq "Increment"} | Remove-VBRRestorePoint

Example 2 This command removes the restore point represented by the $restorepoint variable. The restore point object is obtained with Get-VBRRestorePoint and assigned to the variable beforehand. Remove-VBRRestorePoint -Oib $restorepoint

335 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Remove-VBRRestoreSession Short Description Removes a restore session.

Applies to Version: 7.0 and earlier Platform: VMware, Hyper-V

Syntax Remove-VBRRestoreSession [-Session] [WarningAction ] [-WarningVariable ] [WhatIf] [-Confirm] []

Related Commands Get-VBRRestoreSession

Detailed Description This cmdlet removes the specified restore session from Veeam Backup & Replication. See what else you can perform on restore See what else you can perform on sessions

Parameters Parameter

Session

Description

Specifies the restore session you want to remove.

Required

True

Position

Accept Pipeline Input

Accept Wildcard Characters

1

True (ByValue, ByProperty Name)

False

This cmdlet supports Microsoft PowerShell common parameters. For more information about common parameters, see http://go.microsoft.com/fwlink/p/?LinkID=113216.

336 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Example 1 This command removes the last restore session of the VM named "Fileserver". The restore session is obtained with Get-VBRRestoreSession and piped down. Get-VBRRestoreSession -Name "Fileserver 03" | Select -Last 1 | Remove-VBRRestoreSession

Example 2 This command removes the restore session represented by the $session variable. The restore session object is obtained with Get-VBRRestoreSession and assigned to the variable beforehand. Remove-VBRRestoreSession -Session $session

337 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Remove-VBRServer Short Description Removes a selected server from Veeam Backup & Replication.

Applies to Version: 7.0 and earlier Platform: VMware, Hyper-V

Syntax Remove-VBRServer [-Server] [-WarningAction ] [-WarningVariable ] [-WhatIf] [Confirm] []

Related Commands Get-VBRServer

Detailed Description This cmdlet removes a specified VMware or Hyper-V host from Veeam Backup & Replication. When you remove a host, you only stop managing it via your Veeam Backup & Replication console. The host is not deleted as well as data stored on it, i.e. the backup files. You can import these backup files later to the Veeam Backup & Replication console by running Import-VBRBackup. Please note that when you remove virtual hosts from your Veeam Backup & Replication managing console, the backups of the removed hosts stay in the Veeam Backup & Replication database and repository. See what else you can perform on your virtual infrastructure instances Note:

A server that has any dependencies cannot be deleted. For example, you cannot delete a server that is referenced by a backup or replication job, or that performs the role of a backup proxy or repository. To remove such a server, you will need to delete all referencing jobs or objects first.

Parameters Parameter

Server

Description Specifies the server you want to remove. You can assign multiple servers to this object.

Required

True

Position

Accept Pipeline Input

Accept Wildcard Characters

1

True (ByValue, ByProperty Name)

False

This cmdlet supports Microsoft PowerShell common parameters. For more information about common parameters, see http://go.microsoft.com/fwlink/p/?LinkID=113216.

338 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Example 1 This command removes a Virtual Center named "vCenter01". The server is obtained with GetVBRRestoreSession, selected by -Type and -Name parameters, and piped down. Get-VBRServer -Type VC -Name vCenter01 | Remove-VBRServer

Example 2 This command removes the server represented by the $session variable. The server object is obtained with Get-VBRServer and assigned to the variable beforehand. Remove-VBRServer -Server $server

339 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Remove-VBRTapeMediaPool Short Description Removes a media pool from Veeam Backup & Replication.

Applies to Version: 7.0 Platform: VMware, Hyper-V

Syntax Remove-VBRTapeMediaPool -MediaPool [-WarningAction ] [-WarningVariable ] []

Related Commands Get-VBRTapeMediaPool

Detailed Description This cmdlet excludes a selected media pool from Veeam Backup & Replication. Media pool is a logical group of tapes. Media pools are pre-defined service pools and custom pools used as targets for backup to tape and files to tape jobs. See what else you can perform on tapes Important! You can only delete custom media pools; predefined media pools cannot be deleted. You cannot delete a media pool that contains tapes. To be able to delete such a pool, first move tapes from this pool to other media pools. You cannot delete media pools used by an existing backup/files to tape copy job. In case you definitely have to disable this pool, you should first modify the corresponding job to target another media pool.

Parameters Parameter

MediaPool

Description Specifies the media pool(s) you want to remove. You can assign multiple media pools to this object.

Required

True

Position

Accept Pipeline Input

Accept Wildcard Characters

Named

True (ByValue, ByProperty Name)

False

This cmdlet supports Microsoft PowerShell common parameters. For more information about common parameters, see http://go.microsoft.com/fwlink/p/?LinkID=113216.

340 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Example 1 This command removes the media pool named "Winserver MediaPool". The media pool is obtained with Get-VBRTapeMediaPool and piped down. Get-VBRTapeMediaPool -Name "Winserver MediaPool" | RemoveVBRTapeMediaPool

Example 2 This command removes the media pool represented by the $pool variable. The media pool is obtained with Get-VBRTapeMediaPool and assigned to $pool variable beforehand. Remove-VBRTapeMediaPool -MediaPool $pool

341 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Remove-VBRViProxy Short Description Removes VMware backup proxy from Veeam Backup & Replication.

Applies to Version: 7.0 and earlier Platform: VMware For Hyper-V, run Remove-VBRHvProxy.

Syntax Remove-VBRViProxy -Proxy [-WarningAction ] [-WarningVariable ] [-WhatIf] [Confirm] []

Related Commands Get-VBRViProxy

Detailed Description This cmdlet removes the specified VMware backup proxy from Veeam Backup & Replication. When you remove a backup proxy, Veeam Backup & Replication unassigns the proxy role from the server, so it is no longer used as a backup proxy. The actual server remains connected to Veeam Backup & Replication. See what else you can perform on your virtual proxies Note:

You cannot remove a backup proxy that is explicitly selected in any backup, replication or VM copy job. To remove such a proxy, you need to delete all job references to it first. Run Disable-VBRViProxy to disable a VMware proxy.

Parameters Parameter

Proxy

Description

Specifies the proxy you want to remove.

Required

True

Position

Accept Pipeline Input

Accept Wildcard Characters

Named

True (ByValue, ByProperty Name)

False

This cmdlet supports Microsoft PowerShell common parameters. For more information about common parameters, see http://go.microsoft.com/fwlink/p/?LinkID=113216.

342 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Example 1 This command removes the proxies named "Proxy 01" and "Proxy 03". The proxies are obtained with Get-VBRViProxy and piped down. Get-VBRViProxy -Name "Proxy 01", "Proxy 03"| Remove-VBRViProxy

Example 2 This command removes the proxy represented by the $proxy variable. The proxy is obtained with GetVBRViProxy and assigned to the variable beforehand. Remove-VBRViProxy -Proxy $proxy

343 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Remove-VBRWANAccelerator Short Description Removes a WAN accelerator.

Applies to Version: 7.0 Platform: VMware, Hyper-V Note:

WAN optimization is available only in Veeam Backup & Replication Enterprise Plus Edition.

Syntax Remove-VBRWANAccelerator -Accelerator []

Related Commands Get-VBRWANAccelerator

Detailed Description This cmdlet removes the selected WAN accelerator. WAN accelerator is an architecture component that optimizes file transfer via WAN by means of data deduplication. The role of a WAN accelerator can be assigned to a dedicated Windows-based machine (physical or virtual). For best performance you should set a WAN accelerator on both source and target sides. See what else you can perform on backup copy

Parameters Parameter

Accelerator

Description Specifies the WAN accelerator you want to remove.

Required

Position

Accept Pipeline Input

Accept Wildcard Characters

True

Named

False

False

This cmdlet supports Microsoft PowerShell common parameters. For more information about common parameters, see http://go.microsoft.com/fwlink/p/?LinkID=113216.

344 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Example 1 This command removes the WAN Accelerator named "WANAccelerator 1". The accelerator is obtained with Get-VBRWANAccelerator and piped down. Get-VBRWANAccelerator -Name "WANAccelerator 1" | RemoveVBRWANAccelerator

Example 2 This command removes the WAN accelerator represented by the $a variable. The accelerator is obtained with Get-VBRWANAccelerator and assigned to the $a variable beforehand. Remove-VBRWANAccelerator -Accelerator $a

345 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Remove-VSBApplicationGroup Short Description Removes a specified application group from Veeam Backup & Replication.

Applies to Version: 7.0 and earlier Platform: VMware, Hyper-V

Syntax Remove-VSBApplicationGroup [-AppGroup] [WarningAction ] [-WarningVariable ] [WhatIf] [-Confirm] []

Related Commands Get-VSBApplicationGroup

Detailed Description This cmdlet removes a specified application group from Veeam Backup & Replication. An application group is a component of SureBackup technology providing verification of virtual machines that need other virtual machines or services running, i.e. a domain controller, a DSN server or SQL database. To test such machines for recoverability, you need to create a SureBackup job and provide the copy of the production architecture running in a fenced-off environment that is performed by creating a virtual lab and an application group. See what else you can perform on SureBackup

Parameters Parameter

Description

Required

Position

Accept Pipeline Input

Accept Wildcard Characters

1

True (ByValue, ByProperty Name)

False

Specifies the application group you want to remove. AppGroup

You can assign multiple application groups to this object.

True

This cmdlet supports Microsoft PowerShell common parameters. For more information about common parameters, see http://go.microsoft.com/fwlink/p/?LinkID=113216.

346 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Example 1 This command removes the application groups named "AppGroup 01" and "AppGroup 02". The application groups are obtained with Get-VSBApplicationGroup and piped down. Get-VSBApplicationGroup -Name "AppGroup 01", "AppGroup 02"| Remove-VSBApplicationGroup

Example 2 This command removes the application group represented by the $appgroup variable. The application group is obtained with Get-VSBApplicationGroup and assigned to the variable beforehand. Remove-VSBApplicationGroup -AppGroup $appgroup

347 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Remove-VSBHvVirtualLab Short Description Removes a Hyper-V virtual lab.

Applies to Version: 7.0 Platform: Hyper-V For VMware, run Remove-VSBVirtualLab.

Syntax Remove-VSBHvVirtualLab [-VirtualLab] [WarningAction ][-WarningVariable ] [WhatIf][-Confirm][]

Related Commands Get-VSBHvVirtualLab

Detailed Description This cmdlet removes a virtual lab from Veeam Backup & Replication console. A virtual lab is a component of SureBackup technology providing verification of virtual machines that need other virtual machines or services running, i.e. a domain controller, a DSN server or SQL database. To test such machines for recoverability, you need to create a SureBackup job and provide the copy of the production architecture running in a fenced-off environment that is performed by creating a virtual lab and an application group. The virtual lab is not deleted from server where it was created. When you remove a virtual lab, you stop managing it via your Veeam Backup & Replication console. You can add a removed virtual lab to your console by running Connect-VSBHvVirtualLab. See what else you can perform on SureBackup

Parameters Parameter

Description

Required

Position

Accept Pipeline Input

Accept Wildcard Characters

VirtualLab

Specifies the virtual lab you want to remove from your Veeam Backup & Replication console.

True

Named

True(ByValue, ByProperty Name)

False

This cmdlet supports Microsoft PowerShell common parameters. For more information about common parameters, see http://go.microsoft.com/fwlink/p/?LinkID=113216.

348 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Example 1 This command removes a virtual lab named "Virtual Lab 01". The virtual lab object is obtained with Get-VSBHvVirtualLab and piped down. Get-VSBHvVirtualLab -Name "Virtual Lab 01" | RemoveVSBHvVirtualLab

Example 2 This command removes a virtual lab represented by the $vlab variable. The virtual lab object is obtained with Get-VSBHvVirtualLab and assigned to variable beforehand. Remove-VSBHvVirtualLab -VirtualLab $vlab

349 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Remove-VSBJob Short Description Removes a specified SureBackup job from Veeam Backup & Replication.

Applies to Version: 7.0 and earlier Platform: VMware, Hyper-V

Syntax Remove-VSBJob [-Job] [-WarningAction ] [-WarningVariable ] [-WhatIf] [Confirm] []

Related Commands Get-VSBJob

Detailed Description This cmdlet removes a specified SureBackup job from Veeam Backup & Replication. SureBackup is a Veeam recovery verification technology providing verification of virtual machines that need other virtual machines or services running, i.e. a domain controller, a DSN server or SQL database. To test such machines for recoverability, you need to create a SureBackup job and provide the copy of the production architecture running in a fenced-off environment that is performed by creating a virtual lab and an application group. Run Remove-VBRJob to remove a backup, replication or copy job. See what else you can perform on SureBackup See what else you can perform on jobs

Parameters Parameter

Job

Description Specifies the SureBackup job you want to remove. You can assign multiple jobs to this object.

Required

True

Position

Accept Pipeline Input

Accept Wildcard Characters

1

True (ByValue, ByProperty Name)

False

This cmdlet supports Microsoft PowerShell common parameters. For more information about common parameters, see http://go.microsoft.com/fwlink/p/?LinkID=113216.

350 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Example 1 This command removes the SureBackup job named "SureJob 01" and "SureJob 12". The SureBackup jobs are obtained with Get-VSBJob and piped down. Get-VSBJob -Name "SureJob 01", "SureJob 12"| Remove-VSBJob

Example 2 This command removes the SureBackup job represented by the $surejob variable. The SureBackup job is obtained with Get-VSBJob and assigned to the variable beforehand. Remove-VSBJob -Job $surejob

351 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Remove-VSBSession Short Description Removes a specified SureBackup job session from Veeam Backup & Replication.

Applies to Version: 7.0 and earlier Platform: VMware, Hyper-V

Syntax Remove-VSBSession [-Sessions] [-WarningAction ] [-WarningVariable ] [-WhatIf] [Confirm] []

Related Commands Get-VSBSession

Detailed Description This cmdlet removes a specified SureBackup job session from Veeam Backup & Replication. See what else you can perform on SureBackup See what else you can perform on sessions

Parameters Parameter

Sessions

Description Specifies the SureBackup job session you want to remove. You can assign multiple sessions to this object.

Required

True

Position

Accept Pipeline Input

Accept Wildcard Characters

1

True (ByValue, ByProperty Name)

False

This cmdlet supports Microsoft PowerShell common parameters. For more information about common parameters, see http://go.microsoft.com/fwlink/p/?LinkID=113216.

352 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Example 1 This command removes the SureBackup sessions named "Winserver SureJob" and "Mailserver SureJob". The SureBackup sessions are obtained with Get-VSBSession and piped down. Get-VSBSession -Name "Winserver SureJob", "Mailserver SureJob" | Remove-VSBSession

Example 2 This command removes the SureBackup job session represented by the $suresession variable. The SureBackup job session is obtained with Get-VSBSession and assigned to the variable beforehand. Remove-VSBSession -Sessions $suresession

353 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Remove-VSBVirtualLab Short Description Removes a specified VMware virtual lab from Veeam Backup & Replication.

Applies to Version: 7.0 and earlier Platform: VMware For Hyper-V, run Remove-VSBHvVirtualLab.

Syntax Remove-VSBVirtualLab [-VirtualLab] [WarningAction ] [-WarningVariable ] [WhatIf] [-Confirm] []

Related Commands Get-VSBVirtualLab

Detailed Description This cmdlet allows you to remove a specified VMware virtual lab from Veeam Backup & Replication. A virtual lab is a component of SureBackup technology providing verification of virtual machines that need other virtual machines or services running, i.e. a domain controller, a DSN server or SQL database. To test such machines for recoverability, you need to provide the copy of the production architecture running in a fenced-off environment that is performed by creating a virtual lab and an application group. The virtual lab is not deleted from server where it was created. When you remove a virtual lab, you stop managing it via your Veeam Backup & Replication console. You can add a removed virtual lab to your console by running Connect-VSBVirtualLab. See what else you can perform on SureBackup

Parameters Parameter

VirtualLab

Description Specifies the virtual lab you want to remove. You can assign multiple virtual labs to this object.

Required

True

Position

Accept Pipeline Input

Accept Wildcard Characters

1

True (ByValue, ByProperty Name)

False

This cmdlet supports Microsoft PowerShell common parameters. For more information about common parameters, see http://go.microsoft.com/fwlink/p/?LinkID=113216.

354 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Example 1 This command removes a virtual lab named "Virtual Lab 01". The virtual lab object is obtained with Get-VSBVirtualLab and piped down. Get-VSBVirtualLab -Name "Virtual Lab 01" | Remove-VSBVirtualLab

Example 2 This command removes a virtual lab represented by the $vlab variable. The virtual lab object is obtained with Get-VSBVirtualLab and assigned to the variable beforehand. Remove-VSBVirtualLab -VirtualLab $vlab

355 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Reset-HvVmChangeTracking Short Description Clears change tracking data for a specific VM or specific virtual disk (VHD).

Applies to Version: 7.0 and earlier Platform: Hyper-V

Syntax Reset-HvVmChangeTracking [-Server] [-VMName ] [WarningAction ] [-WarningVariable ] [] -ORReset-HvVmChangeTracking [-Server] [-VhdPath ] [WarningAction ] [-WarningVariable ] []

Related Commands Get-VBRServer

Detailed Description This cmdlet clears and resets change tracking data for a VM or specific virtual disk (VHD). Change tracking data is history of changes kept for each data block. Using the changed block tracking (CBT) mechanism allows to reduce the backup time as the backup process compares the CBT data instead of scanning all data. You may need to reset the change tracking data in case it was corrupted. This cmdlet provides two scenarios. You can reset change tracking for a specific VM or for a specific virtual disk (VHD).

Parameters Description

Required

Position

Accept Pipeline Input

Accept Wildcard Characters

Server

Specifies the server hosting the VM for which you want to reset change tracking data.

True

2

False

False

VMName

Specifies the VM for which you want to reset change tracking data.

False

Named

False

False

VhdPath

Specifies the virtual disk (VHD) for which you want to reset change tracking data.

False

Named

False

False

Parameter

This cmdlet supports Microsoft PowerShell common parameters. For more information about common parameters, see http://go.microsoft.com/fwlink/p/?LinkID=113216.

356 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Example 1 This command resets change tracking data for the VM named "Fileserver". The VM is located on host represented by the $server variable. The server object is obtained with Get-VBRServer and assigned to the variable beforehand. Reset-HvVmChangeTracking -Server $server -VMName "Fileserver"

Example 2 This command resets change tracking data for the specified virtual disk. The VM is located on host represented by the $server variable. The server object is obtained with Get-VBRServer and assigned to the variable beforehand. Reset-HvVmChangeTracking -Server $server -VhdPath "C:\Users\Public\Hyper-V\Virtual Hard Disks\hv_dns.vhdx"

357 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Reset-VBRJobOptions Short Description Sets job settings to default.

Applies to Version: Platform: VMware

Syntax Reset-VBRJobOptions -Job [-WarningAction ] [-WarningVariable ] []

Related Commands Get-VBRJob

Detailed Description This cmdlet clears the custom settings of the specified job and restores their default values. Note that the VSS settings (application-aware image processing and guest file system indexing) are not reset with this cmdlet. Run Reset-VBRJobVssOptions to clear the job VSS settings. Run DisableVBRJobVSSIntegration or Disable-VBRJobGuestFSIndexing to temporarily disable the applicationaware image processing and guest file system indexing settings. You can run this cmdlet with any kind of jobs. See what else you can perform on job options

Parameters Parameter

Job

Description

Specifies the job you want to edit.

Required

True

Position

Accept Pipeline Input

Accept Wildcard Characters

Named

True (ByValue, ByProperty Name)

False

This cmdlet supports Microsoft PowerShell common parameters. For more information about common parameters, see http://go.microsoft.com/fwlink/p/?LinkID=113216.

358 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Example 1 This command sets default settings to backup jobs named "Fileserver Backup Job 1" and "Fileserver Backup Job 2". The jobs object is obtained with Get-VBRJob and piped down. Get-VBRJob -Name "Fileserver Backup Job 1", "Fileserver Backup Job 2" | Reset-VBRJobOptions

Example 2 This command sets default settings to the job represented by the $job variable. The job object is obtained with Get-VBRJob and assigned to the variable beforehand. Reset-VBRJobOptions -Job $job

359 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Reset-VBRJobScheduleOptions Short Description Sets job schedule settings to default.

Applies to Version: Platform: VMware, Hyper-V

Syntax Reset-VBRJobScheduleOptions -Job [-WarningAction ] [-WarningVariable ] []

Related Commands Get-VBRJob

Detailed Description This cmdlet sets the default scheduling options to the selected job. When you clear the schedulling options of a job, you need to run the job manually. You can run this cmdlet with any kind of jobs. See what else you can perform on job options

Parameters Parameter

Job

Description

Specifies job you want to edit.

Required

True

Position

Accept Pipeline Input

Accept Wildcard Characters

Named

True (ByValue, ByProperty Name)

True

This cmdlet supports Microsoft PowerShell common parameters. For more information about common parameters, see http://go.microsoft.com/fwlink/p/?LinkID=113216.

360 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Example 1 This command sets default schedule options to backup jobs named "Fileserver Backup Job" and "Fileserver Copy Job". The jobs object is obtained with Get-VBRJob and piped down. Get-VBRJob -Name "Fileserver Backup Job", "Fileserver Copy Job" | Reset-VBRJobScheduleOptions

Example 2 This command sets default schedule options to the job represented by the $job variable. The job object is obtained with Get-VBRJob and assigned to the variable beforehand. Reset-VBRJobScheduleOptions -Job $job

361 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Reset-VBRJobVssOptions Short Description Sets job VSS settings to default.

Applies to Version: Platform: VMware

Syntax Reset-VBRJobVssOptions -Job [-WarningAction ] [-WarningVariable ][]

Related Commands Get-VBRJob

Detailed Description This cmdlet clears the custom VSS settings of the specified job and restores their default values. VSS (Volume Shadow Services) is a Windows OS service allowing to copy files of running applications that can be modified at the moment of copying. The VSS-aware applications typically are Active Directory, Microsoft SQL, Microsoft Exchange, Sharepoint, etc. To create a transactionally consistent backup of a VM running VSS-aware applications without shutting them down, Veeam Backup & Replication uses application-aware image processing. It allows backup the data fully and consistently. You can run this cmdlet with any kind of jobs. See what else you can perform on job options

Parameters Parameter

Job

Description

Specifies the job you want to edit.

Required

True

Position

Accept Pipeline Input

Accept Wildcard Characters

Named

True (ByValue, ByProperty Name)

False

This cmdlet supports Microsoft PowerShell common parameters. For more information about common parameters, see http://go.microsoft.com/fwlink/p/?LinkID=113216.

362 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Example 1 This command sets default VSS settings to backup jobs named "Fileserver Backup Job 1" and "Fileserver Backup Job 2". The jobs object is obtained with Get-VBRJob and piped down. Get-VBRJob -Name "Fileserver Backup Job 1", "Fileserver Backup Job 2" | Reset-VBRJobVssOptions

Example 2 This command sets default VSS settings to the job represented by the $job variable. The job object is obtained with Get-VBRJob and assigned to the variable beforehand. Reset-VBRJobVssOptions -Job $job

363 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Reset-VSBJobOptions Short Description Sets SureBackup job settings to default.

Applies to Version: Platform: VMware, Hyper-V

Syntax Reset-VSBJobOptions -Job [-WarningAction ] [-WarningVariable ] []

Related Commands Get-VSBJob

Detailed Description This cmdlet clears the custom settings of the specified SureBackup job and restores their default values. See what else you can perform on job options See what else you can perform on SureBackup

Parameters Parameter

Job

Description

Specifies the SureBackup job you want to edit.

Required

True

Position

Accept Pipeline Input

Accept Wildcard Characters

Named

True (ByValue, ByProperty Name)

False

This cmdlet supports Microsoft PowerShell common parameters. For more information about common parameters, see http://go.microsoft.com/fwlink/p/?LinkID=113216.

364 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Example 1 This command sets default settings to SureBackup jobs named "SureBackup Job 1" and "SureBackup Job 2". The jobs object is obtained with Get-VSBJob and piped down. Get-VSBJob -Name "SureBackup Job 1", "SureBackup Job 2" | ResetVSBJobOptions

Example 2 This command sets default settings to the SureBackup job represented by the $SureJob variable. The job object is obtained with Get-VSBJob and assigned to the variable beforehand. Reset-VSBJobOptions -Job $SureJob

365 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Restart-VBRInstantRecovery Short Description Restarts a failed instant recovery job.

Applies to Version: 7.0 and earlier Platform: Hyper-V

Syntax Restart-VBRInstantRecovery [-InstantRecovery] [-WarningAction ] [-WarningVariable ] []

Related Commands Get-VBRInstantRecovery

Detailed Description This cmdlet restarts a failed Hyper-V instant recovery job. With instant recovery technology, Veeam Backup & Replication starts a VM directly from a backup, incremental or full, without copying it to production storage. Please note that the instantly recovered VM runs from a backup and does not provide a wholly functioning service. You need to finalize the successful instant recovery by either permanently migrating the recovered VM to the production host or by stopping publishing the recovered VM. Run Start-VBRHvInstantRecoveryMigration or Stop-VBRInstantRecovery respectively. See what else you can perform on instant recovery

Parameters Parameter

Instant Recovery

Description Specifies the instant recovery session you want to restart. You can assign multiple instant recovery sessions to this object.

Required

True

Position

Accept Pipeline Input

Accept Wildcard Characters

1

True (ByValue, ByProperty Name)

False

This cmdlet supports Microsoft PowerShell common parameters. For more information about common parameters, see http://go.microsoft.com/fwlink/p/?LinkID=113216.

366 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Example 1 This command restarts the last instant recovery session. The needed session object is obtained with Get-VBRInstantRecovery, selected by order and piped down. Get-VBRInstantRecovery | Select -Last 1 | RestartVBRInstantRecovery

Example 2 This command restarts the instant recovery session represented by the $"Recovery Session" variable. The needed session object is obtained with Get-VBRInstantRecovery and assigned to the variable beforehand. Restart-VBRInstantRecovery -InstantRecovery $"Recovery Session"

367 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Set-VBRCredentials Short Description Edits credentials records properties.

Applies to Version: 7.0 Platform: VMware, Hyper-V

Syntax Set-VBRCredentials -Credential -Password [] -ORSet-VBRCredentials -Credential -Description []

Related Commands Get-VBRCredentials

Detailed Description This cmdlet allows editing password or description of a selected credentials record. Select the appropriate syntax for each case. See what else you can perform on credentials

Parameters Parameter

Description

Credential

Specifies the credentials you want to edit.

Password

Specifies the new password for the selected credentials.

Description

Specifies the new description for the selected credentials.

Required

True

True

True

Position

Accept Pipeline Input

Accept Wildcard Characters

Named

True (ByValue, ByProperty Name)

False

Named

True (ByValue, ByProperty Name)

False

Named

True (ByValue, ByProperty Name)

False

This cmdlet supports Microsoft PowerShell common parameters. For more information about common parameters, see http://go.microsoft.com/fwlink/p/?LinkID=113216.

368 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Example 1 This command sets a new password for the credentials record with name "Administrator". The new password is "Password_1". The credentials record is obtained with Get-VBRCredentials and piped down. Get-VBRCredentials -Name "Administrator" | Set-VBRCredentials Password "Password_1"

Example 2 This command sets a new description for the credentials record. The credentials record is obtained with Get-VBRCredentials and assigned to the variable beforehand. Set-VBRCredentials -Credential $c -Description "ESXi Host Credentials"

369 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Set-VBRJobAdvancedBackupOptions Short Description Customizes advanced job backup settings.

Applies to Version: 7.0 Platform: VMware, Hyper-V

Syntax Set-VBRJobAdvancedBackupOptions -Job [-Algorithm {ReverseIncremental | Incremental }] [TransformFullToSyntethic ] [-TransformIncrementsToSyntethic ] [-TransformToSyntethicDays {Sunday | Monday | Tuesday | Wednesday | Thursday | Friday | Saturday}] [EnableFullBackup ] [-FullBackupDays {Sunday | Monday | Tuesday | Wednesday | Thursday | Friday | Saturday}] [FullBackupScheduleKind {Daily | Monthly}] [-Months {January | February | March | April | May | June | July | August | September | October | November | December}] [-DayNumberInMonth {First | Second | Third | Fourth | Last | OnDay}] [-DayOfWeek {Sunday | Monday | Tuesday | Wednesday | Thursday | Friday | Saturday}] []

Related Commands Get-VBRJob

Detailed Description This cmdlet sets advanced backup options for the selected job. You can select backup method: reverse incremental or incremetal, and set schedule settings for synthetic full backups. Read more about advanced backup job settings in Veeam Backup & Replication user guide at http://www.veeam.com/vmware-backup/help-center. See what else you can perform on job options

370 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Parameters Position

Accept Pipeline Input

Accept Wildcard Characters

True

Named

True (ByValue, ByProperty Name)

False

False

Named

False

False

False

Named

False

False

False

Named

False

False

TransformTo SyntethicDays

Specifies days to perform synthetic fulls: Sunday, Monday, Tuesday, Wednesday, Thursday, Friday, Saturday.

False

Named

False

False

Enable FullBackup

If set to TRUE, the active full backup will

False

Named

False

False

Parameter

Description

Required

Specifies the job you want to edit. Job

You can assign multiple jobs to this object. Specifies backup method:

Algorithm

ReverseIncremental : every backup job run creates a full backup file by merging a previous full backup with recent changes. Incremental: the first job run creates a full backup file, and the subsequent runs backups only the changed blocks. Used with incremental backup method.

TransformFull ToSyntethic

If set to TRUE, the full synthetic backup will be enabled. Otherwise, you will have to perform full backups manually. Used with incremental backup method.

Transform Increments ToSyntethic

If set to TRUE, the previous full backup chain will be transformed into the reversed incremental backup chain. Otherwise all created synthetic fulls will remain on disk. Used to save disk space.

371 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

be scheduled. Use FullBackupDays, FullBackupSchedul eKind, -Months, DayNumberInMont h and -DayOfWeek parameters to set the full backup schedule. Sets backup schedule.

FullBackupDays

Specifies days to perform the full backup: Sunday, Monday, Tuesday, Wednesday, Thursday, Friday, Saturday.

False

Named

False

False

False

Named

False

False

False

Named

False

False

False

Named

False

False

False

Named

False

False

Sets backup schedule. FullBackup ScheduleKind

Sets weekly or monthly period to schedule the full backup: Daily, Monthly. Sets backup schedule.

Months

Specifies months to perform the full backup: January, February, March, April, May, June, July, August, September, October, November, December. Sets backup schedule.

DayNumber InMonth

Specifies the period condition for the monthly backup job run: First, Second, Third, Forth, Last. Use this parameter to set the condition for DayOfWeek parameter, i.e. to run the job on first Saturday every month. Sets backup schedule.

DayOfWeek

Specifies the day of week to run the backup job: Sunday, Monday, Tuesday, Wednesday,

372 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Thursday, Friday, Saturday. Use this parameter to set the day for NumberInMonth parameter, i.e. to run the job on first Saturday every month.

This cmdlet supports Microsoft PowerShell common parameters. For more information about common parameters, see http://go.microsoft.com/fwlink/p/?LinkID=113216.

Example 1 This command sets the following backup options for the backup job represented by the $job variable: •

The backup algorithm is set to ReverseIncremental,



The active full backup schedule is set to monthly.

The job object is obtained with Get-VBRJob, assigned to the variable beforehand and piped down. $job | Set-VBRJobAdvancedBackupOptions -Algorithm ReverseIncremental -FullBackupScheduleKind Monthly

Example 2 This command sets the following backup options for all backup jobs: •

The backup algorithm is set to Incremental,



The synthetic full backup is enabled on every Sunday and Thursday,



The previous fulls are set to rollback to chain of increments to save disk space,



The active full backup schedule is set to every second Sunday monthly.

Get-VBRJob -Name Backup* | Set-VBRJobAdvancedBackupOptions Algorithm Incremental -TransformFullToSyntethic True TransformIncrementsToSyntethic True -TransformToSyntethicDays Sunday, Thursday -EnableFullBackup True -FullBackupScheduleKind Monthly -DayNumberInMonth Second -FullBackupDays Sunday

373 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Set-VBRJobAdvancedHvOptions Short Description Customizes Hyper-V job settings.

Applies to Version: 7.0 Platform: Hyper-V

Syntax Set-VBRJobAdvancedHvOptions -Job [CanDoCrashConsistent ] [-EnableHvQuiescence ] [UseChangeTracking ] [-ExcludeSwapFile ] []

Related Commands Get-VBRJob

Detailed Description This cmdlet sets special options for the selected Hyper-V job. In case you cannot use application-aware image processing, you can enable a Hyper-V quiescence mechanism to backup data that can be changed during the backup. Read more about Hyper-V job settings in Veeam Backup & Replication user guide at http://www.veeam.com/vmware-backup/help-center. See what else you can perform on job options

Parameters Position

Accept Pipeline Input

Accept Wildcard Characters

True

Named

True (ByValue, ByProperty Name)

False

CanDoCrash Consistent

If set to TRUE, the crash consistent backup will be enabled. Otherwise the VM will be suspended for a short period of time.

False

Named

False

False

EnableHv Quiescence

If set to TRUE, the Hyper-V quiescence mechanism will be enabled. Use this mechanism if the application-aware image processing cannot be used.

False

Named

False

False

UseChange Tracking

If set to TRUE, the changed block tracking will be

False

Named

False

False

Parameter

Job

Description Specifies the job you want to edit. You can assign multiple jobs to this object.

Required

374 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Parameter

Description

Required

Position

Accept Pipeline Input

Accept Wildcard Characters

False

Named

False

False

enabled. Exclude SwapFile

If set to TRUE, the swap file will be excluded from backup.

This cmdlet supports Microsoft PowerShell common parameters. For more information about common parameters, see http://go.microsoft.com/fwlink/p/?LinkID=113216.

Example This command edits advanced job settings to backup job named "Backup Job 01": •

The Hyper-V quiescence is enabled,



The crash consistent backup is enabled,



The changed block data is enabled,



The swap file is excluded form backup.

The job is obtained with Get-VBRJob and piped down. Get-VBRJob -Name "Backup Job 01" | Set-VBRJobAdvancedHvOptions EnableHvQuiescence True -CanDoCrashConsistent True UseChangeTracking True -ExcludeSwapFile True

375 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Set-VBRJobAdvancedNotificationOptions Short Description Customizes job notification settings.

Applies to Version: 7.0 Platform: VMware, Hyper-V

Syntax Set-VBRJobAdvancedNotificationOptions -Job [SnmpNotification ] [-EmailNotificationAddresses ] [-EmailNotification ] []

Related Commands Get-VBRJob

Detailed Description This cmdlet sets notification options for the selected job. You can set SNMP and email notifications on job run results. Read more about job notification settings in Veeam Backup & Replication user guide at http://www.veeam.com/vmware-backup/help-center. See what else you can perform on job options

Parameters Parameter

Job

Description Specifies the job you want to edit. You can assign multiple jobs to this object.

Position

Accept Pipeline Input

Accept Wildcard Characters

True

Named

True (ByValue, ByProperty Name)

False

Required

Snmp Notification

If set to TRUE, the SNMP notification will be sent. You need to have the SNMP notification pre-configured.

False

Named

False

False

Email Notification

If set to TRUE, the notifications will be sent to email address(es).

False

Named

False

False

Email Notification Addresses

Specifies the email address(es) to send the email notification. You can specify multiple addresses separated by semicolon.

False

Named

False

False

376 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

This cmdlet supports Microsoft PowerShell common parameters. For more information about common parameters, see http://go.microsoft.com/fwlink/p/?LinkID=113216.

Example This command sets SNMP and email notifications for the backup job named "Backup Job 01". The job object is obtained with Get-VBRJob and piped down. Get-VBRJob -Name "Backup Job 01" | SetVBRJobAdvancedNotificationOptions -SnmpNotification True EmailNotification True -EmailNotificationAddresses "[email protected]"

377 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Set-VBRJobAdvancedOptions Short Description Customizes advanced job settings.

Applies to Version: 7.0 Platform: VMware, Hyper-V

Syntax Set-VBRJobAdvancedOptions -Job [-Periodicity {Cycles | Days}] [-Frequency ] [Enabled ] [-Days {Sunday | Monday | Tuesday | Wednesday | Thursday | Friday | Saturday}] [-CommandLine ] [-EnableIntegrityChecks ] [-RetainDays ] []

Related Commands Get-VBRJob

Detailed Description This cmdlet sets advanced options for the selected job. You can set: •

Integrity check: Veeam Backup and Replication will check every full backup file for integrity and recovery availability,



Custom data retention period: if a VM included in this job is deleted, its data will be stored for the specified period. When this period ends, the backup files are deleted. The default period is 14 days,



Post job activity: you can specify a command you want to run after the job run, i.e. to sent a job result report. You can schedule this command to run i.e. every second job run or on specific days.

Read more about advanced job settings in Veeam Backup & Replication user guide at http://www.veeam.com/vmware-backup/help-center. See what else you can perform on job options

378 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Parameters Position

Accept Pipeline Input

Accept Wildcard Characters

True

Named

True (ByValue, ByProperty Name)

False

Enable Integrity Checks

If set to TRUE, automatic backup integrity check will be enabled. Integrity check process verifies the full backup file integrity to avoid data corruption. Otherwise integrity check in not performed.

False

Named

False

False

RetainDays

Specifies the integer setting the number of days to keep backup data for deleted VMs. If ommited, the data retention period will be set to 14 days by default.

False

Named

False

False

False

Named

False

False

False

Named

False

False

False

Named

False

False

Parameter

Job

Description Specifies the job you want to edit. You can assign multiple jobs to this object.

Required

If set to TRUE, the command set in -CommandLine will be executed after the job run. Enabled

Command Line

You need to schedule the command run periodically with -Periodicity and Frequency parameters, or on specific days with -Days parameter. Specifies the command you want to execute after the job run. You can schedule the command run periodically with -Periodicity and Frequency parameters, or on specific days with -Days parameter. Set -Enable parameter to TRUE to enable the command execution. Used to set command run schedule. Specifies the command run schedule type:

Periodicity

Cycles: the command will be executed in periods set with Frequency parameter, Days: the command will be executed on the days specified with -Days parameter.

379 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Parameter

Description

Required

Position

Accept Pipeline Input

Accept Wildcard Characters

False

Named

False

False

False

Named

False

False

Used to set command run schedule to Cycle.

Frequency

Specifies the integer setting the number of the backup job runs after which the command will be executed. To set the command run to cycle run, set -Periodicity parameter to Cycle. You can also set the daily schedule with -Days parameter. Used to set command run schedule to Days.

Days

Specifies the days to run the command: Sunday, Monday, Tuesday, Wednesday, Thursday, Friday, Saturday. You can also set the cycle schedule with -Frequency parameter.

This cmdlet supports Microsoft PowerShell common parameters. For more information about common parameters, see http://go.microsoft.com/fwlink/p/?LinkID=113216.

380 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Example 1 This command edits advanced job settings to backup job named "Backup Job 01": •

The integrity check is enabled,



The data retention period is set to 30 days.

The job is obtained with Get-VBRJob and piped down. Get-VBRJob -Name "Backup Job 01" | Set-VBRJobAdvancedOptions EnableIntegrityChecks True -RetainDays 30

Example 2 This command edits advanced job settings to backup job named "Backup Job 01": •

The integrity check is enabled,



The data retention is not set to leave the default settings,



The post job activity is enabled to run the "report.exe" command periodically after every fifth job run.

The job is obtained with Get-VBRJob and piped down. Get-VBRJob -Name "Backup Job 01" | Set-VBRJobAdvancedOptions EnableIntegrityChecks -Enabled True -CommandLine "report.exe" Periodicity Cycles -Frequency 5

381 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Set-VBRJobAdvancedStorageOptions Short Description Customizes advanced job storage settings.

Applies to Version: 7.0 Platform: VMware, Hyper-V

Syntax Set-VBRJobAdvancedStorageOptions -Job [EnableDeduplication []] [-CompressionLevel ] [StorageBlockSize ] [-WarningAction ] [-WarningVariable ][]

Related Commands Get-VBRJob

Detailed Description This cmdlet sets storage options for the selected job. You can enable backup data deduplication and customize data units compression level and size. Read more about job storage settings in Veeam Backup & Replication user guide at http://www.veeam.com/vmware-backup/help-center. See what else you can perform on job options

Parameters Parameter

Job

Enable Deduplication

Description Specifies the job you want to edit. You can assign multiple jobs to this object. If set to TRUE, the data will be deduplicated during the backup job run (recommended). Otherwise, no data will be checked for duplication.

Position

Accept Pipeline Input

Accept Wildcard Characters

True

Named

True (ByValue, ByProperty Name)

False

False

Named

False

False

False

Named

False

False

Required

Specifies the compression level for the created backup: Compression Level

AUTO _COMPRESSION _LEVEL = -1, NONE _COMPRESSION _LEVEL = 0,

382 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Parameter

Description

Required

Position

Accept Pipeline Input

Accept Wildcard Characters

False

Named

False

False

DEDUPE _COMPRESSION _LEVEL = 4, OPTIMAL _COMPRESSION _LEVEL = 5, HIGH _COMPRESSION _LEVEL = 6, EXTREME _COMPRESSION _LEVEL = 9 Specifies the integer defining the data blocks size. Larger sized blocks provide faster procession but lower deduplication level. Storage BlockSize

0 = KbBlockSize256, 1 = KbBlockSize512, 3 = KbBlockSize1024, 4 = KbBlockSize2048, 5 = KbBlockSize4096, 6 = KbBlockSize8192, 7= Automatic.

This cmdlet supports Microsoft PowerShell common parameters. For more information about common parameters, see http://go.microsoft.com/fwlink/p/?LinkID=113216.

Example 1 This command edits advanced storage settings for the backup jobs named "Backup Job 01" and "Backup Job 02". •

The -EnableDeduplication parameter is set to $TRUE to enable data deduplication,



The compression level is set to none (0),



The storage blocks size is set to Automatic.

The jobs are obtained with Get-VBRJob and piped down. Get-VBRJob -Name "Backup Job 01", "Backup Job 02" | SetVBRJobAdvancedStorageOptions -EnableDeduplication $TRUE CompressionLevel 0 -StorageBlockSize 7

Example 2 This command applies the optimal compression level (=5) to all jobs. The jobs are obtained with GetVBRJob and piped down. Get-VBRJob | Set-VBRJobAdvancedStorageOptions -CompressionLevel 5

383 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Set-VBRJobAdvancedViOptions Short Description Customizes VMware job settings.

Applies to Version: 7.0 Platform: VMware

Syntax Set-VBRJobAdvancedViOptions -Job [-ExcludeSwapFile ] [-VmAttributeName ] [-SetResultsToVmAttribute ] [-DoubleSnapshotThresholdMb ] [EnableDoubleSnapshot ] [-EnableChangeTracking ] [UseChangeTracking ] [-VMToolsQuiesce ] []

Related Commands Get-VBRJob

Detailed Description This cmdlet sets special options for the selected VMware job. Read more about VMware job settings in Veeam Backup & Replication user guide at http://www.veeam.com/vmware-backup/help-center. See what else you can perform on job options

Parameters Parameter

Descripti on

Position

Accept Pipeline Input

Accept Wildcard Characters

True

Named

True (ByValue, ByProperty Name)

False

False

Named

False

False

Required

Specifies the job you want to edit. Job

VMTools Quiesce

You can asign multiple jobs to this object. If set to TRUE, the VMware quiescenc e mechanis m will be enabled. Use this mechanis m if the

384 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Required

Position

Accept Pipeline Input

Accept Wildcard Characters

EnableChange Tracking

If set to TRUE, the changed block tracking will be enabled.

False

Named

False

False

UseChange Tracking

If set to TRUE, the changed block tracking will be used even if CBT is disabled on the ESX(i) host.

False

Named

False

False

EnableDouble Snapshot

If set to TRUE, the delta data will be written to several delta files with specified volume limit. A new delta file will be created when the previous file reaches the threshold value set in DoubleSn apshotThr esholdMb parameter.

False

Named

False

False

Double Snapshot Threshold Mb

Specifies threshold limit value for the delta file in Mb.

False

Named

False

False

Parameter

Descripti on applicatio n-aware image processing cannot be used.

385 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Required

Position

Accept Pipeline Input

Accept Wildcard Characters

Exclude SwapFile

If set to TRUE, the swap file will be excluded from backup.

False

Named

False

False

SetResults ToVm Attribute

If set to TRUE, the job results will be written to custom attributes field of the VM.

False

Named

False

False

VmAttribute Name

Specifies the custom attributes field name.

False

Named

False

False

Parameter

Descripti on

This cmdlet supports Microsoft PowerShell common parameters. For more information about common parameters, see http://go.microsoft.com/fwlink/p/?LinkID=113216.

Example This command edits advanced job settings to backup job named "Backup Job 01": •

The VMware quiescence is enabled,



The changed block data is enabled,



The CBT is forced to use despite the ESX host settings,



The swap file is excluded form backup,



The job results are written to the custom attributes field named "backup Results",



The delta file is set to duplicate when reaching 500 Mb volume.

The job is obtained with Get-VBRJob and piped down. Get-VBRJob -Name "Backup Job 01" | Set-VBRJobAdvancedViOptions VMToolsQuiesce True -EnableChangeTracking True -UseChangeTracking True -ExcludeSwapFile True -VmAttributeName "Backup Results" SetResultsToVmAttribute True -EnableDoubleSnapshot True DoubleSnapshotThresholdMb 500

386 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Set-VBRJobObjectVssOptions Short Description Customizes job VSS settings.

Applies to Version: 7.0 Platform: VMware

Syntax Set-VBRJobObjectVssOptions [-Object] [-Options] [-WarningAction ] [WarningVariable ] [] -ORSet-VBRJobObjectVssOptions [-Object] -Credentials [-WarningAction ] [WarningVariable ] []

Related Commands Get-VBRJobObject New-VBRJobVssOptions ([-ForObject]) Get-VBRCredentials

Detailed Description This cmdlet applies a set of customized VSS settings to the specific objects in job or sets credentials to authenticate with a specific objects in job. VSS (Volume Shadow Services) is a Windows OS service allowing to copy files of running applications that can be modified at the moment of copying. The VSS-aware applications typically are Active Directory, Microsoft SQL, Microsoft Exchange, Sharepoint, etc. To create a transactionally consistent backup of a VM running VSS-aware applications without shutting them down, Veeam Backup & Replication uses application-aware image processing. It allows backup the data fully and consistently. To apply the set of customized settings you need to first create a CVssOptions object which unifies all the VSS options you want to apply to the job object. The CVssOptions object is created with the help of the New-VBRJobVssOptions cmdlet. See what else you can perform on job options See what else you can perform on job objects Run Set-VBRJobVssOptions to set the VSS options to the whole job.

387 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Parameters Parameter

Description

Required

Position

Accept Pipeline Input

Accept Wildcard Characters

False

Object

Specifies the VMs and VM containers for which you want to change VSS settings.

True

1

True (ByValue, ByProperty Name)

Options

Specifies the option that you want to change.

True

2

False

False

Credentials

Specifies the credentials you want to use for authenticating with the guest VM.

True

Named

False

False

This cmdlet supports Microsoft PowerShell common parameters. For more information about common parameters, see http://go.microsoft.com/fwlink/p/?LinkID=113216.

388 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Example 1 This command applies custom VSS options to the VM named "AD_01" included in the backup job named "Active Directory Backup". The job object and the VM object are obtained with Get-VBRJob and Get-VBRJobObject accordingly and piped down. The object containing the set of customized VSS options is obtained with New-VBRJobVssOptions ([-ForObject] option) and assigned to the $options variable beforehand. Get-VBRJob -Name "Active Directory Backup" | Get-VBRJobObject Name "AD_01" | Set-VBRJobVssOptions -Options $options

Example 2 This command applies custom VSS options to the VMs running Active Directory represented by the $"AD_VMs" variable. The VMs object is obtained with Get-VBRJobObject and assigned to the variable beforehand. The object containing the set of customized VSS options is obtained with NewVBRJobVssOptions ([-ForObject] option) and assigned to the $options variable beforehand. Set-VBRJobObjectVssOptions -Object $"AD_VMs" -Options $options

Example 3 This command sets credentials to authenticate with the SQL server included in the SharePoint backup job. The VM object is obtained with Get-VBRJobObject and piped down. The job object to look for the VM in is obtained with Get-VBRJob and assigned to the $"SharePoint Backup" variable beforehand. The credentials record to apply to the VM is obtained with Get-VBRCredentials and assigned to the $"Administrator" variable beforehand. Get-VBRJobObject -Job $"SharePoint Backup" -Name "SharePoint_SQL" | Set-VBRJobObjectVssOptions -Credentials $"Administrator"

Example 4 This command sets credentials to authenticate with the VM represented by the $"SharePoint_SQL" variable. The VM object is obtained with Get-VBRJobObject and assigned to the variable beforehand. The credentials record to apply to the VM is obtained with Get-VBRCredentials and assigned to the $"Administrator" variable beforehand. Set-VBRJobObjectVssOptions -Object $"SharePoint_SQL" -Credentials $"Administrator"

389 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Set-VBRJobOptions Short Description Applies custom job settings.

Applies to Version: 7.0 Platform: VMware

Syntax Set-VBRJobOptions [-Job] [-Options] [-WarningAction ] [-WarningVariable ] []

Related Commands Get-VBRJob New-VBRJobOptions

Detailed Description This cmdlet applies a set of customized settings to a selected job. To apply the set of customized settings you need to first create a CJobOptions object which unifies all the options you want to apply to the job. The CJobOptions object is created with the NewVBRJobOptions cmdlet. See what else you can perform on job options

Parameters Parameter

Description

Required

Position

Accept Pipeline Input

Accept Wildcard Characters

False

False

Job

Specifies the job you want to edit.

True

1

True (ByValue, ByProperty Name)

Options

Specifies the set of parameters you want to apply to the job.

True

2

False

This cmdlet supports Microsoft PowerShell common parameters. For more information about common parameters, see http://go.microsoft.com/fwlink/p/?LinkID=113216.

390 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Example 1 This command applies custom settings to the backup job named "Backup Job 01". The job object is obtained with Get-VBRJob and piped down. The object containing the set of customized options is obtained with New-VBRJobOptions and assigned to the $options variable beforehand. Get-VBRJob -Name "Backup Job 01" | Set-VBRJobOptions -Options $options

Example 2 This command applies custom settings to the backup job represented by the $job variable. The job object is obtained with Get-VBRJob andassigned to the variable beforehand. The object containing the set of customized options is obtained with New-VBRJobOptions and assigned to the $options variable beforehand. Set-VBRJobOptions -Job $job -Options $options

391 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Set-VBRJobProxy Short Description Assigns a specific proxy to a job or enables automatic proxy selection.

Applies to Version: 7.0 Platform: VMware, Hyper-V

Syntax Set-VBRJobProxy -Job -Proxy [-Target] [-WarningAction ] [-WarningVariable ] [] -ORSet-VBRJobProxy -Job -AutoDetect [-Target] [WarningAction ] [-WarningVariable ] []

Related Commands Get-VBRJob Get-VBRViProxy / Get-VBRHvProxy

Detailed Description This cmdlet assigns a specific proxy to a job or enables automatic proxy selection. When you create a job, the proxy server is set automatically by default. With this cmdlet, you can assign a custom proxy to a job or set the automatic proxy selection back. This cmdlet provides two scenarios for each case. You can run this cmdlet with backup and replica jobs. See what else you can perform on job assigned proxies Important! Please note that if you want to set a custom proxy you should make sure that the proxy server is added to Veeam Backup & Replication console, otherwise you will not be able to assign it to the job. The custom proxy server should be configured appropriately. Read more about proxy server settings in Veeam Backup & Replication user guide at http://www.veeam.com/vmware-backup/help-center. Run Get-VBRJobProxy to get the list of proxies assigned to a specific job.

392 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Parameters Parameter

Job

Description Specifies the job you want to set proxy to. You can assign multiple backup jobs to this object.

Position

Accept Pipeline Input

Accept Wildcard Characters

True

Named

True (ByValue, ByProperty Name)

False

Required

Proxy

Specifies the proxy server you want to assign to the job.

True

Named

False

False

Target

If set, the command returns the list of target proxy servers. If omitted, the command returns the list of source proxy servers.

False

Named

False

False

AutoDetect

If set, the proxy server selection mode is set to automatic. If you do not set this parameter, you should specify the custom proxy server.

True

Named

False

False

This cmdlet supports Microsoft PowerShell common parameters. For more information about common parameters, see http://go.microsoft.com/fwlink/p/?LinkID=113216.

393 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Example 1 This command assigns the custom VMware source proxy to the jobs named "Backup Job 01" and "Backup Job 02". The jobs are obtained with Get-VBRJob and piped down. The proxy to assign is obtained with Get-VBRViProxy and assigned to the $"SourceProxy" variable beforehand. The -Target parameter is not set to enable the source proxy allocation. Get-VBRJob -Name "Backup Job 01", "Backup Job 02" | SetVBRJobProxy -Proxy $"SourceProxy"

Example 2 This command assigns the custom Hyper-V target proxy to the job represented by the $job variable. The proxy to assign is obtained with Get-VBRHvProxy and assigned to the $proxy variable beforehand. The -Target parameter is set to enable target proxy allocation. Set-VBRJobProxy -Job $job -Proxy $proxy -Target

Example 3 This command sets the automatic source proxy selection mode to the jobs named "Backup Job 01" and "Backup Job 02". The jobs are obtained with Get-VBRJob and piped down. The -Target parameter is not set to enable the source proxy allocation. Get-VBRJob -Name "Backup Job 01", "Backup Job 02" | SetVBRJobProxy -AutoDetect

394 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Set-VBRJobSchedule Short Description Sets job schedule options.

Applies to Version: 7.0 Platform: VMware, Hyper-V

Syntax Set-VBRJobSchedule -Job [-Daily] [-At ] [-DailyKind ] [-Days ] [WarningAction ] [-WarningVariable ] [] -ORSet-VBRJobSchedule -Job [-At ] [-Days ] [-Monthly] [-NumberInMonth ] [Months ] [-WarningAction ] [WarningVariable ][] -ORSet-VBRJobSchedule -Job [-Periodicaly] [FullPeriod ] [-PeriodicallyKind ] [-WarningAction ] [-WarningVariable ] [] -ORSet-VBRJobSchedule -Job [-After] [-AfterJob ] [-WarningAction ] [WarningVariable ] []

Related Commands Get-VBRJob

Detailed Description This cmdlet sets custom schedule settings to the selected job. You can schedule the job to run: •

Daily on specific time, on specific days of week,



Monthly on specific time, on specific days of month, on specific months,



Periodically within specified period of time or continuously,



After a certain job you specify.

See what else you can perform on job options

395 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Parameters Parameter

Job

Description Specifies the job you want to set schedule to. You can assign multiple jobs to this object.

Required

True

Position

Accept Pipeline Input

Accept Wildcard Characters

Named

True (ByValue, ByProperty Name)

False

Daily: Daily

Sets job schedule to daily run.

False

Named

False

False

At

Specifies the job start time. If not set, the job will start at 10:00 by default.

False

Named

False

False

False

Named

False

False

False

Named

False

False

Specifies the days to run the job: Everyday: the job will run everyday,

DailyKind

Weekdays: the job will run Monday through Friday, Selected days: the job will run on specific days (i.e. Saturdays). Use -Days parameter to set the specific days.

Days

Specifies the days of week to run the job.

Monthly:

At

Specifies the job start time. If not set, the job will start at 10:00 by default.

False

Named

False

False

Days

Specifies the day of week to run the job. Use this parameter to set the day for NumberInMonth parameter, i.e. to run the job on first Saturday every month.

False

Named

False

False

False

Named

False

False

Number InMonth

Specifies the period condition for the job run: First/Second/Third/F orth/Last. Use this parameter to set the condition for -

396 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Parameter

Description

Required

Position

Accept Pipeline Input

Accept Wildcard Characters

Days parameter, i.e. to run the job on first Saturday every month. Monthly

Sets job schedule to monthly run.

False

Named

False

False

Months

Specifies the months to run the job.

False

Named

False

False

False

Named

False

False

False

Named

False

False

False

Named

False

False

Periodically: Periodicaly

FullPeriod

Sets job schedule to periodical run. Sets the integer specifying value for the time period to run the job. Use this parameter to set the value for PeriodicallyKind parameter. Specifies the measurement unit for the time period: Hours: the job will run periodically in number of hours set in FullPeriod parameter,

Periodically Kind

Minutes: the job will run periodically in number of minutes set in -FullPeriod parameter, Continuously: the job will run continuously starting right after it has finished. Use this parameter to set the measure unit for the value set in FullPeriod parameter.

After this job: After

Sets job schedule to run after a specific job.

False

Named

False

False

AfterJob

Specifies the job after which you want to run this job.

False

Named

False

False

This cmdlet supports Microsoft PowerShell common parameters. For more information about common parameters, see http://go.microsoft.com/fwlink/p/?LinkID=113216.

397 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Example 1 This command sets a new schedule to jobs named "Backup Job 01" and "Backup Job 05". The jobs are obtained with Get-VBRJob and piped down. The jobs are scheduled to run daily at 23:00 on weekdays. Get-VBRJob -Name "Backup Job 01", "Backup Job 05" | SetVBRJobSchedule -Daily -At "23:00" -DailyKind Weekdays

Example 2 This command schedules all replication jobs to monthly run. The replication jobs are obtained with Get-VBRJob and piped down. The jobs are scheduled to run every last Saturday at 12:00 in February, May, August and December. Get-VBRJob -Name Replica* | Set-VBRJobSchedule -Monthly -At "12:00" -NumberInMonth Last -Days Saturday -Months February, May, August, December

Example 3 This command schedules the job represented by the $job variable to run every 12 hours. The job is obtained with Get-VBRJob and assigned to the variable beforehand. Set-VBRJobSchedule -Job $job -Periodicaly -FullPeriod 12 PeriodicallyKind Hours

Example 4 This command schedules the job represented by the $job variable to run after the SureBackup job named SureBackup Job 01. The SureBackup Job 01 is obtained with Get-VSBJob and piped down. The backup job is obtained with Get-VBRJob and assigned to $job variable beforehand. Get-VSBJob -Name "SureBackup Job 01" | Set-VBRJobSchedule -After -AfterJob $job

398 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Set-VBRJobScheduleOptions Short Description Applies customized job scheduling settings to a selected backup, replication or copy job.

Applies to Version: 7.0 and earlier Platform: VMware

Syntax Set-VBRJobScheduleOptions [-Job] [-Options] [-WarningAction ] [WarningVariable ] []

Related Commands Get-VBRJob New-VBRJobScheduleOptions

Detailed Description This cmdlet applies customized scheduling options to a selected backup, replication or copy job. To customize the scheduling options you need to first run the New-VBRJobScheduleOptions cmdlet. New-VBRJobScheduleOptions returns the ScheduleOptions object containing the set of default scheduling options. See what else you can perform on job options Run Set-VSBJobScheduleOptions to set scheduling options to SureBackup job.

Parameters Parameter

Job

Description Specifies the job for which you want to change the scheduling options.

Position

Accept Pipeline Input

Accept Wildcard Characters

True

1

True (ByValue, ByProperty Name)

False

True

2

False

False

Required

You can assign multiple jobs to this object. Options

Specifies the custom scheduling options.

This cmdlet supports Microsoft PowerShell common parameters. For more information about common parameters, see http://go.microsoft.com/fwlink/p/?LinkID=113216.

399 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Example 1 This command applies the customized scheduling options to the jobs named "DC Backup" and "DC File Copy". The jobs are obtained with Get-VBRJob and piped down. The options to apply are set to the $"Schedule Options" variable beforehand by running New-VBRJobScheduleOptions. Get-VBRJob -Name "DC Backup", "DC File Copy" | SetVBRJobScheduleOptions -Options $"Schedule Options"

Example 2 This command applies the customized scheduling options to the job represented by the $job variable. The job is obtained with Get-VBRJob and assigned to the variable beforehand. The options to apply are set to the $"Schedule Options" variable beforehand by running New-VBRJobScheduleOptions. Set-VBRJobScheduleOptions -Job $job -Options $"Schedule Options"

400 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Set-VBRJobVssOptions Short Description Applies custom VSS settings to a selected job.

Applies to Version: Platform: VMware, Hyper-V

Syntax Set-VBRJobVssOptions [-Job] [-Options] -Credential [-WarningAction ] [-WarningVariable ] []

Related Commands Get-VBRJob New-VBRJobVssOptions

Detailed Description This cmdlet applies a set of customized VSS settings to a selected job. VSS (Volume Shadow Services) is a Windows OS service allowing to copy files of running applications that can be modified at the moment of copying. The VSS-aware applications typically are Active Directory, Microsoft SQL, Microsoft Exchange, Sharepoint, etc. To create a transactionally consistent backup of a VM running VSS-aware applications without shutting them down, Veeam Backup & Replication uses application-aware image processing. It allows backup the data fully and consistently. To apply the set of customized settings you need to first create a CVssOptions object which unifies all the VSS options you want to apply to the job. The CVssOptions object is created with the help of the New-VBRJobVssOptions cmdlet. See what else you can perform on job options Run Set-VBRJobObjectVssOptions to apply VSS settings to specific objects in job.

Parameters Parameter

Description

Required

Position

Accept Pipeline Input

Accept Wildcard Characters

False

Job

Specifies the job you want to edit.

True

1

True (ByValue, ByProperty Name)

Options

Specifies the set of parameters you want to apply to the job.

True

2

False

False

Credential

Specifies the credentials you want to use for authenticating with the guest VM.

True

Named

False

False

401 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

This cmdlet supports Microsoft PowerShell common parameters. For more information about common parameters, see http://go.microsoft.com/fwlink/p/?LinkID=113216.

Example 1 This command applies custom VSS options to the backup job named "Backup Job 01". The job object is obtained with Get-VBRJob and piped down. The object containing the set of customized VSS options is obtained with New-VBRJobVssOptions and assigned to the $options variable beforehand. Get-VBRJob -Name "Backup Job 01" | Set-VBRJobVssOptions -Options $options

Example 2 This command applies custom VSS options to the job represented by the $job variable. The job object is obtained with Get-VBRJob and assigned to the variable beforehand. The object containing the set of customized VSS options is obtained with New-VBRJobVssOptions and assigned to the $options variable beforehand. Set-VBRJobVssOptions -Job $job -Options $options

402 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Set-VSBJobOptions Short Description Applies custom SureBackup job options.

Applies to Version: 7.0 and earlier Platform: VMware

Syntax Set-VSBJobOptions [-Job] [-Options] [WarningAction ] [-WarningVariable ] []

Related Commands Get-VSBJob

Detailed Description This cmdlet applies customized job options to SureBackup jobs. To customize the SureBackup job options you need to first run the New-VSBJobOptions cmdlet. NewVSBJobOptions returns the CDRJobOptionsobject containing the set of default SureBackup job options. You can customize any of these options and apply further to a SureBackup job. Run Set-VBRJobOptions to edit job options of backup, replication or copy job. See what else you can perform on job options See what else you can perform on SureBackup

Parameters Parameter

Job

Description Specifies the SureBackup job for which you want to customize the job options.

Position

Accept Pipeline Input

Accept Wildcard Characters

True

1

True (ByValue, ByProperty Name)

False

True

2

False

False

Required

You can assign multiple jobs to this object. Options

Specifies the custom SureBackup job options.

This cmdlet supports Microsoft PowerShell common parameters. For more information about common parameters, see http://go.microsoft.com/fwlink/p/?LinkID=113216.

403 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Example 1 This command applies the customized options to the SUreBackup job named "SureBackup Job 01". The job object is obtained with Get-VSBJob and piped down. The options to apply are set to the $"Sure Options" variable beforehand by running New-VSBJobOptions. Get-VBRJob -Name "SureBackup Job 01" | Set-VSBJobOptions -Options $"Sure Options"

Example 2 This command applies the customized job options to the SureBackup job represented by the $SureJob variable. The job is obtained with Get-VSBJob and assigned to the variable beforehand. The options to apply are set to the $"Sure Options" variable beforehand by running New-VSBJobOptions. Set-VBRJobScheduleOptions -Job $SureJob -Options $"Sure Options"

404 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Set-VSBJobSchedule Short Description Sets SureBackup job schedule options.

Applies to Version: 7.0 Platform: VMware, Hyper-V

Syntax Set-VSBJobSchedule [-Job] [-Daily] [-At ] [DailyKind ] [-Days ] [WarningAction ] [-WarningVariable ] [] -ORSet-VSBJobSchedule [-Job] [-At ] [-Days ] [-Monthly] [-NumberInMonth ] [Months ] [-WarningAction ] [WarningVariable ] [] -ORSet-VSBJobSchedule [-Job] [-After] [-AfterJob ] [-WarningAction ] [WarningVariable ] []

Related Commands Get-VSBJob Get-VBRJob

Detailed Description This cmdlet sets custom schedule settings to the selected SureBackup job. You can schedule the job to run: •

Daily on specific time, on specific days of week,



Monthly on specific time, on specific days of month, on specific months,



After a certain job you specify.

See what else you can perform on job options See what else you can perform on SureBackup

405 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Parameters Parameter

Job

Description Specifies the SureBackup job you want to set schedule to. You can include multiple jobs into this object.

Required

True

Position

Accept Pipeline Input

Accept Wildcard Char acters

Named

True (ByValue, ByProperty Name)

False

Daily: Daily

Sets SureBackup job schedule to daily run.

False

Named

False

False

At

Specifies the SureBackup job start time. If not set, the job will start at 10:00 by default.

False

Named

False

False

False

Named

False

False

False

Named

False

False

Specifies the days to run the SureBackup job: Everyday: the job will run everyday, DailyKind

Weekdays: the job will run Monday through Friday, Selected days: the job will run on specific days (i.e. Saturdays). Use -Days parameter to set the specific days.

Days

Specifies the days of week to run the SureBackup job.

Monthly:

At

Specifies the SureBackup job start time. If not set, the job will start at 10:00 by default.

False

Named

False

False

Days

Specifies the day of week to run the SureBackup job. Use this parameter to set the day for NumberInMonth parameter, i.e. to run the job on first Saturday every month.

False

Named

False

False

Number InMonth

Specifies the period condition for the SureBackup job run:

False

Named

False

False

406 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Parameter

Description

Required

Position

Accept Pipeline Input

Accept Wildcard Char acters

First/Second/Third/F orth/Last. Use this parameter to set the condition for Days parameter, i.e. to run the job on first Saturday every month. Monthly

Sets SureBackup job schedule to monthly run.

False

Named

False

False

Months

Specifies the months to run the SureBackup job.

False

Named

False

False

After this job: After

Sets SureBackup job schedule to run after a specific job.

False

Named

False

False

AfterJob

Specifies the job after which you want to run the SureBackup job.

False

Named

False

False

This cmdlet supports Microsoft PowerShell common parameters. For more information about common parameters, see http://go.microsoft.com/fwlink/p/?LinkID=113216.

407 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Example 1 This command schedules the jobs named "SureBackup Job 01" and "SureBackup Job 05" to run daily at 23:00 on weekdays. The SureBackup jobs object is obtained with Get-VSBJob and piped down. Get-VSBJob -Name "SureBackup Job 01", "SureBackup Job 05" | SetVSBJobSchedule -Daily -At "23:00" -DailyKind Weekdays

Example 2 This command schedules all SureBackup jobs to run every last Saturday at 12:00 in February, May, August and December. The SureBackup jobs object is obtained with Get-VSBJob and piped down. Get-VSBJob -Name *SureJob* | Set-VSBJobSchedule -Monthly -At "12:00" -NumberInMonth Last -Days Saturday -Months February, May, August, December

Example 3 This command schedules the job represented by the $job variable to run after the SureBackup job named "SureBackup Job 01". The SureBackup job object is obtained with Get-VSBJob and piped down.. The backup job object is obtained with Get-VBRJob and assigned to $job variable beforehand. Get-VBRJob -Name "SureBackup Job 01" | Set-VBRJobSchedule -After -AfterJob $job

408 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Set-VSBJobScheduleOptions Short Description Applies customized job scheduling options to a selected SureBackup job.

Applies to Version: 7.0 and earlier Platform: VMware

Syntax Set-VSBJobScheduleOptions [-Job] [-Options] [-WarningAction ] [WarningVariable ] []

Related Commands Get-VSBJob New-VBRJobScheduleOptions

Detailed Description This cmdlet applies customized scheduling options to a selected SureBackup job. To customize the scheduling options you need to first run the New-VBRJobScheduleOptions cmdlet. New-VBRJobScheduleOptions returns the ScheduleOptions object containing the set of default scheduling options. You can customize any of these options and apply further to any kind of jobs. Run Set-VBRJobScheduleOptions to set scheduling options of backup, replication or copy job. See what else you can perform on job options See what else you can perform on SureBackup

Parameters Parameter

Job

Description Specifies the SureBackup job for which you want to change the scheduling options.

Position

Accept Pipeline Input

Accept Wildcard Characters

True

1

True (ByValue, ByProperty Name)

False

True

2

False

False

Required

You can assign multiple SureBackup jobs to this object. Options

Specifies the custom scheduling options.

This cmdlet supports Microsoft PowerShell common parameters. For more information about common parameters, see http://go.microsoft.com/fwlink/p/?LinkID=113216.

409 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Example 1 This command applies the customized scheduling options to the SureBackup jobs named "SharePoint SureJob" and "MailServer SureJob". The jobs are obtained with Get-VSBJob and piped down. The options to apply are set to the $"Schedule Options" variable beforehand by running NewVBRJobScheduleOptions. Get-VSBJob -Name "SharePoint SureJob", "MailServer SureJob" | Set-VSBJobScheduleOptions -Options $"Schedule Options"

Example 2 This command applies the customized scheduling options to the SureBackup job represented by the $SureJob variable. The job object is obtained with Get-VSBJob and assigned to the variable beforehand. The options to apply are set to the $"Schedule Options" variable beforehand by running New-VBRJobScheduleOptions. Set-VSBJobScheduleOptions -Job $SureJob -Options $"Schedule Options"

410 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Start-VBRHvInstantRecovery Short Description Starts a VM instant recovery.

Applies to Version: 7.0 Platform: Hyper-V

Syntax Start-VBRHvInstantRecovery [-RestorePoint] [-Server] [-Path] [-VMName ][-PreserveVmID []] [-PowerUp []] [-NICsEnabled []] [PreserveMACs []] [-Reason ] [-WarningAction ] [-WarningVariable ] []

Related Commands Get-VBRRestorePoint Get-VBRServer

Detailed Description This cmdlet allows to perform instant VM recovery. When you run this cmdlet, Veeam Backup & Replication creates a copy of a VM in your Hyper-V environment and starts it immediately (if needed). The VM is started directly from a compressed and deduplicated backup file. Please note that the instantly recovered VM runs from a backup and does not provide a wholly functioning service. You need to finalize the successful instant recovery by either permanently migrating the recovered VM to the production host or by stopping publishing the recovered VM. Run Start-VBRHvInstantRecoveryMigration or Stop-VBRInstantRecovery respectively. Run Restart-VBRInstantRecovery to restart a failed instant recovery session. See what else you can perform on instant recovery

411 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Parameters Parameter

Description

Required

Position

Accept Pipeline Input

Accept Wildcard Characters

False

RestorePoint

Specifies the VM restore point you want to restore the VM to.

True

1

True (ByValue, ByProperty Name)

Server

Specifies the server where you want to restore the VM.

True

2

False

False

Path

Specifies the path to the folder to store the redo logs.

True

3

False

False

VMName

Specifies the name of the VM you want to restore. If not set, the name of the backup will be used.

False

Named

False

False

PowerUp

If set to $True, the VM will be powered up right after it is restored. Otherwise, you will need to power up the VM manually.

False

Named

False

False

NICsEnabled

If set to $True, the restored VM will be connected to the network. Otherwise the VM will have no network connections.

False

Named

False

False

False

Named

False

False

If set to TRUE, the restored VM will get the ID of the original VM. Otherwise, the restored VM will get a new ID.

PreserveVmID

Please note that if the original VM keeps running, preserving the ID will cause conflict. Preserving the ID is useful in case the original VM will not be used in future - in this case, Veeam Backup & Replication will recognize the restored VM as its original and perform all backup and other operations that were scheduled for the original VM.

Specifies the reason for performing restore of the selected VM. Reason

The information you provide will be saved in the session history so that you can reference it later.

412 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

This cmdlet supports Microsoft PowerShell common parameters. For more information about common parameters, see http://go.microsoft.com/fwlink/p/?LinkID=113216.

Example This command starts instant recovery of the VM. •

The VM to restore is obtained together with the restore point to which the VM will be restored with Get-VBRRestorePoint and assigned to the $rpoint variable beforehand.



The Hyper-V host where the restored VM will be located in obtained with Get-VBRServer and assigned to the $server variable beforehand,



The file path for redo logs is c:\Hyper-V\Virtual Hard Disks\Redo,



The VM will be restored with name "New-Exch01",



The -PowerUp parameter is set to $True to enable the VM power up automatically.

Start-VBRHvInstantRecovery -RestorePoint $rpoint -Server $server -Path "c:\Hyper-V\Virtual Hard Disks\Redo" -VMName New-Exch01 PowerUp $True

413 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Start-VBRHvInstantRecoveryMigration Short Description Performs VM migration to a Hyper-V host.

Applies to Version: 6.5 Platform: Hyper-V

Syntax Start-VBRHvInstantRecoveryMigration [-InstantRecovery] [-WarningAction ][WarningVariable ] []

Related Commands Get-VBRInstantRecovery

Detailed Description This cmdlet migrates a recovered VM to the production host. You finalize the instant recovery of the VM initiated with Start-VBRHvInstantRecovery by migrating the VM to production. Run Stop-VBRInstantRecovery to terminate the recovery session by unpublishing the VM. See what else you can perform on instant recovery

Parameters Parameter

Instant Recovery

Description Specifies the session(s) started with the StartVBRHvInstantRecovery cmdlet to finalize migration of a recovered VM to a HyperV host.

Required

True

Position

Accept Pipeline Input

Accept Wildcard Characters

1

True (ByValue, ByProperty Name)

False

You can assign multiple instant recovery sessions to this object.

This cmdlet supports Microsoft PowerShell common parameters. For more information about common parameters, see http://go.microsoft.com/fwlink/p/?LinkID=113216.

414 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Example 1 This command finalizes the current instant recovery session. The session is obtained with GetVBRInstantRecovery and piped down. Get-VBRInstantRecovery | Start-VBRHvInstantRecoveryMigration

Example 2 This command finalizes the instant recovery session represented by the $"Hv Instant Recovery" variable. The session is obtained with Get-VBRInstantRecovery and assigned to the variable beforehand. Start-VBRHvInstantRecoveryMigration -InstantRecovery $"Hv Instant Recovery"

415 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Start-VBRHvReplicaFailback Short Description Performs failback to the production host.

Applies to Version: 7.0 and earlier Platform: Hyper-V

Syntax Start-VBRHvReplicaFailback -RestorePoint [-Reason ] [-RunAsync] [-WarningAction ] [WarningVariable ] [-WhatIf] [-Confirm] []

Related Commands Get-VBRRestorePoint

Detailed Description This cmdlet stars failing back to the production host after failover to its replica. This cmdlet lets you finalize the replica failover started with Start-VBRViReplicaFailover by switching back to the production VM with data synchronization. When you perform failback, you switch back to the original VM on the production site. The failback process collects all the changes that were made to the replica while you failed over to it, and implies them to the source VM. This allows you to switch between source and replica VMs without data loss. To switch back to the production VM and discard the changes made to the replica while failover, start an undo failover process. In this case you return to the production VM in the state preceeding failover. Run Stop-VBRReplicaFailover to undo failover. Undo Failback: If you tried to fail back to the original VM but was unable to, because i.e. it was nonfunctional or corrupted, you can undo the failback and return to the working replica. Run StopVBRViReplicaFailback to undo failback. See what else you can perform on replicas

Parameters Position

Accept Pipeline Input

Accept Wildcard Characters

True

Named

True (ByValue, ByProperty Name)

False

Specifies the reason for performing a failback.

False

Named

False

False

Indicates that the command returns immediately without waiting for the task to

False

Named

False

False

Parameter

Description

RestorePoint

Specifies the replica restore point which you want to fail back.

Reason

RunAsync

Required

416 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Parameter

Description

Required

Position

Accept Pipeline Input

Accept Wildcard Characters

complete.

This cmdlet supports Microsoft PowerShell common parameters. For more information about common parameters, see http://go.microsoft.com/fwlink/p/?LinkID=113216.

Example 1 This command fails back from the VM replica named "WebServer_ replica". The restore point is obtained with Get-VBRRestorePoint and piped down. The restore points of the VM are filtered with Sort-Object method by the "creationtime" property to get the most recent one. The reason is "Configuration recovery". The RunAsync parameter is set to bring the process to the background. Get-VBRRestorePoint -Name "WebServer_replica" | Sort-Object $_.creationtime -Descending | Select -First 1 | StartVBRHvReplicaFailback -Reason "Configuration recovery" -RunAsync

Example 2 This command fails back from the VM replica represented by the $"WebServer_replica restorepoint" variable. The restore point is obtained with Get-VBRRestorePoint and assigned to the variable beforehand. The reason is "Data recovery". The RunAsync parameter is set to bring the process to the background. Start-VBRHvReplicaFailback -RestorePoint $"WebServer_replica restorepoint" -Reason "Data recovery" -RunAsync

417 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Start-VBRHvRestoreVM Short Description Starts restore of the entire VM.

Applies to Version: 7.0 and earlier Platform: Hyper-V For VMware, run Start-VBRRestoreVM.

Syntax Start-VBRHvRestoreVM [-RestorePoint] [-Server ] [Path ] [-VMName ] [-PreserveVmID []] [PowerUp] [-RegisterAsClusterResource] [-NICsEnabled []] [-PreserveMACs []] [-User ] [-Password ] [-Credential ] [-Reason ] [-RunAsync] [WarningAction ] [-WarningVariable ] []

Related Commands Get-VBRRestorePoint Get-VBRServer

Detailed Description Starts restore of the entire VM. See what else you can perform on restore

Parameters Parameter

Description

Required

Position

Accept Pipeline Input

Accept Wildcard Characters

False

RestorePoint

Specifies the VM restore point to which you want to restore.

True

1

True (ByValue, ByProperty Name)

Server

Specifies the host where you want to locate the restored VM.

False

Named

False

False

Path

Specifies the path to the folder where you want to restore the VM.

False

Named

False

False

VMName

Specifies the name you want to apply to the restored VM. By default, the original VM name is applied.

False

Named

False

False

PreserveVmID

If set to TRUE, the restored VM will get the

False

Named

False

False

418 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Required

Position

Accept Pipeline Input

Accept Wildcard Characters

PowerUp

If set, the restored VM will be powered up immediately after the restore. Otherwise, you will have to power up the VM manually.

False

Named

False

False

RegisterAs ClusterResource

If set, the restored VM will be registered as a part of a cluster in case you restore the VM to a clustered host.

False

Named

False

False

NICsEnabled

If set to True, the restored VM will be connected to the network. Otherwise the VM will have no network connections.

False

Named

False

False

False

Named

False

False

Parameter

Description ID of the original VM. Otherwise, the restored VM will get a new ID. Please note that if the original VM keeps running, preserving the ID will cause conflict. Preserving the ID is useful in case the original VM will not be used in future - in this case, Veeam Backup & Replication will recognize the restored VM as its original and perform all backup and other operations that were scheduled for the original VM.

If set to TRUE, the restored VM will get the MAC address of the original VM. Otherwise, the restored VM will get a new MAC address.

PreserveMACs

Please note that if the original VM keeps running, preserving the MAC address will cause conflict. Preserving the MAC address is useful in case the original VM will not be used in future - in this case, the restored VM will be able to use the MAC settings used by its applications, if any are installed.

419 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Parameter

Description

Required

Position

Accept Pipeline Input

Accept Wildcard Characters

False

Named

False

False

False

Named

False

False

False

Named

False

False

False

Named

False

False

False

Named

False

False

Specifies the user name you want to use for authenticating with the VM. User

If you use the Username/Password scenario, the Credentials parameter must be omitted. Specifies the password you want to use for authenticating with the VM.

Password

If you use the Username/Password scenario, the Credentials parameter must be omitted. Specifies the credentials you want to use for authenticating with the VM.

Credential

If you use the Credentials scenario, the -User and -Password parameters must be omitted. Specifies the reason for performing restore of the selected VM.

Reason

RunAsync

The information you provide will be saved in the session history so that you can reference it later. Indicates that the command returns immediately without waiting for the task to complete.

This cmdlet supports Microsoft PowerShell common parameters. For more information about common parameters, see http://go.microsoft.com/fwlink/p/?LinkID=113216.

420 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Start-VBRInstantRecovery Short Description Starts instant VM recovery.

Applies to Version: 7.0 and earlier Platform: VMware

Syntax Start-VBRInstantRecovery [-RestorePoint] [-VMName ] [-Server] [-ResourcePool] [-Datastore ] [-Folder ] [PowerUp] [-NICsEnabled] [-Reason ] [-RunAsync] [WarningAction ] [-WarningVariable ] []

Related Commands Get-VBRRestorePoint Get-VBRServer Find-VBRViResourcePool Find-VBRViDatastore Find-VBRViFolder

Detailed Description This cmdlet starts VM instant recovery. With instant recovery technology, Veeam Backup & Replication starts a VM directly from a backup, incremental or full, without copying it to production storage. Please note that the instantly recovered VM runs from a backup and does not provide a wholly functioning service. You need to finalize the successful instant recovery by either permanently migrating the recovered VM to the production host or by stopping publishing the recovered VM. Run Start-VBRQuickMigration or Stop-VBRInstantRecovery respectively. See what else you can perform on instant recovery

Parameters Required

Position

Accept Pipeline Input

Accept Wildcard Characters

False

False

Parameter

Description

RestorePoint

Specifies the restore point to which you want to recover the VM.

True

1

True (ByValue, ByProperty Name)

VMName

Specifies the name you want to apply to the restored VM. By default, the original VM name is applied.

False

Named

False

421 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Parameter

Description

Required

Position

Accept Pipeline Input

Accept Wildcard Characters

Server

Specifies the target host where you want to locate the restored VM.

True

2

False

False

ResourcePool

Specifies the resource pool where you want to locate the restored VM.

False

3

False

False

Datastore

Specifies the datastore to which you want to connect the restored VM.

False

Named

False

False

Folder

Specifies the folder where you want to locate the restored VM.

False

Named

False

False

PowerUp

If set, the restored VM will be powered up immediately after the restore. Otherwise, you will have to power up the VM manually.

False

Named

False

False

NICsEnabled

If set to True, the restored VM will be connected to the network. Otherwise the VM will have no network connections.

False

Named

False

False

False

Named

False

False

False

Named

False

False

Specifies the reason for performing restore of the selected VM. Reason

RunAsync

The information you provide will be saved in the session history so that you can reference it later. Indicates that the command returns immediately without waiting for the task to complete.

This cmdlet supports Microsoft PowerShell common parameters. For more information about common parameters, see http://go.microsoft.com/fwlink/p/?LinkID=113216.

422 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Example 1 This command starts the instant recovery of the VM named "MSExchange". The VM is restored to the original location and to the last restore point. The backup and the restore point are obtained with Get-VBRBackup and Get-VBRRestorePoint respectively and piped down. The server to locate the restored VM is obtained with Get-VBRServer and assigned to the $server variable beforehand. Get-VBRBackup -Name "MSExchange Backup" | Get-VBRRestorePoint | Select -Last 1 | Start-VBRInstantRecovery -Server $server

Example 2 This command restores the VM to another location and with different settings. The following parameters are set: •

The restore point is obtained with Get-VBRRestorePoint and assigned to the $restorepoint variable,



The VM is restored with name "MSExchange_Restored",



The server to locate the restored VM is obtained with Get-VBRServer and assigned to the $server variable,



The resource pool is obtained with Find-VBRViResourcePool and assigned to the $pool variable,



The datastore is obtained with Find-VBRViDatastore and assigned to the $store variable,



The folder to locate the restored VM is C:\Restored,



The -PowerUp parameter is set to TRUE to enable the auto power up of the restored VM,



The -NICsEnabled parameter is set to TRUE to connect the restored VM to the host network,



The restore reason is "Data recovery",



The RunAsync parameter is set to bring the process to the background.

Start-VBRInstantRecovery -RestorePoint $restorepoint -VMName "MSExchange_Restored" -Server $server -ResourcePool $pool Datastore $store -Folder "C:\Restored" -PowerUp TRUE -NICsEnabled TRUE -Reason "Data recovery" -RunAsync

423 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Start-VBRJob Short Description Starts backup, replication or copy job.

Applies to Version: 7.0 and earlier Platform: VMware

Syntax Start-VBRJob [-Job] [-FullBackup] [-RetryBackup] [-RunAsync] [-WarningAction ] [-WarningVariable ] []

Related Commands Get-VBRJob

Detailed Description This cmdlet allows you to start a created or stopped backup, replication or copy job.You can start the job for an ordinary run, or force a full backup, or set the job to try to restart in case it fails. When you create a job, you need to run it manually unless you enable a job schedule. Run SetVBRJobSchedule to schedule the job to run automatically. You can start the job for an ordinary run, or force a full backup, or set the job to try to restart in case it fails. Run Stop-VBRJob to stop a running job. Run Enable-VBRJob to enable a disabled job. Run Start-VSBJob to start a SureBackup job. See what else you can perform on jobs

Parameters Parameter

Job

Description Specifies the job you want to start. You can assign multiple jobs to this object.

Position

Accept Pipeline Input

Accept Wildcard Characters

True

1

True (ByValue, ByProperty Name)

False

Required

FullBackup

Specify this parameter if you want to perform an active full backup.

False

Named

False

False

RetryBackup

Specify this parameter if you want the job to try to restart in case it fails. By default, the job automatically tries to restart for 3 times.

False

Named

False

False

424 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Parameter

RunAsync

Description

Required

Position

Accept Pipeline Input

Accept Wildcard Characters

Indicates that the command returns immediately without waiting for the task to complete.

False

Named

False

False

This cmdlet supports Microsoft PowerShell common parameters. For more information about common parameters, see http://go.microsoft.com/fwlink/p/?LinkID=113216.

Example 1 This command starts the jobs named "WebApplications Server Backup" and "Fileserver Copy Job". The job is obtained with Get-VBRJob and piped down. Get-VBRJob -Name "WebApplications Server Backup", "Fileserver Copy Job" | Start-VBRJob

Example 2 This command starts the vCloud backup job right after it the job is created. (See Add-VBRvCloudJob for creating a vCloud job). The RunAsync parameter is set to bring the process to the background. Add-VBRvCloudJob -Entity $"vCloud Server" -Name "vCloud Server Backpup" | Start-VBRJob -RunAsync

Example 3 This command starts the job named "WebApplications Server Backup" and requires to perform a full backup. The job is obtained with Get-VBRJob and piped down. Get-VBRJob -Name "WebApplications Server Backup" | Start-VBRJob FullBackup

Example 4 This command starts the job represented by the $job variable. The job is obtained with Get-VBRJob and assigned to the variable beforehand. The -RetryBackup parameter is set to enable the automatic retry. The RunAsync parameter is set to bring the process to the background. Start-VBRJob -Job $job -RetryBackup -RunAsync

425 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Start-VBRQuickMigration Short Description Starts Quick Migration of a virtual machine.

Applies to Version: 7.0 Platform: VMware

Syntax Start-VBRQuickMigration -Entity -Server [ResourcePool ] [-Datastore ] [-Folder ] [-SourceProxy ] [-TargetProxy ] [-ForceVeeamQM] [DeleteSorceVmFiles] [-RunAsync] [-WarningAction ] [-WarningVariable ][]

Related Commands Find-VBRViEntity Get-VBRServer Find-VBRViResourcePool Find-VBRViDatastore Find-VBRViFolder Get-VBRViProxy

Detailed Description This cmdlet starts Quick Migration for a selected virtual machine(s). Quick Migration is a service allowing to promptly migrate a VM between ESX(i) hosts, datastores or both in any state with minimum disruption to business operations and end user access to services.

Parameters Parameter

Description

Required

Position

Accept Pipeline Input

Accept Wildcard Characters

Named

True (ByValue, ByProperty Name)

False

False

False

Entity

Specifies the virtual machine(s) you want to migrate. You can assign multiple VMs to this object.

Server

Specifies the destination server to where you want to migrate the VM.

True

Named

True (ByValue, ByProperty Name)

ResourcePool

Specifies the destination resource pool to where you want to migrate the VM.

False

Named

False

True

426 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Parameter

Description

Required

Position

Accept Pipeline Input

Accept Wildcard Characters

Datastore

Specifies the destination datastore to where you want to migrate the VM.

False

Named

False

False

Folder

Specifies the destination folder to where you want to migrate the VM.

False

Named

False

False

False

Named

False

False

False

Named

False

False

False

Named

False

False

Specifies the source backup proxy(ies).

SourceProxy

If not specified, Veeam Backup & Replication provides automatic selection of the proxy (recommended). For best migration performance you should deploy at least one source backup proxy. You can assign multiple proxies to this object. Specifies the target backup proxy(ies).

TargetProxy

If not specified, Veeam Backup & Replication provides automatic selection of the proxy (recommended). For best migration performance you should deploy at least one target backup proxy. You can assign multiple proxies to this object. Forces using Veeam Quick Migration.

Force VeeamQM

If omitted, migration process will use VMware VMotion given that the migration scenario and VMware licensing allows it.

DeleteSorce VmFiles

If set, the original VM will be deleted upon receiving the heartbeat from the VM on the target host.

False

Named

False

False

RunAsync

Indicates that the command returns immediately without waiting for the task to complete.

False

Named

False

False

This cmdlet supports Microsoft PowerShell common parameters. For more information about common parameters, see http://go.microsoft.com/fwlink/p/?LinkID=113216.

427 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Example This command starts Quick Migration of the selected VM. •

The VM to migrate is obtained with Find-VBRViEntity and assigned to the $vm variable beforehand,



The host to where the VM will be migrated is obtained with Get-VBRServer and assigned to the $server variable beforehand,



The resource pool to where the VM will be migrated is obtained with FindVBRViResourcePool and assigned to the $pool variable beforehand,



The datastore to connect the VM to is obtained with Find-VBRViDatastore and assigned to the $datastore variable beforehand,



The folder to where the VM will be migrated is obtained with Find-VBRViFolder and assigned to the $folder variable beforehand.

The source and target proxies are not set enabling the Quick Migration mechanism to select them automatically. The -ForceVeeamQM parameter is not set enabling the use of VMware VMotion. The DeleteSourceVmFiles parameter is set to enable the clear up of the original VM files upon successful migration. The -RunAsync parameter is not set. Start-VBRQuickMigration -Entity $vm -Server $server -ResourcePool $pool -Datastore $d -Folder $folder -DeleteSorceVmFiles

428 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Start-VBRReplicaFailover Short Description Fails over a corrupted VM to its replica. Note:

In Backup & Replication v6 this cmdlet was replaced by Start-VBRViReplicaFailover. The cmdlet will still work but it is advised to rewrite your scripts using new cmdlets for added benefits.

Applies to Version: 7.0 and earlier Platform: VMware, Hyper-V

Syntax Start-VBRReplicaFailover [-RestorePoint] [-Reason ] [-RunAsync] [-WarningAction ] [WarningVariable ] [-WhatIf] [-Confirm] []

Related Commands Get-VBRRestorePoint

Detailed Description This cmdlet allows you fail over a corrupted VM to its successfully created replica. Performing failover is switching to a VM replica in case the original VM is damaged. You can fail over to the latest state of a replica or to any of its good known restore points. See what else you can perform on replicas

Parameters Position

Accept Pipeline Input

Accept Wildcard Characters

True

1

True (ByValue, ByProperty Name)

False

Specifies the reason for performing a failover.

False

Named

False

False

Indicates that the command returns immediately without waiting for the task to complete.

False

Named

False

False

Parameter

Description

RestorePoint

Specifies the replica restore point to which you want to fail over.

Reason

RunAsync

Required

This cmdlet supports Microsoft PowerShell common parameters. For more information about common parameters, see http://go.microsoft.com/fwlink/p/?LinkID=113216.

429 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Example 1 This command fails over to the VM replica named "WebServer_ replica" to its latest restore point. The restore point is obtained with Get-VBRRestorePoint and piped down. The restore points of the VM are filtered with Sort-Object method by the "creationtime" property to get the most recent one. The reason is "Configuration recovery". The RunAsync parameter is set to bring the process to the background. Get-VBRRestorePoint -Name "WebServer_replica" | Sort-Object $_.creationtime -Descending | Select -First 1 | StartVBRReplicaFailover -Reason "Configuration recovery" -RunAsync

Example 2 This command fails over to the VM replica represented by the $"WebServer_replica restorepoint" variable. The restore point is obtained with Get-VBRRestorePoint and assigned to the variable beforehand. The reason is "Data recovery". The RunAsync parameter is set to bring the process to the background. Start-VBRReplicaFailover -RestorePoint $"WebServer_replica restorepoint" -Reason "Data recovery" -RunAsync

430 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Start-VBRRestoreVM Short Description Starts restore of the entire VM.

Applies to Version: 7.0 and earlier Platform: VMware For Hyper-V, run Start-VBRHvRestoreVM

Syntax Start-VBRRestoreVM [-RestorePoint] [-Server] [[ResourcePool] ] [[-Datastore] ] [-Folder ] [-VMName ] [-DiskType ] [-PowerUp []] [-Reason ] [-RunAsync] [-WarningAction ] [WarningVariable ] []

Related Commands Get-VBRRestorePoint Get-VBRServer Find-VBRViResourcePool Find-VBRViDatastore Find-VBRViFolder

Detailed Description This cmdlet starts the entire VM restore. With this cmdlet, you can restore the VM to the original location or to another location, or with different settings. See what else you can perform on restore

Parameters Required

Position

Accept Pipeline Input

Accept Wildcard Characters

False

Parameter

Description

RestorePoint

Specifies the VM restore point to which you want to restore.

True

1

True (ByValue, ByProperty Name)

Server

Specifies the host where you want to locate the restored VM.

True

2

False

False

ResourcePool

Specifies the resource pool where you want to locate the restored VM.

False

3

False

False

431 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Description

Required

Position

Accept Pipeline Input

Accept Wildcard Characters

Datastore

Specifies the datastore to which you want to connect the restored VM.

False

4

False

False

Folder

Specifies the folder where you want to locate the restored VM.

False

Named

False

False

VMName

Specifies the name you want to apply to the restored VM. By default, the original VM name is applied.

False

Named

False

False

DiskType

Specifies the disk type foryou want to apply to the restored VM: Thin, Thick or AsOriginal.

False

Named

False

False

PowerUp

If set, the restored VM will be powered up immediately after the restore. Otherwise, you will have to power up the VM manually.

False

Named

False

False

False

Named

False

False

False

Named

False

False

Parameter

Specifies the reason for performing restore of the selected VM. Reason

RunAsync

The information you provide will be saved in the session history so that you can reference it later. Indicates that the command returns immediately without waiting for the task to complete.

This cmdlet supports Microsoft PowerShell common parameters. For more information about common parameters, see http://go.microsoft.com/fwlink/p/?LinkID=113216.

Example This example allows you to restore the VM from the restore point specified in the $point variable and start it on the host specified in the $server variable and resource pool specified in the $rpool variable, putting it on the datastore specified in the $dstore variable. Start-VBRRestoreVM –RestorePoint $point –Server $server – ResourcePool $rpool –Datastore $dstore –PowerUp TRUE

432 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Start-VBRRestoreVMFiles Short Description Restores VM configuration files.

Applies to Version: 7.0 and earlier Platform: VMware

Syntax Start-VBRRestoreVMFiles [-RestorePoint] [-Server] [-Path] [-Files ] [-Reason ] [RunAsync] [-WarningAction ] [-WarningVariable ] []

Related Commands Get-VBRRestorePoint Get-VBRServer Get-VBRFilesInRestorePoint

Detailed Description This cmdlet allows you to restore configuration file (.vmx) or virtual disks (.vmdk) of a selected VM. Run Start-VBRWindowsFileRestore to restore VM disks data. See what else you can perform on restore

Parameters Parameter

Description

Required

Position

Accept Pipeline Input

Accept Wildcard Characters

RestorePoint

Specifies the VM restore point to which you want to restore.

True

1

True

False

Server

Specifies the host to which the VM guest files should be restored.

True

2

False

False

Path

Specifies the string with the path to the folder where restored files should be saved

True

3

False

False

Files

Specifies the files you want to restore (by default, all files from the VM will be restored).

False

Named

True (ByName)

False

Reason

Specifies the string with the reason for performing the VM guest OS file restore.

False

Named

False

False

RunAsync

Indicates that the command returns immediately without waiting for the task to

False

Named

False

False

433 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Parameter

Description

Required

Position

Accept Pipeline Input

Accept Wildcard Characters

complete.

This cmdlet supports Microsoft PowerShell common parameters. For more information about common parameters, see http://go.microsoft.com/fwlink/p/?LinkID=113216.

Example This example allows you to restore all VM guest OS files from the restore point specified in the $point variable and save them on the host specified in the $server variable to the C:\BackupFiles folder. Start-VBRRestoreVMFiles –RestorePoint $point –Server $server – Path “C:\BackupFiles”

434 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Start-VBRTapeCatalog Short Description Indexes library or tape.

Applies to Version: 7.0 Platform: VMware, Hyper-V

Syntax Start-VBRTapeCatalog -Library [-RunAsync] [WarningAction ] [-WarningVariable ] [] -ORStart-VBRTapeCatalog -Medium [-RunAsync] [WarningAction ] [-WarningVariable ] []

Related Commands Get-VBRTapeLibrary Get-VBRTapeMedium

Detailed Description This cmdlet starts indexing process for files stored on tapes. You can catalog for a library or for a tape or a group of tapes. This cmdlet provides scenarios for both cases. See what else you can perform on tapes

Parameters Parameter

Description

Required

Position

Accept Pipeline Input

Accept Wildcard Characters

Named

True (ByValue, ByProperty Name)

False

False

False

Library

Specifies the tape library you want to catalog.

Medium

Specifies the tape(s) you want to catalog.

True

Named

True (ByValue, ByProperty Name)

RunAsync

Indicates that the command returns immediately without waiting for the task to complete.

False

Named

False

True

435 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

This cmdlet supports Microsoft PowerShell common parameters. For more information about common parameters, see http://go.microsoft.com/fwlink/p/?LinkID=113216.

Example 1 This command starts indexing the tapes with names starting with "001". The tapes are obtained with Get-VBRTapeMedium and piped down. The -RunAsync parameter is set to enable the background processing of the job. Get-VBRTapeMedium -Name 001* | Start-VBRTapeCatalog -RunAsync

Example 2 This command starts indexing the library represented by $lib variable. The library object is obtained with Get-VBRTapeLibrary and assigned to the variable beforehand. The -RunAsync parameter is set to enable the background. Start-VBRTapeCatalog -Library $lib -RunAsync

436 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Start-VBRTapeInventory Short Description Inventories library or tape.

Applies to Version: 7.0 Platform: VMware, Hyper-V

Syntax Start-VBRTapeInventory -Library [-RunAsync] [WarningAction ][-WarningVariable ] [] -ORStart-VBRTapeInventory -Medium [-RunAsync] [WarningAction ][-WarningVariable ] []

Related Commands Get-VBRTapeLibrary Get-VBRTapeMedium

Detailed Description This cmdlet launches an inventory session. You can run an inventory session either for a library or for a tape. The cmdlet provides syntax for both scenarios. When you launch the Tape library inventory job for a specific library, Veeam Backup & Replication gets updated information on the components (i.e. media pools, drives, and tapes) of the selected library. When you launch the Tape library inventory job for a specific tape, Veeam Backup & Replication recognizes its contents. You can then move the tapes to appropriate media pools according to their contents. See what else you can perform on tapes

437 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Parameters Parameter

Description

Required

Position

Accept Pipeline Input

Accept Wildcard Characters

Named

True (ByValue, ByProperty Name)

False

False

False

Library

Specifies the tape library you want to inventory.

Medium

Specifies the tape you want to inventory.

True

Named

True (ByValue, ByProperty Name)

RunAsync

Indicates that the command returns immediately without waiting for the task to complete.

False

Named

False

True

This cmdlet supports Microsoft PowerShell common parameters. For more information about common parameters, see http://go.microsoft.com/fwlink/p/?LinkID=113216.

Example 1 This command starts the Tape library inventory job for the tape named "00110000". The tape is obtained with Get-VBRTapeMedium and piped down. The -RunAsync parameter is set to bring the process to the background. Get-VBRTapeMedium -Name 00110000 | Start-VBRTapeInventory

Example 2 This command starts the Tape library inventory job for the library represented by $lib variable. The library object is obtained with Get-VBRTapeLibrary and assigned to the variable beforehand. The RunAsync parameter is set to bring the process to the background. Start-VBRTapeInventory -Library $lib -RunAsync

438 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Start-VBRTapeRestore Short Description Starts VM restore from tape.

Applies to Version: 7.0 Platform: VMware, Hyper-V

Syntax Start-VBRTapeRestore -RestorePoint -Repository [-Reason ] [RunAsync][] -ORStart-VBRTapeRestore -RestorePoint -Server -Path [-Reason ] [-RunAsync][]

Related Commands Get-VBRRestorePoint Get-VBRBackupRepository Get-VBRServer

Detailed Description This cmdlet starts restoring VMs from backup copied to tape. You can restore VMs to a chosen backup repository or to a folder on the server you specify. Choose an appropriate syntax for each option. See what else you can perform on tapes See what else you can perform on restore

Parameters Parameter

RestorePoint

Description Specifies the particular restore point(s) of the VM. You can assign multiple restore points to this object.

Position

Accept Pipeline Input

Accept Wildcard Characters

True

Named

True (ByValue, ByProperty Name)

False

Required

Repository

Specifies the backup repository where you want to restore the VM.

True

Named

False

False

Reason

Specifies the reason for restore.

False

Named

False

False

Server

Specifies the server where you want to restore the VM.

True

Named

False

False

439 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Parameter

Description

Required

Position

Accept Pipeline Input

Accept Wildcard Characters

Path

Specifies the path to the folder where you want to restore the VM.

True

Named

False

False

RunAsync

Indicates that the command returns immediately without waiting for the task to complete.

False

Named

False

False

This cmdlet supports Microsoft PowerShell common parameters. For more information about common parameters, see http://go.microsoft.com/fwlink/p/?LinkID=113216.

Example 1 This command starts restoring a VM named "VM01" to a specified backup repository. •

The VM01 restore point is obtained with Get-VBRRestorePoint. The backup to get the restore point from is represented by the $backup variable. The most recent restore point is selected with Select method and piped down.



The repository to where the VM will be restored is obtained with Get-VBRBackupRepository and assigned to the $repository variable beforehand,



The reason for restore is "Data recovery",



The -RunAsync parameter is set to bring the process to the background.

Get-VBRRestorePoint -Backup $backup | Where {$_.Name -eq "VM01"} |Select -First 1 | Start-VBRTapeRestore -Repository $repository Reason "Data recovery" -RunAsync

Example 2 This command starts restoring a VM to a specified backup repository. •

The restore point to which the VM wil be restored is obtained with Get-VBRRestorePoint and assigned to the $rpoint variable beforehand,



The host to where the VM will be restored is obtained with Get-VBRServer and assigned to the $server variable beforehand,



The path to the folder where the VM will be restored is "c:\Restored",



The -Reason parameter is not set,



The -RunAsync parameter is set to bring the process to the background.

Start-VBRTapeRestore -RestorePoint $rpoint -Server $server -Path "c:\Restored' -RunAsync

440 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Start-VBRTapeRestoreFiles Short Description Starts files restore from tape.

Applies to Version: 7.0 Platform: VMware, Hyper-V

Syntax Start-VBRTapeRestoreFiles [-Files ] [-Version ] -Server -Path [PreserveHierarhy] [-Overwrite ] [-Security] [RunAsync] [-WarningAction ] [-WarningVariable ] []

Related Commands Get-VBRServer Find-VBRTapeCatalog Find-VBRTapeCatalogVersion

Detailed Description This cmdlet starts restoring files from backup copied to tape. You can restore file to its most recent state or to any of its backup version. The versions of files are used as restore points. See what else you can perform on tapes See what else you can perform on restore

Parameters Parameter

Description

Required

Position

Accept Pipeline Input

Accept Wildcard Characters

Named

True (ByValue, ByProperty Name)

False

False

Files

Specifies the files to restore. The most recent file version is used.

Version

Specifies the version of the files you want to restore.

False

Named

True (ByValue, ByProperty Name)

Server

Specifies the source host where the files to restore are located.

True

Named

False

False

Path

Specifies the path to the files to restore.

True

Named

False

False

Preserve Hierarhy

If indicated, the files and folders will be restored in respect to the original folder

False

Named

False

False

False

441 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Parameter

Description

Required

Position

Accept Pipeline Input

Accept Wildcard Characters

False

Named

False

False

False

False

hierarchy. Otherwise all files and folders are restored into a plain sequence. Indicates the overwrite options in case the file exists on the target side: Overwrite

• None - leave the original file, • Newer - overwrite the file if the restore file in newer, • Always - overwrite the existing file.

Security

If indicated, the files will be restored with with the original security settings. Otherwise the file/folder security settings will be inherited from parent item.

False

Named

True (ByValue, ByProperty Name)

RunAsync

Indicates that the command returns immediately without waiting for the task to complete.

False

Named

False

This cmdlet supports Microsoft PowerShell common parameters. For more information about common parameters, see http://go.microsoft.com/fwlink/p/?LinkID=113216.

442 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Example 1 This command starts restoring the file named "VM01 Backup Job 1.vbm". The file to restore is obtained with Find-VBRTapeCatalog and piped down. •

The host to look for files on is obtained with Get-VBRServer and assigned to the $server variable beforehand,



The file path is "C:\backup\Backup Job 1\VM01 Backup Job 1.vbm",



The -PreserveHierarhy parameter is set to retain the original folder hierarchy,



The -Overwrite parameter is set to Newer,



The RunAsync parameter is set to bring the process to the background.

Find-VBRTapeCatalog -Name "VM01 Backup Job 1.vbm" | StartVBRTapeRestoreFiles Server $server -Path "C:\backup\Backup Job 1\VM01 Backup Job 1.vbm" -PreserveHierarhy -Overwrite Newer Security -RunAsync

Example 2 This command restores a specific version of the file named "VM01 Backup Job 1.vbm". The file version is obtained with Find-VBRTapeCatalogVersion and assigned to the $fileversion variable beforehand. •

The host to look for files on is obtained with Get-VBRServer and assigned to the $server variable beforehand,



The file path is "C:\backup\Backup Job 1\VM01 Backup Job 1.vbm",



The -PreserveHierarhy parameter is set to retain the original folder hierarchy,



The -Overwrite parameter is set to Always,



The RunAsync parameter is set to bring the process to the background.

Start-VBRTapeRestoreFiles -Version $fileversion -Server $server Path "C:\backup\Backup Job 1\VM01 Backup Job 1.vbm" PreserveHierarhy -Overwrite Always

443 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Start-VBRvCloudInstantRecovery Short Description Starts a vCloud VM instant recovery.

Applies to Version: 7.0 Platform: VMware

Syntax Start-VBRvCloudInstantRecovery [-RestorePoint] [-vApp ] [-VmName ] [-Datastore ] [-PowerOn] [-Reason ] [RunAsync] [-WarningAction ] [-WarningVariable ] []

Related Commands Get-VBRRestorePoint Find-VBRvCloudEntity

Detailed Description This cmdlet performs instant recovery of the selected vCloud VM. You can restore the VM to the original location or to another vApp. To restore the VM to another vApp indicate the desired vApp object for the -vApp parameter. To perform restore to the original location, omit this parameter. The VM that you want to restore and its parameters are derived from the specified restore point data. See what else you can perform on vCloud See what else you can perform on instant recovery

Parameters Parameter

Description

Required

Position

Accept Pipeline Input

Accept Wildcard Characters

False

RestorePoint

Specifies the restore point of the VM.

True

1

True (ByValue, ByProperty Name)

vApp

Specifies the vApp you want to restore the VM to. If omitted, the VM will be restored to the original vApp.

False

Named

False

False

VmName

Specifies the name under which the VM should be restored and registered. By default, the original name of the VM is used. If you are restoring the VM to the

False

Named

False

False

444 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Parameter

Description

Required

Position

Accept Pipeline Input

Accept Wildcard Characters

False

Named

False

False

False

Named

False

False

False

Named

False

False

False

Named

False

False

same vApp where the original VM is registered and the original VM still resides there, it is recommended that you change the VM name to avoid conflicts. Specifies the datastore you want to connect the restored VM to. If ommited, the VM will be connected to the original datastore. Datastore

PowerOn

Note: If you restore the VM to another vApp, make sure that the datastore is available in the Organization VCD hosting the vApp to which the VM is restored. If set, the VM will be powered up right after it is restored. Otherwise you will need to power up the VM manually. Specifies the reason for performing restore of the selected VM.

Reason

RunAsync

The information you provide will be saved in the session history so that you can reference it later. Indicates that the command returns immediately without waiting for the task to complete.

This cmdlet supports Microsoft PowerShell common parameters. For more information about common parameters, see http://go.microsoft.com/fwlink/p/?LinkID=113216.

445 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Example 1 This command starts instant recovery for the VM. The VM is restored to the original location with all its settings unchanged. The restore point object is obtained with Get-VBRRestorePoint and assigned to the $rpoint variable beforehand. Start-VBRvCloudInstantRecovery -RestorePoint $rpoint

Example 2 This command starts instant recovery for the VM named "VM01". The VM is restored to another vApp and is connected to another datastore. •

The VM restore point is obtained with Get-VBRRestorePoint and piped down. The most resent restore point is selected with Select method,



The VM is restored to a new vApp represented by the $vapp variable, the vApp is obtained with Find-VBRvCloudEntity ([-VApp] option) and assigned to the variable beforehand,



The -VmName parameter is omitted to restore the VM with its original name,



The new datastore the VM will be connected to is represented by $datastore variable, the datastore is obtained with Find-VBRDatastore and assigned to the variable beforehand,



The -PowerOn parameter is set to power up the VM automatically right after it is restored,



The reason for restore is "Configuration test",



The RunAcync parameter is set to bring the process to the background.

Get-VBRRestorePoint -Backup $backup | where {$_.Name -eq "VM01"} | Select -First 1 | Start-VBRvCloudInstantRecovery -vApp $vapp Datastore $datastore -PowerOn -Reason "Configuration test" RunAsync

446 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Start-VBRvCloudRestoreVApp Short Description Starts a vApp restore.

Applies to Version: 7.0 Platform: VMware

Syntax Start-VBRvCloudRestoreVApp [-RestoreParams] [-PowerUp][-Reason ][RunAsync][] -ORStart-VBRvCloudRestoreVApp [-RestorePoint] [-PowerUp] [Reason ][-RunAsync][]

Related Commands New-VBRvCloudVAppRestoreSettings Get-VBRRestorePoint

Detailed Description This cmdlet starts a restore session for a selected vApp. With this cmdlet, you can restore the vApp to the original location or to another location, or with different settings. To restore the vApp to the original location you only need to indicate the desired restore point. Be careful to specify the restore point of the vApp, not an individual VM which is not a valid value for this cmdlet. Veeam Backup & Raplication gets all the information needed for restore from the restore point data. To run restore to another location or with different settings you need to first create aCVcdVAppRestoreSettingsobject which unifies all the settings options required for restore. TheCVcdVAppRestoreSettingsobject is created with the help of the NewVBRvCloudVAppRestoreSettings cmdlet. See the New-VBRvCloudVAppRestoreSettings topic for detailed instructions for advanced setup options. This cmdlet provides two scenarios for each case. See what else you can perform on vCloud See what else you can perform on restore

447 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Parameters Position

Accept Pipeline Input

Accept Wildcard Characters

True

1

True (ByValue, ByProperty Name)

False

RestorePoint

Specifies the restore point of the vApp. Used to restore vApp with all the same settings unchanged.

False

Named

False

False

PowerUp

If set, the vApp will be powered up right after it is restored. Otherwise you will need to power up the vApp manually.

False

Named

False

False

False

Named

False

False

False

Named

False

False

Parameter

Description

RestoreParams

Specifies the CVcdVAppRestoreSetti ngs object containing all settings required for the vApp restore.

Required

Specifies the reason for performing restore of the selected vApp. Reason

RunAsync

The information you provide will be saved in the session history so that you can reference it later. Indicates that the command returns immediately without waiting for the task to complete.

This cmdlet supports Microsoft PowerShell common parameters. For more information about common parameters, see http://go.microsoft.com/fwlink/p/?LinkID=113216.

448 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Example 1 This command starts a vApp restore. The vApp named "vApp_01" is restored to the original location and with all settings unchanged. The vApp restore point is obtained with Get-VBRRestorePoint and assigned to the $restorepoint variable beforehand. Start-VBRvCloudRestoreVApp -RestorePoint $restorepoint

Example 2 This command restores a vApp to another location. The vApp named "vApp_01" is restored to organization named "Org_02" with all other settings remaining unchanged. To restore the vApp to another organization, you need to first customize the CVcdVAppRestoreSettings object The CVcdVAppRestoreSettings object is obtained with NewVBRvCloudVAppRestoreSettings: The restore point of the vApp is obtained with Get-VBRRestorePoint by selecting the vApp named "vApp_01" from the backup objects using the Where method. The restore point is piped down to the New-VBRvCloudVAppRestoreSettings cmdlet. The obtained CVcdVAppRestoreSettings object is assigned to the $restoreparams variable. $restoreparams=Get-VBRRestorePoint -Backup $backup | Where {$_.Name -eq "vApp_01"} | New-VBRvCloudVAppRestoreSettings Further you need to change the organization in the CVcdVAppRestoreSettings object: The Org.Vdc property of the $restoreparams variable is changed to the target organization named "Org_02". The needed organization is obtained with Find-VBRvCloudEntity ([-OrganizationVdc] option). $restoreparams.OrgVdc=Find-VBRvCloudEntity -OrganizationVdc -Name "Org_02" Now you need to run Start-VBRvCloudRestoreVApp with the customized $restoreparams variable. The RunAcync parameter is set to bring the process to the background: Start-VBRvCloudRestoreVApp -RestoreParams $restoreparams RunAsync

449 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Start-VBRvCloudRestoreVm Short Description Starts a vCloud VM restore.

Applies to Version: 7.0 Platform: VMware

Syntax Start-VBRvCloudRestoreVm [-RestorePoint] [-vApp ] [-StorageProfile ] [vCloudDatastore ] [-VmTemplate ] [-VMName ] [-PowerUp] [-Reason ] [RunAsync] [-WarningAction ] [-WarningVariable ] []

Related Commands Get-VBRRestorePoint Find-VBRvCloudEntity

Detailed Description This cmdlet starts a restore session of a selected vCloud VM. With this cmdlet, you can restore the VM to the original location or to another location, or with different settings. To restore a VM to the original location you only need to indicate the desired restore point. Be careful to specify the restore point of the VM, not the vApp which is not a valid value for this cmdlet. Veeam Backup & Raplication gets all the information needed for restore from the restore point data. To run restore to another location or with different settings you need to set the new settings values with the parameters available in this cmdlet. These parameters are not obligatory, so you can type only those that you want to change. You cannot restore multiple VM with one command, to restore several VMs you need to start a restore session for each one. See what else you can perform on vCloud See what else you can perform on restore

450 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Parameters Parameter

RestorePoint

Description Specifies the restore point of the VM. If you specify no other parameters of the VM, it will be restored with its initial settings, i.e. the datastore or VM template.

Position

Accept Pipeline Input

Accept Wildcard Characters

True

1

True (ByValue, ByProperty Name)

False

Required

A multiple VMs object is not valid in this cmdlet. vApp

Specifies the vApp where to you want to restore the VM.

False

Named

False

False

Storage Profile

Specifies the storage profile you want to apply to the restored VM.

False

Named

False

False

vCloud Datastore

Specifies the datastore you want to use with the restored VM.

False

Named

False

False

VmTemplate

Specifies the template you want to apply to the restored VM.

False

Named

False

False

VMName

Specifies the VM name you want to apply to the restored VM.

False

Named

False

False

PowerUp

If set, the VM will be powered up right after it is restored. Otherwise you will need to power up the VM manually.

False

Named

False

False

False

Named

False

False

False

Named

False

False

Specifies the reason for performing restore of the selected VM. Reason

RunAsync

The information you provide will be saved in the session history so that you can reference it later. Indicates that the command returns immediately without waiting for the task to complete.

This cmdlet supports Microsoft PowerShell common parameters. For more information about common parameters, see http://go.microsoft.com/fwlink/p/?LinkID=113216.

451 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Example 1 This command starts a vCloud VM restore. The VM is restored to the original location and with all settings unchanged. All the information needed for restore is taken from the restore point represented by the $restorepoint variable. The restore point object is obtained with Get-VBRRestorePoint and assigned to the variable beforehand. Start-VBRvCloudRestoreVm -RestorePoint $restorepoint

Example 2 This command restores a VM to another vApp and with another storage profile. •

The VM to restore and the restore point to which it should be restored is represented by the $restorepoint variable. The restore point object is obtained with Get-VBRRestorePoint and assigned to the variable beforehand,



The vApp object to where the VM will be restored is represented by the $vapp variable. The vApp object is obtained with Find-VBRvCloudEntity ([-VApp] option) and assigned to the variable beforehand.



The storage profile object that will be applied to the restored VM is represented by the $profile variable. The storage profile object is obtained with Find-VBRvCloudEntity ([StorageProfile] option) and assigned to the variable beforehand.

Start-VBRvCloudRestoreVm -RestorePoint $restorepoint -vApp $vapp -StorageProfile $profile

452 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Start-VBRViReplicaFailback Short Description Fails back to the production host.

Applies to Version: 7.0 and earlier Platform: Hyper-V

Syntax Start-VBRViReplicaFailback -RestorePoint [-Reason ] [-RunAsync] [-Complete] [-PowerOn] [-WarningAction ] [-WarningVariable ] [-WhatIf] [Confirm] []

Related Commands Get-VBRRestorePoint

Detailed Description This cmdlet stars failing back to the production host after failover to its replica. This cmdlet lets you finalize the replica failover started with Start-VBRViReplicaFailover by switching back to the production VM with data synchronization. When you perform failback, you switch back to the original VM on the production site. The failback process collects all the changes that were made to the replica while you failed over to it, and implies them to the source VM. This allows you to switch between source and replica VMs without data loss. To switch back to the production VM and discard the changes made to the replica while failover, start an undo failover process. In this case you return to the production VM in the state preceeding failover. Run Stop-VBRReplicaFailover to undo failover. Undo Failback: If you tried to fail back to the original VM but was unable to, because i.e. it was nonfunctional or corrupted, you can undo the failback and return to the working replica. Run StopVBRViReplicaFailback to undo failback. See what else you can perform on replicas

Parameters Position

Accept Pipeline Input

Accept Wildcard Characters

True

Named

True (ByValue, ByProperty Name)

False

Specifies the reason for performing a failback.

False

Named

False

False

Indicates that the command returns immediately without waiting for the task to

False

Named

False

False

Parameter

Description

RestorePoint

Specifies the replica restore point which you want to fail back.

Reason

RunAsync

Required

453 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Parameter

Description

Required

Position

Accept Pipeline Input

Accept Wildcard Characters

complete. Complete

If set, the failback will be commited.

False

Named

False

False

PowerOn

If set, the production VM will be powered on after the failback. Otherwise, you will have to power the VM on manually.

False

Named

False

False

This cmdlet supports Microsoft PowerShell common parameters. For more information about common parameters, see http://go.microsoft.com/fwlink/p/?LinkID=113216.

Example 1 This command fails back from the VM replica named "WebServer_ replica". The restore point is obtained with Get-VBRRestorePoint and piped down. The restore points of the VM are filtered with Sort-Object method by the "creationtime" property to get the most recent one. The reason is "Configuration recovery". The RunAsync parameter is set to bring the process to the background. Get-VBRRestorePoint -Name "WebServer_replica" | Sort-Object $_.creationtime -Descending | Select -First 1 | StartVBRViReplicaFailback -Reason "Configuration recovery" -RunAsync

Example 2 This command fails back from the VM replica represented by the $"WebServer 01_replica restorepoint" variable. The restore point is obtained with Get-VBRRestorePoint and assigned to the variable beforehand. The reason is "Data recovery". The RunAsync parameter is set to bring the process to the background. Start-VBRViReplicaFailback -RestorePoint $"WebServer_replica restorepoint" -Reason "Data recovery" -RunAsync

454 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Start-VBRViReplicaFailover Short Description Fails over a corrupted VM to its replica.

Applies to Version: 7.0 and earlier Platform: VMware, Hyper-V

Syntax Start-VBRViReplicaFailover [-RestorePoint] [-Reason ] [-RunAsync] [-Definite] [-WarningAction ] [-WarningVariable ] [-WhatIf] [Confirm] []

Related Commands Get-VBRRestorePoint

Detailed Description This cmdlet allows you fail over a corrupted VM to its successfully created replica. Performing failover is switching to a VM replica in case the original VM is damaged. You can fail over to the latest state of a replica or to any of its good known restore points. In Veeam Backup & Replication, failover is a temporary stage that needs to be finalized: •

You can perform permanent failover to permanently move your workload to the target host if the source is nonrecoverable. Your target host should have adequate recources. The replica starts acting like source in this case. To perform the permanent failover, run this cmdlet with -Definite parameter.



You can perform failback to recover the original VM on the source host or in a new location. Failback is used in case you failed over to a DR site that is not intended for continuous operations, and would like to move the operations back to the production site when the consequences of a disaster are eliminated. Run Start-VBRViReplicaFailback for VMware or Start-VBRHvReplicaFailback for Hyper-V to failback to the original VM.



You can undo failover to switch back to the original VM, revert replication operations and discard changes made to the working VM replica. In this case you loose all the changes that were made to the replica while you failed over to it. Run Stop-VBRReplicaFailover to undo failover.

See what else you can perform on replicas

455 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Parameters Position

Accept Pipeline Input

Accept Wildcard Characters

True

1

True (ByValue, ByProperty Name)

False

Specifies the reason for performing a failover.

False

Named

False

False

RunAsync

Indicates that the command returns immediately without waiting for the task to complete.

False

Named

False

False

Definite

Performs permanent failover.

False

Named

False

False

Parameter

Description

RestorePoint

Specifies the replica restore point to which you want to fail over.

Reason

Required

This cmdlet supports Microsoft PowerShell common parameters. For more information about common parameters, see http://go.microsoft.com/fwlink/p/?LinkID=113216.

456 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Example 1 This command fails over to the VM replica named "WebServer_ replica" to its latest restore point. The restore point is obtained with Get-VBRRestorePoint and piped down. The restore points of the VM are filtered with Sort-Object method by the "creationtime" property to get the most recent one. The reason is "Configuration recovery". The RunAsync parameter is set to bring the process to the background. Get-VBRRestorePoint -Name "WebServer_replica" | Sort-Object $_.creationtime -Descending | Select -First 1 | StartVBRViReplicaFailover -Reason "Configuration recovery" -RunAsync

Example 2 This command starts permanent failover to the VM replica named "WebServer_ replica" to its latest restore point. The restore point is obtained with Get-VBRRestorePoint and piped down. The restore points of the VM are filtered with Sort-Object method by the "creationtime" property to get the most recent one. The reason is "Configuration recovery". The RunAsync parameter is set to bring the process to the background. The -Definite parameter is set to perform the permanent failover. Get-VBRRestorePoint -Name "WebServer_replica" | Sort-Object $_.creationtime -Descending | Select -First 1 | StartVBRViReplicaFailover -Reason "Configuration recovery" -RunAsync Definite

Example 3 This command fails over to the VM replica represented by the $"WebServer_replica restorepoint" variable. The restore point is obtained with Get-VBRRestorePoint and assigned to the variable beforehand. The reason is "Data recovery". The RunAsync parameter is set to bring the process to the background. Start-VBRViReplicaFailover -RestorePoint $"WebServer_replica restorepoint" -Reason "Data recovery" -RunAsync

457 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Start-VBRWindowsFileRestore Short Description Starts VM files restore.

Applies to Version: 7.0 and earlier Platform: VMware

Syntax Start-VBRWindowsFileRestore [-RestorePoint] [-Reason ] [-WarningAction ] [-WarningVariable ] []

Related Commands Get-VBRRestorePoint

Detailed Description This cmdlet allows you to restore files stored on disks of VM running Windows. Run Start-VBRRestoreVMFiles to restore VM configuration files. See what else you can perform on restore

Parameters Required

Position

Accept Pipeline Input

Accept Wildcard Characters

False

False

Parameter

Description

RestorePoint

Specifies the VM restore point to which you want to restore.

True

1

True (ByValue, ByProperty Name)

Reason

Specifies the string with the reason for performing the VM file restore.

False

Named

False

This cmdlet supports Microsoft PowerShell common parameters. For more information about common parameters, see http://go.microsoft.com/fwlink/p/?LinkID=113216.

458 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Example This command starts a Windows file restore session. The restore point is selected by getting the backup job named "Job 1", sorting its restore points and selecting the most recent one.The file to restore "readme.txt" located on FirstDrive is copied to disk "C". The restore session is assigned to the $result variable. $result = Get-VBRBackup | where {$_.jobname -eq "Job 1"} | GetVBRRestorePoint | where {$_.name -eq "VM1"} | Sort-Object creationtime -Descending | Select-Object -First 1 | StartVBRWindowsFileRestore $file = $result.FirstDrive + ":\readme.txt" Copy $file c:\

459 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Start-VBRZip Short Description Performs VeeamZIP on the selected VM.

Applies to Version: 7.0 and earlier Platform: VMware, Hyper-V

Syntax Start-VBRZip [-BackupRepository ] -Entity [-Compression ] [-DisableQuiesce] [-RunAsync] [WarningAction ] [-WarningVariable ] [] -ORStart-VBRZip [-Folder ] -Entity [-Compression ] [-DisableQuiesce] [-RunAsync] [-WarningAction ] [-WarningVariable ] []

Related Commands Get-VBRBackupRepository Find-VBRViEntity / Find-VBRHvEntity

Detailed Description This cmdlet performs VeeamZIP backup of the selected VM. VeeamZIP is a quick backup procedure always producing a full backup. The VeeamZIP task runs once the time it is created and does not appear in the jobs list. The result backup file is stored in the specified folder and does not appear automatically in the backups list. Run Import-VBRBackup to start managing the backup file with Veeam Backup & Replication.

Parameters Parameter

Backup Repository

Entity

Description

Required

Position

Accept Pipeline Input

Accept Wildcard Characters

Specifies the backup repository where you want to save the backup file. If none is specified, the default repository will be used.

False

Named

False

False

True

Named

True (ByValue, ByProperty Name)

False

False

Named

False

False

Specifies the VM for which you want to create a VeeamZIP file. You can assign multiple VMs to this object.

Compression

Specifies then integer number corresponding to

460 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Required

Position

Accept Pipeline Input

Accept Wildcard Characters

DisableQuiesce

If set, the VM will be backed up without using the VMware tools quiescence. Otherwise, the applications running on the target VM will be quiesced to provide transactionally consistent backup with use of VMware Tools.

False

Named

False

False

RunAsync

Indicates that the command returns immediately without waiting for the task to complete.

False

Named

False

False

Folder

Specifies the full path to the folder on the server where you want to store the created backup file. If omitted, the created

False

Named

False

False

Parameter

Description the desired compression level: 0 = None. Consider disabling compression to achieve better deduplication ratios on deduplicating storage appliances at the cost of reduced backup performance. 4 = Dedupe-friendly. This is the recommended setting for using with deduplicating storage devices and caching WAN accelerators. This setting is used by default. 5 = Optimal (recommended). Optimal compression provides for the best compression to performance ratio, and lowest backup proxy CPU usage. 6 = High. High compression provides additional 10% compression ratio over Optimal, at the cost of 8x higher CPU usage. 9 = Extreme. Extreme compression provides additional 3% compression ratio over High, at the cost of 2x higher CPU usage.

461 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Parameter

Description

Required

Position

Accept Pipeline Input

Accept Wildcard Characters

backup file will be saved to the C:\backup folder on the Veeam Backup server.

This cmdlet supports Microsoft PowerShell common parameters. For more information about common parameters, see http://go.microsoft.com/fwlink/p/?LinkID=113216.

Example 1 This command starts a VeeamZIP for the VM named "Fileserver01". The VM object is obtained with Find-VBRViEntity and piped down. The backup repository to store the result backup file is obtained with Get-VBRBackupRepository and assigned to the $"Repository 01" variable beforehand. The RunAsync parameter is set to bring the process to the background. Find-VBRViEntity -Server $server -Name "Fileserver01" | StartVBRZip -BackupRepository $"Repository 01" -RunAsync

Example 2 This command starts a VeeamZIP for the VM repersented by the $vm variable. The VM object is obtained with Find-VBRViEntity and assigned to the variable beforehand. The path to the folder where the backup file will be stored is D:\Repository\VeeamZIP. The compression level is set to 4 (Dedupefriendly). The VMware quiescence is disabled. The The -RunAsync parameter is set to bring the process to the background. Start-VBRZip -Folder "D:\Repository\VeeamZIP" -Entity $vm Compression 4 -DisableQuiesce -RunAsync

462 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Start-VSBJob Short Description Starts a created SureBackup job.

Applies to Version: 7.0 and earlier Platform: VMware, Hyper-V

Syntax Start-VSBJob [-Job] [-RunAsync] [-WarningAction ] [-WarningVariable ] []

Related Commands Get-VSBJob

Detailed Description This cmdlet allows you to start a created SureBackup job. SureBackup is a Veeam recovery verification technology providing verification of virtual machines that need other virtual machines or services running, i.e. a domain controller, a DSN server or SQL database. To test such machines for recoverability, you need to create a SureBackup job and provide the copy of the production architecture running in a fenced-off environment that is performed by creating a virtual lab and an application group. When you create a job, you need to run it manually unless you enable a job schedule. Run SetVSBJobSchedule to schedule the SureBackup job to run automatically. Run Stop-VSBJob to stop a running SureBackup job. Run Start-VBRJob to start a backup, replication or copy job. See what else you can perform on SureBackup See what else you can perform on jobs

Parameters Parameter

Job

RunAsync

Description Specifies the SureBackup job you want to run. You can assign multiple jobs to this object. Indicates that the command returns immediately without waiting for the task to complete.

Position

Accept Pipeline Input

Accept Wildcard Characters

True

1

True (ByValue, ByProperty Name)

False

False

Named

False

False

Required

463 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

This cmdlet supports Microsoft PowerShell common parameters. For more information about common parameters, see http://go.microsoft.com/fwlink/p/?LinkID=113216.

Example 1 This command starts the SureBackup jobs named "SharePoint SureJob 01" and "SharePoint SureJob 02". The jobs are obtained with Get-VSBJob and piped down. Get-VSBJob -Name "SharePoint SureJob 01", "SharePoint SureJob 02" | Start-VSBJob

Example 2 This command starts the SureBackup job represented by the $SureJob variable. The job object is obtained with Get-VSBJob and assigned to the variable beforehand. Start-VSBJob -Job $SureJob

464 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Stop-VBRInstantRecovery Short Description Stops a running instant VM recovery process.

Applies to Version: 7.0 and earlier Platform: VMware, Hyper-V

Syntax Stop-VBRInstantRecovery [-InstantRecovery] [RunAsync] [-WarningAction ] [-WarningVariable ] []

Related Commands Get-VBRInstantRecovery

Detailed Description This cmdlet stops publishing a VM within an instant recovery process. With instant recovery technology, Veeam Backup & Replication starts a VM directly from a backup, incremental or full, without copying it to production storage. You need to finalize the successful instant recovery by either migrating the recovered VM to production or by stopping publishing the recovered VM. To migrate the VM, run Start-VBRQuickMigration. See what else you can perform on instant recovery

Parameters Parameter

Description

Required

Position

Accept Pipeline Input

Accept Wildcard Characters

False

False

Instant Recovery

Specifies the running instant VM recovery process that you want to stop.

True

1

True (ByValue, ByProperty Name)

RunAsync

Indicates that the command returns immediately without waiting for the task to complete.

False

Named

False

This cmdlet supports Microsoft PowerShell common parameters. For more information about common parameters, see http://go.microsoft.com/fwlink/p/?LinkID=113216.

465 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Example 1 This command stops the last instant recovery session. The needed session object is obtained with GetVBRInstantRecovery, selected by order and piped down. Get-VBRInstantRecovery | Select -Last 1 | Stop-VBRInstantRecovery

Example 2 This command storps the instant recovery session represented by the $"Recovery Session" variable. The needed session object is obtained with Get-VBRInstantRecovery and assigned to the variable beforehand. Stop-VBRInstantRecovery -InstantRecovery $"Recovery Session"

466 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Stop-VBRJob Short Description Stops a selected running backup, replication or copy job.

Applies to Version: 7.0 and earlier Platform: VMware

Syntax Stop-VBRJob [-Job] [-RunAsync] [-WarningAction ] [-WarningVariable ] [-WhatIf] [Confirm] []

Related Commands Get-VBRJob

Detailed Description This cmdlet stops a running backup, replication or copy job. The job is stopped once, the scheduled job will start the next scheduled time. Run Start-VBRJob to start the job manually. Run Disable-VBRJob to temporarily disable a job. Run Stop-VSBJob to stop a SureBackup job. See what else you can perform on jobs

Parameters Parameter

Job

RunAsync

Description Specifies the job you want to stop. You can assign multiple jobs to this object. Indicates that the command returns immediately without waiting for the task to complete.

Position

Accept Pipeline Input

Accept Wildcard Characters

True

1

True (ByValue, ByProperty Name)

False

False

Named

False

False

Required

This cmdlet supports Microsoft PowerShell common parameters. For more information about common parameters, see http://go.microsoft.com/fwlink/p/?LinkID=113216.

467 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Example 1 This command stops the copy job named "SharePoint File Copy Job". The needed job object is obtained with Get-VBRJob and piped down. Get-VBRJob -Name "SharePoint File Copy Job" | Stop-VBRJob

Example 2 This command stops the copy job represented by the $"SharePoint File Copy Job" variable. The needed session object is obtained with Get-VBRJob and assigned to the variable beforehand. Stop-VBRJob -Job $"SharePoint File Copy Job"

468 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Stop-VBRReplicaFailover Short Description Undoes the replica failover.

Applies to Version: 7.0 and earlier Platform: VMware, Hyper-V

Syntax Stop-VBRReplicaFailover [-RestorePoint] [-RunAsync] [Force] [-WarningAction ] [-WarningVariable ] [-WhatIf] [-Confirm] []

Related Commands Get-VBRRestorePoint

Detailed Description This cmdlet allows you to undo the replica failover. This cmdlet lets you finalize the replica failover started with Start-VBRViReplicaFailover by reverting back to the production VM discarding changes. When you undo the failover, you switch back to the original VM, revert replication operations and discard changes made to the working VM replica. In this case you loose all the changes that were made to the replica while you failed over to it. You can select a restore point to revert to. To switch back to the production VM and synchronize the changes made to the replica while failover, start a failback process. Run Start-VBRViReplicaFailback or Start-VBRHvReplicaFailback to fail back to the VMware or Hyper-V production VM respectively. See what else you can perform on replicas

Parameters Parameter

Description

Required

Position

Accept Pipeline Input

Accept Wildcard Characters

False

RestorePoint

Specifies the restore point of the production VM to recover to.

True

1

True (ByValue, ByProperty Name)

RunAsync

Indicates that the command returns immediately without waiting for the task to complete.

False

Named

False

False

Force

Indicates that the replica job starts running without waiting for the target host to power off. Otherwise the replica job will start only after the target host is powered off.

False

Named

False

False

469 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

This cmdlet supports Microsoft PowerShell common parameters. For more information about common parameters, see http://go.microsoft.com/fwlink/p/?LinkID=113216.

Example 1 This command stops failover process by reverting to the production VM. The restore point of the replica VM is obtained with Get-VBRRestorePoint and piped down. The restore points of the VM are filtered with Sort-Object method by the "creationtime" property to get the most recent one. The reason is "Configuration recovery". The RunAsync parameter is set to bring the process to the background. The -Force parameter is set to start the replica job running anyway. Get-VBRRestorePoint -Name "WebServer_replica" | Sort-Object $_.creationtime -Descending | Select -First 1 | StopVBRReplicaFailover -Reason "Configuration recovery" -RunAsync Force

Example 2 This command stops failover process by reverting to the production VM. The restorepoint of the replica VM is represented by the $"WebServer_replica restorepoint" variable. The restore point is obtained with Get-VBRRestorePoint and assigned to the variable beforehand. The reason is "Data recovery". The RunAsync parameter is set to bring the process to the background. Stop-VBRReplicaFailover -RestorePoint $"WebServer_replica restorepoint" -Reason "Data recovery" -RunAsync

470 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Stop-VBRViReplicaFailback Short Description Undoes the replica failback.

Applies to Version: 7.0 and earlier Platform: VMware, Hyper-V

Syntax Stop-VBRViReplicaFailback -RestorePoint [-RunAsync] [WarningAction ] [-WarningVariable ] [WhatIf] [-Confirm] []

Related Commands Get-VBRRestorePoint

Detailed Description This cmdlet allows you to undo the replica failback started with Start-VBRViReplicaFailback or StartVBRHvReplicaFailback. If you tried to fail back to the production VM but was unable to, because i.e. it was non-functional or corrupted, you can undo the failback and return to the working replica. See what else you can perform on replicas

Parameters Required

Position

Accept Pipeline Input

Accept Wildcard Characters

False

False

Parameter

Description

RestorePoint

Specifies the restore point of the replica VM for which you want to undo the failback.

True

1

True (ByValue, ByProperty Name)

RunAsync

Indicates that the command returns immediately without waiting for the task to complete.

False

Named

False

This cmdlet supports Microsoft PowerShell common parameters. For more information about common parameters, see http://go.microsoft.com/fwlink/p/?LinkID=113216.

471 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Example 1 This command stops failback from the replica VM named "WebServer_replica". The restore point is obtained with Get-VBRRestorePoint and piped down. The restore points of the VM are filtered with Sort-Object method by the "creationtime" property to get the most recent one. The RunAsync parameter is set to bring the process to the background. Get-VBRRestorePoint -Name "WebServer_replica" | Sort-Object $_.creationtime -Descending | Select -First 1 | StopVBRViReplicaFailback -RunAsync

Example 2 This command stops failback from the replica VM named "WebServer_replica". The restorepoint to revert to is represented by the $"WebServer_replica restorepoint" variable. The restore point is obtained with Get-VBRRestorePoint and assigned to the variable beforehand. The RunAsync parameter is set to bring the process to the background. Stop-VBRViReplicaFailback -RestorePoint $"WebServer_replica restorepoint" -RunAsync

472 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Stop-VBRWindowsFileRestore Short Description Stops guest OS file recovery session for VMs running Windows.

Applies to Version: 7.0 and earlier Platform: VMware

Syntax Stop-VBRWindowsFileRestore [[-FileRestore] ] [WarningAction ] [-WarningVariable ] []

Detailed Description This cmdlet allows you to stop the initiated guest OS file recovery session for VMs running Windows or to disconnect the drive you have mounted to restore data. This cmdlet provides syntax for both scenarios accordingly. See what else you can perform on restore

Parameters Parameter

Description

Required

Position

Accept Pipeline Input

Accept Wildcard Characters

FileRestore

Specifies the running file-level restore session you want to stop.

False

1

False

False

This cmdlet supports Microsoft PowerShell common parameters. For more information about common parameters, see http://go.microsoft.com/fwlink/p/?LinkID=113216.

Example This command stops a file restore session initiated with Start-VBRWindowsFileRestore and assigned to $result variable. $result = Get-VBRBackup | where {$_.jobname -eq "Job 1"} | GetVBRRestorePoint | where {$_.name -eq "VM1"} | Sort-Object creationtime -Descending | Select-Object -First 1 | StartVBRWindowsFileRestore $file = $result.FirstDrive + ":\readme.txt" Copy $file c:\ Stop-VBRWindowsFileRestore $Result

473 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Stop-VSBJob Short Description Stops a selected running SureBackup job.

Applies to Version: 7.0 and earlier Platform: VMware, Hyper-V

Syntax Stop-VSBJob [-Job] [-RunAsync] [-WarningAction ] [-WarningVariable ] [-WhatIf] [Confirm] []

Related Commands Get-VSBJob

Detailed Description This cmdlet stops a running SureBackup job. The job is stopped once, the scheduled SureBackup job will start the next scheduled time. SureBackup is a Veeam recovery verification technology providing verification of virtual machines that need other virtual machines or services running, i.e. a domain controller, a DSN server or SQL database. To test such machines for recoverability, you need to create a SureBackup job and provide the copy of the production architecture running in a fenced-off environment that is performed by creating a virtual lab and an application group. Run Start-VSBJob to start the job manually. Run Stop-VBRJob to stop a backup, replication or copy job. See what else you can perform on SureBackup See what else you can perform on jobs

Parameters Parameter

Job

RunAsync

Description Specifies the SureBackup job you want to stop. You can assign multiple jobs to this object. Indicates that the command returns immediately without waiting for the task to complete.

Position

Accept Pipeline Input

Accept Wildcard Characters

True

1

True (ByValue, ByProperty Name)

False

False

Named

False

False

Required

This cmdlet supports Microsoft PowerShell common parameters. For more information about common parameters, see http://go.microsoft.com/fwlink/p/?LinkID=113216.

474 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Example 1 This command stops the SureBackup job named "AD SureJob". The needed job object is obtained with Get-VSBJob and piped down. Get-VSBJob -Name "AD SureJob" | Stop-VSBJob

Example 2 This command stops the SureBackup job represented by the $"AD SureJob" variable. The needed job object is obtained with Get-VSBJob and assigned to the variable beforehand. Stop-VSBJob -Job $"AD SureJob"

475 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Sync-HP3Storage Short Description Rescans a SAN storage.

Applies to Version: 7.0 Platform: VMware HP SAN storage system: HP 3PAR StoreServ

Syntax Sync-HP3Storage [-Storage ] []

Related Commands Get-HP3Storage

Detailed Description This cmdlet rescans the selected SAN storage to synchronize its infrastructure with Veeam Backup & Replication. Rescanning discovers new or checks for deleted volumes and snapshots. Veeam Backup & Replication runs rescan automatically every 3 minutes. You can perform rescan manually if you want to display the newly added or deleted volumes or snapshots. Run Sync-HP3Volume to rescan the selected volumes only. See what else you can perform on HP 3PAR instances

Parameters Parameter

Storage

Description

Specifies the storage you want to rescan.

Required

False

Position

Accept Pipeline Input

Accept Wildcard Characters

Named

True (ByValue, ByProperty Name)

False

This cmdlet supports Microsoft PowerShell common parameters. For more information about common parameters, see http://go.microsoft.com/fwlink/p/?LinkID=113216.

476 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Example 1 This command synchronizes the storage named "HP Store 01". The storage object is obtained with Get-HP3Storage and piped down. Get-HP3Storage -Name "HP Store 01" | Sync-HP3Storage

Example 2 This command synchronizes the storage represented by the $"store01" variable. The storage object is obtained with Get-HP3Storage and assigned to the variable beforehand. Sync-HP3Storage -Storage $"store01"

477 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Sync-HP3Volume Short Description Rescans a SAN volume.

Applies to Version: 7.0 Platform: VMware HP SAN storage system: HP 3PAR StoreServ

Syntax Sync-HP3Volume -Volume []

Related Commands Get-HP3Volume

Detailed Description This cmdlet rescans the selected SAN volume(s) to synchronize the storage system infrastructure with Veeam Backup & Replication. Rescanning discovers new or checks for deleted snapshots. Veeam Backup & Replication runs rescan automatically every 3 minutes. You can perform rescan manually if you want to display the newly added or deleted snapshots. Run Sync-HP3Storage to rescan the SAN storage. See what else you can perform on HP 3PAR instances

Parameters Parameter

Volume

Description Specifies the volume(s) you want to synchronize. You can assign multiple volumes to this object.

Required

True

Position

Accept Pipeline Input

Accept Wildcard Characters

Named

True (ByValue, ByProperty Name)

False

This cmdlet supports Microsoft PowerShell common parameters. For more information about common parameters, see http://go.microsoft.com/fwlink/p/?LinkID=113216.

478 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Example 1 This command synchronizes the volume named "HP Vol 01". The volume object is obtained with GetHP3Volume and piped down. Get-HP3Volume -Name "HP Vol 01" | Sync-HP3Volume

Example 2 This command synchronizes the volume named "HP Vol 01". The volume object is obtained with GetHP3Volume and assigned to the variable beforehand. Sync-HP3Volume -Volume $"HP Vol 01"

479 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Sync-HP4Storage Short Description Rescans a SAN storage.

Applies to Version: 7.0 Platform: VMware HP SAN storage systems: HP LeftHand P4000, HP StoreVirtual VSA

Syntax Sync-HP4Storage -Storage []

Related Commands Get-HP4Storage

Detailed Description This cmdlet rescans the selected SAN storage to synchronize its infrastructure with Veeam Backup & Replication. Rescanning discovers new or checks for deleted volumes and snapshots. Veeam Backup & Replication runs rescan automatically every 3 minutes. You can perform rescan manually if you want to display the newly added or deleted volumes or snapshots. Run Sync-HP4Volume to rescan the selected volumes only. See what else you can perform on HP LeftHand P4000 or HP StoreVirtual VSA instances

Alias Sync-VBRHPStorage

Parameters Parameter

Storage

Description

Specifies the storage you want to synchronize.

Required

True

Position

Accept Pipeline Input

Accept Wildcard Characters

Named

True (ByValue, ByProperty Name)

False

This cmdlet supports Microsoft PowerShell common parameters. For more information about common parameters, see http://go.microsoft.com/fwlink/p/?LinkID=113216.

480 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Example 1 This command synchronizes the storage named "HP Store 01". The storage object is obtained with Get-HP4Storage and piped down. Get-HP4Storage -Name "HP Store 01" | Sync-HP4Storage

Example 2 This command synchronizes the storage named "HP Store 01". The storage object is obtained with Get-HP4Storage and assigned to the variable beforehand. Sync-HP4Storage -Storage $"HP Store 01"

481 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Sync-HP4Volume Short Description Rescans a SAN volume.

Applies to Version: 7.0 Platform: VMware HP SAN storage systems: HP LeftHand P4000, HP StoreVirtual VSA

Syntax Sync-HP4Volume -Volume []

Related Commands Get-HP4Volume

Detailed Description This cmdlet rescans the selected SAN volume(s) to synchronize the storage system infrastructure with Veeam Backup & Replication. Rescanning discovers new or checks for deleted snapshots. Veeam Backup & Replication runs rescan automatically every 3 minutes. You can perform rescan manually if you want to display the newly added or deleted snapshots. Run Sync-HP4Storage to rescan the SAN storage. See what else you can perform on HP LeftHand P4000 or HP StoreVirtual VSA instances

Alias Sync-VBRHPVolume

Parameters Parameter

Volume

Description Specifies the volume(s) you want to synchronize. You can assign multiple volumes to this object.

Required

True

Position

Accept Pipeline Input

Accept Wildcard Characters

Named

True (ByValue, ByProperty Name)

False

This cmdlet supports Microsoft PowerShell common parameters. For more information about common parameters, see http://go.microsoft.com/fwlink/p/?LinkID=113216.

482 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Example 1 This command synchronizes the volume named "HP Vol 01". The volume object is obtained with GetHP4Volume and assigned to the variable beforehand. Get-HP4Volume -Name "HP Vol 01" | Sync-HP4Volume

Example 2 This command synchronizes the volume named "HP Vol 01". The storage object is obtained with GetHP4Volume and piped down. Sync-HP4Volume -Volume $"HP Vol 01"

483 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Sync-VBRBackupCopyJob Short Description Rescans a selected backup repository.

Applies to Version: 7.0 and earlier Platform: VMware, Hyper-V

Syntax Sync-VBRBackupCopyJob -Job [-WarningAction ] [-WarningVariable ][]

Related Commands Get-VBRJob

Detailed Description This cmdlet starts manual data synchronization for the selected backup copy job. The backup copy job is copying backup files from the source backup repository to the target backup repository. The backup copy job runs continuously synchronizing the backup repositories in userdefined time periods. With this cmdlet, you can synchronize the source and the target repositories manually. See what else you can perform on backup copy

Parameters Parameter

Job

Description Specifies the backup copy job for which you want to start manual synchronization.

Required

True

Position

Accept Pipeline Input

Accept Wildcard Characters

Named

True (ByValue, ByProperty Name)

False

This cmdlet supports Microsoft PowerShell common parameters. For more information about common parameters, see http://go.microsoft.com/fwlink/p/?LinkID=113216.

484 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Example 1 This command synchronizes data for the backup copy job named "AD Backup Copy". The needed job object is obtained with Get-VBRJob and piped down. Get-VBRJob -Name "AD Backup Copy" | Sync-VBRBackupCopyJob

Example 2 This command synchronizes data for the backup copy job represented by the $"AD backup" variable. The needed job object is obtained with Get-VBRJob and assigned to the variable beforehand. Sync-VBRBackupCopyJob -Job $"AD backup"

485 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Sync-VBRBackupRepository Short Description Rescans a selected backup repository.

Applies to Version: 7.0 and earlier Platform: VMware, Hyper-V

Syntax Sync-VBRBackupRepository -Repository [WarningAction ] [-WarningVariable ] []

Related Commands Get-VBRBackupRepository

Detailed Description This cmdlet allows you to rescan a specified backup repository for details about backups stored on it. You can perform the repository rescan i.e. in case you have imported or copied backups. See what else you can perform on backup repositories

Parameters Parameter

Repository

Description

Specifies backup repository you want to rescan.

Required

True

Position

Accept Pipeline Input

Accept Wildcard Characters

Named

True (ByValue, ByProperty Name)

False

This cmdlet supports Microsoft PowerShell common parameters. For more information about common parameters, see http://go.microsoft.com/fwlink/p/?LinkID=113216.

486 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3

Example 1 This command rescans the repository named "Local Repository 01". The needed repository object is obtained with Get-VBRBackupRepository and piped down. Get-VBRBackupRepository -Name "Local Repository 01" | SyncVBRBackupRepository

Example 2 This command rescans the repository represented by the $repository variable. The needed repository object is obtained with Get-VBRBackupRepository and assigned to the variable beforehand. Sync-VBRBackupRepository -Repository $repository

487 | Veeam Backup PowerShell Reference | USER GUIDE | REV 3