[Openais] [trunk] load and unloading of service handlers

Steven Dake sdake at redhat.com
Tue Sep 18 21:30:58 PDT 2007


The following patch changes around service.c and service.h considerably
to load and unload service handlers at user command.

This can be achieved via the opeanis_cfgtool program in the test
directory and the lib/cfg directory.

For example, after running aisexec, the checkpoint service can be
unloaded, then tested, then loaded, then tested.

That would look like this:

[root at balance test]# ./testckpt
some testckpt output showing that checkpoints are working
[root at balance test]# ./openais-cfgtool -u openais_ckpt -v 0
Unloading service 'openais_ckpt' version '0'
[root at balance test]# ./testckpt
testckpt fails to work and would return errors
[root at balance test]# ./openais-cfgtool -l openais_ckpt -v 0
Loading service 'openais_ckpt' version '0'
[root at balance test]# ./testckpt
some testckpt output showing that checkpoints are working

When the service is loaded into aisexec the following will be printed:

Sep 18 21:28:12.741108 [SERV ] Service initialized 'openais checkpoint
service B.01.01'


Some reference counting is still required to ensure unloads don't happen
to a service under use and integration with the ipc system needs to
occur for the purposes of the exec_exit_fn to operate properly.

But this is a first start.

Regards
-steve
-------------- next part --------------
A non-text attachment was scrubbed...
Name: loadunload.patch
Type: text/x-patch
Size: 26639 bytes
Desc: not available
Url : http://lists.linux-foundation.org/pipermail/openais/attachments/20070918/cc4d4ee0/loadunload.bin


More information about the Openais mailing list