Skip to content

Commit e4a00fc

Browse files
Merge pull request MicrosoftDocs#3203 from robinharwood/roharwoo_failoverclusters_example_formatting_1
FailoverClusters Bulk Fixup (1/4) - Update example formatting
2 parents 3ca3f37 + abead04 commit e4a00fc

29 files changed

+213
-396
lines changed

Diff for: docset/winserver2022-ps/failoverclusters/Add-ClusterCheckpoint.md

+14-13
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
description: Use this topic to help manage Windows and Windows Server technologies with Windows PowerShell.
33
external help file: Microsoft.FailoverClusters.PowerShell.dll-Help.xml
44
Module Name: FailoverClusters
5-
ms.date: 10/21/2022
5+
ms.date: 11/22/2022
66
online version: https://learn.microsoft.com/powershell/module/failoverclusters/add-clustercheckpoint?view=windowsserver2022-ps&wt.mc_id=ps-gethelp
77
schema: 2.0.0
88
title: Add-ClusterCheckpoint
@@ -36,26 +36,27 @@ local server.
3636

3737
### Example 1: Add registry checkpoint
3838

39-
```
40-
PS C:\> Add-ClusterCheckpoint -ResourceName "Cluster Name" -RegistryCheckpoint "software\clusname"
41-
Resource Name
42-
-------- ----
43-
Cluster Name software\clusname
39+
```powershell
40+
Add-ClusterCheckpoint -ResourceName "Cluster Name" -RegistryCheckpoint "software\clusname"
4441
```
4542

46-
This example adds a registry checkpoint called software\clusname for the resource named cluster
43+
This example adds a registry checkpoint called `software\clusname` for the resource named cluster
4744
name.
4845

4946
### Example 2: Add cryptographic checkpoint
5047

51-
```
52-
PS C:\> Get-ClusterResource -Name "Cluster Name" | Add-ClusterCheckpoint -CryptoCheckpointName "Microsoft Base Cryptographic Provider v1.0" -CryptoCheckpointType 1 -CryptoCheckpointKey "Crypto"
53-
Resource Name Type Key
54-
-------- ---- ---- ---
55-
Cluster Name Microsoft Base Cryptograph... 1 Crypto
48+
```powershell
49+
$parameters = @{
50+
CryptoCheckpointName = 'Microsoft Base Cryptographic Provider v1.0'
51+
CryptoCheckpointType = '1'
52+
CryptoCheckpointKey = 'Crypto'
53+
}
54+
Get-ClusterResource -Name "Cluster Name" | Add-ClusterCheckpoint @parameters
5655
```
5756

58-
This example adds a cryptographic checkpoint for the resource named Cluster Name.
57+
This example adds a cryptographic checkpoint for the resource named Cluster Name. This example uses
58+
splatting to pass parameter values from the `$Parameters` variable to the command. Learn more about
59+
[Splatting](/powershell/module/microsoft.powershell.core/about/about_splatting).
5960

6061
## PARAMETERS
6162

Diff for: docset/winserver2022-ps/failoverclusters/Add-ClusterDisk.md

+9-19
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
description: Use this topic to help manage Windows and Windows Server technologies with Windows PowerShell.
33
external help file: Microsoft.FailoverClusters.PowerShell.dll-Help.xml
44
Module Name: FailoverClusters
5-
ms.date: 10/21/2022
5+
ms.date: 11/22/2022
66
online version: https://learn.microsoft.com/powershell/module/failoverclusters/add-clusterdisk?view=windowsserver2022-ps&wt.mc_id=ps-gethelp
77
schema: 2.0.0
88
title: Add-ClusterDisk
@@ -34,40 +34,30 @@ information about disks that you can add to the cluster.
3434

3535
### Example 1: Add available disks to the Available Storage group
3636

37-
```
38-
PS C:\> Get-ClusterAvailableDisk | Add-ClusterDisk
39-
Name State Group ResourceType
40-
---- ----- ----- ------------
41-
Cluster Disk 7 OnlinePending Available Storage Physical Disk
42-
Cluster Disk 8 OnlinePending Available Storage Physical Disk
37+
```powershell
38+
Get-ClusterAvailableDisk | Add-ClusterDisk
4339
```
4440

4541
This example identifies the disks that are ready to be added to the cluster, and then adds them to
4642
Available Storage cluster group.
4743

4844
### Example 2: Add a specific available disk to Available Storage
4945

50-
```
51-
PS C:\> Get-ClusterAvailableDisk | Where-Object -FilterScript { $_.ScsiAddress -Eq 50331651 } | Add-ClusterDisk
52-
Name State Group ResourceType
53-
---- ----- ----- ------------
54-
Cluster Disk 4 OnlinePending Available Storage Physical Disk
46+
```powershell
47+
Get-ClusterAvailableDisk | Where-Object -FilterScript { $_.ScsiAddress -Eq 50331651 } | Add-ClusterDisk
5548
```
5649

