]> sourceware.org Git - lvm2.git/log
lvm2.git
15 years agoDistinguish between powers of 1000 and powers of 1024 in unit suffixes.
Alasdair Kergon [Wed, 30 Sep 2009 14:19:00 +0000 (14:19 +0000)]
Distinguish between powers of 1000 and powers of 1024 in unit suffixes.

15 years agoJust a cleanup from previous commit. We don't need pvname local var in _activate_lvs_...
Peter Rajnoha [Wed, 30 Sep 2009 12:05:25 +0000 (12:05 +0000)]
Just a cleanup from previous commit. We don't need pvname local var in _activate_lvs_in_vg anymore...

15 years agolook up pvmove by pvmove LV when PVMOVE flag is set
Alasdair Kergon [Tue, 29 Sep 2009 20:33:49 +0000 (20:33 +0000)]
look up pvmove by pvmove LV when PVMOVE flag is set

15 years agoDon't attempt to restart pvmoves when deactivating LVs in vgchange.
Alasdair Kergon [Tue, 29 Sep 2009 20:22:35 +0000 (20:22 +0000)]
Don't attempt to restart pvmoves when deactivating LVs in vgchange.
Restart lvconverts in vgchange by sharing lv_spawn_background_polling.

15 years agoGeneralise polldaemon code by changing mirror-specific variable names.
Alasdair Kergon [Tue, 29 Sep 2009 19:35:26 +0000 (19:35 +0000)]
Generalise polldaemon code by changing mirror-specific variable names.

15 years agoDon't attempt to deactivate an LV if any of its snapshots are in use.
Alasdair Kergon [Tue, 29 Sep 2009 18:50:28 +0000 (18:50 +0000)]
Don't attempt to deactivate an LV if any of its snapshots are in use.

15 years agoReturn fail if lv_deactivate did not removed device from kernel.
Milan Broz [Tue, 29 Sep 2009 15:17:54 +0000 (15:17 +0000)]
Return fail if lv_deactivate did not removed device from kernel.

lv_deactivate now returns always success, because tree deactivation
functions (see dm_tree_deactivate_children) always returns success.

Because code should return failure in lv_deactivate at least,
fix it by checking for device existence after real deactivation call.

(After discussion this was prefered solution to dm tree function rewrite
which affects snapshots and mirrors.)

15 years agoTrivial cleanup to lvcreate man page - use virtualsize in example.
Dave Wysochanski [Tue, 29 Sep 2009 15:11:06 +0000 (15:11 +0000)]
Trivial cleanup to lvcreate man page - use virtualsize in example.

virtualsize replaced virtualoriginsize but the example was never updated.

15 years agoProvide alternative implementation of obsolete siginterrupt().
Alasdair Kergon [Mon, 28 Sep 2009 21:23:02 +0000 (21:23 +0000)]
Provide alternative implementation of obsolete siginterrupt().

15 years agoConsolidate LV allocation into alloc_lv().
Alasdair Kergon [Mon, 28 Sep 2009 17:46:15 +0000 (17:46 +0000)]
Consolidate LV allocation into alloc_lv().

15 years agoTreat input units of both 's' and 'S' as 512-byte sectors. (2.02.49)
Alasdair Kergon [Mon, 28 Sep 2009 16:36:03 +0000 (16:36 +0000)]
Treat input units of both 's' and 'S' as 512-byte sectors.  (2.02.49)

's' and 'S' are special suffixes representing sectors and are always 512 bytes,
regardless of whether you're using powers of 1000 or 1024.

15 years agoAdd global/si_unit_consistency to enable cleaned-up use of units in output.
Alasdair Kergon [Mon, 28 Sep 2009 16:23:44 +0000 (16:23 +0000)]
Add global/si_unit_consistency to enable cleaned-up use of units in output.
Add configure --enable-units-compat to set si_unit_consistency off by default.

Use standard output units for 'PE Size' and 'Stripe size' in pv/lvdisplay.

15 years agopost-release
Alasdair Kergon [Sat, 26 Sep 2009 00:42:47 +0000 (00:42 +0000)]
post-release

15 years agoFix log fn prototype.
Alasdair Kergon [Sat, 26 Sep 2009 00:29:13 +0000 (00:29 +0000)]
Fix log fn prototype.

