Skip to content

Commit e71387f

Browse files
Merge pull request #12737 from MicrosoftDocs/main
Auto Publish – main to live - 2026-02-04 23:00 UTC
2 parents aea674a + ed225b5 commit e71387f

33 files changed

+361
-197
lines changed

reference/5.1/Microsoft.PowerShell.Management/Set-Service.md

Lines changed: 11 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
external help file: Microsoft.PowerShell.Commands.Management.dll-Help.xml
33
Locale: en-US
44
Module Name: Microsoft.PowerShell.Management
5-
ms.date: 03/20/2024
5+
ms.date: 02/04/2026
66
online version: https://learn.microsoft.com/powershell/module/microsoft.powershell.management/set-service?view=powershell-5.1&WT.mc_id=ps-gethelp
77
schema: 2.0.0
88
title: Set-Service
@@ -168,6 +168,7 @@ Name StartType
168168
spooler Automatic
169169
SQLWriter Automatic
170170
```
171+
171172
## PARAMETERS
172173

173174
### -ComputerName
@@ -291,18 +292,18 @@ Accept wildcard characters: False
291292

292293
Sets the startup type of the service. The acceptable values for this parameter are:
293294

294-
- **Automatic** - The service is started or was started by the operating system, at system start-up.
295+
- `Automatic` - The service is started or was started by the operating system, at system start-up.
295296
If an automatically started service depends on a manually started service, the manually started
296297
service is also started automatically at system startup.
297-
- **Disabled** - The service is disabled and cannot be started by a user or application.
298-
- **Manual** - The service is started only manually, by a user, using the Service Control Manager,
298+
- `Disabled` - The service is disabled and cannot be started by a user or application.
299+
- `Manual` - The service is started only manually, by a user, using the Service Control Manager,
299300
or by an application.
300-
- **Boot** - Indicates that the service is a device driver started by the system loader. This
301+
- `Boot` - Indicates that the service is a device driver started by the system loader. This
301302
value is valid only for device drivers.
302-
- **System** - Indicates that the service is a device driver started by the 'IOInitSystem()'
303+
- `System` - Indicates that the service is a device driver started by the 'IOInitSystem()'
303304
function. This value is valid only for device drivers.
304305

305-
The default value is **Automatic**.
306+
The default value is `Automatic`.
306307

307308
```yaml
308309
Type: System.ServiceProcess.ServiceStartMode
@@ -323,9 +324,9 @@ Specifies the status for the service.
323324

324325
The acceptable values for this parameter are as follows:
325326

326-
- **Paused**. Suspends the service.
327-
- **Running**. Starts the service.
328-
- **Stopped**. Stops the service.
327+
- `Paused`. Suspends the service.
328+
- `Running`. Starts the service.
329+
- `Stopped`. Stops the service.
329330

