Previous Page | Next Page

Using the SAS RFC Server

Using the SAS RFC Server on UNIX

In a UNIX environment, the SAS RFC server for SAP is installed in the !SASROOT/saspgm/dbi/bin directory. You must add this directory to the PATH environment variable and add the location of the shared libraries to the appropriate environment variable. For more detailed information about how to set up the environment variables, see Installation Instructions-- SAS/ACCESS Interface to R/3.

To start the SAS RFC server in a UNIX environment, use the following command

sasrfc_server [-d 0|1|2|3|4|5|6] [-n name] [-p port] [-w workdir] [-N namespace] 
     [-V variant] [-help] [-c dialog_compat_port] 
     [-b "-p port-number -V variant_name -R report_name"] 
     [-B number_of_bytes]

Optional parameters are enclosed in brackets [ ].

To stop the SAS RFC server in a UNIX environment, use the following command:

sasrfc_server [-k] [-p port]

Optional parameters are enclosed in brackets [ ].

The options for the SAS RFC server command for UNIX are as follows:

-d n

specifies whether to run the server as a daemon process or as an application and specifies the diagnostic level.

The server is run as a daemon process when you specify -dn where n=0 or when you do not specify the -dn option. After successful initialization, all messages are routed to syslog.

When you specify the -dn option where n= any number between 1 and 6, the program runs as an application and messages are routed to standard error. Higher diagnostic levels route more detailed messages to standard error.

-k

stops the service.

-n name

specifies the name of the service. This option is used to distinguish multiple daemon processes. For example, a test service might be started as -n test.

-p port

identifies the port number on which the service listens. The default port number is 6999.

-w workdir

specifies the working directory. For example, if your working directory is named tmp, specify the option as follows: -w /tmp.

-N namespace

specifies the namespace for ABAP functions and programs that are used by SAS. The default value is /SAS/. If the ABAP programs are installed in the customer namespace rather than in the /SAS/ namespace, then this parameter identifies where the ABAP programs are installed.

-V variant

specifies the report variant that is assigned to this server. You must assign a report variant for each SAS RFC Server that accesses an SAP application server in batch mode. The variant parameter G_DEST specifies a unique destination to call back to the SAS RFC Server.

-help

specifies that you want to display command line Help.

-c
dialog_compat
_port

identifies the option that, when specified, runs the SAS RFC Server in V8 compatibility mode on the port indicated by the dialog_compat_port parameter. The port number must be different than the one used for the V9 requests. If the -c option is omitted, no dialog compatibility will be available.

-b
"-p port_number
-V variant_name
-R report_name"

enables batch compatibility so that you can process V8 ACCR3 requests while you are using a V9 SAS RFC server. You must use the double quotation marks in the batch compatibility option in order to separate the batch compatibility parameters from the V9 parameters that use the same syntax.

The port parameter is optional. If omitted, the port number defaults to 6999.

The report variant parameter is required and must be a valid variant of the report.

The report parameter is optional and would normally be omitted. If the report parameter is omitted, then report_name defaults to /SAS/ZSASV8COMPAT.

The values in port_number, variant_name, and report_name must be different from the values used by V9 and different from the values used by dialog compatibility.

-B number_of_bytes

sets the minimum buffer size for data transfers in batch and dialog modes. The number of bytes should be greater than 10000 and no more than 8 digits, or it will be ignored. If the -B option is omitted, the default is 10000 bytes.

In batch mode, if you specify a value for the G_BUFMAX parameter that is less than the value of -B, then the -B value is used.

For example, to start the SAS RFC server as a daemon process with the name of test on port number 6991, use the following command:

sasrfc_server -n test -p 6991

The following example command shows how to display command line Help:

sasrfc_server

To start the SAS RFC server with debug level 4 on port number 6991, use the following command:

sasrfc_server -d 4 -p 6991

To stop a SAS RFC server that is running on port number 6991, use the following command:

sasrfc_server -k -p 6991

Previous Page | Next Page | Top of Page