| Commit message (Collapse) | Author | Age | Files | Lines |
| |
|
|
|
|
| |
(Haven't checked error path handling though)
|
|
|
|
| |
lvm.conf *and* lvmetad is running.
|
|
|
|
| |
lvmcache.c). No functional change.
|
|
|
|
|
|
|
|
| |
Move the free_vg() to vg.c and replace free_vg with release_vg
and make the _free_vg internal.
Patch is needed for sharing VG in vginfo cache so the release_vg function name
is a better fit here.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Fixing some const warnings - with API change in:
int vg_extend(struct volume_group *vg, int pv_count, const char *const *pv_names,
Change is needed - as lvm2api expects const behaviour here.
So vg_extend() is doing local strdup for unescaping.
skip_dev_dir return const char* from const char* vg_name.
Rest of the patch is cleanup of related warnings.
Also using dm_report_filed_string() API change to simplify
casting in _string_disp and _lvname_disp.
|
| |
|
| |
|
| |
|
| |
|
|
|
|
|
| |
There is no difference from lvs_in_vg_activated now,
convert all users to this call.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
lvm_list_vg_uuids() functions
where we should not expose internal VG names/uuids (the ones with "#" prefix )through the
interface. Otherwise, we could end up with library users opening internal VGs which will
initiate locking mechanism that won't be cleaned up properly.
"#orphans_{lvm1, lvm2, pool}" names are treated in a special way, they are truncated first
to "orphans" and this is used as a part of the lock name then (e.g. while calling lvm_vg_open()).
When library user calls lvm_vg_close(), the original name "orphans_{lvm1, lvm2, pool}"
is used directly and therefore no unlock occurs.
We should exclude internal VG names and uuids in the lists provided by lvmcache:
lvmcache_get_vgids() and lvmcache_get_vgnames().
|
|
|
|
|
| |
Make readonly locking available as locking type 4.
Fix readonly locking to permit writeable global locks (for vgscan). (2.02.49)
|
|
|
|
|
|
|
| |
Should be no functional change.
Author: Dave Wysochanski <dwysocha@redhat.com>
|
|
|
|
|
|
|
|
| |
Should be no functional change.
Will allow us to reorder lock obtaining if needed.
Author: Dave Wysochanski <dwysocha@redhat.com>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Fix vg_read() error paths to properly release upon vg_read_error().
Note that in the iterator paths (process_each_*()), we release
inside the iterator so no individual cleanup is needed. However there
are a number of other places we missed the cleanup. Proper cleanup
when vg_read_error() is true should be calling vg_release(vg), since
there should be no locks held if we get an error (except in certain
special cases, which IMO we should work to remove from the code).
Unfortunately the testsuite is unable to detect these types of memory
leaks. Most of them can be easily seen if you try an operation
(e.g. lvcreate) with a volume group that does not exist. Error
message looks like this:
Volume group "vg2" not found
You have a memory leak (not released memory pool):
[0x1975eb8]
You have a memory leak (not released memory pool):
[0x1975eb8]
Author: Dave Wysochanski <dwysocha@redhat.com>
|
|
|
|
|
|
|
|
|
|
| |
Sun May 3 12:54:28 CEST 2009 Petr Rockai <me@mornfall.net>
* Convert vgrename to vg_read_for_update.
Rebased 6/26/2009 - Dave W.
Author: Petr Rockai <prockai@redhat.com>
Committer: Dave Wysochanski <dwysocha@redhat.com>
|
| |
|
| |
|
|
|
|
|
|
|
|
|
| |
As a simplification to the tools and further liblvm, this patch pushes
the setting of NON_BLOCKING lock flag inside the lock_vol() call.
The policy we set is if any existing VGs are currently locked, we
set the NON_BLOCKING flag.
Should be no functional change.
|
| |
|
|
|
|
| |
Author: Takahiro Yasui <tyasui@redhat.com>
|
| |
|
| |
|
| |
|
| |
|
|
|
|
| |
rename variable to reduce confusion
|
| |
|
| |
|
|
|
|
|
| |
Add (empty) orphan VGs to lvmcache during initialisation.
Fix orphan VG name used for format_pool.
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Update vgrename to call validate_vg_rename_params().
Fix vgcreate and vgsplit default arguments by adding defaults parameter to
fill_vg_create_params().
Add t-vgrename-usage.sh test.
Bugzilla: bz251992
---
tools/toollib.c | 32 ++++++++------------------------
tools/toollib.h | 5 ++---
tools/vgcreate.c | 35 +++++++++++++++++++++--------------
tools/vgrename.c | 35 ++++++-----------------------------
tools/vgsplit.c | 21 ++++++++++++++-------
5 files changed, 51 insertions(+), 77 deletions(-)
|
|
|
|
|
|
|
|
| |
Fix missing VG unlocks in some pvchange error paths.
Add some missing validation of VG names.
Rename validate_vg_name() to validate_new_vg_name().
Change orphan lock to VG_ORPHANS.
Change format1 to use ORPHAN as orphan VG name.
|
| |
|
| |
|
| |
|
| |
|
| |
|
| |
|
|
|
|
| |
Add fallback_to_clustered_locking and fallback_to_local_locking parameters.
|
| |
|
|
|
|
|
|
|
| |
Fix some memory leaks in error paths found by coverity.
Use C99 struct initialisers.
Move DEFS into configure.h.
Clean-ups to remove miscellaneous compiler warnings.
|
| |
|
|
|
|
| |
Add vgid to struct physical_volume and pass with vg_name to some functions.
|
| |
|
| |
|
| |
|
| |
|
| |
|
| |
|