Help Center
Choose product document...
Veeam Backup for Microsoft Office 365 2.0
PowerShell Reference

Add-VBORepository

Short Description

Adds backup repositories to Veeam Backup for Microsoft Office 365.

Syntax

This cmdlet provides 5 parameter sets.

  • For adding a backup repository:

Add-VBORepository -Proxy <VBOProxy> -Name <string> -Path <string> [-Description <string>] [-Force]  [<CommonParameters>]

  • For adding a backup repository with daily clean-up schedule (retention period measured in years):

Add-VBORepository -Proxy <VBOProxy> -Name <string> -Path <string> -RetentionPeriod <VBORetentionPeriod> {Year1 | Years2 | Years3 | Years5 | Years7 | Years10 | Years25 | KeepForever} -RetentionFrequencyType <VBORetentionFrequencyType> {Daily | Monthly} -DailyTime <timespan> -DailyType <VBODailyType> {Everyday | Workdays | Weekends | Monday | Tuesday | Wednesday | Thursday | Friday | Saturday | Sunday} [-Description <string>] [-Force]  [<CommonParameters>]

  • For adding backup repository with monthly clean-up schedule (retention period measured in years):

Add-VBORepository -Proxy <VBOProxy> -Name <string> -Path <string> -RetentionPeriod <VBORetentionPeriod> {Year1 | Years2 | Years3 | Years5 | Years7 | Years10 | Years25 | KeepForever} -RetentionFrequencyType <VBORetentionFrequencyType> {Daily | Monthly} -MonthlyTime <timespan> -MonthlyDayNumber <VBOMonthlyDayNumber> {First | Second | Third | Fourth | Last} -MonthlyDayOfWeek <DayOfWeek> {Sunday | Monday | Tuesday | Wednesday | Thursday | Friday | Saturday} [-Description <string>] [-Force]  [<CommonParameters>]

  • For adding backup repository with daily clean-up schedule (retention period measured in months or days):

Add-VBORepository -Proxy <VBOProxy> -Name <string> -Path <string> -CustomRetentionPeriodType <VBOCustomRetentionPeriodType> {Months | Days} -CustomRetentionPeriod <int> -RetentionFrequencyType <VBORetentionFrequencyType> {Daily | Monthly} -DailyTime <timespan> -DailyType <VBODailyType> {Everyday | Workdays | Weekends | Monday | Tuesday | Wednesday | Thursday | Friday | Saturday | Sunday} [-Description <string>] [-Force]  [<CommonParameters>]

  • For adding backup repository with monthly clean-up schedule (retention period measured in months or days):

Add-VBORepository -Proxy <VBOProxy> -Name <string> -Path <string> -CustomRetentionPeriodType <VBOCustomRetentionPeriodType> {Months | Days} -CustomRetentionPeriod <int> -RetentionFrequencyType <VBORetentionFrequencyType> {Daily | Monthly} -MonthlyTime <timespan> -MonthlyDayNumber <VBOMonthlyDayNumber> {First | Second | Third | Fourth | Last} -MonthlyDayOfWeek <DayOfWeek> {Sunday | Monday | Tuesday | Wednesday | Thursday | Friday | Saturday} [-Description <string>] [-Force]  [<CommonParameters>]

Detailed Description

This cmdlet creates a backup repository on a specified server. A backup repository represents a folder where Veeam Backup for Microsoft Office 365 keeps organization backups. A created backup repository is added to the Veeam Backup for Microsoft Office 365 configuration.

You can set the retention period for this repository in years, months or days. Additionally, you can configure a clean-up schedule to check the backups in the repository and remove the outdated ones. Depending on how frequently you want to perform a clean-up you can set a daily or monthly schedule. For each clean-up schedule type you can specify the clean-up day and time.

Parameters

Parameter

Description

Required

Position

Accept
Pipeline
Input

Accept
Wildcard
Characters

Proxy

Specifies Veeam Backup for Microsoft Office 365 backup proxy. Veeam Backup for Microsoft Office 365 will add backup repository to this backup proxy.

True

Named

False

False

Name

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

True

Named

False

False

Description

Specifies the description of the backup repository.

False

Named

False

False

Path

Specifies the full path to the backup repository on the proxy server.

True

Named

False

False

Retention
Period

Specifies the retention period in years:

  • Year1
  • Years2
  • Years3
  • Years5
  • Years7
  • Years10
  • Years25
  • KeepForever

Default: Years3.

Backup jobs targeted to this repository will back up organization items that were created or modified within the indicated retention period.

For example, if you set the retention period to 2 years, the backup job will back up all items that were created or modified 2 years ago or later. When an item’s age exceeds the retention, it is deleted.

If you select Keep forever, the backup job will back up all items and will never remove them.

If you want to measure the retention period in months or days, use CustomCustomRetentionPeriodType parameter.

True

Named

False

False

Custom
Retention
Period
Type

Indicates that the retention period will be set in one of the retention period types:

  • Months
  • Days

True

Named

False

False

Custom
Retention
Period

Specifies the retention period in months or days:

  • Specifies retention period in months if CustomRetentionPeriodType parameter is set to Months
  • Specifies retention period in days if CustomRetentionPeriodType parameter is set to Days

Backup jobs targeted to this repository will back up organization items that were created or modified within the indicated retention period.

For example, if you set the CustomRetentionPeriodType to Months and CustomRetentionPeriod to 23, the backup job will back up all items that were created or modified 23 months ago or later. When an item’s age exceeds the retention, it is deleted.

True

Named

False

False

Retention
Frequency
Type

