Commit Graph

239 Commits

Author SHA1 Message Date
Steven Dake
cf0d63aa3f Patch to fix stack protector sig abort that occurs when ipc buffer is too
short.


git-svn-id: http://svn.fedorahosted.org/svn/corosync/trunk@2974 fd59a12c-fef9-0310-b244-a6a79926bd2f
2010-06-29 18:15:20 +00:00
Steven Dake
0e9f0bfeb4 Make cpg_membership_get() functional.
git-svn-id: http://svn.fedorahosted.org/svn/corosync/trunk@2855 fd59a12c-fef9-0310-b244-a6a79926bd2f
2010-05-19 05:03:52 +00:00
Angus Salkeld
4ff33854ad add __attribute__((noreturn)) to functions that always exit.
we had some __attribute__((__noreturn__))
and some    __attribute__((noreturn))

I made them all: __attribute__((noreturn))



git-svn-id: http://svn.fedorahosted.org/svn/corosync/trunk@2853 fd59a12c-fef9-0310-b244-a6a79926bd2f
2010-05-19 04:34:53 +00:00
Angus Salkeld
ad71b66c7b cov (many): make sure all _set() functions return a signed int
in the body it can return -1, and callers check for -1.
but the return type is unsigned int?



git-svn-id: http://svn.fedorahosted.org/svn/corosync/trunk@2849 fd59a12c-fef9-0310-b244-a6a79926bd2f
2010-05-18 00:46:08 +00:00
Angus Salkeld
25a3d310ac cov 10390: remove pointless assert.
git-svn-id: http://svn.fedorahosted.org/svn/corosync/trunk@2837 fd59a12c-fef9-0310-b244-a6a79926bd2f
2010-05-16 21:32:21 +00:00
Jan Friesse
d5884cd714 SAM integration of quorum
Patch adds integration of SAM and quorum, so it's now possible to use
SAM_RECOVERY_POLICY_QUORUM_QUIT or SAM_RECOVERY_POLICY_QUORUM_RESTART
recovery policy. With these policies, sam_start will block until
corosync is quorate. If quorum is lost during health checking, recovery
action is taken.


git-svn-id: http://svn.fedorahosted.org/svn/corosync/trunk@2822 fd59a12c-fef9-0310-b244-a6a79926bd2f
2010-05-13 11:20:49 +00:00
Jan Friesse
e8b143595c CPG model_initialize and ringid + members callback
Patch adds new function to initialize cpg, cpg_model_initialize. Model
is set of callbacks. With this function, future addions of models
should  be possible without changing the ABI.

Patch also contains callback in CPG_MODEL_V1 for notification about
Totem membership changes.


git-svn-id: http://svn.fedorahosted.org/svn/corosync/trunk@2770 fd59a12c-fef9-0310-b244-a6a79926bd2f
2010-04-20 12:40:48 +00:00
Jan Friesse
da6fce352b Support for store user data in SAM
Ability to in-memory storing of user data which survives between
instances of process.

Also ability needed ability for bi-directional communication between
child and parent is added.


git-svn-id: http://svn.fedorahosted.org/svn/corosync/trunk@2769 fd59a12c-fef9-0310-b244-a6a79926bd2f
2010-04-20 10:32:07 +00:00
Jan Friesse
a568462601 Support for user configurable warning signal
Allow developer configure a signal to be send as a warning signal
before real SIGKILL.


git-svn-id: http://svn.fedorahosted.org/svn/corosync/trunk@2753 fd59a12c-fef9-0310-b244-a6a79926bd2f
2010-04-01 12:51:07 +00:00
Angus Salkeld
15afe1d192 CTS: add a test for sync events
git-svn-id: http://svn.fedorahosted.org/svn/corosync/trunk@2742 fd59a12c-fef9-0310-b244-a6a79926bd2f
2010-03-30 07:11:56 +00:00
Christine Caulfield
1baa7b2ab3 Add a reload callback to libconfdb.
This also increments the libconfdb version to 4.1.0



