Zdenek Kabelac
a23f91ad2f
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
4fef104bf1
Define DM_COOKIE_AUTO_CREATE
...
TODO: Use it also for already written code.
2011-01-10 13:42:31 +00:00
Zdenek Kabelac
57f8bc3081
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
40fbdb71bd
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
7cbf6fa3a6
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
019423f769
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
4114ac5d22
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
1a2e58b067
Add aclocal.m4 (for pkgconfig).
2011-01-07 16:27:05 +00:00
Petr Rockai
9ce215ed01
Skip the api/percent test on kernels <= 2.6.32.
2011-01-07 15:04:52 +00:00
Petr Rockai
ad7bccb8ea
Add a test for the interaction of snapshots of mirrors and lvconvert --repair.
2011-01-07 14:56:52 +00:00
Petr Rockai
3621b75306
Add a test for the interaction of transient errors and dmeventd mirror repair.
2011-01-07 14:56:10 +00:00
Petr Rockai
14908e3a3b
Fix a typo in the new relaxed mirror check (test/lib/check.sh).
2011-01-07 14:42:35 +00:00
Alasdair Kergon
7ce032b99d
Using Fedora 14's autoreconf.
2011-01-07 14:38:34 +00:00
Petr Rockai
dcaf6313af
Remove *.t in test/api's make clean target.
2011-01-07 13:07:10 +00:00
Petr Rockai
b74d30d55a
Disable activation/monitoring in testing lvm.conf by default.
2011-01-07 13:04:17 +00:00
Petr Rockai
9c705ce71e
Relax the mirror test in test/lib/check.sh.
2011-01-07 13:03:46 +00:00
Petr Rockai
16af1b083b
In aux, exit 200 no longer works as skip -- replace with real skip call.
2011-01-07 13:03:04 +00:00
Petr Rockai
f4d63e9e58
Fix up the make clean target in test/.
2011-01-07 12:26:02 +00:00
Zdenek Kabelac
cae4882865
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
9d4bb244e3
Intentionaly ignore result from get_config_uint32
2011-01-06 15:25:07 +00:00
Zdenek Kabelac
41b1b9487c
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
6c1db4a7d6
Remove unneeded stack prints after log_error
2011-01-06 09:45:05 +00:00
Jonathan Earl Brassow
7b0c0103a9
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
ef6ec3f737
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
78269c2110
Check result of dm_snprintf for error
2011-01-05 15:10:30 +00:00
Zdenek Kabelac
eb91c54467
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
56b6c12e8a
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
6507ce98df
Remove obsolete bits of support code from test/.
2011-01-05 14:15:26 +00:00
Petr Rockai
2fbadde558
Re-enable t-lvconvert-repair-transient, avoiding the deadlock by running mkfs
...
asynchronously.
2011-01-05 14:15:01 +00:00
Zdenek Kabelac
5a363d74f2
Add missing error path tests
2011-01-05 14:03:36 +00:00
Zdenek Kabelac
b2817688ac
Fail deamonization if lvmcache_init fail
...
FIXME Add proper cleanup
2011-01-05 12:59:46 +00:00
Zdenek Kabelac
659b348a44
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
6990a8c942
Remove unused variable mirr_state and its assignment
2011-01-05 12:27:56 +00:00
Zdenek Kabelac
98b4ee635d
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
7d048d52f6
Fix another bug in t-pvcreate-operation-md (should pass now).
2011-01-05 01:04:47 +00:00
Petr Rockai
41fb54489f
Add a test for RHBZ 640621 (metadata/dirs + no PV MDAs broken).
2011-01-05 01:00:34 +00:00
Petr Rockai
3be9ec308a
Fix typo in t-pvcreate-operation-md.sh.
2011-01-05 00:38:41 +00:00
Petr Rockai
f120a17b1d
Move the mkdtemp functionality into test/lib/utils.sh.
2011-01-05 00:26:19 +00:00
Petr Rockai
fc7054c150
Fix a couple of bugs in the new (test/lib/)aux.sh.
2011-01-05 00:25:07 +00:00
Petr Rockai
cde70f94db
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
8f0f328dbf
Fix bug 635949: lvconvert man page clarification
2011-01-04 21:41:35 +00:00
Jonathan Earl Brassow
10e3bdcce3
Change to correct cmirrord return code is user visible - update WHATS_NEW
...
file.
2011-01-04 21:33:06 +00:00
Jonathan Earl Brassow
bc036c01cb
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
c14f565d18
Export DM_CONTROL_NODE_UMASK and use it while creating /dev/mapper/control.
2011-01-04 14:43:53 +00:00
Petr Rockai
f56007d95f
Use system assert in test/api/percent.c, for now.
2011-01-03 15:07:39 +00:00
Milan Broz
65599cfb58
Fix wrongly paired unlocking of global lock in pvchange. (2.02.66)
2010-12-23 14:23:30 +00:00
Zdenek Kabelac
39b2b95477
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
e65561feae
Add backtraces for backup and backup_remove fail paths
2010-12-22 15:36:41 +00:00
Zdenek Kabelac
2a2170efc0
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
adb5fb90b1
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