Information on Branding and DP4 configuration

This page contains all the information you require for branding your DP4 system so that it can be installed safely on any suitable machine without the risk of other DP4 systems already present, or to be installed later interfering with it, or your system with them.

The [branding] Section

The [branding] section of the DP4 configuration file contains entries that affect compatibility with existing DP4 installations. Most of them must be changed if you want to make your DP4 installation completely independent of any other DP4 installation that might be present on the machine, and most of the others you will want to change to "badge engineer" your DP4 system (this is the primary reason the various entries are included in this section rather than one of the others). If you are supplying any kind of "shrink-wrapped" application which is based on DP4 you are highly recommended to make use of this section to ensure that installing your application does not affect any other DP4 installations that might already be present on the machine. There are also a number of other things you may need to do beyond changing the [branding] entries. These are described later on.

Other Branding Issues

The remainder of this page discusses various other aspects of configuring DP4 so that it can co-exist with other DP4 installations on the same computer system.

Networking-related branding issues

The following discussion is confined to DP4 installation using TCP/IP protocol. Multiple installations on one machine are not supported for other network protocols.

For a machine to act as a DP4 network server or client for different DP4 installations it will be necessary to ensure that DP4 messages intended for one DP4 instance are not accidentally intercepted by another DP4 service and not accidentally sent to the wrong server because of host file or DNS problems.

Port Number

DP4 uses TCP/IP port 5000 by default when creating sockets (and Windows servers use ports 5001 and 5002 also). If multiple DP4 installations use DP4 networking they should all use different port numbers. The network administrator for the system will have to decide on suitable port numbers for each application, and edit the appropriate [startup] sections in the various dp4.ini files to apply -socket command tails . Unfortunately there does not seem to be a more graceful way of doing this.

Machine Names

If possible use real machine names (specified with the -server_name command tail) to identify the location of DP4 servers. If you have to use the old server number scheme instead, for example because you are using auxdistr, then use a [tcpip_servers] section to convert the dp4servernn names into real machine names. Currently the "dp4servernn" type names remain hard-coded into the DP4 network programs when you use server numbers.

Unix Related Issues

On Unix the inter-process communication (IPC)used to communicate with the DP4 interface is built directly into application programs. Unfortunately this means that the changes to this mechanism to permit simultaneous operation of multiple DP4 systems on the same machine require you to relink your C application programs and ADCs with the DP4 Enterprise C library. Until you have done this you must continue to use one of the old IPC mechanisms supported by previous releases of DP4.

The newest and now preferred IPC mechanism is enabled for programs built with the new library if there is an accessible file named dp4ftok in the directory where the initial dp4.ini file is located. The Unix ftok() routine is then used to construct the various DP4 IPC keys based on this file. If this file does not exist but /etc/dp4ftok does that file is used instead in the same way (this requires your program to be built with 4.522 or later libraries). Finally if neither file exists the pre 4.522 scheme of hard coded IPC keys is used instead.