Chapter Contents

Previous

Next
SAS/SHARE User's Guide

UNIX: Creating the Server Environment

You can invoke the SAS System and start a server session automatically by using the following command syntax:

sas sas-input-file server-config-file

where

sas-input-file
is the name of the file that contains the SAS statements to start a server. For information about the content of this file, see Starting and Managing a SAS/SHARE Server.

server-config-file
is the file that contains the system option settings for the server's SAS session. For information about the SAS system options, see the next section.

Include the SAS command in a start-up script so that the server is created at machine start-up. Doing so ensures that the server is running whenever a client needs it.


Setting SAS System Performance Options

These options affect the operation of the server.

BUFNO=n | nK | nM | nG | MAX | MIN | hexX
specifies the number of buffers to use for SAS data sets. The default is 1.

For SAS/SHARE, setting the value of the BUFNO= option too high may hurt performance by using too much memory because SAS/SHARE may be accessing multiple files at once.

The maximum number of buffers you can allocate is determined by the amount of memory available. See All Hosts: Setting SAS System Performance Options for more information about the BUFNO= option.

BUFSIZE=n | nK | nM | nG | MAX | MIN | hexX
specifies the permanent buffer size for an output SAS data set. Under UNIX, the default is 0.

For SAS/SHARE, setting the value of the BUFSIZE= option too high may hurt performance by using too much memory because SAS/SHARE may be accessing multiple files at once.

If you use the default value 0 when you create a SAS data set, the V7 engine calculates a buffer size to optimize CPU and I/O use. This size is the smallest multiple of 8K that can hold 80 observations but is not larger than 64K.

See All Hosts: Setting SAS System Performance Options for more information about the BUFSIZE= option.

FILELOCKS NONE | FAIL | CONTINUE
specifies whether SAS locks others out of a SAS file before opening it for update or output. This prevents other SAS sessions from opening it for update or output at the same time. Because a server's SAS session is no different from any other SAS session, it is recommended that you specify FILELOCKS FAIL in all SAS sessions to prevent a server and any other SAS session from simultaneously opening the same SAS file for update or output. The default value is FAIL.

The values for FILELOCKS are

NONE
specifies that no file locking occurs. All protection from shared update access to SAS files is removed. This is the default.

FAIL
specifies that file locking is in effect. If a file cannot be locked, an attempt to open it fails.

CONTINUE
specifies that file locking is in effect. If a file is already locked by someone else, an attempt to open it fails. If the file cannot be locked for some other reason, the file is opened and a warning message is sent to the log.

For file locking to work on some hosts, you must have the host's file locking service running. This usually involves having a lock daemon (such as lockd) and a stat daemon (such as statd) running. You may also need to execute other commands. For details, see the manual pages or system administration instructions.

In addition, if you are working with NFS-mounted files, the file locking service must be running both on your client and on the server.

MEMSIZE=n | nK | nM | nG | MAX | MIN | hexX
specifies a limit on the total amount of memory that SAS uses at any one time. Under UNIX, the default is 32M.

The server should be allowed a large amount of memory in order to accommodate the needs of all its users. The number of concurrent SAS files open by server users and the number and size of I/O buffers for each SAS file have a direct impact on the amount of memory required by the server. You should be aware that, in some cases, SAS terminates abnormally when it is unable to satisfy a memory request.

The MEMSIZE= option takes the following values:

n
specifies the amount of memory in bytes.

nK
specifies the amount of memory in 1-kilobyte multiples.

nM
specifies the amount of memory in 1-megabyte multiples.

nG
specifies the amount of memory in 1-gigabyte multiples.

MIN
specifies 0, which means that there is no limit.

MAX
specifies 2,147,483,647. On 64-bit systems, MAX is 9,007,199,254,740,992.

Note:   The default may be larger on some machines.  [cautionend]

hexX
specifies the amount of memory in a hexadecimal number that must be followed by an X.

UNBUFLOG
specifies that the SAS log file (which was specified in the ALTLOG= option) is opened so that other processes can read it, and that each line written to the log is then immediately transferred to disk. This option enables you to examine the server SAS log while the server is running. The UNBUFLOG option must be specified in a SAS command or in a SAS configuration file.

Note:   The overhead that is incurred by the UNBUFLOG option may degrade the performance of a busy server.   [cautionend]

A typical SAS configuration file follows:

-bufno 1
-bufsize 0
-filelocks fail
-memsize 32M
-unbuflog

See SAS Companion for UNIX Environments for more information about these SAS system options.


Chapter Contents

Previous

Next

Top of Page

Copyright 1999 by SAS Institute Inc., Cary, NC, USA. All rights reserved.