Salesforce

How to find the value of -Mpb with VSTs?

« Go Back

Information

 
TitleHow to find the value of -Mpb with VSTs?
URL NameHow-to-find-the-value-of-Mpb-with-VSTs-000061356
Article Number000176764
EnvironmentProduct: OpenEdge
Version: 11.5
OS: All supported versions
Other: _Servers VST
Question/Problem Description
How to find the value of -Mpb with VSTs?
Where is the -Mpb parameter value stored in the VST table?
How to find how many remote servers are available for each login broker via VST ?
What is the current value of -Mpb for login brokers?
How many of the "Maximum Servers Per Broker" are in use?
Steps to Reproduce
Clarifying Information
Possible use cases include:
  1. How many users have been configured to connect to each login broker (Mpb * Ma).
  2. How many users are currently connected to each login broker (_Server-CurrUsers).
  3. Are there spare maxservers (-Mn) remaining to start another secondary login broker?
Error Message
Defect Number
Enhancement Number
Cause
Resolution
Unfortunately to find the Maximum Servers Per Broker (-Mpb) database startup parameter through VST's or ABL, is not available in versions prior to OpenEdge 11.5, which is one of the reasons for the _servers._srvparam* VST change in OpenEdge 11.5.0

Since -Mpb values are not printed to the database lg file at startup for secondary login brokers, the -Mpb value could be obtained from the startup parameters that were used either in the conmgr.properties (numberofservers) or startup scripts (-Mpb). This however is not failsafe as to the parameters that were actually used in the current multi-user session. For example a different conmgr.properties could have been used with -f parameter or another database startup script was used to start the database.

An alternative approach pre-11.5 would be to run: (1 + (Mpb * Mi ) - Mi) concurrent 'dummy' client server connections to each of the LOGIN brokers, in order that all the remote servers (AUTO) are initialized at database startup. The number of remote servers can then be found by counting: _servers._server-type = "auto" and in addition the _Server-CurrUsers and _Server-PendConn in relation to the _Server-MaxUsers (-Ma).  In other words, the number of remote servers for each login broker is only realised by starting the -Mpb for each LOGIN broker.

Starting with OpenEdge 11.5, the _servers VST has additional _SrvParam* extent fields, which show the values of the Broker-specific startup parameters:
 
Maximum Port for Auto Servers (-maxport): 5000 (5649)
Minimum Port for Auto Servers (-minport): 3000 (5648)
Maximum Number of Clients Per Server (-Ma): 1 (4257)
Minimum Clients Per Server (-Mi): 1 (4259)
Message Buffer Size (-Mm): 1024 (12818)
Servers per Protocol (-Mp): 0 (12819)
Maximum Servers Per Broker (-Mpb): 0 (5647)
Network Type (-N): TCP (4263)
Pending client connection timeout (-PendConnTimeout): 20 (10357)
Service Name (-S): 9898 (4262)
Broker server group support (-ServerType): BOTH (17804)
SQL Server Max Open Cursors (-SQLCursors): 0 (10028)
SQL Server Stack Size (-SQLStack): 0 (10026)
SQL Server Statement Cache Size (-SQLStmtCache): 0 (10027)
Size [1K byte units] of SQL Server temp table buffer (-SQLTempStoreBuff): 0 (10029)
Size [1K byte units] of SQL Server temp table disk storage (-SQLTempStoreDisk): 0 (10030)
Size [1K byte units] of SQL Server temp table data page (-SQLTempStorePageSize): 0 (10031)

As practical example, the following code example:
  • Will show the -Mpb value of each login broker and the remote servers that login broker has spawned currently (if any). 
  • If the _servers._srvparam-value of -Mpb is 0, this means that the Maximum Servers Per Broker (-Mpb) parameter was not set when that login broker was started and is therefore the value of the Maximum Number of Servers (-Mn) on the primary login broker, which can be found with the new 11.5 _DbParams VST ( or the _Startup VST in previous versions).
DEFINE VARIABLE iParamCount AS INTEGER NO-UNDO.
DEFINE BUFFER autoservers FOR _servers.

FOR EACH _servers WHERE _Server-Pid = _Server-Broker-Pid:
    DO iParamCount = 1 TO EXTENT( _servers._srvparam-name):
        IF _srvparam-name[iParamCount] = "-Mpb" THEN 
            DISPLAY 
            _servers._server-type
            _servers._server-num
            _servers._Server-Pid
            _servers._Server-Broker-Pid
            _servers._server-portnum
            _servers._srvparam-name[iParamCount]
            _servers._srvparam-value[iParamCount].
    END.

    FOR EACH autoservers WHERE 
        autoservers._server-type = "auto" AND 
        autoservers._Server-Broker-Pid = _servers._Server-Broker-Pid:
        DISPLAY 
            autoservers._server-type 
            autoservers._server-num 
            autoservers._Server-Pid 
            autoservers._Server-Broker-Pid
            autoservers._server-portnum 
            autoservers._Server-MaxUsers 
            autoservers._Server-CurrUsers 
            autoservers._Server-PENDConn.
    END.
END.

 
Workaround
Notes
Keyword Phrase
Last Modified Date5/2/2017 8:51 AM

Powered by