git-svn-id: http://svn.fedorahosted.org/svn/corosync/trunk@2683 fd59a12c-fef9-0310-b244-a6a79926bd2f
2010-03-16 09:51:30 +00:00
Angus Salkeld
1e17751d0d Remove warnings.
git-svn-id: http://svn.fedorahosted.org/svn/corosync/trunk@2682 fd59a12c-fef9-0310-b244-a6a79926bd2f
2010-03-11 00:27:04 +00:00
Jan Friesse
009dfc090e Support for lib_cpg_finalize
Add support for MESSAGE_REQ_CPG_FINALIZE message. This will allow us
remove cpg_pd from list of active connections, and remove problem, when
cpg_finalize + cpg_initialize + cpg_join can result in CPG_ERR_EXIST
error.


git-svn-id: http://svn.fedorahosted.org/svn/corosync/trunk@2676 fd59a12c-fef9-0310-b244-a6a79926bd2f
2010-03-04 12:17:47 +00:00
Jan Friesse
5a8200c1cb Fix corosync shutdown process
This patch change corosync shutdown process, so now:
- exit function of service engine is called
- all IPC connections are closed and removed from poll
- service engine is unlocked


git-svn-id: http://svn.fedorahosted.org/svn/corosync/trunk@2657 fd59a12c-fef9-0310-b244-a6a79926bd2f
2010-02-16 11:29:14 +00:00
Angus Salkeld
c6beee076a pass transitional members into the sync_init() callbacks.
git-svn-id: http://svn.fedorahosted.org/svn/corosync/trunk@2653 fd59a12c-fef9-0310-b244-a6a79926bd2f
2010-02-04 00:18:51 +00:00
Jan Friesse
f4a644c711 Add schedwrk_create_nolock function
This patch adds schedwrk_create_nolock, which will not call
serialize_lock before execution of callback.


git-svn-id: http://svn.fedorahosted.org/svn/corosync/trunk@2649 fd59a12c-fef9-0310-b244-a6a79926bd2f
2010-01-22 09:45:29 +00:00
Jan Friesse
0ed4d53083 SAM implementation merge
The SAM library provide a tool to check the health
of an application. The main purpose of SAM is to restart
a local process when it fails to respond to a healthcheck
request in a configured time interval.



git-svn-id: http://svn.fedorahosted.org/svn/corosync/trunk@2570 fd59a12c-fef9-0310-b244-a6a79926bd2f
2009-12-07 17:06:53 +00:00
Angus Salkeld
29eb20a389 Rename totem_new_msg_signal() to something more generic.
git-svn-id: http://svn.fedorahosted.org/svn/corosync/trunk@2553 fd59a12c-fef9-0310-b244-a6a79926bd2f
2009-11-29 18:42:00 +00:00
Angus Salkeld
27d383276b coroipcs: Add a queue_size stats counter to each ipc connection.
git-svn-id: http://svn.fedorahosted.org/svn/corosync/trunk@2552 fd59a12c-fef9-0310-b244-a6a79926bd2f
2009-11-29 18:28:39 +00:00
Angus Salkeld
ce8046f353 coroipcs: add logging for flow control state changes.
git-svn-id: http://svn.fedorahosted.org/svn/corosync/trunk@2551 fd59a12c-fef9-0310-b244-a6a79926bd2f
2009-11-29 18:25:51 +00:00
Andrew Beekhof
ea204f3810 Fix compilation on RHEL-4: If _GNU_SOURCE isn't defined, then neither is pthread_spinlock_t and compilation fails
git-svn-id: http://svn.fedorahosted.org/svn/corosync/trunk@2542 fd59a12c-fef9-0310-b244-a6a79926bd2f
2009-11-05 13:01:25 +00:00
Angus Salkeld
07072bd0b1 Add a log_printf function to coroipcs so we can pass the log level
git-svn-id: http://svn.fedorahosted.org/svn/corosync/trunk@2530 fd59a12c-fef9-0310-b244-a6a79926bd2f
2009-10-18 18:15:24 +00:00
Angus Salkeld
4e6e33467d allow coroipcs to work without calling stats initialization.
git-svn-id: http://svn.fedorahosted.org/svn/corosync/trunk@2518 fd59a12c-fef9-0310-b244-a6a79926bd2f
2009-10-12 21:50:10 +00:00
Angus Salkeld
73a24c0352 Add totem stats to objdb.
git-svn-id: http://svn.fedorahosted.org/svn/corosync/trunk@2517 fd59a12c-fef9-0310-b244-a6a79926bd2f
2009-10-12 17:30:20 +00:00
Angus Salkeld
afbbc5e5ff Add connection related statistics to the object db.
git-svn-id: http://svn.fedorahosted.org/svn/corosync/trunk@2514 fd59a12c-fef9-0310-b244-a6a79926bd2f
2009-10-12 00:36:55 +00:00
Angus Salkeld
73b7aa19bb Add value types to objdb keys.
This allows you to create a key with a know type.
And then get the type with the key value.



