Alasdair Kergon
d3efe22fa2
Fix read-only identical table reload supression.
2011-07-24 23:59:03 +00:00
Zdenek Kabelac
830df40482
Compare also file size to detect changed config file
...
Clvmd detects modifed config file before it takes lv_lock.
If the config file is changed rapidly - the change was ignored within
a seocnd ranged. This patch adds also compare of file size.
So change like some flag for 0 to 1 would pass unnoticed - but
it's quick fix for failing test suite.
FIXME: Implement inotify solution.
2011-07-21 13:23:48 +00:00
Petr Rockai
c2ca1a707a
lvmetad: Obliterate vg_status by returning the same information from
...
update_pv_status, saving a dozen lines of code and execution time of one
walkthrough of the PV list.
2011-07-20 21:33:41 +00:00
Petr Rockai
bc0a902434
lvmetad: Fix a possible infinite loop in vg_status.
2011-07-20 21:27:28 +00:00
Petr Rockai
fba6c62b84
lvmetad: Robustify update_pv_status and remove an useless lookup.
2011-07-20 21:26:18 +00:00
Petr Rockai
0cfb99d385
First stab at making lvmetad-core threadsafe. The current design should allow
...
very reasonable amount of parallel access, although the hash tables may become
a point of contention under heavy loads. Nevertheless, there should be orders
of magnitude less contention on the hash table locks than we currently have on
block device scanning.
2011-07-20 21:23:43 +00:00
Petr Rockai
dcbf5a3b5d
lvmetad: Avoid stale PV -> VG mappings on metadata update.
2011-07-20 18:45:32 +00:00
Petr Rockai
cd7bca83e1
Optimise PV -> VG lookups by using a UUID (hash) map.
2011-07-20 18:34:57 +00:00
Petr Rockai
652e0757c9
Free up allocated memory before exiting, in lvmetad.
2011-07-20 18:24:49 +00:00
Petr Rockai
a720420466
Fix two small (but eventually unbounded) leaks in daemon-server.c.
2011-07-20 18:23:33 +00:00
Petr Rockai
42e23dbf6c
Can't have a global memory pool in lvmetad (that would constitute an ongoing
...
memory leak) => remove it (it's been unused anyway).
2011-07-20 16:49:21 +00:00
Petr Rockai
50ff3c076e
Make lvmetad also report VGID in reply when adding a PV without MDAs (this
...
obviously only works for VGs that already had at least some MDA discovered).
2011-07-20 16:46:40 +00:00
Petr Rockai
4eb53158e5
Add code to lvmetad's testclient that scans an actual physical device,
...
effectively emulating a future "pvscan --lvmetad" command.
2011-07-20 15:15:41 +00:00
Petr Rockai
c33d33bab7
Make lvmetad report the VG ID and status (complete, partial) in reply to pv_add
...
requests.
2011-07-20 15:14:17 +00:00
Petr Rockai
2ef620ec7f
Towards MISSING (PV) flag management in lvmetad.
2011-07-19 19:15:22 +00:00
Petr Rockai
0a305e9666
Make it possible to represent type-correct single-item arrays in config trees.
2011-07-19 19:12:38 +00:00
Petr Rockai
cc6032956f
Add an API to config.h for creating values in the config_tree mempool.
2011-07-19 19:11:24 +00:00
Petr Rockai
3c238baf03
Work out some more details in metadata update in lvmetad.
2011-07-19 16:48:13 +00:00
Jonathan Earl Brassow
7411a44871
Remove and unneeded parameter from build_parallel_areas_from_lv()
2011-07-19 16:37:42 +00:00
Jonathan Earl Brassow
aa6599e687
Fix potential null ptr deref in 'origin_from_cow'
...
return NULL rather than segfaulting if lv->snapshot is not set
2011-07-19 16:23:52 +00:00
Petr Rockai
9796bd4db6
More work on cache maintenance code in lvmetad: keep track of PV status.
2011-07-19 14:13:59 +00:00
Petr Rockai
252853560c
Start filling in the core LVMetaD functionality and the corresponding
...
testclient bits.
2011-07-18 14:48:30 +00:00
Petr Rockai
372e9b3d64
Various improvements to the daemon-common code, including automated response
...
formatting from config trees provided by the daemon implementation.
2011-07-18 14:46:54 +00:00
Petr Rockai
aac236f4a8
Improve format_buffer in daemon-shared.c, adding block formatting in addition
...
to string/integer (this propagates to the *simple* family of request/response
functionality).
2011-07-18 14:42:44 +00:00
Petr Rockai
542b0d0a65
Revert the #include changes. Need to fix this at the #include site for now, and
...
eventually refactor the way we structure #includes in the all of the library.
2011-07-18 14:34:33 +00:00
Petr Rockai
2710477deb
Slightly refactor the config code to allow better reuse (no functional change).
2011-07-18 13:26:08 +00:00
Petr Rockai
9c1f6bc985
Add a missing libdevmapper.h #include to lvm-types.h (for dm_list).
2011-07-18 13:24:48 +00:00
Petr Rockai
a1adf38cab
Add a couple missing #includes in uuid.h.
2011-07-18 13:24:14 +00:00
Zdenek Kabelac
80869133f2
Better version of failing 'should' test
...
where the naming is left completely on lvm.
(Commited code has been different version of test).
So here it should be able to figure out new free name and create a new LV.
2011-07-18 12:12:41 +00:00
Zdenek Kabelac
8e97096fa2
Adding test for repair when confusing metadata are found
2011-07-18 12:04:42 +00:00
Jonathan Earl Brassow
4ebbd137de
LVM2 RAID design doc
2011-07-14 17:00:59 +00:00
Petr Rockai
4ded6393df
Fix t-vgreduce-usage to stop relying on the persistent cache not seeing a
...
device that has been brought back from the dead: this sometimes fails with
clvmd (the cache is updated "too soon"). Instead, force a pvscan and rely on an
up-to-date cache as usual.
2011-07-11 12:13:07 +00:00
Alasdair Kergon
11853cd95a
post-release
2011-07-08 19:57:32 +00:00
Alasdair Kergon
6585b5a197
remove unnecessary lvconvert.h
2011-07-08 19:42:11 +00:00
Alasdair Kergon
9f65343fa6
pre-release
2011-07-08 19:19:44 +00:00
Alasdair Kergon
b6793963e9
Downgrade error message - it isn't strictly an internal error in the
...
library, and the known cause within lvm2 got fixed.
2011-07-08 19:13:05 +00:00
Alasdair Kergon
730cfc74b8
move doc to doc dir
2011-07-08 18:55:28 +00:00
Alasdair Kergon
574f7c61da
missing ifdef when new fn unused
2011-07-08 17:31:06 +00:00
Alasdair Kergon
3151e0995a
Remove dev name prefix from dmsetup line output if exactly one dev requested.
2011-07-08 17:08:19 +00:00
Alasdair Kergon
1485b6fc93
Ignore activation/verify_udev_operations if dm kernel driver vsn < 4.18.
2011-07-08 16:49:04 +00:00
Milan Broz
d8ff1b1efb
Fix warning for pvcreate over MD linear.
...
If MD linear device has set rounding (overload chunk size attribute),
the pvcreate command prints this warning:
/dev/md0 sysfs attr level not in expected format: linear
2011-07-08 15:53:59 +00:00
Alasdair Kergon
a73e9a6cfa
Need to snapshot lookup by uuid instead of name in case it's renamed.
2011-07-08 15:35:50 +00:00
Alasdair Kergon
32b7009196
Log cookie values when incrementing/decrementing to give clues about races.
2011-07-08 15:34:47 +00:00
Alasdair Kergon
c9ff339c23
Move snapshot removal activation logic into lib/activate.
2011-07-08 12:49:50 +00:00
Alasdair Kergon
ee840ff14c
Move snapshot deactivation logic into lib/activate, fixing the
...
teardown sequence. (Previously the snapshot was deactivated while its
origin was active and before its removal was committed to disk, so
restarting after a crash at the point would leave corruption.)
2011-07-08 12:48:41 +00:00
Alasdair Kergon
c837830f6a
report which dev was not found
2011-07-08 12:35:48 +00:00
Zdenek Kabelac
a6fc6250e0
Increase timeout for udev settle
...
For some unknown reason (atm) udev settle takes longer time on recent rawhide.
To pass the test - inrease the settle timeout.
2011-07-08 10:05:43 +00:00
Alasdair Kergon
f5f3defc02
Cope with a PV only discovered missing when creating deptree.
2011-07-06 00:29:44 +00:00
Alasdair Kergon
86b15c7c90
Abort operation if dm_tree_node_add_target_area fails.
2011-07-05 23:10:14 +00:00
Alasdair Kergon
3a8eb3870e
Always perform preload logic before suspending - not only in the case when we
...
have precommitted metadata. (Necessary to avoid loading tables
while suspend in lvchange --refresh.)
2011-07-05 18:36:37 +00:00