DP4 Configuration Utilities

in this topic the "home" directory of DP4 is referred to from time to time. Up to release 4.523 this means the /usr/datafit/ directory. From release 4.525 it is the directory specified in the DP4HOME environment variable, or /opt/dp4 if DP4HOME is left undefined.

USERDATA

The DP4 utility USERDATA allows you to specify the terminal type, from the list it displays, by typing the corresponding letter.

This results in the automatic creation of userdata.sys in the current directory. At install time dp4install runs this program from the base directory of the DP4 installation. userdata.sys stores more than merely the terminal-type information, and its role in defining the DP4 configuration is discussed fully in the next section.

DFSETUP

After selecting the terminal type, the DP4 utility DFSETUP runs. Your DP4 licence file should have been pre-configured with sensible values so you can use it immediately, but you should check the various directory assignments match your requirements in any case.

DFSETUP allows you to configure various aspects of your DP4 installation such as the location of the different classes of DP4 file (there are some restrictions, see File_Location below), logging options, user preferences and printer set up.

The changes you make in DFSETUP are written to one of three locations:

When DFSETUP is run from the command line and updates userdata.sys it will read userdata.sys from the "home" directory if one is not present in the current directory. DFSETUP always writes changes to userdata.sys in the current directory. You can therefore arrange for each user to have their own copy of userdata.sys by ensuring each user works in a different directory.

DFSETUP can be invoked from the command line or from the DP4 system menus (Option 1 - System configuration ). This affects where the changes are stored as shown by the following table. (The letter C indicates that DFSETUP was run from the command line, M indicates that it was run from the system menus).

DFSETUP Option

USERDATA.SYS

DP4 Licence file

SYSTEM

Directory Assignment

 

CM

 

Console/Transaction logging

 

CM

 

User Preferences

C

 

M

Keyboard Customisation

CM

 

 

Printer Characteristics

 

 

CM

Serial Number

 

CM

 

Terminal Characteristics

CM *

 

 

* If you use the Terminal Characteristics option, the information is saved to terminal.sys in the current directory. Should you do this, rename terminal.sys to userdata.sys to use the new settings. The settings are not written to userdata.sys directly so that you can prepare a file for use on another machine.

Changing the Location of Files

Up to release 4.523 you can only change the location of certain DP4 files. Up to release 4.523 DP4 expects to find datafit.sys in /usr/datafit/. 16 bit programs converted to Unix with exe2unix expect to find the terminal manager (trm3) and database manager (srv3) in /usr/datafit/bin/.

From release 4.525 DP4 files can be installed in any directory. The only restriction is that the DP4HOME environment variable must point to the directory containing the DP4 licence file (dp4.sys) and the DP4 configuration file (dp4.ini)

The location of databases can be changed by following this procedure:

  1. Create a backup copy of the DP4 licence file (e.g. by using cp to copy it to a backup directory)
  2. If necessary create the new directory where databases are to be stored, and copy the system database to the new location.
  3. Run dfsetup and choose the Directory Assigment option. Specify the new location for the databases. DFSETUP will warn you if the system database cannot be found in the new location (which may happen if you have mistyped the new location, or failed to copy the system database, or there is a permission problem).
  4. Exit from all DP4 programs and make sure srv3 is no longer running, for example by running shutdown −stop. Check that you can still run dfsetup correctly to verify that the system database is correctly accessed from the new location.
  5. Move all the other databases to the new location.

It is possible, but not recommended to store the system database separately from other databases doing the following:

  1. Move the system database to its new location
  2. Run the DP4 utility, sysdb , giving the new location and name of the system database, as in:
    sysdb /newdirectory/system