Set-VBOHistorySettings

Short Description

Modifies history settings for backup and backup copy job sessions.

Syntax

This cmdlet provides the following parameter sets:

  • KeepOnlyLastXweeks (Default)

    Set-VBOHistorySettings -KeepOnlyLastXweeks <Int32> [<CommonParameters>]

  • KeepAllSessions

    Set-VBOHistorySettings [-KeepAllSessions] [<CommonParameters>]

Detailed Description

This cmdlet modifies the job session history settings. By default, Veeam Backup for Microsoft 365 will keep job sessions forever.

To modify settings, you need to enter the necessary parameters with new values. The parameters that you omit will remain unchanged.

Parameters

Parameters

Parameter

Description

Type

Required

Position

Accept Pipeline Input

KeepAllSessions

Defines that Veeam Backup for Microsoft 365 will keep job sessions forever.

Default: False

SwitchParameter

True

Named

False

KeepOnlyLastXweeks

Specifies the retention period for job sessions (weeks).

Default: 53

Int32

True

Named

False

<CommonParameters>

This cmdlet supports Microsoft PowerShell common parameters. For more information on common parameters, see the About Common Parameters section of Microsoft Learn.

Output Object

The cmdlet returns the VBOHistorySettings object that contains history settings for backup and backup copy job sessions.

Examples

Set-VBOHistorySettingsExample 1: Setting Job Session Retention Period

This command sets job session retention period in weeks.

Set-VBOHistorySettings -KeepOnlyLastXweeks 1

Set-VBOHistorySettingsExample 2: Keeping Job Sessions Forever

This command configures Veeam Backup for Microsoft 365 to keep job sessions forever.

Set-VBOHistorySettings -KeepAllSessions

Page updated 2026-08-21

Page content applies to build 8.6.0.1102