Remove-NAVServerSession
Closes the specified client connection to a Business Central Server instance.
Syntax
Remove-NAVServerSession
[-Tenant <TenantId>]
-SessionId <Int32>
[-RetryMode <RetryMode>]
[-NetworkTimeout <TimeSpan>]
[-MaxRetries <Int32>]
[-DelayBetweenRetries <TimeSpan>]
[-ServerInstance] <String>
[-Force]
[-ProgressAction <ActionPreference>]
[-WhatIf]
[-Confirm]
[<CommonParameters>]
Description
Use the Remove-NAVServerSession cmdlet to close a client connection, as identified by the SessionId parameter. You can use the Get-NAVServerSession cmdlet to obtain information about current Business Central sessions.
Examples
EXAMPLE 1
Remove-NAVServerSession -ServerInstance BC -Tenant default -SessionId 11
This example closes the session with Session ID 11 in the on the BC instance.
Parameters
-Confirm
Prompts you for confirmation before executing the command.
Type: | SwitchParameter |
Aliases: | cf |
Position: | Named |
Default value: | None |
Required: | False |
Accept pipeline input: | False |
Accept wildcard characters: | False |
-DelayBetweenRetries
Specifies the delay between retries.
Type: | TimeSpan |
Position: | Named |
Default value: | None |
Required: | False |
Accept pipeline input: | False |
Accept wildcard characters: | False |
-Force
Forces the command to run without asking for user confirmation.
Type: | SwitchParameter |
Position: | Named |
Default value: | None |
Required: | False |
Accept pipeline input: | False |
Accept wildcard characters: | False |
-MaxRetries
Specifies the maximum number of retries for the operation in case of failure.
Type: | Int32 |
Position: | Named |
Default value: | None |
Required: | False |
Accept pipeline input: | False |
Accept wildcard characters: | False |
-NetworkTimeout
Specifies the network timeout of the operation.
Type: | TimeSpan |
Position: | Named |
Default value: | None |
Required: | False |
Accept pipeline input: | False |
Accept wildcard characters: | False |
-ProgressAction
A common PowerShell parameter that determines how PowerShell responds to progress updates generated by a script, cmdlet, or provider. Learn more.
Type: | ActionPreference |
Aliases: | proga |
Position: | Named |
Default value: | None |
Required: | False |
Accept pipeline input: | False |
Accept wildcard characters: | False |
-RetryMode
Specifies the retry mode when the service instance is not available.
Possible values: Fixed, Exponential
Type: | RetryMode |
Accepted values: | Fixed, Exponential |
Position: | Named |
Default value: | None |
Required: | False |
Accept pipeline input: | False |
Accept wildcard characters: | False |
-ServerInstance
Specifies the name of a Business Central Server instance, for example, BC or myinstance. You can specify either the full name of an instance, such as MicrosoftDynamicsNavServer$myinstance or the short name such as myinstance.
Type: | String |
Position: | 0 |
Default value: | None |
Required: | True |
Accept pipeline input: | True |
Accept wildcard characters: | False |
-SessionId
A number that identifies a Business Central Server session. You can obtain a list of current sessions using the Get-NAVServerSession cmdlet.
Type: | Int32 |
Position: | Named |
Default value: | None |
Required: | True |
Accept pipeline input: | False |
Accept wildcard characters: | False |
-Tenant
Specifies the ID of the tenant you want to remove the connection from, such as Tenant1. This parameter is required unless the specified service instance is not configured to run multiple tenants.
Type: | TenantId |
Aliases: | Id |
Position: | Named |
Default value: | None |
Required: | False |
Accept pipeline input: | True |
Accept wildcard characters: | False |
-WhatIf
Describes what would happen if you executed the command without actually executing the command.
Type: | SwitchParameter |
Aliases: | wi |
Position: | Named |
Default value: | None |
Required: | False |
Accept pipeline input: | False |
Accept wildcard characters: | False |
Inputs
System.String
You can pipe a string that contains a Business Central Server instance name to the cmdlet.
Outputs
None