CHAPTER 3: Server Configuration File




3.1 Introduction

Before accessing or starting any Empress Distributed Server, all machines that are involved with the Empress Distributed Server (including all clients and servers) must have a Server Configuration File. The purpose of this file is to inform the clients which Empress Distributed Servers they can access. The Server Configuration File also provides the clients and servers with essential communication parameters.

The Server Configuration File must be set up at both client and server machines. The information in this file must be identical on both types of machines. The name of the host on which the server resides, the number of server sub-processes, the owner of the server and retry and timeout values for communications with the server are provided to the client and server through this file.

Users may set up multiple Server Configuration Files by using the Empress environment variable MSSERVERCONFIGFILE which indicates the location of the particular configuration file that is to be used.



3.2 Set Up

The format of the Server Configuration File is as follows:

MSSERVERNAME=xxx
   MSSERVERHOSTNAME=xxx
   MSSERVERNPROCS=nnn
   MSSERVERADMINISTRATOR=xxx
   MSSERVERSECURITY
      MSSERVERACCEPTHOST=xxx xxx
      MSSERVERREJECTHOST=xxx xxx
      MSSERVERDATABASE=XXX
   MSSERVERSECURITYEND
   MSSERVERNETTYPE=INET_SOCKET
      MSINETPORT=nnnn
      MSINETREPLYTIMEOUT=nnn
      MSINETREPLYRETRY=nnn
      MSINETMESSAGETIMEOUT=nnn
      MSINETMESSAGERETRY=nnn
      MSINETPACKETTIMEOUT=nnn
      MSINETPACKETRETRY=nnn
      MSINETMAXPACKETSIZE=nnnnn
   MSSERVERNETEND
MSSERVEREND
MSSERVERNAME=yyy
   MSSERVERHOSTNAME=yyy
   MSSERVERNPROCS=nnn
   MSSERVERADMINISTRATOR=yyy
   MSSERVERSECURITY
      MSSERVERACCEPTHOST=yyy yyy
      MSSERVERREJECTHOST=yyy yyy
   MSSERVERSECURITYEND
   MSSERVERNETTYPE=INET_SOCKET
      MSINETPORT=nnnn
      MSINETREPLYTIMEOUT=nnn
      MSINETREPLYRETRY=nnn
      MSINETMESSAGETIMEOUT=nnn
      MSINETMESSAGERETRY=nnn
      MSINETPACKETTIMEOUT=nnn
      MSINETPACKETRETRY=nnn
      MSINETMAXPACKETSIZE=nnnnn
   MSSERVERNETEND
MSSERVEREND
   .
   .
   .

A Server Configuration File is made up of several definition blocks. Each block starts with MSSERVERNAME and ends with MSSERVEREND.

MSSERVERNAME is the name of the server. This can be any name that the user desires.

MSSERVERHOSTNAME is the name of the machine on which the server resides. This name must be known by the local machine's operating system.

MSSERVERNPROCS is the number of sub-processes for this server. Database requests are distributed among these processes to balance the load.

MSSERVERADMINISTRATOR is the name of the server administrator. After the server has been started, only the server administrator or the user who started the server may perform certain server administrative functions such as shutdown or client removal.

Note

Between the MSSERVERSECURITY and MSSERVERSECURITYEND is the server security block. These entries are optional. MSSERVERACCEPTHOST specifies the host and optionally followed by the user names to be accepted by the server. MSSERVERREJECTHOST specifies the host and optionally followed by the user names to be rejected by the server.

MSSERVERDATABASE specifies the database that the server can access. if this variable is not set, the default will be any database. You can have multiple entries of MSSERVERACCEPTHOST, MSSERVERREJECTHOST and MSSERVERDATABASE.

Between MSSERVERNETTYPE and MSSERVERNETEND is the network descriptor block. Currently only one network descriptor block is allowed per server definition block.

MSSERVERNETTYPE is the network access type. At the moment, the Empress Distributed Server is only capable of using Internet sockets to communicate with the network. Therefore, INET_SOCKET is the only acceptable entry.

MSINETPORT is the Internet port number which the server will recognize. This entry must be between 5001 and 65534. No two active servers on the same machine can have the same entry.

MSINETREPLYTIMEOUT and MSINETREPLYRETRY are the timeout value and the number of retries, respectively, for the client awaiting a high-level response.

MSINETMESSAGETIMEOUT and MSINETMESSAGERETRY are the timeout value and number of retries, respectively, for the client's message handler awaiting acknowledgement.

MSINETPACKETTIMEOUT and MSINETPACKETRETRY are the timeout value and number of retries, respectively, for the client's packet handler awaiting acknowledgement.

Note

The timeout values are in seconds. Any or all of these timeout and entries are optional. Setting too short a reply or message timeout can lead to unnecessary request re-transmissions when the request or reply is large. This may cause serious performance degradation.

Note

MSINETMAXPACKETSIZE is the maximum size of the packets transported by the server. This entry is in bytes and is optional. If omitted, the Empress Distributed Server will query the system and set an appropriate default value.

MSSERVERNETEND is the end marker for the network descriptor block.

MSSERVEREND is the end marker for the server definition block.

Warning

Proceed with caution when changing the default values.

3.2.1 Examples

Using the same examples for the Global Data Dictionary, here are the corresponding Server Configuration files for each machine:

3.2.1.1 Client/Server Configuration

Figure 3-1: Client Server

Server: slave

MSSERVERNAME=slave
   MSSERVERHOSTNAME=slave
   MSSERVERNPROCS=1
   MSSERVERADMINISTRATOR=empress
   MSSERVERNETTYPE=INET_SOCKET
      MSINETPORT=8450
      MSINETREPLYTIMEOUT=60
      MSINETREPLYRETRY=4
      MSINETMESSAGETIMEOUT=30
      MSINETMESSAGERETRY=4
      MSINETPACKETTIMEOUT=5
      MSINETPACKETRETRY=4
   MSSERVERNETEND