330331
```yaml
331332
Type: System.String

reference/7.4/Microsoft.PowerShell.Management/Get-Service.md

Lines changed: 18 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
external help file: Microsoft.PowerShell.Commands.Management.dll-Help.xml
33
Locale: en-US
44
Module Name: Microsoft.PowerShell.Management
5-
ms.date: 03/20/2024
5+
ms.date: 02/04/2026
66
online version: https://learn.microsoft.com/powershell/module/microsoft.powershell.management/get-service?view=powershell-7.4&WT.mc_id=ps-gethelp
77
schema: 2.0.0
88
aliases:
@@ -108,10 +108,10 @@ Status is only one property of service objects. To see all of the properties, ty
108108
This example gets services that have dependent services.
109109

110110
```powershell
111-
Get-Service |
112-
Where-Object {$_.DependentServices} |
111+
Get-Service | Where-Object {$_.DependentServices} |
113112
Format-List -Property Name, DependentServices, @{
114-
Label="NoOfDependentServices"; Expression={$_.DependentServices.Count}
113+
Label = "NoOfDependentServices"
114+
Expression = {$_.DependentServices.Count}
115115
}
116116
```
117117

@@ -140,7 +140,7 @@ This example shows that when you sort services in ascending order by the value o
140140
property, stopped services appear before running services. This happens because the value of
141141
**Status** is an enumeration, in which `Stopped` has a value of `1`, and `Running` has a value of
142142
`4`. For more information, see
143-
[ServiceControllerStatus](/dotnet/api/system.serviceprocess.servicecontrollerstatus).
143+
[ServiceControllerStatus](xref:System.ServiceProcess.ServiceControllerStatus).
144144

145145
To list running services first, use the **Descending** parameter of the `Sort-Object` cmdlet.
146146

@@ -338,9 +338,16 @@ PowerShell includes the following aliases for `Get-Service`:
338338

339339
This cmdlet is only available on Windows platforms.
340340

341-
Beginning in PowerShell 6.0, the following properties are added to the **ServiceController**
342-
objects: **UserName**, **Description**, **DelayedAutoStart**, **BinaryPathName**, and
343-
**StartupType** .
341+
PowerShell 6.0 introduced the following changes:
342+
343+
- The **ServiceController** objects now include the following properties:
344+
- **UserName**
345+
- **Description**
346+
- **DelayedAutoStart**
347+
- **BinaryPathName**
348+
- **StartupType**
349+
- The command no longer includes the **ComputerName** parameter. To use this command on a remote computer,
350+
use the `Invoke-Command` to target a remote system.
344351

345352
This cmdlet can display services only when the current user has permission to see them. If this
346353
cmdlet does not display services, you might not have permission to see them.
@@ -363,10 +370,12 @@ services. The **Status** property of a service is an enumerated value in which t
363370
statuses represent integer values. The sort is based on the integer value, not the name. `Running`
364371
appears before `Stopped` because `Stopped` has a value of `1`, and `Running` has a value of `4`. For
365372
more information, see
366-
[ServiceControllerStatus](/dotnet/api/system.serviceprocess.servicecontrollerstatus).
373+
[ServiceControllerStatus](xref:System.ServiceProcess.ServiceControllerStatus).
367374

368375
## RELATED LINKS
369376

377+
[Invoke-Command](../Microsoft.PowerShell.Core/Invoke-Command.md)
378+
370379
[New-Service](New-Service.md)
371380

372381
[Restart-Service](Restart-Service.md)

reference/7.4/Microsoft.PowerShell.Management/New-Service.md

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
external help file: Microsoft.PowerShell.Commands.Management.dll-Help.xml
33
Locale: en-US
44
Module Name: Microsoft.PowerShell.Management
5-
ms.date: 12/12/2022
5+
ms.date: 02/04/2026
66
online version: https://learn.microsoft.com/powershell/module/microsoft.powershell.management/new-service?view=powershell-7.4&WT.mc_id=ps-gethelp
77
schema: 2.0.0
88
title: New-Service
@@ -318,8 +318,13 @@ This cmdlet is only available on Windows platforms.
318318

319319
To run this cmdlet, start PowerShell by using the **Run as administrator** option.
320320

321+
Beginning in PowerShell 6.0, the command no longer includes the **ComputerName** parameter. To use
322+
this command on a remote computer, use the `Invoke-Command` to target a remote system.
323+
321324
## RELATED LINKS
322325

326+
[Invoke-Command](../Microsoft.PowerShell.Core/Invoke-Command.md)
327+
323328
[Get-Service](Get-Service.md)
324329

325330
[Restart-Service](Restart-Service.md)

reference/7.4/Microsoft.PowerShell.Management/Remove-Service.md

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
external help file: Microsoft.PowerShell.Commands.Management.dll-Help.xml
33
Locale: en-US
44
Module Name: Microsoft.PowerShell.Management
5-
ms.date: 12/12/2022
5+
ms.date: 02/04/2026
66
online version: https://learn.microsoft.com/powershell/module/microsoft.powershell.management/remove-service?view=powershell-7.4&WT.mc_id=ps-gethelp
77
schema: 2.0.0
88
title: Remove-Service
@@ -152,8 +152,13 @@ This cmdlet is only available on Windows platforms.
152152
153153
To run this cmdlet, start PowerShell by using the **Run as administrator** option.
154154
155+
Like the other `*-Service` cmdlets, this command doesn't have a **ComputerName** parameter. To use
156+
this command on a remote computer, use the `Invoke-Command` to target a remote system.
157+
155158
## RELATED LINKS
156159

160+
[Invoke-Command](../Microsoft.PowerShell.Core/Invoke-Command.md)
161+
157162
[Get-Service](Get-Service.md)
158163

159164
[Restart-Service](Restart-Service.md)

reference/7.4/Microsoft.PowerShell.Management/Restart-Service.md

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
external help file: Microsoft.PowerShell.Commands.Management.dll-Help.xml
33
Locale: en-US
44
Module Name: Microsoft.PowerShell.Management
5-
ms.date: 09/03/2024
5+
ms.date: 02/04/2026
66
online version: https://learn.microsoft.com/powershell/module/microsoft.powershell.management/restart-service?view=powershell-7.4&WT.mc_id=ps-gethelp
77
schema: 2.0.0
88
title: Restart-Service
@@ -269,8 +269,13 @@ This cmdlet is only available on Windows platforms.
269269
The service names appear in the **Name** column, and the display names appear in the
270270
**DisplayName** column.
271271

272+
Beginning in PowerShell 6.0, the command no longer includes the **ComputerName** parameter. To use
273+
this command on a remote computer, use the `Invoke-Command` to target a remote system.
274+
272275
## RELATED LINKS
273276

277+
[Invoke-Command](../Microsoft.PowerShell.Core/Invoke-Command.md)
278+
274279
[Get-Service](Get-Service.md)
275280

276281
[New-Service](New-Service.md)

reference/7.4/Microsoft.PowerShell.Management/Resume-Service.md

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
external help file: Microsoft.PowerShell.Commands.Management.dll-Help.xml
33
Locale: en-US
44
Module Name: Microsoft.PowerShell.Management
5-
ms.date: 12/12/2022
5+
ms.date: 02/04/2026
66
online version: https://learn.microsoft.com/powershell/module/microsoft.powershell.management/resume-service?view=powershell-7.4&WT.mc_id=ps-gethelp
77
schema: 2.0.0
88
title: Resume-Service
@@ -247,8 +247,13 @@ This cmdlet is only available on Windows platforms.
247247
The service names appear in the **Name** column, and the display names appear in the
248248
**DisplayName** column.
249249

250+
Beginning in PowerShell 6.0, the command no longer includes the **ComputerName** parameter. To use
251+
this command on a remote computer, use the `Invoke-Command` to target a remote system.
252+
250253
## RELATED LINKS
251254

255+
[Invoke-Command](../Microsoft.PowerShell.Core/Invoke-Command.md)
256+
252257
[Get-Service](Get-Service.md)
253258

254259
[New-Service](New-Service.md)

reference/7.4/Microsoft.PowerShell.Management/Set-Service.md

Lines changed: 19 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
external help file: Microsoft.PowerShell.Commands.Management.dll-Help.xml
33
Locale: en-US
44
Module Name: Microsoft.PowerShell.Management
5-
ms.date: 03/20/2024
5+
ms.date: 02/04/2026
66
online version: https://learn.microsoft.com/powershell/module/microsoft.powershell.management/set-service?view=powershell-7.4&WT.mc_id=ps-gethelp
77
schema: 2.0.0
88
title: Set-Service
@@ -224,18 +224,19 @@ SQLWriter Automatic
224224

225225
### -Credential
226226

227-
Specifies the account used by the service as the [Service Logon Account](/windows/desktop/ad/about-service-logon-accounts).
227+
Specifies the account used by the service as the
228+
[Service Logon Account](/windows/desktop/ad/about-service-logon-accounts).
228229

229230
Type a user name, such as **User01** or **Domain01\User01**, or enter a **PSCredential** object,
230231
such as one generated by the `Get-Credential` cmdlet. If you type a user name, this cmdlet prompts
231232
you for a password.
232233

233-
Credentials are stored in a [PSCredential](/dotnet/api/system.management.automation.pscredential)
234-
object and the password is stored as a [SecureString](/dotnet/api/system.security.securestring).
234+
Credentials are stored in a [PSCredential](xref:System.Management.Automation.PSCredential) object
235+
and the password is stored as a [SecureString](xref:System.Security.SecureString).
235236

236237
> [!NOTE]
237238
> For more information about **SecureString** data protection, see
238-
> [How secure is SecureString?](/dotnet/api/system.security.securestring#how-secure-is-securestring).
239+
> [How secure is SecureString?](xref:System.Security.SecureString#how-secure-is-securestring).
239240
240241
This parameter was introduced in PowerShell 6.0.
241242

@@ -390,14 +391,14 @@ Specifies the start mode of the service.
390391

391392
The acceptable values for this parameter are as follows:
392393

393-
- **Automatic** - The service is started or was started by the operating system, at system start-up.
394+
- `Automatic` - The service is started or was started by the operating system, at system start-up.
394395
If an automatically started service depends on a manually started service, the manually started
395396
service is also started automatically at system startup.
396-
- **AutomaticDelayedStart** - Starts shortly after the system boots.
397-
- **Disabled** - The service is disabled and cannot be started by a user or application.
398-
- **InvalidValue** - Has no effect. The cmdlet does not return an error but the StartupType of the
397+
- `AutomaticDelayedStart` - Starts shortly after the system boots.
398+
- `Disabled` - The service is disabled and cannot be started by a user or application.
399+
- `InvalidValue` - Has no effect. The cmdlet does not return an error but the StartupType of the
399400
service is not changed.
400-
- **Manual** - The service is started only manually, by a user, using the Service Control Manager,
401+
- `Manual` - The service is started only manually, by a user, using the Service Control Manager,
401402
or by an application.
402403

403404
```yaml
@@ -419,9 +420,9 @@ Specifies the status for the service.
419420