15 years agomissing dm_snprintf
Alasdair Kergon [Fri, 25 Sep 2009 19:06:05 +0000 (19:06 +0000)]
missing dm_snprintf

15 years agopre-release
Alasdair Kergon [Fri, 25 Sep 2009 18:30:27 +0000 (18:30 +0000)]
pre-release

15 years agopre-release
Alasdair Kergon [Fri, 25 Sep 2009 18:30:26 +0000 (18:30 +0000)]
pre-release

15 years agoensure dm_strdup succeeds
Alasdair Kergon [Fri, 25 Sep 2009 18:19:09 +0000 (18:19 +0000)]
ensure dm_strdup succeeds

15 years agoremove unused var & rename fn
Alasdair Kergon [Fri, 25 Sep 2009 18:13:17 +0000 (18:13 +0000)]
remove unused var & rename fn

15 years agoHandle any path supplied to dm_task_set_name() by looking up in /dev/mapper.
Alasdair Kergon [Fri, 25 Sep 2009 18:08:04 +0000 (18:08 +0000)]
Handle any path supplied to dm_task_set_name() by looking up in /dev/mapper.

15 years agoUse the same default umask for /dev dirs (DM_DEV_DIR_UMASK).
Peter Rajnoha [Fri, 25 Sep 2009 11:58:00 +0000 (11:58 +0000)]
Use the same default umask for /dev dirs (DM_DEV_DIR_UMASK).

15 years agoAdd more hints in 12-dm-permissions.rules. Add 'dmsetup splitname' and 'y|--yes'...
Peter Rajnoha [Wed, 23 Sep 2009 12:52:52 +0000 (12:52 +0000)]
Add more hints in 12-dm-permissions.rules. Add 'dmsetup splitname' and 'y|--yes' to dmsetup manpage.

15 years ago'_emit_areas_line' returns 1 for success and 0 for failure. This always
Jonathan Earl Brassow [Tue, 22 Sep 2009 16:26:59 +0000 (16:26 +0000)]
'_emit_areas_line' returns 1 for success and 0 for failure.  This always
confuses me, so I've added a comment at the top of the function to
remind me of this.

I also found that 'mirror_emit_segment_line' was returning 0 (return_0)
on failure /and/ success.  It now returns 1 for success and 0 for failure -
just like '_emit_areas_line' and its calling function, '_emit_segment_line'.

15 years agoMinor replace of of ${top_srcdir} with $(top_srcdir) for lcov target
Zdenek Kabelac [Tue, 22 Sep 2009 13:32:39 +0000 (13:32 +0000)]
Minor replace of of ${top_srcdir} with $(top_srcdir) for lcov target

15 years agoAdd some advisory comments for users in 12-dm-permissions.rules.
Peter Rajnoha [Tue, 22 Sep 2009 12:03:32 +0000 (12:03 +0000)]
Add some advisory comments for users in 12-dm-permissions.rules.

15 years agoFix dmeventd _temporary_log_fn parameters. (2.02.50)
Alasdair Kergon [Thu, 17 Sep 2009 10:37:23 +0000 (10:37 +0000)]
Fix dmeventd _temporary_log_fn parameters. (2.02.50)

15 years agoEnable dmeventd monitoring section of config file by default.
Alasdair Kergon [Wed, 16 Sep 2009 23:48:41 +0000 (23:48 +0000)]
Enable dmeventd monitoring section of config file by default.

15 years agodrop -ing suffix
Alasdair Kergon [Wed, 16 Sep 2009 23:40:19 +0000 (23:40 +0000)]
drop -ing suffix

15 years agoUpdate lvm2_monitoring script.
Alasdair Kergon [Wed, 16 Sep 2009 23:22:40 +0000 (23:22 +0000)]
Update lvm2_monitoring script.

15 years agoFix lvm2app test to run under test/api subdirectory only when configured.
Dave Wysochanski [Tue, 15 Sep 2009 19:59:04 +0000 (19:59 +0000)]
Fix lvm2app test to run under test/api subdirectory only when configured.

15 years agoAdd vg_is_resizeable() and cleanup references.
Dave Wysochanski [Tue, 15 Sep 2009 18:35:13 +0000 (18:35 +0000)]
Add vg_is_resizeable() and cleanup references.