git-svn-id: http://svn.fedorahosted.org/svn/corosync/trunk@2511 fd59a12c-fef9-0310-b244-a6a79926bd2f
2009-10-10 03:20:38 +00:00
Steven Dake
978b60806b Totem IBA implementation.
git-svn-id: http://svn.fedorahosted.org/svn/corosync/trunk@2481 fd59a12c-fef9-0310-b244-a6a79926bd2f
2009-09-25 06:23:04 +00:00
Angus Salkeld
ce4e9902b6 turn off _POSIX_THREAD_PROCESS_SHARED for uclibc
git-svn-id: http://svn.fedorahosted.org/svn/corosync/trunk@2477 fd59a12c-fef9-0310-b244-a6a79926bd2f
2009-09-25 02:27:50 +00:00
Angus Salkeld
b13a7aba13 add small-memory-footprint option to configure
This adds the following option to configure:
--enable-small-memory-footprint

When enabled the following defines are set
to reduce the overall memory footprint.

MESSAGE_SIZE_MAX=1024*64
MESSAGE_QUEUE_MAX=512
PROCESSOR_COUNT_MAX=16
IPC_REQUEST_SIZE=1024*64
IPC_RESPONSE_SIZE=1024*64
IPC_DISPATCH_SIZE=1024*64




git-svn-id: http://svn.fedorahosted.org/svn/corosync/trunk@2410 fd59a12c-fef9-0310-b244-a6a79926bd2f
2009-09-09 18:58:38 +00:00
Jan Friesse
db87fb8f56 Implementation of cpg_iteration functions
This functions allows iterate available cpg groups
and their members. API is modelled like ckpt iteration
functions.


git-svn-id: http://svn.fedorahosted.org/svn/corosync/trunk@2399 fd59a12c-fef9-0310-b244-a6a79926bd2f
2009-08-31 09:23:16 +00:00
Steven Dake
21825d46ea Fix incorrect assertion with frame sizes of 9000.
git-svn-id: http://svn.fedorahosted.org/svn/corosync/trunk@2395 fd59a12c-fef9-0310-b244-a6a79926bd2f
2009-08-28 01:19:30 +00:00
Steven Dake
3d05244ca0 Allow finalize routines to occur inside dispatch routines.
git-svn-id: http://svn.fedorahosted.org/svn/corosync/trunk@2394 fd59a12c-fef9-0310-b244-a6a79926bd2f
2009-08-24 17:50:12 +00:00
Steven Dake
ee7ce5e328 Use unnamed shared posix semaphores on platforms which support them.
git-svn-id: http://svn.fedorahosted.org/svn/corosync/trunk@2379 fd59a12c-fef9-0310-b244-a6a79926bd2f
2009-08-04 00:22:41 +00:00
Steven Dake
69928e301a Add notification when totem has completed initialization.
This triggers the initialization of the service engines which may need totem
for initialization.