420421
The acceptable values for this parameter are as follows:
421422

422-
- **Paused**. Suspends the service.
423-
- **Running**. Starts the service.
424-
- **Stopped**. Stops the service.
423+
- `Paused`. Suspends the service.
424+
- `Running`. Starts the service.
425+
- `Stopped`. Stops the service.
425426

426427
```yaml
427428
Type: System.String
@@ -507,8 +508,13 @@ a command doesn't work correctly, you might not have the required permissions.
507508
To find a service's service name or display name, use `Get-Service`. The service names are in the
508509
**Name** column and the display names are in the **DisplayName** column.
509510

511+
Beginning in PowerShell 6.0, the command no longer includes the **ComputerName** parameter. To use
512+
this command on a remote computer, use the `Invoke-Command` to target a remote system.
513+
510514
## RELATED LINKS
511515

516+
[Invoke-Command](../Microsoft.PowerShell.Core/Invoke-Command.md)
517+
512518
[Get-Service](Get-Service.md)
513519

514520
[New-Service](New-Service.md)

reference/7.4/Microsoft.PowerShell.Management/Start-Service.md

Lines changed: 11 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
external help file: Microsoft.PowerShell.Commands.Management.dll-Help.xml
33
Locale: en-US
44
Module Name: Microsoft.PowerShell.Management
5-
ms.date: 10/15/2024
5+
ms.date: 02/04/2026
66
online version: https://learn.microsoft.com/powershell/module/microsoft.powershell.management/start-service?view=powershell-7.4&WT.mc_id=ps-gethelp
77
schema: 2.0.0
88
aliases:
@@ -92,9 +92,10 @@ existing file.
9292

9393
This example shows how to start a service when the start type of the service is **Disabled**.
9494

95-
```
95+
```powershell
9696
PS> Start-Service tlntsvr
97-
Start-Service : Service 'Telnet (TlntSvr)' cannot be started due to the following error: Cannot start service TlntSvr on computer '.'.
97+
Start-Service : Service 'Telnet (TlntSvr)' cannot be started due to the following error: Cannot
98+
start service TlntSvr on computer '.'.
9899
At line:1 char:14
99100
+ Start-Service <<<< tlntsvr
100101
@@ -256,7 +257,8 @@ Accept wildcard characters: False
256257

257258
This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable,
258259
-InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose,
259-
-WarningAction, and -WarningVariable. For more information, see [about_CommonParameters](https://go.microsoft.com/fwlink/?LinkID=113216).
260+
-WarningAction, and -WarningVariable. For more information, see
261+
[about_CommonParameters](https://go.microsoft.com/fwlink/?LinkID=113216).
260262

261263
## INPUTS
262264

@@ -303,8 +305,13 @@ This cmdlet is only available on Windows platforms.
303305
work to do. When PowerShell starts a service that stops itself almost immediately, it displays the
304306
following message: `Service \<display-name\> start failed.`
305307

308+
Beginning in PowerShell 6.0, the command no longer includes the **ComputerName** parameter. To use
309+
this command on a remote computer, use the `Invoke-Command` to target a remote system.
310+
306311
## RELATED LINKS
307312

313+
[Invoke-Command](../Microsoft.PowerShell.Core/Invoke-Command.md)
314+
308315
[Get-Service](Get-Service.md)
309316

310317
[New-Service](New-Service.md)

reference/7.4/Microsoft.PowerShell.Management/Stop-Service.md

Lines changed: 9 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
external help file: Microsoft.PowerShell.Commands.Management.dll-Help.xml
33
Locale: en-US
44
Module Name: Microsoft.PowerShell.Management
5-
ms.date: 01/27/2023
5+
ms.date: 02/04/2026
66
online version: https://learn.microsoft.com/powershell/module/microsoft.powershell.management/stop-service?view=powershell-7.4&WT.mc_id=ps-gethelp
77
schema: 2.0.0
88
aliases:
@@ -51,15 +51,15 @@ to stop.
5151

5252
### Example 1: Stop a service on the local computer
5353

54-
```
54+
```powershell
5555
PS C:\> Stop-Service -Name "sysmonlog"
5656
```
5757

