• 検索結果がありません。

Configuration Files

ドキュメント内 WPS Workbench User Guide (ページ 105-108)

Configuration files are files that contain system options that control the initial WPS environment.

Configuration files are used during WPS initialisation when WPS is run from the command line, and when the Workbench is being used.

A configuration file is a simple text file that you can open in a text editor to add, remove or change system options to suit your needs.

There is a base configuration file that is included with the WPS installation, called wps.cfg and it is located in the directory where WPS is installed. It is recommended that this file be left untouched and one of the override mechanisms below be used if any modifications need to be made.

A number of configuration files can be processed during WPS initialisation, each of which may set some of the same options. If an option is set in more than one place the last one processed will have precedence.

Options set on the command line, or options set in the Startup Options configuration panel for a server will override any settings that are set in the configuration files.

WPS Initialisation Procedure for Windows

When WPS is invoked, the following initialisation procedure occurs:

1. WPS checks the operating system environment variable WPS_SYS_CONFIG. If it exists then the specified configuration file is processed first. The processing of this file doesn't affect whether the default configuration files are loaded.

2. Any files specified via the -config option on the command line, or specified in the Startup Options configuration panel for a server will be processed next. If any configuration files are specified in -config options in this way, then the default configuration files listed below are not loaded, and instead the process jumps straight to the processing of WPS_USER_CONFIG (step 4). Note that overriding the default configuration file processing, specifically the loading of the wps.cfg file in the WPS installation directory must be done with care. There are many required options in the base wps.cfg file. If you choose to use the -config option it is recommended that you either take a copy of the base file

and modify it to suit, or you make sure to include the base wps.cfg file in your customer configuration file and then override any settings you need, for example:

-set wpshome 'somewhere' -config !wpshome/wps.cfg

/* And now set any options you want */

3. Then WPS checks for a number of default configuration files. These are processed in the following order:

a. wps.cfg in the WPS installation directory b. My Documents/My WPS Files/.wps.cfg c. My Documents/My WPS Files/wps.cfg d. My Documents/My WPS Files/.wpsv3.cfg e. My Documents/My WPS Files/wpsv3.cfg f. wps.cfg in the current directory

g. wpsv3.cfg in the current directory

4. WPS checks for the environment variable WPS_USER_CONFIG. If it exists then the specified configuration file is processed.

5. WPS checks for the environment variable WPS_OPTIONS. If it exists, then any options that are specified in WPS_OPTIONS are processed. The syntax of this environment variable is the same as if the options are specified on the command line.

6. Any options specified on the command line are then processed.

WPS Initialisation Procedure for UNIX platforms

When WPS is invoked, the following initialisation procedure occurs.

1. All configuration files specified via -config options on the command line or in the Startup Options configuration panel for a server are processed first. If any configuration files are loaded in this way, then the list of default configuration variables in step 4 are not loaded.

2. WPS then checks the WPS_OPTIONS and WPS_V3OPTIONS environment variables for -config options and processes those files. If any configuration files are loaded in this way, then the list of default configuration variables in step 4 are not loaded. Note that this step is skipped if the -NOCONFIG option is specified on the command line.

3. WPS then checks the following environment variables, and if they exist loads the configuration files named by them (the environment variables are expected to name a single configuration file each):

a. WPS_CONFIG b. WPS_V3CONFIG

If any configuration files are loaded in this way, then the list of default configuration variables in step 4 are not loaded. Note that this step is skipped if the -NOCONFIG option is specified on the command line.

4. Assuming that no configuration files have yet been loaded, the list of default configuration files is loaded. The following files are loaded in the order shown:

• wps.cfg in the WPS installation directory

• wps_local.cfg in the WPS installation directory. This file can be edited to provide site specific overrides of various options.

• .wps.cfg in your home directory

• wps.cfg in your home directory

• .wpsv3.cfg in your home directory

• wpsv3.cfg in your home directory

• wps.cfg in the current directory

• wpsv3.cfg in the current directory

5. WPS checks for the environment variable WPS_OPTIONS. If it exists, then any options that are specified in WPS_OPTIONS are processed. The syntax of this environment variable is the same as if the options are specified on the command line.

6. WPS checks for the environment variable WPS_V3OPTIONS and processes it in the same way.

7. Any options specified on the command line are then processed.

There are also so-called "restricted" configuration files that will always be processed. Any options in these files cannot be changed by any other method. The files are based on the user's userid and groupid.

For example if the user is <user> and the group is <group> then the following configuration files will be processed:

• misc/rstropts/rwps.cfg in the WPS installation directory

• misc/rstropts/groups/<group>_rwps.cfg in the WPS installation directory

• misc/rstropts/users/<user>_rwps.cfg in the WPS installation directory Getting Information About the Startup Procedure

It is possible to check which config files have been processed by checking the CONFIG system option.

You can do this by invoking a simple PROC OPTIONS statement as follows:

proc options option=CONFIG;

run;

When using the Workbench you can get the information in the following way. Ensure that you have the WPS Server Explorer View open and right click on the WPS Server icon and choose Properties from the pop-up menu. In the Properties dialog, choose System Options and you will see the values of all system options for the server. Scrolling down to CONFIG will show all the configuration files that were used.

You can also set the VERBOSE system option on the command line, or in the Startup Options configuration panel for a server and WPS will generate information in the normal log output indicating which configuration files were processed and which system options were set.

To set the VERBOSE option in the workbench, take the following steps. From the Startup Options screen it is possible to change the values that System Options will be set to when the Workbench is loaded.

For example:

1. Open the Properties for the relevant server.

2. Select Startup Options from the list of available pages on the left hand side.

3. Click Add....

4. Click the Select... button (next to the Name text box).

5. Scroll down the list and find the VERBOSE option and click OK.

6. Click on the dropdown box next to Value and change the value to VERBOSE (or NOVERBOSE to turn the option off).

7. Click OK.

8. Click OK once again in the properties dialog.

9. A message box will appear stating that the change will not occur until the server is restarted. Click Yes to perform the restart.

10.Check the log (see Working with Logs) and the change to the VERBOSE option means that the processed configuration files and the system options will be shown there when the Workbench starts.

ドキュメント内 WPS Workbench User Guide (ページ 105-108)

関連したドキュメント