Clean up VG_RESIZEABLE flag by creating vg_is_resizeable().
Update comment - we no longer have ALLOW_RESIZEABLE.
Also use vg_is_exported() in one place missed by earlier patch.
Should be no functional change.

15 years agoRemove test/api which should only be under 'make test'.
Alasdair Kergon [Tue, 15 Sep 2009 15:37:12 +0000 (15:37 +0000)]
Remove test/api which should only be under 'make test'.

15 years agopost-release
Alasdair Kergon [Tue, 15 Sep 2009 13:54:28 +0000 (13:54 +0000)]
post-release

15 years agopre-release cleanup
Alasdair Kergon [Tue, 15 Sep 2009 13:49:10 +0000 (13:49 +0000)]
pre-release cleanup

15 years agomissing (C) reminders
Alasdair Kergon [Tue, 15 Sep 2009 12:51:28 +0000 (12:51 +0000)]
missing (C) reminders

15 years agodm release cleanup
Alasdair Kergon [Tue, 15 Sep 2009 11:41:38 +0000 (11:41 +0000)]
dm release cleanup

15 years agopre-release
Alasdair Kergon [Tue, 15 Sep 2009 10:57:16 +0000 (10:57 +0000)]
pre-release

15 years agoFix process_each_vg / _process_one_vg when vg_read() returns FAILED_LOCKING.
Dave Wysochanski [Tue, 15 Sep 2009 01:38:59 +0000 (01:38 +0000)]
Fix process_each_vg / _process_one_vg when vg_read() returns FAILED_LOCKING.

Remove the checks for vg_read_error() in most of the tools callback
functions and instead make the check in _process_one_vg() more general.

In all but vgcfgbackup, we do not want to proceed if we get any error
from vg_read().  In vgcfgbackup's case, we may proceed if the backup
is to proceed with inconsistent VGs.  This is a special case though,
and we mark it with the READ_ALLOW_INCONSISTENT flag passed to
process_each_vg (and subsequently to _process_one_vg).

NOTE: More cleanup is needed in the vg_read_error() path cases.
This patch is a start.

15 years agoMore cmirror makefile fixes from Fabio.
Alasdair Kergon [Mon, 14 Sep 2009 22:57:46 +0000 (22:57 +0000)]
More cmirror makefile fixes from Fabio.

15 years agoFix build failure when enabling dmeventd and applib.
Dave Wysochanski [Mon, 14 Sep 2009 22:56:27 +0000 (22:56 +0000)]
Fix build failure when enabling dmeventd and applib.

This patch fixes a build with options similar to the following:
./configure --enable-debug --enable-applib --enable-dmeventd --enable-cmdlib

15 years agoAdd lots of missing stack debug messages to tools.
Alasdair Kergon [Mon, 14 Sep 2009 22:47:49 +0000 (22:47 +0000)]
Add lots of missing stack debug messages to tools.
Make readonly locking available as locking type 4.
Fix readonly locking to permit writeable global locks (for vgscan). (2.02.49)

15 years agoUse vg_is_exported(vg) macro everywhere.
Dave Wysochanski [Mon, 14 Sep 2009 19:44:15 +0000 (19:44 +0000)]
Use vg_is_exported(vg) macro everywhere.

This patch is all just cleanup and no other patch depends on it.
Replace explicit dereference and check with vg_is_exported().
Update a few copyrights and remove unnecessary whitespace.
Should be no functional change.

15 years agoAdd most relevant vg_attr fields as lvm2app 'get' functions.
Dave Wysochanski [Mon, 14 Sep 2009 19:43:11 +0000 (19:43 +0000)]
Add most relevant vg_attr fields as lvm2app 'get' functions.

Of the vgs field vg_attr, a few of the most likely to be used attributes
are clustered, exported, and partial.  This patch adds the following 3
functions:
uint64_t lvm_vg_is_clustered(const vg_t vg)
uint64_t lvm_vg_is_exported(const vg_t vg)
uint64_t lvm_vg_is_partial(const vg_t vg)

15 years agoUpdate lvm and vgs man pages to clarify 'partial' is a VG missing PVs.
Dave Wysochanski [Mon, 14 Sep 2009 19:42:13 +0000 (19:42 +0000)]
Update lvm and vgs man pages to clarify 'partial' is a VG missing PVs.

