Lock-DPMLibraryDoor

Locks the door of a DPM library.

Syntax

Lock-DPMLibraryDoor
    [-DPMLibrary] <Library>
    [-Async]
    [-DoorAccessJobStateChangeEventHandler <DoorAccessJobStateChangeEventHandler>]
    [-WhatIf]
    [-Confirm]
    [<CommonParameters>]

Description

The Lock-DPMLibraryDoor cmdlet locks the door of a System Center - Data Protection Manager (DPM) library.

Examples

Example 1: Lock a library door

PS C:\>$DpmLibrary = Get-DPMLibrary -DPMServerName "DPMServer07"
PS C:\> Lock-DPMLibraryDoor -DPMLibrary $DpmLibrary[0]

The first command gets the libraries associated with the server, and then stores the library objects in the $DpmLibrary variable.

The second command locks the library door for the first library object stored in $DpmLibrary. This DPM server has more than one library. Therefore, the command uses standard Windows PowerShell array syntax to specify the first member of the $DpmLibrary array.

Parameters

-Async

Indicates that the command runs asynchronously. When you run a command asynchronously, the command prompt returns immediately even if the job takes an extended time to finish.

Type:SwitchParameter
Position:Named
Default value:None
Required:False
Accept pipeline input:True
Accept wildcard characters:False

-Confirm

Prompts you for confirmation before running the cmdlet.

Type:SwitchParameter
Aliases:cf
Position:Named
Default value:False
Required:False
Accept pipeline input:False
Accept wildcard characters:False

-DoorAccessJobStateChangeEventHandler

Specifies an event handler for certain door access events. You can use this parameter to update a GUI that runs in Windows PowerShell, but do not use it in the Windows PowerShell console.

Type:DoorAccessJobStateChangeEventHandler
Aliases:Handler
Position:Named
Default value:None
Required:False
Accept pipeline input:True
Accept wildcard characters:False

-DPMLibrary

Specifies a DPM library object that this cmdlet locks. To obtain a DPM library object, use the Get-DPMLibrary cmdlet.

Type:Library
Position:1
Default value:None
Required:True
Accept pipeline input:True
Accept wildcard characters:False

-WhatIf

Shows what would happen if the cmdlet runs. The cmdlet is not run.

Type:SwitchParameter
Aliases:wi
Position:Named
Default value:False
Required:False
Accept pipeline input:False
Accept wildcard characters:False