Fixing some makesfiles, so that the correct things link against pthreads.
Also changed dmevent so that in no longer links against pthreads, and
dynamically loads libdmevent.so. Everything seems to work just fine like this.
Timeout event implementation:
The daemon side of this is mostly the same as the patch I sent out. To select
a timeout period different than the default and to get the timeout period,
I added two library calls, dm_set_event_timeout() and dm_get_event_timeout().
If people are against them, the other option is to tack extra arguments onto
dm_regiser_for_event() and dm_get_registered_device(). I also added a
-t option to dmevent, so people can try out timeouts.
Alasdair Kergon [Fri, 3 Jun 2005 14:49:51 +0000 (14:49 +0000)]
Always insert an intermediate layer for mirrors.
Suppress hidden LVs from reports unless --all is given.
Use square brackets for hidden LVs in reports.
Centralise restrictions on LV names.
AJ Lewis [Wed, 25 May 2005 21:08:36 +0000 (21:08 +0000)]
Change the multilog code to toggle between async and sync writes for all
log types. This means the threaded_syslog type is no longer valid. A new
fxn multilog_async is available to toggle between the two modes. If an
app is compiled without pthreads and tries to use async logging, no logging
will occur while async is enabled.
dmeventd has been modified to use the new code
I'm not positive I like the way the async_logger code calls the log fxn,
but it works for now. Suggestions for other ways to do it would be helpful
AJ Lewis [Wed, 11 May 2005 15:21:44 +0000 (15:21 +0000)]
more clvmd rhel4 initscript cleanup
- don't echo after an 'action' call - action does the echo itself
- use vgdisplay/vgs to determine which VGs are marked clustered and only
deactivate those VGs (unless the LVM_VGS var is set in
/etc/sysconfig/cluster)
AJ Lewis [Mon, 9 May 2005 18:44:35 +0000 (18:44 +0000)]
o Changed the multilog API a bit (I warned you)
- multilog_add_type, multilog_del_type, multilog_custom, and
multilog_init_verbose all have different arguments.
- Primary change is that caller only passes in config info, and the
lib keeps track of state internally. No more exporting of
'struct log_data'.
- Custom callers now only get the custom data pointer passed into their
log fxn (that is set with multilog_custom)
- Added basic README that describes libmultilog
fixed dmevent so that it doesn't do a double free when you run
# dmevent -l
Also, changed the behaviour of dm_get_registered_device(), so that it doesn't
change the pointer you passed in without freeing the memory on a non-next call,
and doesn't free your pointer without setting it to NULL on a failed next call.
o libmultilog needs introducing of list locking in order to stand
multilog_add_type()/multilog_del_type cycles correctly.
o fixed segfault in multilog_add_type()
o fixed test-multilog.c
o cleaned up libmultilog (list macros, indentation, braces, comments)
- make noop use multilog
- add event_nr to thread_status struct and set appropriately so that the
thread actually waits for an event
- essentially make error_detected return true. Let the DSOs determine
how to interpret the status info
AJ Lewis [Tue, 3 May 2005 21:29:13 +0000 (21:29 +0000)]
o stick multilog into the dm-event lib and dmeventd code again
o more tweaks to libmultilog calls - the api isn't set in stone yet, so
don't get too comfortable.
o not sure the dmeventd in device-mapper/dmeventd works - i've been using
the one in lib/event/
o currently both daemons are set to log only to syslog
dmeventd was looking for dsos with libdmeventd<name>.so
The Makefile turned noop.c into libdmeventnoop.so
The Makefile now turns noop.c into libdmeventdnoop.so