5858
This command stops the Performance Logs and Alerts (SysmonLog) service on the local computer.
5959

6060
### Example 2: Stop a service by using the display name
6161

62-
```
62+
```powershell
6363
PS C:\> Get-Service -DisplayName "telnet" | Stop-Service
6464
```
6565

@@ -69,7 +69,7 @@ an object that represents the Telnet service. The pipeline operator (`|`) pipes
6969

7070
### Example 3: Stop a service that has dependent services
7171

72-
```
72+
```powershell
7373
PS C:\> Get-Service -Name "iisadmin" | Format-List -Property Name, DependentServices
7474
PS C:\> Stop-Service -Name "iisadmin" -Force -Confirm
7575
```
@@ -297,8 +297,13 @@ To find the service names and display names of the services on your system, type
297297
service names appear in the **Name** column and the display names appear in the **DisplayName**
298298
column.
299299

300+
Beginning in PowerShell 6.0, the command no longer includes the **ComputerName** parameter. To use
301+
this command on a remote computer, use the `Invoke-Command` to target a remote system.
302+
300303
## RELATED LINKS
301304

305+
[Invoke-Command](../Microsoft.PowerShell.Core/Invoke-Command.md)
306+
302307
[Get-Service](Get-Service.md)
303308

304309
[New-Service](New-Service.md)

0 commit comments

Comments
 (0)