15 years agoAdd max_pv and max_lv vg 'get' lvm2app exports.
Dave Wysochanski [Mon, 14 Sep 2009 15:45:23 +0000 (15:45 +0000)]
Add max_pv and max_lv vg 'get' lvm2app exports.

15 years agoDo not run mdadm tests if MD module is not loaded.
Milan Broz [Sun, 13 Sep 2009 19:28:00 +0000 (19:28 +0000)]
Do not run mdadm tests if MD module is not loaded.

15 years agoMove dm_cookie_supported check into dm_udev_get_sync_supprt function.
Peter Rajnoha [Fri, 11 Sep 2009 16:11:25 +0000 (16:11 +0000)]
Move dm_cookie_supported check into dm_udev_get_sync_supprt function.

We don't have to call dm_cookie_supported with dm_udev_get_sync_support
this way. Also, it's necessary for the current code to work properly on
systems without cookie support (older kernels).

15 years agoAdd manpage entry for dmsetup's udevcomplete_all and udevcookies commands.
Peter Rajnoha [Fri, 11 Sep 2009 16:06:31 +0000 (16:06 +0000)]
Add manpage entry for dmsetup's udevcomplete_all and udevcookies commands.

15 years agoSeveral changes in udev rules:
Peter Rajnoha [Fri, 11 Sep 2009 16:05:20 +0000 (16:05 +0000)]
Several changes in udev rules:

- add DM_UDEV_RULES_VSN to provide a variable to be checked for in the other
  rules (e.g. to check that DM rules are actually installed, we can alternate
  functionality in the other rules based on this information, also we have
  versioning support for the rules)
- set proper sbin path for dmsetup and blkid, /sbin first, then /usr/sbin.
  This is necessary for anaconda to work properly.
- add 'last_rule' for cryptsetup's temporary devices (symlinks in /dev/mapper
  only)

15 years agoAdd one define that is necessary for older (experimental) libudev to work.
Peter Rajnoha [Fri, 11 Sep 2009 15:57:51 +0000 (15:57 +0000)]
Add one define that is necessary for older (experimental) libudev to work.

15 years agoCheck that udev is running and set internal state appropriately.
Peter Rajnoha [Fri, 11 Sep 2009 15:56:06 +0000 (15:56 +0000)]
Check that udev is running and set internal state appropriately.

15 years agoAdd libudev configuration check.
Peter Rajnoha [Fri, 11 Sep 2009 15:55:07 +0000 (15:55 +0000)]
Add libudev configuration check.

15 years agoAdd y|--yes option for dmsetup to provide a default 'YES' answer to questions.
Peter Rajnoha [Fri, 11 Sep 2009 15:53:57 +0000 (15:53 +0000)]
Add y|--yes option for dmsetup to provide a default 'YES' answer to questions.

15 years agoFix Makefile to take into account dmsetup's reconfiguration.
Peter Rajnoha [Fri, 11 Sep 2009 15:52:22 +0000 (15:52 +0000)]
Fix Makefile to take into account dmsetup's reconfiguration.

15 years agoUpdate lvm2app unit test vgtest - fix remove bug.
Dave Wysochanski [Fri, 4 Sep 2009 19:17:46 +0000 (19:17 +0000)]
Update lvm2app unit test vgtest - fix remove bug.

We now must commit to disk after lvm_vg_remove().

15 years agoFix path to test/api/vgtest in nightly testsuite.
Dave Wysochanski [Fri, 4 Sep 2009 14:26:16 +0000 (14:26 +0000)]
Fix path to test/api/vgtest in nightly testsuite.

15 years agoRemove 'test' interative api unit tests from 'TARGET' line.
Dave Wysochanski [Fri, 4 Sep 2009 13:49:02 +0000 (13:49 +0000)]
Remove 'test' interative api unit tests from 'TARGET' line.

The test/api directory TARGET line will be reserved for non-interactive
unit tests.  Building the interactive test can still be done with "make test"
from the test/api dir.

15 years agoAdd lvm2app.sh to nightly testsuite.
Dave Wysochanski [Fri, 4 Sep 2009 12:54:23 +0000 (12:54 +0000)]
Add lvm2app.sh to nightly testsuite.

More tests to come but for now just call into vgtest.
Fix warning in vgtest.c

