Use a Subserver to Handle Large Loads

In larger installations, the functions performed by vovserver may be handled by two cooperating processes, the primary server and the subserver. The subserver can offload the client processing relative to some costly functionality, such as long lists (nc list), GUI (nc gui), and waiting for jobs to complete (nc wait).

The tradeoff is that in the current implementation, only one subserver is allowed. The status in the subserver is maintained up-to-date by processing the event stream coming from the primary server. The subserver passes through all events received from the primary server to all of its "notify clients".

The primary server must be used to submit, stop, and forget jobs. The subserver is to be used as a read-only server. While it appears to behave as the primary server, any write operations attempted on the subserver, such as stopping or forgetting jobs, will not work. The user interfaces prevent the users from attempting such operations on the subserver, but the interfaces can be circumvented by directly calling the "vtk_*" API.

Start the Subserver

The simplest way to start the subserver is to call the following script:
% $VOVDIR/etc/autostart/subserver.csh

That script can be added to the *.swd/autostart directory to always start the subserver at system restart.

At the low level, the subserver is started with the vtk_subserver_start API:
vtk_subserver_start newPortNumber newPortReadOnly flags
For example:
% vovsh -x 'vtk_subserver_start 16271 16272 0'

Use the Subserver

Some commands support the -ss and -noss options. The default differs among commands. For example, nc list uses the subserver by default, while nc gui does not.
% nc list 
% nc list -noss                                      (default behavior)
% nc list -ss                                    
% nc wait -set abc -ss
% nc gui -ss &
To use the primary server instead of the subserver, use the option -noss.
% nc list -noss
% nc wait -set abc -noss                             (default behavior)
% nc gui -noss &

Stop the Subserver

There is no command to stop the subserver; the subserver is supposed to run forever. However, the subserver process can be killed with the following command:
The primary server is not affected by the subserver, because to the primary server, the subserver is another client. However, all clients connected to the subserver are likely to exit with an error.