NAME
Set-DcsBackUpFolder
SYNOPSIS
Assigns a folder where the configuration backups should be stored on a server after being created.
SYNTAX
Set-DcsBackUpFolder -Server <Object> [ -Folder <String> ] [ -Connection <String> ] [ -PipelineVariable <String> ]
DESCRIPTION
Assigns a folder where the configuration backups should be stored on a server after being created. If the folder does not exist, it will be created. The backup folder should be set for each server in the server group. The folder will appear when the Backup-DcsConfiguration cmdlet is invoked.
PARAMETERS
- -Server<Object>
- ServerHostData object, computer name, or ID that identifies the the server where the folder should be located. The computer name must be unique or the name must be fully qualified.
-
- Required: true
- Position: 1
- Default value:
- Accept pipeline input: true (ByValue)
- Accept wildcard characters: false
-
- -Folder<String>
- The complete path to the folder used to store configuration backups. If the folder does not exist, it will be created. The path should begin with the drive letter. For instance, "C:\Backups" could be a valid value. To remove the folder, use an empty string as the value; for example "".
-
- Required: false
- Position: 2
- Default value:
- Accept pipeline input: false
- Accept wildcard characters: false
-
- -Connection<String>
- Alias of the connection to the server group. If not specified, the default connection will be used.
-
- Required: false
- Position: named
- Default value:
- Accept pipeline input: false
- Accept wildcard characters: false
-
- -PipelineVariable<String>
-
- Required: false
- Position: named
- Default value:
- Accept pipeline input: false
- Accept wildcard characters: false
-
INPUTS
ServerHostData : Object that identifies the server.
OUTPUTS
string : The path of the backup folder.
NOTES
Also see Get-DcsBackupFolder, Backup-DcsConfiguration.
EXAMPLES
$servers = Get-DcsServer Set-DcsBackUpFolder -Server $servers[0] -Folder "C:\Backups\" Set-DcsBackUpFolder -Server $servers[1] -Folder "C:\Backups\"
The cmdlet Get-DcsServer is used to get ServerHostData objects for all servers in the server group and store the objects in the variable $servers. The cmdlet Set-DcsBackupFolder is invoked once for each server to set the location of the backup folder to "C:\Backups\" on each server.
C:\Backups\ C:\Backups\