git-svn-id: http://svn.fedorahosted.org/svn/corosync/trunk@2372 fd59a12c-fef9-0310-b244-a6a79926bd2f
2009-07-27 02:00:05 +00:00
Andrew Beekhof
21407aa76b Use the preferred prefix for the Pacemaker service
git-svn-id: http://svn.fedorahosted.org/svn/corosync/trunk@2362 fd59a12c-fef9-0310-b244-a6a79926bd2f
2009-07-14 12:34:18 +00:00
Steven Dake
c6efbddcf9 Add poll destroy to coroipcs.
git-svn-id: http://svn.fedorahosted.org/svn/corosync/trunk@2348 fd59a12c-fef9-0310-b244-a6a79926bd2f
2009-07-08 05:23:33 +00:00
Steven Dake
2a31caedd3 Add ring id field to evs.
git-svn-id: http://svn.fedorahosted.org/svn/corosync/trunk@2341 fd59a12c-fef9-0310-b244-a6a79926bd2f
2009-07-01 20:57:37 +00:00
Steven Dake
453ef211c1 Pass handle is evs callback functions.
git-svn-id: http://svn.fedorahosted.org/svn/corosync/trunk@2339 fd59a12c-fef9-0310-b244-a6a79926bd2f
2009-07-01 20:21:48 +00:00
Steven Dake
23ce53be4d Set ERR_SECURITY to 100 to give plenty of room for other people's error codes.
git-svn-id: http://svn.fedorahosted.org/svn/corosync/trunk@2337 fd59a12c-fef9-0310-b244-a6a79926bd2f
2009-07-01 20:03:07 +00:00
Steven Dake
3e0ab804cb Code cleanup for evs service from Wojtek.
git-svn-id: http://svn.fedorahosted.org/svn/corosync/trunk@2333 fd59a12c-fef9-0310-b244-a6a79926bd2f
2009-07-01 19:19:06 +00:00
Steven Dake
130d9c9908 Add context get and set operations to evs handles and man pages.
git-svn-id: http://svn.fedorahosted.org/svn/corosync/trunk@2329 fd59a12c-fef9-0310-b244-a6a79926bd2f
2009-07-01 06:27:00 +00:00
Steven Dake
15d2c48963 Export poll handle via coroapi.h.
git-svn-id: http://svn.fedorahosted.org/svn/corosync/trunk@2318 fd59a12c-fef9-0310-b244-a6a79926bd2f
2009-06-29 23:24:24 +00:00
Steven Dake
e1b054ae0a Change sync_init api call to pass information relevant for making
synchronization decisions.


git-svn-id: http://svn.fedorahosted.org/svn/corosync/trunk@2305 fd59a12c-fef9-0310-b244-a6a79926bd2f
2009-06-27 01:59:59 +00:00
Steven Dake
9bf201420c Add AMF_V2_SERVICE defintion
git-svn-id: http://svn.fedorahosted.org/svn/corosync/trunk@2301 fd59a12c-fef9-0310-b244-a6a79926bd2f
2009-06-26 02:50:38 +00:00
Steven Dake
f540be9060 Add compatability option in config file. Defaults to whitetank.
Add sync_mode to coroapi to indicate to corosync the service engine's
desired compatibility mode.


git-svn-id: http://svn.fedorahosted.org/svn/corosync/trunk@2298 fd59a12c-fef9-0310-b244-a6a79926bd2f
2009-06-26 00:25:52 +00:00
Steven Dake
e35059f57d definition error in corodefs.h
git-svn-id: http://svn.fedorahosted.org/svn/corosync/trunk@2297 fd59a12c-fef9-0310-b244-a6a79926bd2f
2009-06-25 23:20:38 +00:00
Steven Dake
da53358394 Define CMAN and CRM service ids.
git-svn-id: http://svn.fedorahosted.org/svn/corosync/trunk@2295 fd59a12c-fef9-0310-b244-a6a79926bd2f
2009-06-25 20:55:16 +00:00
Jan Friesse
f7ed512a1d Add database lock init to hdb_* functions
Without this, lock can be called to unitialized and locking unitialized
lock isn't good idea.


git-svn-id: http://svn.fedorahosted.org/svn/corosync/trunk@2291 fd59a12c-fef9-0310-b244-a6a79926bd2f
2009-06-25 10:22:23 +00:00
Jan Friesse
53bf62fd04 Add locking of database in hdb_handle_refcount_get
git-svn-id: http://svn.fedorahosted.org/svn/corosync/trunk@2290 fd59a12c-fef9-0310-b244-a6a79926bd2f
2009-06-25 10:21:54 +00:00
Ryan O'Hara
518237712b Add hdb_handle_refcount_get call.
git-svn-id: http://svn.fedorahosted.org/svn/corosync/trunk@2287 fd59a12c-fef9-0310-b244-a6a79926bd2f
2009-06-23 22:28:31 +00:00