Unloading and reloading queue pools
The contents of a queue pool can be unloaded to a sequential file and subsequently reloaded by running the server program using the FUNCTION parameter.
About this task
This can be used to preserve the queue pool across planned coupling facility maintenance, or to move the queue pool to a different coupling facility. The server does not support automatic structure REBUILD, but the unload and reload process is more flexible. The reloaded queue pool does not need the same name as the original pool.
- FUNCTION={UNLOAD|RELOAD}
- requests the server to perform the special functions UNLOAD or
RELOAD. When the unload or reload processing has completed (normally
or abnormally) the server program terminates.
If this parameter is omitted, the server program initializes the cross-memory queue server environment.
When UNLOAD or RELOAD is specified, the server program requires exclusive use of the list structure. If the structure is currently being used by a normal server, the attempt to unload or reload is rejected. Similarly, if a normal server attempts to start while an unload or reload function is in progress, the attempt is rejected because shared access to the structure is not available.
All normal server parameters can be specified on UNLOAD and RELOAD, but many of these, such as the number of queue buffers, are ignored because they do not apply to unload or reload processing.
RECFM=F,LRECL=4096,BLKSIZE=4096.
An
upper limit for the total size of the data set in bytes can be estimated
from the pool usage statistics produced by the server. The total data
size in bytes is obtained by multiplying the number of elements in
use by the element size (usually 256), and for each queue there is
also some control information which typically occupies fewer than
100 bytes per queue. The size is normally smaller than this because
unused space in data elements is not included in the unloaded file.
See Figure 1 for an example of UNLOAD
JCL.
The RELOAD function requires a DD statement for file name DFHXQRL describing the sequential data set from which the queue pool is to be reloaded. The structure is allocated if necessary during reloading, in which case the same server parameters may be used to control structure attributes as for normal server execution. The RELOAD process bypasses any queues that are already found in the queue pool, because, for example, the structure was too small and the reload job had to be restarted after using ALTER to increase the size.
Note that when a pool is nearly full (with less than about 5% free entries and elements) there is no guarantee that it can be unloaded and reloaded into a structure of exactly the same size. The amount of space available is affected by the current ratio of entries to elements, which can only be controlled approximately by the automatic ALTER process.
If the structure reaches the warning level during reloading, the automatic ALTER process attempts to adjust the entry to element ratio, and the reload process will automatically wait for the ALTER to complete if no space is available while an ALTER is still in progress.