15 years agoRestore umask when device node creation fails.
Dave Wysochanski [Thu, 3 Sep 2009 21:51:26 +0000 (21:51 +0000)]
Restore umask when device node creation fails.

Author: Florian Zumbiehl <florz@florz.de>
Acked-by: Dave Wysochanski <dwysocha@redhat.com>
15 years agoAdd daemons/cmirrord files to git - somehow got messed up with cvs rename.
Dave Wysochanski [Thu, 3 Sep 2009 21:11:53 +0000 (17:11 -0400)]
Add daemons/cmirrord files to git - somehow got messed up with cvs rename.

When clogd was renamed to cmirrord, somehow git got the remove of the old
files but not the add of the new files.  This patch adds the new files.

Signed-off-by: Dave Wysochanski <dwysocha@redhat.com>
15 years agoFix path to test/api/vgtest in nightly testsuite.
Dave Wysochanski [Fri, 4 Sep 2009 14:26:16 +0000 (14:26 +0000)]
Fix path to test/api/vgtest in nightly testsuite.

15 years agoRemove 'test' interative api unit tests from 'TARGET' line.
Dave Wysochanski [Fri, 4 Sep 2009 13:49:02 +0000 (13:49 +0000)]
Remove 'test' interative api unit tests from 'TARGET' line.

The test/api directory TARGET line will be reserved for non-interactive
unit tests.  Building the interactive test can still be done with "make test"
from the test/api dir.

15 years agoAdd lvm2app.sh to nightly testsuite.
Dave Wysochanski [Fri, 4 Sep 2009 12:54:23 +0000 (12:54 +0000)]
Add lvm2app.sh to nightly testsuite.

More tests to come but for now just call into vgtest.
Fix warning in vgtest.c

15 years agoRestore umask when device node creation fails.
Dave Wysochanski [Thu, 3 Sep 2009 21:51:26 +0000 (21:51 +0000)]
Restore umask when device node creation fails.

Author: Florian Zumbiehl <florz@florz.de>
Acked-by: Dave Wysochanski <dwysocha@redhat.com>
15 years agoDo not override the distclean target in liblvm's Makefile, it annoys make and
Petr Rockai [Thu, 3 Sep 2009 18:19:07 +0000 (18:19 +0000)]
Do not override the distclean target in liblvm's Makefile, it annoys make and
the make.tmpl-included distclean should work better anyway.

15 years agoUpdate lvm2app vgtest to take vgname and devices as parameters.
Dave Wysochanski [Thu, 3 Sep 2009 17:13:46 +0000 (17:13 +0000)]
Update lvm2app vgtest to take vgname and devices as parameters.

15 years agoUpdate lvm_vg_write() to handle the deferred commit of lvm_vg_write().
Dave Wysochanski [Wed, 2 Sep 2009 21:40:10 +0000 (21:40 +0000)]
Update lvm_vg_write() to handle the deferred commit of lvm_vg_write().

Now that we've refactored the internal library functions that do the
vg_remove, we can handle the deferred commit of a lvm_vg_remove() inside
lvm_vg_write().  This makes the VG create/remove API more consistent in
terms of disk commits - they now both require an lvm_vg_write() to commit
the create or remove to disk.

Signed-off-by: Dave Wysochanski <dwysocha@redhat.com>
Author: Dave Wysochanski <dwysocha@redhat.com>

15 years agoUpdate vg_remove_single_* functions to use the removed_pvs list.
Dave Wysochanski [Wed, 2 Sep 2009 21:39:49 +0000 (21:39 +0000)]
Update vg_remove_single_* functions to use the removed_pvs list.

Now that we've split vg_remove_single into two routines, in the first routine
that only manipulates memory, we move the PVs from the vg->pvs list to the
vg->removed_pvs list.  Then later, we iterate through this list to write the
removed PVs to disk, which removes them from the volume group and places them
into the internal ORPHAN VG.

Signed-off-by: Dave Wysochanski <dwysocha@redhat.com>
Author: Dave Wysochanski <dwysocha@redhat.com>

15 years agoSplit vg_remove_single into 2 functions - the second part commits to disk.
Dave Wysochanski [Wed, 2 Sep 2009 21:39:29 +0000 (21:39 +0000)]
Split vg_remove_single into 2 functions - the second part commits to disk.