Specifies clean-up schedule type:

  • Daily: to check and remove the outdated backups once a day. Use DailyTime parameter to set the time of the day for performing clean-up. Use DailyType parameter to set the days for performing clean-up.
  • Monthly: to check and remove the outdated backups once a month. Use MonthlyTime parameter to set the time of the day for performing clean-up. Use MonthlyDayNumber and MonthlyDayOfWeek parameters to set the day for performing clean-up.

Default: Daily.

True

Named

False

False

Daily
Time

For daily clean-up schedule.

Specifies the time of the day when clean-up must be performed.

Default: 18:00:00.

True

Named

False

False

Daily
Type

For daily clean-up schedule.

Specifies the days when clean-up must be performed:

  • Sunday
  • Monday
  • Tuesday
  • Wednesday
  • Thursday
  • Friday
  • Saturday
  • Everyday
  • Workdays
  • Weekends

Default: Everyday.

True

Named

False

False

Monthly
Time

For monthly clean-up schedule.

Specifies the time of the day when clean-up must be performed.

Default: 18:00:00.

True

Named

False

False

Monthly
DayNumber

For monthly clean-up schedule.

Specifies the order number for the day of the week when clean-up must be performed:

  • First
  • Second
  • Third
  • Fourth
  • Last

Default: First.

True

Named

False

False

Monthly
DayOfWeek

For monthly clean-up schedule.

Specifies the day of the week when clean-up must be performed:

  • Sunday
  • Monday
  • Tuesday
  • Wednesday
  • Thursday
  • Friday
  • Saturday

Default: Monday.

True

Named

False

False

Force

Indicates that the cmdlet will add a backup repository to Veeam Backup for Microsoft Office 365 configuration without notifying the user.

False

Named

False

False

<CommonParameters>

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 example shows how to add a new backup repository to Veeam Backup for Microsoft Office 365 configuration.

You will need to perform the following steps:

  1. Run Get-VBOProxy to get the backup proxy where the repository will be added. Save the result to the $proxy variable.
  2. Run Add-VBORepository with the $proxy variable.

PS C:\PS> $proxy = Get-VBOProxy -Hostname support.north.local

PS C:\PS> Add-VBORepository -Proxy $proxy -Name "ABC Backup" -Path "C:\Backup Repository" -Description "North ABC"

Example 2

This example shows how to add a new backup repository with the following retention settings:

  • The retention period is 1 year.
  • The backup organization data will be removed per the daily clean-up schedule: everyday at 3:00 PM.

You will need to perform the following steps:

  1. Run Get-VBOProxy to get the backup proxy where the repository will be added. Save the result to the $proxy variable.
  2. Run Add-VBORepository with the $proxy variable.

PS C:\PS> $proxy = Get-VBOProxy -Id "d96f55a4-d15d-410b-b0f0-d51d17ccdab6"

PS C:\PS> Add-VBORepository -Proxy $proxy -Name "ABC Backup" -Path "C:\Backup Repository" -RetentionPeriod Year1 -RetentionFrequencyType Daily -DailyTime 15:00:00 -DailyType Everyday -Description "Daily ABC"

Example 3

This example shows how to add a new backup repository with the following retention settings:

  • The retention period for organization data is 2 years.
  • The backup organization data will be removed per the monthly clean-up schedule: every last Sunday at 2:00 PM.

You will need to perform the following steps:

  1. Run Get-VBOProxy to get the backup proxy where the repository will be added. Save the result to the $proxy variable.
  2. Run Add-VBORepository with the $proxy variable.

PS C:\PS> $proxy = Get-VBOProxy -Hostname "support.south.local"

PS C:\PS> Add-VBORepository -Proxy $proxy -Name "Critical Mailboxes" -Path "C:\ABC Backup\Critical" -RetentionPeriod Year2 -RetentionFrequencyType Monthly -MonthlyTime 14:00:00 -MonthlyDayNumber Last -MonthlyDayOfWeek Sunday -Description "Monthly ABC"

Example 4

This example shows how to add a new backup repository with the following retention settings:

  • The retention period for organization items is 3 months.
  • The backup organization data will be removed per the daily clean-up schedule: everyday at 12:00 PM.

You will need to perform the following steps:

  1. Run Get-VBOProxy to get the backup proxy where the repository will be added. Save the result to the $proxy variable.
  2. Run Add-VBORepository with the $proxy variable.

PS C:\PS> $proxy = Get-VBOProxy -Id "d96f55a4-d15d-410b-b0f0-d51d17ccdab6"

PS C:\PS> Add-VBORepository -Proxy $proxy -Name "Daily Reports" -Path "C:\ABC Backup\Reports" -CustomRetentionPeriodType Months -CustomRetentionPeriod 3 -RetentionFrequencyType Daily -DailyTime 12:00:00 -DailyType Workdays -Description "Daily ABC"

Example 5

This example shows how to add a new backup repository with the following retention settings:

  • The retention period for organization data is 7 days.
  • The backup organization data will be removed per the monthly clean-up schedule: every first Monday at 8:00 AM.

You will need to perform the following steps:

  1. Run Get-VBOProxy to get the backup proxy where the repository will be added. Save the result to the $proxy variable.
  2. Run Add-VBORepository with the $proxy variable.

PS C:\PS> $proxy = Get-VBOProxy -Hostname support.west.local

PS C:\PS> Add-VBORepository -Proxy $proxy -Name "Monthly Reports" -Path "C:\ABC Backup\Reports" -CustomRetentionPeriodType Days -CustomRetentionPeriod 7 -RetentionFrequencyType Monthly -MonthlyTime 08:00:00 -MonthlyDayNumber First -MonthlyDayOfWeek Monday -Description "Monthly ABC"

Related Commands

Get-VBOProxy

Veeam Large Logo

User Guide

RESTful API Reference

PowerShell Reference