5750
This example examines disks that are ready to be added to the cluster, finds the disk with a
5851
specific SCSI address, and adds it to Available Storage cluster group.
5952

6053
### Example 3: Cluster a physical disk
6154

62-
```
63-
PS C:\> Get-Disk -Number 11 | Add-ClusterDisk
64-
Name State OwnerGroup ResourceType
65-
---- ----- ---------- ------------
66-
Cluster Disk 5 OnlinePending Available Storage Physical Disk
55+
```powershell
56+
Get-Disk -Number 11 | Add-ClusterDisk
6757
```
6858

69-
This example clusters a physical disk. This cmdlet adds a physical disk to the **Available Storage**
70-
for the cluster.
59+
This example clusters a physical disk. This cmdlet adds a physical disk to the cluster
60+
_Available Storage_.
7161

7262
## PARAMETERS
7363

Diff for: docset/winserver2022-ps/failoverclusters/Add-ClusterFileServerRole.md

+12-21
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
description: Use this topic to help manage Windows and Windows Server technologies with Windows PowerShell.
33
external help file: Microsoft.FailoverClusters.PowerShell.dll-Help.xml
44
Module Name: FailoverClusters
5-
ms.date: 10/21/2022
5+
ms.date: 11/22/2022
66
online version: https://learn.microsoft.com/powershell/module/failoverclusters/add-clusterfileserverrole?view=windowsserver2022-ps&wt.mc_id=ps-gethelp
77
schema: 2.0.0
88
title: Add-ClusterFileServerRole
@@ -38,38 +38,29 @@ clustered file server should use.
3838

3939
### Example 1: Create a clustered file server
4040

41-
```
42-
PS C:\> Add-ClusterFileServerRole -Storage "Cluster Disk 8"
43-
Name OwnerNode State
44-
---- --------- -----
45-
cluster1FS node1 Online
41+
```powershell
42+
Add-ClusterFileServerRole -Storage "Cluster Disk 8"
4643
```
4744

48-
This example creates a clustered file server using Cluster Disk 8, and assigns a default name.
45+
This example creates a clustered file server using `Cluster Disk 8`, and assigns a default name.
4946

5047
### Example 2: Create and name a clustered file server
5148

52-
```
53-
PS C:\> Add-ClusterFileServerRole -Storage "Cluster Disk 6" -Name cluster1FS12
54-
Name OwnerNode State
55-
---- --------- -----
56-
cluster1FS12 node1 Online
49+
```powershell
50+
Add-ClusterFileServerRole -Storage "Cluster Disk 6" -Name cluster1FS12
5751
```
5852

59-
This example creates a clustered file server using Cluster Disk 6, and assigns the name
60-
cluster1FS12.
53+
This example creates a clustered file server using `Cluster Disk 6`, and assigns the name
54+
`cluster1FS12`.
6155

6256
### Example 3: Create a clustered file server with no waiting for resources
6357

64-
```
65-
PS C:\> Add-ClusterFileServerRole -Storage "Cluster Disk 8" -Wait 0
66-
Name OwnerNode State
67-
---- --------- -----
68-
cluster1FS node1 Pending
58+
```powershell
59+
Add-ClusterFileServerRole -Storage "Cluster Disk 8" -Wait 0
6960
```
7061

71-
This example creates a clustered file server using Cluster Disk 8, and assigns a default name. The
72-
cmdlet completes without waiting for all resources to come online.
62+
This example creates a clustered file server using `Cluster Disk 8`, and assigns a default name.
63+
The cmdlet completes without waiting for all resources to come online.
7364

7465
## PARAMETERS
7566

Diff for: docset/winserver2022-ps/failoverclusters/Add-ClusterGenericApplicationRole.md

+19-21
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
description: Use this topic to help manage Windows and Windows Server technologies with Windows PowerShell.
33
external help file: Microsoft.FailoverClusters.PowerShell.dll-Help.xml
44
Module Name: FailoverClusters
5-
ms.date: 10/21/2022
5+
ms.date: 11/22/2022
66
online version: https://learn.microsoft.com/powershell/module/failoverclusters/add-clustergenericapplicationrole?view=windowsserver2022-ps&wt.mc_id=ps-gethelp
77
schema: 2.0.0
88
title: Add-ClusterGenericApplicationRole
@@ -40,38 +40,36 @@ If so, then it is presumed to be online and will not be restarted or failed over
4040

4141
### Example 1: Configure an application as a generic clustered application
4242