Split vg_remove_single into vg_remove_check (mandatory checks before
vgremove) and vg_remove (do actual remove by committing to disk).

In liblvm, we'd like to provide an consistent API that allows multiple
changes in memory, then let lvm_vg_write() control the commit to disk.  In
some cases (for example, lvresize calls fsadm) this may not be possible.
However, since we are using an object model and dividing things into small
operations, the most logical model seems to be the lvm_vg_write model, and
handling the special cases as they arrive.  So as best as possible
we move towards this end.

A possible optimization would be to consolidate vg_remove (committing)
code with vgreduce code.  A second possible optimization is making vgreduce
of the last device equivalent to vgremove.  Today, lvm_vg_reduce fails if
vgreduce is called with the last device, but from an object model perspective
we could view this as equivalent to vgremove and allow it.  My gut feel is
we do not want to do this though.

Author: Dave Wysochanski <dwysocha@redhat.com>

15 years agoRename internal library function vg_remove to vg_remove_mdas.
Dave Wysochanski [Wed, 2 Sep 2009 21:39:07 +0000 (21:39 +0000)]
Rename internal library function vg_remove to vg_remove_mdas.

Later patches should consolidate the vgremove / vgreduce functions but for
now let's clarify what vg_remove actually does by changing the name.

Author: Dave Wysochanski <dwysocha@redhat.com>

15 years agoEnforce an alphabetical lock ordering for vgname locks.
Dave Wysochanski [Wed, 2 Sep 2009 21:34:11 +0000 (21:34 +0000)]
Enforce an alphabetical lock ordering for vgname locks.

Add a new constraint that vgname locks must be obtained in
alphabetical order.  At this point, we have test coverage for
the 3 commands affected - vgsplit, vgmerge, and vgrename.
Tests have been updated to cover these commands.
Going forward any command or library call that must obtain
more than one vgname lock must do so in alphabetical order.
Future patches will update lvm2app to enforce this ordering.

Author: Dave Wysochanski <dwysocha@redhat.com>

15 years agoUpdate vgrename to take into account vgname lock ordering.
Dave Wysochanski [Wed, 2 Sep 2009 21:29:40 +0000 (21:29 +0000)]
Update vgrename to take into account vgname lock ordering.

Should be no functional change.

Author: Dave Wysochanski <dwysocha@redhat.com>

15 years agoRefactor vgrename into vg_rename_old and vg_rename_new.
Dave Wysochanski [Wed, 2 Sep 2009 21:29:23 +0000 (21:29 +0000)]
Refactor vgrename into vg_rename_old and vg_rename_new.

Should be no functional change.
Will allow us to reorder lock obtaining if needed.

Author: Dave Wysochanski <dwysocha@redhat.com>

15 years agoChange vgmerge behavior to open/lock first vg based on alphabetical ordering.
Dave Wysochanski [Wed, 2 Sep 2009 21:28:43 +0000 (21:28 +0000)]
Change vgmerge behavior to open/lock first vg based on alphabetical ordering.

This enforces our alphabetical lock ordering rules for vgmerge.

Author: Dave Wysochanski <dwysocha@redhat.com>

15 years agoRefactor vgmerge - combine _vgmerge_to and _vgmerge_from into _vgmerge_vg_read.
Dave Wysochanski [Wed, 2 Sep 2009 21:28:27 +0000 (21:28 +0000)]
Refactor vgmerge - combine _vgmerge_to and _vgmerge_from into _vgmerge_vg_read.

These functions are identical so should be no functional change.

Author: Dave Wysochanski <dwysocha@redhat.com>

15 years agoRefactor vgmerge - create _vgmerge_from and _vgmerge_to.
Dave Wysochanski [Wed, 2 Sep 2009 21:28:10 +0000 (21:28 +0000)]
Refactor vgmerge - create _vgmerge_from and _vgmerge_to.

These functions are really identical but for clarity I made them separate
functions in this patch.

Should be no functional change.

Author: Dave Wysochanski <dwysocha@redhat.com>

15 years agoRefactor vgmerge - introduce lock_vg_from_first flag.
Dave Wysochanski [Wed, 2 Sep 2009 21:27:55 +0000 (21:27 +0000)]
Refactor vgmerge - introduce lock_vg_from_first flag.

Should be no functional change.