MSSERVEREND

Client:

MSSERVERNAME=slave
   MSSERVERHOSTNAME=slave
   MSSERVERNPROCS=1
   MSSERVERADMINISTRATOR=empress
   MSSERVERNETTYPE=INET_SOCKET
      MSINETPORT=8450
      MSINETREPLYTIMEOUT=60
      MSINETREPLYRETRY=4
      MSINETMESSAGETIMEOUT=30
      MSINETMESSAGERETRY=4
      MSINETPACKETTIMEOUT=5
      MSINETPACKETRETRY=4
   MSSERVERNETEND
MSSERVEREND

3.2.1.2. Multi-Server Configuration

Figure 3-2: Multi-Server

Server: slave1

MSSERVERNAME=slave1
   MSSERVERHOSTNAME=slave1
   MSSERVERNPROCS=1
   MSSERVERADMINISTRATOR=empress
   MSSERVERNETTYPE=INET_SOCKET
      MSINETPORT=8450
      MSINETREPLYTIMEOUT=60
      MSINETREPLYRETRY=4
      MSINETMESSAGETIMEOUT=30
      MSINETMESSAGERETRY=4
      MSINETPACKETTIMEOUT=5
      MSINETPACKETRETRY=4
   MSSERVERNETEND
MSSERVEREND

Server: slave2

MSSERVERNAME=slave2
   MSSERVERHOSTNAME=slave2
   MSSERVERNPROCS=1
   MSSERVERADMINISTRATOR=empress
   MSSERVERNETTYPE=INET_SOCKET
      MSINETPORT=8451
      MSINETREPLYTIMEOUT=60
      MSINETREPLYRETRY=4
      MSINETMESSAGETIMEOUT=30
      MSINETMESSAGERETRY=4
      MSINETPACKETTIMEOUT=5
      MSINETPACKETRETRY=4
   MSSERVERNETEND
MSSERVEREND

Client:

MSSERVERNAME=slave1
   MSSERVERHOSTNAME=slave1
   MSSERVERNPROCS=1
   MSSERVERADMINISTRATOR=empress
   MSSERVERNETTYPE=INET_SOCKET
      MSINETPORT=8450
      MSINETREPLYTIMEOUT=60
      MSINETREPLYRETRY=4
      MSINETMESSAGETIMEOUT=30
      MSINETMESSAGERETRY=4
      MSINETPACKETTIMEOUT=5
      MSINETPACKETRETRY=4
   MSSERVERNETEND
MSSERVEREND
MSSERVERNAME=slave2
   MSSERVERHOSTNAME=slave2
   MSSERVERNPROCS=1
   MSSERVERADMINISTRATOR=empress
   MSSERVERNETTYPE=INET_SOCKET
      MSINETPORT=8451
      MSINETREPLYTIMEOUT=60
      MSINETREPLYRETRY=4
      MSINETMESSAGETIMEOUT=30
      MSINETMESSAGERETRY=4
      MSINETPACKETTIMEOUT=5
      MSINETPACKETRETRY=4
   MSSERVERNETEND
MSSERVEREND

3.2.1.3 Fully Distributed Configuration

Figure 3-3: Fully Distributed

Server: copper

MSSERVERNAME=copper
   MSSERVERHOSTNAME=copper
   MSSERVERNPROCS=1
   MSSERVERADMINISTRATOR=empress
   MSSERVERNETTYPE=INET_SOCKET
      MSINETPORT=8450
      MSINETREPLYTIMEOUT=60
      MSINETREPLYRETRY=4
      MSINETMESSAGETIMEOUT=30
      MSINETMESSAGERETRY=4
      MSINETPACKETTIMEOUT=5
      MSINETPACKETRETRY=4
   MSSERVERNETEND
MSSERVEREND
MSSERVERNAME=gold
   MSSERVERHOSTNAME=gold
   MSSERVERNPROCS=1
   MSSERVERADMINISTRATOR=empress
   MSSERVERNETTYPE=INET_SOCKET
      MSINETPORT=8451
      MSINETREPLYTIMEOUT=60
      MSINETREPLYRETRY=4
      MSINETMESSAGETIMEOUT=30
      MSINETMESSAGERETRY=4
      MSINETPACKETTIMEOUT=5
      MSINETPACKETRETRY=4
   MSSERVERNETEND
MSSERVEREND

Server: Gold

MSSERVERNAME=copper
   MSSERVERHOSTNAME=copper
   MSSERVERNPROCS=1
   MSSERVERADMINISTRATOR=empress
   MSSERVERNETTYPE=INET_SOCKET
      MSINETPORT=8450
      MSINETREPLYTIMEOUT=60
      MSINETREPLYRETRY=4
      MSINETMESSAGETIMEOUT=30
      MSINETMESSAGERETRY=4
      MSINETPACKETTIMEOUT=5
      MSINETPACKETRETRY=4
   MSSERVERNETEND
MSSERVEREND
MSSERVERNAME=gold
   MSSERVERHOSTNAME=gold
   MSSERVERNPROCS=1
   MSSERVERADMINISTRATOR=empress
   MSSERVERNETTYPE=INET_SOCKET
      MSINETPORT=8451
      MSINETREPLYTIMEOUT=60
      MSINETREPLYRETRY=4
      MSINETMESSAGETIMEOUT=3
      MSINETMESSAGERETRY=4
      MSINETPACKETTIMEOUT=5
      MSINETPACKETRETRY=4
   MSSERVERNETEND
MSSERVEREND