Please ensure Javascript is enabled for purposes of website accessibility
Powered by Zoomin Software. For more details please contactZoomin

PI Powershell

SetPIBufferingControlState Class

  • Last UpdatedDec 15, 2025
  • 4 minute read
SetPIBufferingControlState Class

Set the PI Buffer control state

The Set-PIBufferingControlState cmdlet sets the buffering state on the local instance of PI Buffer Subsystem for a single buffered server. In order to use this cmdlet, the running user must be a member of either "PI Buffering Administrators" or "Administrators" local groups. This cmdlet can only be directly run against the local instance of PI Buffer Subsystem. The user will be prompted for confirmation before removing the buffered server, this can be overridden using the -Force parameter.

This cmdlet is analogous to pibufss.exe -bc ... options

This cmdlet can be run against remote PI Buffer Subsystems by leveraging PowerShell Remoting.

Inheritance Hierarchy

SystemObject
  InternalCommand
    Cmdlet
      PSCmdlet
        OSIsoft.PowerShellOSICmdletBase
          OSIsoft.PowerShellSetPIBufferingControlState

Namespace:  OSIsoft.PowerShell
Assembly:  OSIsoft.PowerShell (in OSIsoft.PowerShell.dll) Version: 3.1.1.0 (3.1.1.466)

Syntax

[CmdletAttribute("Set", "PIBufferingControlState", SupportsShouldProcess = true)]
public class SetPIBufferingControlState : OSICmdletBase
<CmdletAttribute("Set", "PIBufferingControlState", SupportsShouldProcess := true)>
Public Class SetPIBufferingControlState
	Inherits OSICmdletBase

Dim instance As SetPIBufferingControlState
[CmdletAttribute(L"Set", L"PIBufferingControlState", SupportsShouldProcess = true)]
public ref class SetPIBufferingControlState : public OSICmdletBase
[<CmdletAttribute("Set", "PIBufferingControlState", SupportsShouldProcess = true)>]
type SetPIBufferingControlState =  
    class
        inherit OSICmdletBase
    end

The SetPIBufferingControlState type exposes the following members.

Constructors

  NameDescription
Public method
SetPIBufferingControlState

Properties

  NameDescription
Public property
ControlCommand

Buffer control state to set for the buffered server

Public property
Force

Force the removal of the buffered server without prompting user for confirmation

Public property
LogicalServerName

Logical server name. This is the PI Collective name for collectives, or the server name for standalone PI Data Archive servers

Public property
PhysicalServerName

Physical server name. This is the member node name for PI Collectives, or the server name for standalone PI Data Archive servers. If not specified for a PI Collective, all member sessions will be included. This parameter is not required for a standalone PI Data Archive server.

Public property
Timeout

Timeout to use when setting the buffer control state. EX: "00:01:00" is 1 minute. If not specified, the default timeout is 1 minute.

Examples

Set-PIBufferingControlState -ControlCommand StopBuffering -LogicalServerName PISRV-Collective -PhysicalServerName PISRV-2

Sets the buffer state of "StopBuffering" on the "PISRV-2" (which is a member of "PISRV-Collective") on the local PI Buffer Subsystem instance. The user is prompted for confirmation before the server is removed. The default timeout of 1 minute is used.

Examples

Set-PIBufferingControlState -ControlCommand StartBuffering -LogicalServerName PISRV-Collective -PhysicalServerName PISRV-2

Sets the buffer state of "StartBuffering" on the "PISRV-2" (which is a member of "PISRV-Collective") on the local PI Buffer Subsystem instance. The user is prompted for confirmation before the server is removed. The default timeout of 1 minute is used.

Examples

Invoke-Command -ComputerName PIINT1 -ScriptBlock { Set-PIBufferingControlState -ControlCommand StopBuffering -LogicalServerName PISRV-Collective -PhysicalServerName PISRV-2 }

Sets the buffer state of "StopBuffering" on the "PISRV-2" (which is a member of "PISRV-Collective") on the local PI Buffer Subsystem instance. The user is prompted for confirmation before the server is removed. The default timeout of 1 minute is used.

Note the use of Invoke-Command. Failure of this example to execute properly is likely not an issue with Set-PIBufferingControlState, but with the network or PS connection to the remote computer. Note that the OSIsoft.PowerShell module must be installed on the remote computer as well for this to work.

See Also

TitleResults for “How to create a CRG?”Also Available in