Author: Dave Wysochanski <dwysocha@redhat.com>

15 years agoChange vgsplit behavior to open/lock first vg based on alphabetical ordering.
Dave Wysochanski [Wed, 2 Sep 2009 21:27:39 +0000 (21:27 +0000)]
Change vgsplit behavior to open/lock first vg based on alphabetical ordering.

If the destination vgname comes before the source vgname, we must open the
destination first because of the locking rules.  Thus, do a strcmp and set
the flag based on the comparison.

Author: Dave Wysochanski <dwysocha@redhat.com>

15 years agoRefactor vgsplit - reorder _vgsplit_from and _vgsplit_to based on flag.
Dave Wysochanski [Wed, 2 Sep 2009 21:27:22 +0000 (21:27 +0000)]
Refactor vgsplit - reorder _vgsplit_from and _vgsplit_to based on flag.

Slight functional change.  If we open the destination first, we cannot
know the 'fmt'.  In this case we use the default metadata type unless
the user has specified -M on the cmdline.  If not, in most cases this
is fine since we use the LVM2 default metadata type.  However, if the
user is specifying a non-default metadata type (e.g. lvm1) and the order
of the names is such that we have to open the destination (vg_to) first,
we have a problem.  So in this case, we require the use of -M and vgsplit
will fail with an error if not.  I've updated the man page to recommend
the usage of -M in this case.

Author: Dave Wysochanski <dwysocha@redhat.com>

15 years agoRefactor vgsplit: _vgsplit_from or _vgsplit_to failure cleanup depends on order.
Dave Wysochanski [Wed, 2 Sep 2009 21:27:05 +0000 (21:27 +0000)]
Refactor vgsplit: _vgsplit_from or _vgsplit_to failure cleanup depends on order.

Should be no functional change.

Author: Dave Wysochanski <dwysocha@redhat.com>

15 years agoRefactor vgsplit - create _vgsplit_from function to open source vg.
Dave Wysochanski [Wed, 2 Sep 2009 21:26:50 +0000 (21:26 +0000)]
Refactor vgsplit - create _vgsplit_from function to open source vg.

Should be no functional change and allows future reorder of source and dest
vgs.

Author: Dave Wysochanski <dwysocha@redhat.com>

15 years agoRefactor vgsplit - create _vgsplit_to function which creates or opens dest vg.
Dave Wysochanski [Wed, 2 Sep 2009 21:26:34 +0000 (21:26 +0000)]
Refactor vgsplit - create _vgsplit_to function which creates or opens dest vg.

Move the creating/opening of the destination vg into its own function so later
we can reorder the source / destination vg opening based on the alphabetical
lock order rule.

Should be no functional change but code is a bit tricky.

Author: Dave Wysochanski <dwysocha@redhat.com>

15 years agoRefactor vgsplit - add 'lock_vg_from_first' flag.
Dave Wysochanski [Wed, 2 Sep 2009 21:26:18 +0000 (21:26 +0000)]
Refactor vgsplit - add 'lock_vg_from_first' flag.

Introduce 'lock_vg_from_first' flag to retain which vg was locked first.
Should be no functional change.

Author: Dave Wysochanski <dwysocha@redhat.com>

15 years agoRefactor vgsplit - remove bad2 label.
Dave Wysochanski [Wed, 2 Sep 2009 21:26:01 +0000 (21:26 +0000)]
Refactor vgsplit - remove bad2 label.

No functional change.

Author: Dave Wysochanski <dwysocha@redhat.com>

15 years agoRefactor vgsplit to move existing_vg logic in a separate 'if' statement.
Dave Wysochanski [Wed, 2 Sep 2009 21:25:44 +0000 (21:25 +0000)]
Refactor vgsplit to move existing_vg logic in a separate 'if' statement.

This will aid in future refactorings and allow for us to reorder the source
and destination vg based on alphabetical names.
Should be no functional change.

Author: Dave Wysochanski <dwysocha@redhat.com>

15 years agoFix vgsplit test to require -M on ordering of vgnames.
Dave Wysochanski [Wed, 2 Sep 2009 19:38:53 +0000 (19:38 +0000)]
Fix vgsplit test to require -M on ordering of vgnames.

15 years agoclogd->cmirrord
Alasdair Kergon [Wed, 2 Sep 2009 19:32:37 +0000 (19:32 +0000)]
clogd->cmirrord

