Chapter Contents

Previous

Next
SAS/SHARE User's Guide

OS/2: Creating the Server Environment

You must perform the following steps to create the server environment on an OS/2 host:

  1. Set SAS system performance options.

  2. Create a command file for the server.

  3. Run the command file for the server.


Setting SAS System Performance Options

The following SAS system options can be used to tune server performance:

BUFNO=n | nK | nM | nG | MAX | MIN | hexX
specifies the number of buffers to use for SAS data sets. There is no maximum number of buffers you can allocate, except for memory constraints. The default is 3.

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 one time.

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

BUFSIZE=n | nK
specifies the permanent buffer size for an output SAS data set. The value can range from 512 bytes through 1 megabyte. You may want to vary the value of the BUFSIZE= option if you are trying to maximize the number of observations per page.

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 one time.

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 3
-bufsize 0
-unbuflog

See SAS Companion for the OS/2 Environment for more information about these SAS system options.


Creating a Command File for the Server

The command file performs process setup and invokes SAS, which runs a SAS program that contains the setup that is needed for the server environment and then runs the PROC SERVER statement. See Starting and Managing a SAS/SHARE Server for details about how to write a SAS program to start a server.

Use REXX to write a command file. The command file is appended with .CMD. A typical command file follows:

/* REXX exec */
string=stream('c:\server.dmp','c','query exists')
if (string=") then
   do;
     "sas runshare $gpf dump -set sasdump 
      c:\server.dmp"
   end;
else
   do;
     say "c:\server.dmp exists -  "
     "you must re-name or delete it before 
     starting server"
   end;

This command file looks for an existing dump file from a previous server execution before it invokes the SAS System. Then, the REXX EXEC invokes SAS to execute the RUNSHARE.SAS program. In addition, there may be other tasks that you need to perform before you start the server.


Running the Command File for the Server

Perform the following steps to verify that the server runs:

  1. Run the server on the workstation where the SAS files to be shared are stored.

    Treat the server workstation as you would a network file server machine by limiting the down time and competing work on the workstation.

  2. Create an object in the start-up folder of the workstation where the server runs.

    This causes the command file for the server to be executed when the OS/2 system is started. It also ensures that the server is available to the first client that attempts access. For more information about creating an object in the start-up folder, see the SAS documentation for your operating environment.

Note:   Be sure that your command file does not invoke the SAS System in interactive mode.  [cautionend]


Chapter Contents

Previous

Next

Top of Page

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