Jim Meyering
ab7b859d8a
sync.c: avoid printf format warning
...
* exec/sync.c (sync_deliver_fn): cast to unsigned long int, use %lu
git-svn-id: http://svn.fedorahosted.org/svn/corosync/trunk@2034 fd59a12c-fef9-0310-b244-a6a79926bd2f
2009-04-08 07:57:36 +00:00
Jim Meyering
373254bdb9
sync.c: avoid warning about now-unused variables
...
* exec/sync.c (vsf_none, vsf_iface): Remove decls of now-unused
file-scoped variables.
git-svn-id: http://svn.fedorahosted.org/svn/corosync/trunk@2033 fd59a12c-fef9-0310-b244-a6a79926bd2f
2009-04-08 07:57:18 +00:00
Jim Meyering
36eefbadef
Convert all "int iov_len" decls to "unsigned int iov_len".
...
Used this command:
git grep -l 'int iov_len' \
| xargs perl -pi -e 's/((?:^|,)\s*)(int iov_len)/${1}unsigned $2/'
Here's an approximate (autogenerated by vc-chlog) list of affected
file names and functions/macros:
* README.devmap:
* exec/coroipcs.c (sending_allowed_private_data)
(coroipcs_response_iov_send, msg_send, msg_send_or_queue)
(coroipcs_dispatch_iov_send):
* exec/coroipcs.h (handler_fn_get):
* exec/main.c (deliver_fn, main_mcast):
* exec/main.h (FALSE):
* exec/sync.c (vsf_iface, sync_deliver_fn):
* exec/totemmrp.c (totemsrp_handle_in, pg_deliver_fn)
(totemmrp_deliver_fn, totemmrp_initialize, totemmrp_mcast):
* exec/totemmrp.h (TOTEMMRP_H_DEFINED):
* exec/totemnet.c (iov_len, encrypt_and_sign_worker)
(ucast_sendmsg, mcast_sendmsg, totemnet_token_send):
* exec/totemnet.h (TOTEMNET_FLUSH):
* exec/totempg.c (deliver_fn, totempg_deliver_fn, mcast_msg)
(totempg_groups_initialize, totempg_groups_mcast_joined)
(totempg_groups_joined_reserve):
* exec/totemsrp.c (iov_len, totemsrp_recv, totemsrp_deliver_fn)
(totemsrp_initialize, totemsrp_mcast, token_send):
* exec/totemsrp.h (TOTEMSRP_H_DEFINED):
* exec/vsf_ykd.c (ykd_deliver_fn):
* include/corosync/coroipcc.h (handleInstanceDestructor):
* include/corosync/cpg.h (cpg_callbacks_t):
* include/corosync/engine/coroapi.h (ipc_response_iov_send)
(ipc_dispatch_iov_send, totem_mcast, tpg_init, tpg_joined_mcast)
(tpg_joined_reserve, tpg_groups_mcast, tpg_groups_reserve):
* include/corosync/totem/totempg.h (TOTEMPG_SAFE):
* lib/coroipcc.c (coroipcc_msg_send)
(coroipcc_msg_send_reply_receive)
(coroipcc_msg_send_reply_receive_in_buf):
* lib/cpg.c (cpg_mcast_joined):
* lib/util.h (versionsSupported):
* services/pload.c (send_message):
* services/votequorum.c (conn, quorum_deliver_fn):
git-svn-id: http://svn.fedorahosted.org/svn/corosync/trunk@2031 fd59a12c-fef9-0310-b244-a6a79926bd2f
2009-04-08 07:56:45 +00:00
Jim Meyering
2eba2a6cb8
continue pulling previous thread: mostly constification
...
* exec/apidef.c (typedef_tpg_join, typedef_tpg_leave)
(typedef_tpg_groups_mcast, typedef_tpg_groups_send_ok):
* exec/sync.c (barrier_data_process, sync_barrier_send)
(sync_start_init, sync_service_init, sync_start_process)
(sync_service_process, sync_deliver_fn, sync_request_send)
(sync_request):
* exec/sync.h (name):
* exec/totemmrp.c (totemmrp_callback_token_create):
* exec/totemmrp.h (TOTEMMRP_H_DEFINED):
* exec/totempg.c (list, app_confchg_fn)
(callback_token_received_fn, totempg_callback_token_create)
(totempg_groups_mcast_joined, totempg_groups_joined_release)
(totempg_groups_mcast_groups):
* exec/totemsrp.c (callback_fn, totemsrp_confchg_fn)
(totemsrp_initialize, totemsrp_callback_token_create):
* exec/totemsrp.h (TOTEMSRP_H_DEFINED):
* exec/vsf_ykd.c (ykd_state_send_msg, ykd_attempt_send_msg)
(ykd_confchg_fn):
* include/corosync/engine/coroapi.h (timer_add_absolute)
(totem_ifaces_print, totem_ip_print, totem_callback_token_create)
(sync_request, plugin_interface_reference):
* include/corosync/totem/totempg.h (TOTEMPG_SAFE):
* services/cpg.c (cpg_confchg_fn):
* services/pload.c (msgs_sent, pload_service_engine)
(send_message, start_mcasting):
* services/votequorum.c (conn, quorum_confchg_fn):
git-svn-id: http://svn.fedorahosted.org/svn/corosync/trunk@2030 fd59a12c-fef9-0310-b244-a6a79926bd2f
2009-04-08 06:44:59 +00:00
Jim Meyering
3a32139cfc
*_confchg_fn: make pointer params const, change *_entries to be size_t
...
* exec/main.c (confchg_fn):
* exec/quorum.h (sync_callback_fn_t):
* exec/sync.c (sync_ring_id, barrier_data_process)
(sync_start_init, sync_service_process, sync_primary_callback_fn)
(sync_deliver_fn, sync_confchg_fn):
* exec/sync.h (name):
* exec/totemmrp.c (totemsrp_handle_in, pg_confchg_fn)
(totemmrp_confchg_fn, totemmrp_initialize):
* exec/totemmrp.h (TOTEMMRP_H_DEFINED):
* exec/totempg.c (confchg_fn, totempg_confchg_fn)
(totempg_groups_initialize):
* include/corosync/engine/coroapi.h (tpg_init, confchg_fn)
(sync_abort):
* include/corosync/totem/totempg.h (TOTEMPG_SAFE):
* services/cfg.c (shutdown_reply, cfg_confchg_fn)
(message_handler_req_exec_cfg_ringreenable):
* services/cpg.c (api, cpg_confchg_fn):
* services/evs.c (MESSAGE_REQ_EXEC_EVS_MCAST, evs_confchg_fn):
* services/pload.c (MESSAGE_REQ_EXEC_PLOAD_MCAST)
(pload_confchg_fn):
git-svn-id: http://svn.fedorahosted.org/svn/corosync/trunk@2029 fd59a12c-fef9-0310-b244-a6a79926bd2f
2009-04-08 06:44:50 +00:00
Jim Meyering
cf2c12a988
evs.h: s/int/size_t; const-correctness changes
...
* exec/sync.c (barrier_data_confchg_entries):
* include/corosync/evs.h (evs_deliver_fn_t, evs_confchg_fn_t):
(evs_callbacks_t):
* lib/evs.c (MIN, evs_join, evs_leave, evs_mcast_joined):
(evs_mcast_groups, evs_membership_get):
* test/evsbench.c (evs_deliver_fn, evs_confchg_fn):
* test/evsverify.c (evs_deliver_fn, evs_confchg_fn, main):
* test/testevs.c (evs_deliver_fn, evs_confchg_fn, main):
git-svn-id: http://svn.fedorahosted.org/svn/corosync/trunk@2023 fd59a12c-fef9-0310-b244-a6a79926bd2f
2009-04-08 06:43:17 +00:00
Jim Meyering
db4838bc35
quorum.h (quorum_set_quorate_fn_t): make first param const
...
* exec/quorum.h (sync_callback_fn_t):
* exec/sync.c (current_members_cnt, sync_primary_callback_fn):
* exec/sync.h (name):
* exec/vsf_quorum.c (sync_primary_callback_fn):
(quorum_api_set_quorum):
* exec/vsf_ykd.c (ykd_primary_callback_fn):
* include/corosync/engine/coroapi.h (sync_callback_fn_t):
* include/corosync/engine/quorum.h (quorum_set_quorate_fn_t):
git-svn-id: http://svn.fedorahosted.org/svn/corosync/trunk@2022 fd59a12c-fef9-0310-b244-a6a79926bd2f
2009-04-08 06:43:03 +00:00
Steven Dake
12754324f9
Forward port of sync v1 engine from whitetank and rework of quorum
...
engine to not break syncing.
git-svn-id: http://svn.fedorahosted.org/svn/corosync/trunk@2019 fd59a12c-fef9-0310-b244-a6a79926bd2f
2009-04-07 21:41:25 +00:00
Jim Meyering
3965e378e6
avoid prototype warnings
...
* test/evsbench.c: Declare functions/vars static.
* test/evsverify.c: Likewise.
* test/testcpg2.c: Likewise.
* test/testcpg.c: Likewise.
* test/logsysbench.c: Likewise.
* test/cpgbench.c: Likewise.
* exec/sync.c: Likewise.
git-svn-id: http://svn.fedorahosted.org/svn/corosync/trunk@1982 fd59a12c-fef9-0310-b244-a6a79926bd2f
2009-04-01 09:33:23 +00:00
Jim Meyering
9bd1a8e728
declare many functions "static" (also avoids missing prototype warnings)
...
* exec/main.c (sigintr_handler, serialize_lock, serialize_unlock):
(serialize_lock, serialize_unlock):
* exec/sync.c (sync_start_init, sync_callbacks_load):
* exec/vsf_ykd.c (ykd_state_init):
* lcr/uis.c (cmd1):
* services/pload.c (send_message, token_callback, start_mcasting):
* tools/corosync-cfgtool.c (service_load_do, service_unload_do):
(shutdown_do, showaddrs_do, killnode_do, usage_do):
* tools/corosync-fplay.c (totemip_print, print_string_len):
(sync_printer_confchg_set_sync, sync_printer_set_sync_state):
(sync_printer_process_currentstate):
(sync_printer_process_get_shouldsync):
(sync_printer_checkpoint_release):
(sync_printer_checkpoint_transmit, sync_printer_section_transmit):
(sync_printer_checkpoint_receive, sync_printer_section_receive):
(sync_printer_nada, sync_printer_confchg_fn):
(printer_totemsrp_mcast, printer_totemsrp_delv):
(printer_totempg_mcast_fits, sync_printer_service_process):
* tools/corosync-objctl.c (get_child_name, get_parent_name):
(get_key):
git-svn-id: http://svn.fedorahosted.org/svn/corosync/trunk@1980 fd59a12c-fef9-0310-b244-a6a79926bd2f
2009-04-01 09:33:07 +00:00
Fabio M. Di Nitto
031c02f589
- Every .c file should include "config.h" to get the right defines...
...
- services/Makefile.am: add include search paths for config.h
- include/corosync/cs_config.h.in exports LCRSODIR and SOCKETDIR
- tools/Makefile.am: drop -D defines for dirs that are now in
cs_config.h or config.h
- configure.ac: sanitize prefix and exec_prefix paths. Export DIRS in
*config.h
- lib/Makefile.am: : drop -D defines for dirs that are now in
cs_config.h or config.h. Add rule to build lcr_ifact.o or building from
lib/ fails miserably
git-svn-id: http://svn.fedorahosted.org/svn/corosync/trunk@1877 fd59a12c-fef9-0310-b244-a6a79926bd2f
2009-03-19 12:58:53 +00:00
Steven Dake
58ab8d4a65
Unification around hdb_handle_t data type.
...
git-svn-id: http://svn.fedorahosted.org/svn/corosync/trunk@1782 fd59a12c-fef9-0310-b244-a6a79926bd2f
2009-02-25 11:14:47 +00:00
Christine Caulfield
cfc7da3573
quorum is now an optional loadable module (though I've put it into the
...
defaults in services.c) and can load another module to do the quorum
work (eg YKD which I've made more compliant too). All the quorum code
has been removed from sync.c. quorum.c is simply a shim later for the
coroapi, the main module is in vsf_quorum.c
There are coroapi calls to query quorate status and also to get
notifications when it changes.
I've included the testquorum.lcrso module in this patch because I think
it's really helpful for testing. It sets the quorum state based on an
objdb variable, this can be set or cleared using corosync-cfgtool
git-svn-id: http://svn.fedorahosted.org/svn/corosync/trunk@1704 fd59a12c-fef9-0310-b244-a6a79926bd2f
2008-12-08 15:55:41 +00:00
Angus Salkeld
56eaee9561
cleanup the last of the SAF headers and types
...
This includes the rename of identifiers from corosync to cs.
git-svn-id: http://svn.fedorahosted.org/svn/corosync/trunk@1689 fd59a12c-fef9-0310-b244-a6a79926bd2f
2008-11-06 21:49:07 +00:00
Steven Dake
0c631e24fc
Logsys flight recorder.
...
git-svn-id: http://svn.fedorahosted.org/svn/corosync/trunk@1681 fd59a12c-fef9-0310-b244-a6a79926bd2f
2008-10-30 22:25:56 +00:00
Angus Salkeld
531bd3adec
Add support for AMF (sync_request)
...
git-svn-id: http://svn.fedorahosted.org/svn/corosync/trunk@1666 fd59a12c-fef9-0310-b244-a6a79926bd2f
2008-09-17 19:04:19 +00:00
Steven Dake
dd3991c0bb
Proper rename of openais usage to corosync throughout tree.
...
git-svn-id: http://svn.fedorahosted.org/svn/corosync/trunk@1637 fd59a12c-fef9-0310-b244-a6a79926bd2f
2008-08-14 16:54:46 +00:00
Steven Dake
e1f531380a
Revert patch 1633 which breaks build.
...
git-svn-id: http://svn.fedorahosted.org/svn/corosync/trunk@1636 fd59a12c-fef9-0310-b244-a6a79926bd2f
2008-08-14 16:44:26 +00:00
Steven Dake
c4a1c7eb96
Change all occurances of openais to corosync.
...
git-svn-id: http://svn.fedorahosted.org/svn/corosync/trunk@1633 fd59a12c-fef9-0310-b244-a6a79926bd2f
2008-08-14 16:04:01 +00:00
Fabien Thomas
0c92a5e564
reorganize include file to match installed tree to build openais without installing corosync; correct some warnings and error under FreeBSD and Darwin
...
git-svn-id: http://svn.fedorahosted.org/svn/corosync/trunk@1632 fd59a12c-fef9-0310-b244-a6a79926bd2f
2008-08-14 14:59:50 +00:00
Steven Dake
617dbdf2f0
Split openais and corosync tree into two seperate repositories.
...
git-svn-id: http://svn.fedorahosted.org/svn/corosync/trunk@1622 fd59a12c-fef9-0310-b244-a6a79926bd2f
2008-08-05 13:23:46 +00:00
Steven Dake
46babc95ad
Initial move of corosync and openais trees into seperate directories.
...
git-svn-id: http://svn.fedorahosted.org/svn/corosync/trunk@1582 fd59a12c-fef9-0310-b244-a6a79926bd2f
2008-07-21 07:59:08 +00:00
Steven Dake
4cb815a6ce
Forward port of the synchronization engine into trunk.
...
git-svn-id: http://svn.fedorahosted.org/svn/corosync/trunk@1563 fd59a12c-fef9-0310-b244-a6a79926bd2f
2008-06-24 04:46:03 +00:00
Steven Dake
31779dc311
Remove totemip reference from file.
...
git-svn-id: http://svn.fedorahosted.org/svn/corosync/trunk@1560 fd59a12c-fef9-0310-b244-a6a79926bd2f
2008-06-24 04:44:36 +00:00
Steven Dake
46b0163813
Change all email addresses that were sdake@mvista.com to sdake@redhat.com.
...
git-svn-id: http://svn.fedorahosted.org/svn/corosync/trunk@1541 fd59a12c-fef9-0310-b244-a6a79926bd2f
2008-05-12 13:48:06 +00:00
Steven Dake
dcf2bb0137
Allow missing spots in the synchronization engine
...
git-svn-id: http://svn.fedorahosted.org/svn/corosync/trunk@1448 fd59a12c-fef9-0310-b244-a6a79926bd2f
2007-09-15 20:32:36 +00:00
Steven Dake
113a3c4f88
The logsys logging system. Read logsys_overview.8.
...
git-svn-id: http://svn.fedorahosted.org/svn/corosync/trunk@1428 fd59a12c-fef9-0310-b244-a6a79926bd2f
2007-09-09 06:38:10 +00:00
Steven Dake
ca24b42838
Fix problem in synchronization engine which results in possible failures of
...
the synchronization engine.
git-svn-id: http://svn.fedorahosted.org/svn/corosync/trunk@1424 fd59a12c-fef9-0310-b244-a6a79926bd2f
2007-09-09 06:12:56 +00:00
Steven Dake
cb154572a2
Patch from Renaud to report some broken Solaris porting from past.
...
git-svn-id: http://svn.fedorahosted.org/svn/corosync/trunk@1353 fd59a12c-fef9-0310-b244-a6a79926bd2f
2007-03-06 16:18:44 +00:00
Hans Feldt
97919b8d16
Cleaning up and preparing for later patch.
...
git-svn-id: http://svn.fedorahosted.org/svn/corosync/trunk@1310 fd59a12c-fef9-0310-b244-a6a79926bd2f
2006-11-17 06:57:00 +00:00
Hans Feldt
5796de0f76
- sync_abort is called if there is a new config change during synchronization
...
- a new function sync_request() that can be called by a user to execute
synchronization on request of a specified service.
git-svn-id: http://svn.fedorahosted.org/svn/corosync/trunk@1280 fd59a12c-fef9-0310-b244-a6a79926bd2f
2006-10-24 06:30:50 +00:00
Steven Dake
b6b81153bb
Make sure sync_activate is called only once per service handler.
...
git-svn-id: http://svn.fedorahosted.org/svn/corosync/trunk@1174 fd59a12c-fef9-0310-b244-a6a79926bd2f
2006-08-03 05:32:11 +00:00
Steven Dake
afb4ca0606
Use memb_ring_id_copy for alignment purposes on 64 aligned arches and keep
...
the port id in host byte order until it is used in the totem protocol stack.
git-svn-id: http://svn.fedorahosted.org/svn/corosync/trunk@1164 fd59a12c-fef9-0310-b244-a6a79926bd2f
2006-07-26 07:21:08 +00:00
Steven Dake
45ec255e2c
Fix synchronization not working properly.
...
git-svn-id: http://svn.fedorahosted.org/svn/corosync/trunk@1132 fd59a12c-fef9-0310-b244-a6a79926bd2f
2006-07-17 21:52:55 +00:00
Steven Dake
a778bba481
Proper barrier operation as requested.
...
git-svn-id: http://svn.fedorahosted.org/svn/corosync/trunk@1121 fd59a12c-fef9-0310-b244-a6a79926bd2f
2006-07-14 21:09:57 +00:00
Steven Dake
01afe82393
32/64/mixed endian support for checkpoint service.
...
git-svn-id: http://svn.fedorahosted.org/svn/corosync/trunk@1074 fd59a12c-fef9-0310-b244-a6a79926bd2f
2006-06-21 21:15:16 +00:00
Steven Dake
483a9baac7
The redundant ring take 4 patch. This includes modes for active, passive,
...
and none. Read openais.conf.5 for information regarding how to configure
redundant ring.
git-svn-id: http://svn.fedorahosted.org/svn/corosync/trunk@1032 fd59a12c-fef9-0310-b244-a6a79926bd2f
2006-05-19 19:49:40 +00:00
Hans Feldt
905ba3b406
- printouts buffered before log_setup() has been called, flushed at early exit.
...
- rests of old logging removed from all code (#define LOG_SERVICE...).
- line feed added if not in message.
- new trace() function added so that trace macros adds minimum of code and runtime penalties to user code.
- ENTER_ARGS macro changed to ENTER. ENTER macro now requires arguments.
- openais.conf.5 man page updated with logger directives.
git-svn-id: http://svn.fedorahosted.org/svn/corosync/trunk@1021 fd59a12c-fef9-0310-b244-a6a79926bd2f
2006-05-03 08:45:44 +00:00
Steven Dake
e92d65ba90
add vsf none option for those that don't want a virtual synchrony filter
...
git-svn-id: http://svn.fedorahosted.org/svn/corosync/trunk@1018 fd59a12c-fef9-0310-b244-a6a79926bd2f
2006-04-30 04:52:21 +00:00
Steven Dake
f50a6a11c8
Patch from Hans to significantly improve the logging functionality
...
read openais.conf.5 for info on how the new logging works.
git-svn-id: http://svn.fedorahosted.org/svn/corosync/trunk@995 fd59a12c-fef9-0310-b244-a6a79926bd2f
2006-04-18 19:53:18 +00:00
Steven Dake
dd18b864d8
scale part 3
...
componentize YKD dynamic linear voting algorithm
git-svn-id: http://svn.fedorahosted.org/svn/corosync/trunk@982 fd59a12c-fef9-0310-b244-a6a79926bd2f
2006-04-13 23:11:07 +00:00
Steven Dake
f52c38ffac
defect 1153
...
Fix segfault with sync service if syncronization is interrupted during recovery.
git-svn-id: http://svn.fedorahosted.org/svn/corosync/trunk@960 fd59a12c-fef9-0310-b244-a6a79926bd2f
2006-03-29 19:02:42 +00:00
Muni Bajpai
0c0cd07156
defect 1115
...
added support for reinitializing synchrony to support ongoing sync during a re-configuration.
git-svn-id: http://svn.fedorahosted.org/svn/corosync/trunk@942 fd59a12c-fef9-0310-b244-a6a79926bd2f
2006-03-07 19:40:23 +00:00
Muni Bajpai
197b23317c
defect 1115
...
fix faulty check.
git-svn-id: http://svn.fedorahosted.org/svn/corosync/trunk@941 fd59a12c-fef9-0310-b244-a6a79926bd2f
2006-03-06 22:02:47 +00:00
Muni Bajpai
cbaa6601d2
bug 1115. Fixes the synchronization algorithm which was skipping services.
...
git-svn-id: http://svn.fedorahosted.org/svn/corosync/trunk@938 fd59a12c-fef9-0310-b244-a6a79926bd2f
2006-03-06 02:44:04 +00:00
Steven Dake
62120cb81a
defect 981
...
This patch fixes a problem where the synchronization engine would not work
cross endian.
git-svn-id: http://svn.fedorahosted.org/svn/corosync/trunk@935 fd59a12c-fef9-0310-b244-a6a79926bd2f
2006-03-02 23:26:58 +00:00
Steven Dake
cf160dd9cd
Fabien's patch for the BSD/Darwin port.
...
git-svn-id: http://svn.fedorahosted.org/svn/corosync/trunk@926 fd59a12c-fef9-0310-b244-a6a79926bd2f
2006-02-21 07:32:00 +00:00
Steven Dake
f6cfe4e86e
This is a major rework of the service handling code. Now service handlers
...
can be dynamically loaded via the live component replacement service. Sync
handlers are also dynamically contributed.
It is possible to build using either dynamic loading via LCR or static
linking of the entire executive. This is controlled by the BUILD_DYNAMIC
configuration option in the Makefile.
git-svn-id: http://svn.fedorahosted.org/svn/corosync/trunk@892 fd59a12c-fef9-0310-b244-a6a79926bd2f
2006-01-20 20:40:21 +00:00
Steven Dake
7b2ddfa428
enhancement 1020
...
Adds AMF B.01.01 support - still needs alot of work
git-svn-id: http://svn.fedorahosted.org/svn/corosync/trunk@879 fd59a12c-fef9-0310-b244-a6a79926bd2f
2006-01-03 05:51:38 +00:00
Steven Dake
d920864d61
enhancement 1019
...
Modify YKD to select primary component and execute the synchronization
operation only in the main partition. In the non-primary partition, no
new requests are allowed - they are all returned with the error code
SA_AIS_ERR_TRY_AGAIN.
git-svn-id: http://svn.fedorahosted.org/svn/corosync/trunk@878 fd59a12c-fef9-0310-b244-a6a79926bd2f
2006-01-03 04:10:17 +00:00