15 years agoAdd alphabetical vgname ordering tests for vgsplit, vgmerge, vgrename.
Dave Wysochanski [Wed, 2 Sep 2009 18:31:11 +0000 (18:31 +0000)]
Add alphabetical vgname ordering tests for vgsplit, vgmerge, vgrename.

15 years agorename clogd dir to cmirrord
Alasdair Kergon [Wed, 2 Sep 2009 17:36:46 +0000 (17:36 +0000)]
rename clogd dir to cmirrord

15 years agoImplement write lock prioritisation for file locking and make it default.
Petr Rockai [Wed, 2 Sep 2009 14:47:39 +0000 (14:47 +0000)]
Implement write lock prioritisation for file locking and make it default.

15 years agoFix cmirrod build directory while we wait to do a proper rename of the
Fabio M. Di Nitto [Wed, 2 Sep 2009 11:49:03 +0000 (11:49 +0000)]
Fix cmirrod build directory while we wait to do a proper rename of the
directory and move files.

15 years agoDrop clogd Makefile from CVS since it's always autogenerated from Makefile.in
Fabio M. Di Nitto [Tue, 1 Sep 2009 19:13:38 +0000 (19:13 +0000)]
Drop clogd Makefile from CVS since it's always autogenerated from Makefile.in
at configure time.

15 years agoFix --with-clvmd=all to deal with the case where no cluster managers are available.
Fabio M. Di Nitto [Tue, 1 Sep 2009 19:11:45 +0000 (19:11 +0000)]
Fix --with-clvmd=all to deal with the case where no cluster managers are available.

Also simplify the check by removing an unnecessary variable and update
configure messages.

15 years agoRemove unwanted Makefiles and don't purge lvm2.po that's
Fabio M. Di Nitto [Tue, 1 Sep 2009 18:11:14 +0000 (18:11 +0000)]
Remove unwanted Makefiles and don't purge lvm2.po that's
under RCS.

15 years agoAdd some code to clvmd to look in the corosync confdb to see what cluster
Christine Caulfield [Tue, 1 Sep 2009 09:48:01 +0000 (09:48 +0000)]
Add some code to clvmd to look in the corosync confdb to see what cluster
interface it should be using, it can still be overriden with -I.

If corosync isn't running or there is no information then the usual
checking will happen.

This code only builds if corosync is available.

15 years agochange clogd to cmirrord
Alasdair Kergon [Fri, 28 Aug 2009 20:51:40 +0000 (20:51 +0000)]
change clogd to cmirrord
make pidfile locn configurable

15 years agoRewrite clvmd configuration code.
Alasdair Kergon [Fri, 28 Aug 2009 19:22:05 +0000 (19:22 +0000)]
Rewrite clvmd configuration code.

15 years agocluster log daemon (clogd): Adjust for kernel CTR arg reordering
Jonathan Earl Brassow [Fri, 28 Aug 2009 05:27:09 +0000 (05:27 +0000)]
cluster log daemon (clogd): Adjust for kernel CTR arg reordering

We have moved the internally generated mirror-device-size
parameter from the end of the CTR string to the begining.
This change adjusts for that.

15 years agoFix global locking in PV reporting commands (2.02.49).
Milan Broz [Mon, 24 Aug 2009 11:37:20 +0000 (11:37 +0000)]
Fix global locking in PV reporting commands (2.02.49).

15 years agoFix uuid warning in pvcreate to use terminated (and dash formatted) UUID string.
Milan Broz [Thu, 20 Aug 2009 07:03:02 +0000 (07:03 +0000)]
Fix uuid warning in pvcreate to use terminated (and dash formatted) UUID string.

# pvcreate -u udwxr7-BoKY-EeKM-r033-xK6o-4og7-F13sGi /dev/sdc
   uuid udwxr7BoKYEeKMr033xK6o4og7F13sGi|��� already in use on "/dev/sdb1"
 is now
# pvcreate -u udwxr7-BoKY-EeKM-r033-xK6o-4og7-F13sGi /dev/sdc
   uuid udwxr7-BoKY-EeKM-r033-xK6o-4og7-F13sGi already in use on "/dev/sdb1"

This page took 0.071927 seconds and 5 git commands to generate.