43-
```
44-
PS C:\> Add-ClusterGenericApplicationRole -CommandLine NewApplication.exe
45-
Name OwnerNode State
46-
---- --------- -----
47-
cluster1GenApp node2 Online
43+
```powershell
44+
Add-ClusterGenericApplicationRole -CommandLine NewApplication.exe
4845
```
4946

50-
This example configures NewApplication.exe as a generic clustered application. A default name will
51-
be used for client access and this application requires no storage.
47+
This example configures `NewApplication.exe` as a generic clustered application.
48+
A default name will be used for client access and this application requires no storage.
5249

5350
### Example 2: Configure an application with storage and name
5451

55-
```
56-
PS C:\> Add-ClusterGenericApplicationRole -CommandLine NewApplication.exe -Storage "Cluster Disk 4" -Name NewApplication
57-
Name OwnerNode State
58-
---- --------- -----
59-
NewApplication node2 Online
52+
```powershell
53+
$parameters = @{
54+
CommandLine = 'NewApplication.exe'
55+
Storage = 'Cluster Disk 4'
56+
Name = 'NewApplication'
57+
}
58+
Add-ClusterGenericApplicationRole @parameters
6059
```
6160

62-
This example configures NewApplication.exe as a generic clustered application using Cluster Disk 4,
63-
and assigns the name NewApplication.
61+
This example configures `NewApplication.exe` as a generic clustered application using Cluster Disk 4,
62+
and assigns the name NewApplication. This example uses splatting to pass parameter values from the
63+
`$Parameters` variable to the command. Learn more about
64+
[Splatting](/powershell/module/microsoft.powershell.core/about/about_splatting).
6465

6566
### Example 3: Configure application with no wait for resources
6667

67-
```
68-
PS C:\> Add-ClusterGenericApplicationRole -CommandLine NewApplication.exe -Wait 0
69-
Name OwnerNode State
70-
---- --------- -----
71-
cluster1GenApp node2 Pending
68+
```powershell
69+
Add-ClusterGenericApplicationRole -CommandLine NewApplication.exe -Wait 0
7270
```
7371

74-
This example configures NewApplication.exe as a generic clustered application and assigns the name
72+
This example configures `NewApplication.exe` as a generic clustered application and assigns the name
7573
NewApplication. The cmdlet completes without waiting for all resources to come online.
7674

7775
## PARAMETERS

Diff for: docset/winserver2022-ps/failoverclusters/Add-ClusterGenericScriptRole.md

+11-20
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
description: Use this topic to help manage Windows and Windows Server technologies with Windows PowerShell.
33
external help file: Microsoft.FailoverClusters.PowerShell.dll-Help.xml
44
Module Name: FailoverClusters
5-
ms.date: 10/21/2022
5+
ms.date: 11/22/2022
66
online version: https://learn.microsoft.com/powershell/module/failoverclusters/add-clustergenericscriptrole?view=windowsserver2022-ps&wt.mc_id=ps-gethelp
77
schema: 2.0.0
88
title: Add-ClusterGenericScriptRole
@@ -39,38 +39,29 @@ script, the application will be restarted or failed over.
3939

4040
### Example 1: Configure a script to run on a failover cluster
4141

42-
```
43-
PS C:\> Add-ClusterGenericScriptRole -ScriptFilePath "script1.vbs"
44-
Name OwnerNode State
45-
---- --------- -----
46-
cluster1GenScript node2 Online
42+
```powershell
43+
Add-ClusterGenericScriptRole -ScriptFilePath "script1.vbs"
4744
```
4845

49-
This example configures the script named script1.vbs to run within a failover cluster, using
46+
This example configures the script named `script1.vbs` to run within a failover cluster, using
5047
defaults for the name and IP address, and doesn't assign a disk.
5148

5249
### Example 2: Configure a script on a failover cluster and assign a clustered script name
5350

54-
```
55-
PS C:\> Add-ClusterGenericScriptRole -ScriptFilePath "script1.vbs" -Storage "Cluster Disk 4" -Name "script1"
56-
Name OwnerNode State
57-
---- --------- -----
58-
script1 node2 Online
51+
```powershell
52+
Add-ClusterGenericScriptRole -ScriptFilePath "script1.vbs" -Storage "Cluster Disk 4" -Name "script1"
5953
```
6054

61-
This example configures the script named script1.vbs to run within a failover cluster and use
62-
Cluster Disk 4. The cmdlet assigns the clustered script the name script1.
55+
This example configures the script named `script1.vbs` to run within a failover cluster and use
56+
`Cluster Disk 4`. The cmdlet assigns the clustered script the name script1.
6357

6458
### Example 3: Configure a script to run on a fail over cluster without waiting for resources
6559

66-
```
67-
PS C:\> Add-ClusterGenericScriptRole -ScriptFilePath "script1.vbs" -Wait 0
68-
Name OwnerNode State
69-
---- --------- -----
70-
cluster1GenScript node2 Pending
60+
```powershell
61+
Add-ClusterGenericScriptRole -ScriptFilePath "script1.vbs" -Wait 0
7162
```
7263

