Zdenek Kabelac
f6fdfd56e4
Add internal fs cookie
...
Add functions for handling internal lvm cookie used for
all dm_tree operations until fs_unlock is called.
2011-01-10 13:44:39 +00:00
Zdenek Kabelac
b3c6850b1c
Define DM_COOKIE_AUTO_CREATE
...
TODO: Use it also for already written code.
2011-01-10 13:42:31 +00:00
Zdenek Kabelac
95d3c5f7e1
Use strndup as GNU extension
...
strndup needs _GNU_SOURCE defined as it's GNU extension.
Remove duplicate string.h header added in previous harness commit.
2011-01-10 13:25:22 +00:00
Zdenek Kabelac
2dd15068fb
Cache config_tree
...
Start to use config_tree for cache just like vgmetadata.
When vgmetadata are erased destroy its cached config tree.
2011-01-10 13:15:57 +00:00
Zdenek Kabelac
6feecf76d4
Change import_vg_from_buffer to use config_tree
...
Change function import_vg_from_buffer() to import_vg_from_config_tree().
Instead of creating config tree inside the function allow config tree to
be passed as parameter - usable later for caching.
2011-01-10 13:13:42 +00:00
Zdenek Kabelac
12fbaae042
Add default error path for get_property
...
Set invalid property value for error path when NULL handler is passed.
Fixes use of uninitialized prop structure as we return 'v' by value.
---
2011-01-10 13:07:58 +00:00
Zdenek Kabelac
349da06cfa
Improve OCF dir support
...
Add --with-ocfdir configurable option.
Fix superfluous /usr in ocf_scriptdir instalation path.
2011-01-10 13:00:53 +00:00
Alasdair Kergon
a592016297
Add aclocal.m4 (for pkgconfig).
2011-01-07 16:27:05 +00:00
Petr Rockai
0011955f3a
Skip the api/percent test on kernels <= 2.6.32.
2011-01-07 15:04:52 +00:00
Petr Rockai
dbb55cb3e1
Add a test for the interaction of snapshots of mirrors and lvconvert --repair.
2011-01-07 14:56:52 +00:00
Petr Rockai
235ea42e59
Add a test for the interaction of transient errors and dmeventd mirror repair.
2011-01-07 14:56:10 +00:00
Petr Rockai
be294072a1
Fix a typo in the new relaxed mirror check (test/lib/check.sh).
2011-01-07 14:42:35 +00:00
Alasdair Kergon
f11781c50e
Using Fedora 14's autoreconf.
2011-01-07 14:38:34 +00:00
Petr Rockai
21ee9f3234
Remove *.t in test/api's make clean target.
2011-01-07 13:07:10 +00:00
Petr Rockai
a1da766a21
Disable activation/monitoring in testing lvm.conf by default.
2011-01-07 13:04:17 +00:00
Petr Rockai
55be86d4c7
Relax the mirror test in test/lib/check.sh.
2011-01-07 13:03:46 +00:00
Petr Rockai
2479e17526
In aux, exit 200 no longer works as skip -- replace with real skip call.
2011-01-07 13:03:04 +00:00
Petr Rockai
62fbc0a033
Fix up the make clean target in test/.
2011-01-07 12:26:02 +00:00
Zdenek Kabelac
b2c682e462
Fix memory leak in filter creation error path
...
If some allocation for peristent filter fails its memory reference
was lost, fix it by calling filter's destructor.
Fix log_error messages for failing allocation.
2011-01-06 15:29:24 +00:00
Zdenek Kabelac
ff4a77c5ca
Intentionaly ignore result from get_config_uint32
2011-01-06 15:25:07 +00:00
Zdenek Kabelac
0a9b444a60
Remove dead assignment of 'ret' value
...
Variable 'ret' assigned from _do_event() was actually not used and replaced with next
assignment without any read of the returned value.
Code is reformated - so the error path is put in the if() branch and normal
code is put after the 'if' together with FIXME comment.
FIXME lowprio: logging needs to be fixed in this code,
- multiple log_errors are printed, stacks are missing...
2011-01-06 10:45:41 +00:00
Zdenek Kabelac
4b1232984b
Remove unneeded stack prints after log_error
2011-01-06 09:45:05 +00:00
Jonathan Earl Brassow
7871d2c8e7
Reverting recent commit to disallow adding/removing mirror log while
...
removing/adding mirror images... There was already code in there to
do the job - I just didn't find it in WHATS_NEW (or in the code right
away).
2011-01-05 23:18:46 +00:00
Jonathan Earl Brassow
327dbf1078
Prevent the user from simultaneously adding a mirror log while removing
...
a mirror image (or removing a log while adding a mirror). Advise the
user to use two separate commands instead.
This issue become especially problematic when PVs are specified, as they
tend to mean different things when adding vs removing. In a command that
mixes adding and removing, it is impossible to decern exactly what the
user wants.
This change prevents bug 603912.
2011-01-05 20:02:45 +00:00
Zdenek Kabelac
2d6e83ea19
Check result of dm_snprintf for error
2011-01-05 15:10:30 +00:00
Zdenek Kabelac
5fc79ef6dc
Add sys_debug loging for unlink
...
This unlink intentionally silently ignores any errors.
It's still worth to trace its error status in debug mode.
2011-01-05 15:06:10 +00:00
Zdenek Kabelac
5c4622fd2a
Fix gcc warnings for missing headers and prototypes
...
Add missing header string.h (strcmp, strndup).
Add 'static' to fix missing prototypes gcc warning.
Remove unused variables verbose_off, TESTDIR, PREFIX.
2011-01-05 15:03:43 +00:00
Petr Rockai
e485801d49
Remove obsolete bits of support code from test/.
2011-01-05 14:15:26 +00:00
Petr Rockai
20b7fe3379
Re-enable t-lvconvert-repair-transient, avoiding the deadlock by running mkfs
...
asynchronously.
2011-01-05 14:15:01 +00:00
Zdenek Kabelac
006e5fa0ea
Add missing error path tests
2011-01-05 14:03:36 +00:00
Zdenek Kabelac
de0ae6a18f
Fail deamonization if lvmcache_init fail
...
FIXME Add proper cleanup
2011-01-05 12:59:46 +00:00
Zdenek Kabelac
1936d75b3c
Return PERCENT_INVALID for error case
...
If the percent value could not be determined return PERCENT_INVALID.
Indent function with tabs.
2011-01-05 12:33:51 +00:00
Zdenek Kabelac
a5d006d515
Remove unused variable mirr_state and its assignment
2011-01-05 12:27:56 +00:00
Zdenek Kabelac
4522d931f6
Remove dead assignment to thisfd
...
Value of 'thisfd' is not read again after its assigment
2011-01-05 12:17:19 +00:00
Petr Rockai
5d6a6bdf7b
Fix another bug in t-pvcreate-operation-md (should pass now).
2011-01-05 01:04:47 +00:00
Petr Rockai
5e79ce33d6
Add a test for RHBZ 640621 (metadata/dirs + no PV MDAs broken).
2011-01-05 01:00:34 +00:00
Petr Rockai
7271b0afea
Fix typo in t-pvcreate-operation-md.sh.
2011-01-05 00:38:41 +00:00
Petr Rockai
da6e9afebf
Move the mkdtemp functionality into test/lib/utils.sh.
2011-01-05 00:26:19 +00:00
Petr Rockai
92ebc9219e
Fix a couple of bugs in the new (test/lib/)aux.sh.
2011-01-05 00:25:07 +00:00
Petr Rockai
1b7c4b9bce
Substantial rework of the functional test support code. Some new features:
...
- somewhat neater, more consistent and more readable output
- possible to set any lvm.conf value: aux lvmconf "section/key = value"
- LVM_TEST_NODEBUG to suppress the (lengthy) "## DEBUG" output
- back-substitution on test output ($TESTDIR/$PREFIX -> @TESTDIR@/@PREFIX@)
- support code moved from test/ to test/lib/ --> less clutter
2011-01-05 00:16:18 +00:00
Jonathan Earl Brassow
63bd9ec3ff
Fix bug 635949: lvconvert man page clarification
2011-01-04 21:41:35 +00:00
Jonathan Earl Brassow
76e0e1d0eb
Change to correct cmirrord return code is user visible - update WHATS_NEW
...
file.
2011-01-04 21:33:06 +00:00
Jonathan Earl Brassow
f25f57ae75
Fix bug 632681: cmirrord shouldn't fail 'start' if already started
...
Return 0 from the cmirrord init script if the daemon is already
running.
http://refspecs.freestandards.org/LSB_3.1.1/LSB-Core-generic/LSB-Core-generic/iniscrptact.html
2011-01-04 21:16:54 +00:00
Peter Rajnoha
8d5391f1c3
Export DM_CONTROL_NODE_UMASK and use it while creating /dev/mapper/control.
2011-01-04 14:43:53 +00:00
Petr Rockai
9a09ca42d2
Use system assert in test/api/percent.c, for now.
2011-01-03 15:07:39 +00:00
Milan Broz
fadd934150
Fix wrongly paired unlocking of global lock in pvchange. (2.02.66)
2010-12-23 14:23:30 +00:00
Zdenek Kabelac
0ddb15964a
Remove check for existance of vg pointer
...
Checking for vg being != NULL in this place is not needed.
Pointer vg is already dereferced in this function above this code line.
Also this internal function _read_pv is always called with valid 'vg' pointer.
2010-12-22 15:44:09 +00:00
Zdenek Kabelac
2ae2ca89bf
Add backtraces for backup and backup_remove fail paths
2010-12-22 15:36:41 +00:00
Zdenek Kabelac
bd43da4f9d
Hide unused code into if 0
...
Make it obvious for lcov coverage and static analyzis we
are not interested in this piece of code.
2010-12-22 15:32:15 +00:00
Zdenek Kabelac
4388a09b0f
Detect errors from dm_task_set calls
...
Check for errors in dm_task_set calls.
Use goto_bad macro with stack trace.
Replace label failed: with bad:.
2010-12-22 15:28:44 +00:00