In this configuration there are no separate instructions for client and server machines - all machines using this configuration can act as both clients and servers.
Machines are loaded as follows:On Win32 platforms:
[startup]
1=dp4srvr.w32 -aux
2=tcpw.w32 -server_name servername
3=tcpmgr.w32 -aux
On Windows CE platforms:
[startup]
1=dp4srvr.wce -aux
2=tcpw.wce -server_name servername
3=tcpmgr.wce -aux
On Unix and Linux:
srv3 -aux -remain
tcp3 -server_name servername
tcpmgr -aux
With 4.525 and dbdaemon you would use the following startup section:
[startup]
1=srv3 -aux
2=tcp3 -server_name servername
3=tcpmgr -aux
In each case servername is replaced by the pingable name of the DP4 server machine to be used as the "default" server. (If you are running over the Internet the name may not actually be pingable, but it must be resolvable to the correct IP address). Usually servername will be the name of the machine itself so that it usually acts as its own server. From 4.525/4.620 you can use the name localhost, assuming your TCP/IP configuration supports this. This normally equates to the "loopback" address 127.0.0.1 . This may be convenient if you want to load this configuration on a large number of machines and don't want to have to tailor each machine's DP4 configuration individually. You could use the name of another server, if you usually want to run against its databases.
You cannot use localhost on older versions of TCPMGR because it did not listen on this address.
You can load DP4 temporarily. Add the -noremain option to the startup line of the network client (tcpw/tcp3).
If you include the commands required for running DP4 Thin Client and enable TCPMGR as an application server, you will have a machine that has the full range of DP4 networking capabilities.
The commands for running this configuration on Win32 platforms are:
[startup]If your default server_name is localhost, or some other connection to self, you must remember to specify a different server when running programs with tsrun. If you accidentally try to run a program as a thin client of the local application server, the application will usually fail (possibly horribly). With 4.621 the application will simply fail to start.
A particular advantage of this type of configuration is that two machines can each act as a server for the other's network requests, and that you can arrange for a server to automatically run a program of your choice on the "reverse" connection to a client. The program is run each time a connection is made to the server from a machine that is not already connected. Using this facility you may be able to reduce the amount of data transferred across the network for tasks such as synchronisation of data between two machines. (From 4.620 RECASTDB can be used for this purpose).
To use this facility you must load tcpmgr with the command tail -reverse, and in the DP4 configuration file specify a command line to be run in the onconnect entry. When a new connection is created this command line will be executed. The IP address of the incoming connection is specified as a final argument, (prefixed with a #). Therefore if you make the final argument of the onconnect string -server_name, or -synchronise (for RECASTDB) the program will automatically run against the correct client machine.