73-
This example configures the script called script1.vbs to run within a failover cluster, using
64+
This example configures the script called `script1.vbs` to run within a failover cluster, using
7465
defaults for the name and IP address, and doesn't assign a disk. The cmdlet completes without
7566
waiting for all resources to come online.
7667

Diff for: docset/winserver2022-ps/failoverclusters/Add-ClusterGenericServiceRole.md

+6-12
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
description: Use this topic to help manage Windows and Windows Server technologies with Windows PowerShell.
33
external help file: Microsoft.FailoverClusters.PowerShell.dll-Help.xml
44
Module Name: FailoverClusters
5-
ms.date: 10/21/2022
5+
ms.date: 11/22/2022
66
online version: https://learn.microsoft.com/powershell/module/failoverclusters/add-clustergenericservicerole?view=windowsserver2022-ps&wt.mc_id=ps-gethelp
77
schema: 2.0.0
88
title: Add-ClusterGenericServiceRole
@@ -39,26 +39,20 @@ restarted or failed over.
3939

4040
### Example 1: Configure a service that uses default values
4141

42-
```
43-
PS C:\> Add-ClusterGenericServiceRole -ServiceName "Service1"
44-
Name OwnerNode State
45-
---- --------- -----
46-
cluster1GenSvc node1 Online
42+
```powershell
43+
Add-ClusterGenericServiceRole -ServiceName "Service1"
4744
```
4845

4946
This example configures Service1 as a generic clustered service, using defaults for the name and IP
5047
address, and doesn't assign a disk.
5148

5249
### Example 2: Configure a service that uses default values and a specified disk
5350

54-
```
55-
PS C:\> Add-ClusterGenericServiceRole -ServiceName "Service1" -Storage "Cluster Disk 6"
56-
Name OwnerNode State
57-
---- --------- -----
58-
cluster1GenSvc node1 Online
51+
```powershell
52+
Add-ClusterGenericServiceRole -ServiceName "Service1" -Storage "Cluster Disk 6"
5953
```
6054

61-
This example configures Service1 as a generic clustered service using Cluster Disk 6, and assigns
55+
This example configures Service1 as a generic clustered service using `Cluster Disk 6`, and assigns
6256
defaults for the name and IP address.
6357

6458
## PARAMETERS

Diff for: docset/winserver2022-ps/failoverclusters/Add-ClusterGroup.md

+3-6
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
description: Use this topic to help manage Windows and Windows Server technologies with Windows PowerShell.
33
external help file: Microsoft.FailoverClusters.PowerShell.dll-Help.xml
44
Module Name: FailoverClusters
5-
ms.date: 10/21/2022
5+
ms.date: 11/22/2022
66
online version: https://learn.microsoft.com/powershell/module/failoverclusters/add-clustergroup?view=windowsserver2022-ps&wt.mc_id=ps-gethelp
77
schema: 2.0.0
88
title: Add-ClusterGroup
@@ -31,11 +31,8 @@ is the unit of failover. During failover, all resources in the resource group mo
3131

3232
### Example 1: Add a resource group
3333

34-
```
35-
PS C:\> Add-ClusterGroup -Name "Group1"
36-
Name OwnerNode State
37-
---- --------- -----
38-
Group1 node1 Online
34+
```powershell
35+
Add-ClusterGroup -Name "Group1"
3936
```
4037

4138
This example adds an empty resource group called Group1 to the failover cluster.

Diff for: docset/winserver2022-ps/failoverclusters/Add-ClusterGroupSetDependency.md

+5-5
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
description: Use this topic to help manage Windows and Windows Server technologies with Windows PowerShell.
33
external help file: ClusterCollection.cdxml-help.xml
44
Module Name: FailoverClusters
5-
ms.date: 10/21/2022
5+
ms.date: 11/22/2022
66
online version: https://learn.microsoft.com/powershell/module/failoverclusters/add-clustergroupsetdependency?view=windowsserver2022-ps&wt.mc_id=ps-gethelp
77
schema: 2.0.0
88
title: Add-ClusterGroupSetDependency
@@ -37,12 +37,12 @@ The `Add-ClusterGroupSetDependency` cmdlet adds a dependency to a cluster set.
3737

3838
### Example 1: Add a dependency to a provider set
3939

40-
```
41-
PS C:\> Add-ClusterGroupSetDependency -Name "Set001" -Provider "Provider002"
40+
```powershell
41+
Add-ClusterGroupSetDependency -Name "Set001" -Provider "Provider002"
4242
```
4343

44-
This command adds the set named Provider002 as a provider to the set named Set001. Both sets cannot
45-
be empty.
44+
This command adds the set named `Provider002` as a provider to the set named `Set001`.
45+
Both sets cannot be empty.
4646

4747
## PARAMETERS
4848

0 commit comments

Comments
 (0)