1
0
mirror of git://sourceware.org/git/lvm2.git synced 2024-12-28 11:22:15 +03:00
Commit Graph

3227 Commits

Author SHA1 Message Date
taka
251ee5f5a2 Fix error message when archive initialization fails. 2009-04-02 20:46:11 +00:00
Milan Broz
9ab1d88a91 Fix debug pool grow object to properly support delta=0
(It prints garbage for some reports)
2009-04-02 15:02:18 +00:00
Milan Broz
5d3d9f57fe Allocate new pv->vg_name from pool, it can be destroyed later.
(The mempool rename will be used later by vg private mempools)
2009-04-02 15:01:11 +00:00
Milan Broz
0889882255 Do not use pointer from released memory pool (cmd->cmd_line). 2009-04-02 14:59:48 +00:00
Christine Caulfield
2a1f78f95a Make sure clvmd-corosync releases the lockspace when it exits.
patch from Xinwei Hu
2009-04-01 07:51:05 +00:00
Milan Broz
6faaa1a0cc Add some more special chars for device name test. 2009-03-31 17:30:47 +00:00
Milan Broz
77dd12a028 fix some issues when compiling with -D DEBUG_POOL
- fix compilation issues
- fix wrong pool object maipulation (lvm dumpconfig triggers assert)
- second iteration in loop _log_parallel_areas operates on non-existing object
2009-03-26 09:25:18 +00:00
Milan Broz
6a954445f1 Fix segfault for vgcfgrestore on VG with missing PVs. 2009-03-24 13:16:34 +00:00
Christine Caulfield
9500e898c6 Block SIGINT & SIGTERM in clvmd subthreads so they don't delay shutdown.
Patch from Xinwei Hu, Thanks
2009-03-24 11:49:15 +00:00
taka
c5989d4350 Restore log_suppress state when metadata backup file is up-to-date.
Author: Takahiro Yasui <tyasui@redhat.com>
2009-03-23 22:57:27 +00:00
taka
8f782be41d Remove old metadata backup file after renaming vg.
Author: Takahiro Yasui <tyasui@redhat.com>
2009-03-23 22:29:06 +00:00
taka
afcc447a64 Fix size and error message of memory allocation at backup initialization.
Author: Takahiro Yasui <tyasui@redhat.com>
2009-03-23 21:56:32 +00:00
taka
8cfcba83ae Fix error message when adding metadata directory to internal list fails.
Author: Takahiro Yasui <tyasui@redhat.com>
2009-03-23 21:13:37 +00:00
Petr Rockai
a8315726ce Missed file from previous checkin. 2009-03-17 14:40:00 +00:00
Petr Rockai
da668c80b2 Some extra (paranoid) checks on dev_is_{md,swap} result. 2009-03-17 14:00:58 +00:00
Petr Rockai
55455ac21f Detect and wipe swap signatures in pvcreate. 2009-03-17 13:59:56 +00:00
Dave Wysochanski
74adacf96a Fix some clean rules, fix previous distclean checkin.
In libdm/Makefile.in, we need to cleanup the symlink properly.
Adding to CLEAN_TARGETS seemed like the simplest way to do this
in the current build framework.  We could redo dependencies for
VERSIONED_SHLIB, but for now just add to CLEAN_TARGETS.

For scripts/Makefile.in, we should be adding to DISTCLEAN_TARGETS.
The generic rule in make.tmpl.in takes care of the cleanup.

Signed-off-by: Dave Wysochanski <dwysocha@redhat.com>
Author: Takahiro Yasui <tyasui@redhat.com>
2009-03-16 20:00:10 +00:00
Dave Wysochanski
a384b41308 Fix some distclean rules.
By gnu coding stds, 'distclean' should remove all files generated
by ./configure in addition to what 'clean' does.

Author: Takahiro Yasui <tyasui@redhat.com>
2009-03-16 18:28:04 +00:00
Milan Broz
048a329afc Fix warning in previous commit. 2009-03-16 15:19:29 +00:00
Milan Broz
3c3d16e794 Fix lv_count when manipulating with snapshots and max_lv is set.
Patch fixes these problems:
 - during the snapshot creation process, it needs create 2 LVs,
   one is cow, second becomes snapshot.
   If the code fails in vg_add_snapshot, code lvcreate will not remove
   LV cow volume.

 - if max_lv is set and VG contains snapshot, it can happen that
   during the activation lv_count is temporarily increased over the limit
   and VG metadata are not properly processed
   see https://bugzilla.redhat.com/show_bug.cgi?id=490298

 - vgcfgrestore alows restore with max_lv set to lower valuer that actual
   LV count. This later leads to situation that max_lv is completely ignored.

 - vgck doesn't call vg_validate(). It should at least try:-)

Signed-off-by: Milan Broz <mbroz@redhat.com>
2009-03-16 14:34:57 +00:00
Dave Wysochanski
d95b544dfd Remove unnecessary includes in lvm_base.c.
We would like to declare our handles pv_t, vg_t, and lv_t in
the external library header lvm.h.  However, these are already
defined in metadata-exported.h for the use of some of the
in-progress liblvm APIs.  Thus, we cannot both define
them in lvm.h and include metadata-exported.h in the external
library C files.  We could use preprocessor tricks (#ifndef)
but for now we just avoid the include.
2009-03-10 15:38:46 +00:00
Milan Broz
5d9ea7b91b Fix clvmd build after liblvm commit. 2009-03-10 12:10:12 +00:00
Dave Wysochanski
500289229a Fix error messages when PV uuid or pe_start reading fails.
Author: Takahiro Yasui <tyasui@redhat.com>
Committer: Dave Wysochanski <dwysocha@redhat.com>
2009-03-09 15:42:10 +00:00
Dave Wysochanski
21d62387ae Add missing liblvm/.exported_symbols 2009-03-08 18:58:53 +00:00
Dave Wysochanski
3bbfb30dcb Fix liblvm version symlink. 2009-03-08 18:10:39 +00:00
Dave Wysochanski
819fbc6ed5 Remove unnecessary linker flags for liblvm. 2009-03-08 17:29:26 +00:00
Dave Wysochanski
53e7c8fa34 Add DSO generation for new LVM application library.
Fix test/api/test build.
2009-03-08 17:06:55 +00:00
Dave Wysochanski
35d13cad96 Move lvm.h from lib to liblvm. 2009-03-06 22:49:48 +00:00
Dave Wysochanski
c190fc702e Add new liblvm build directory and move lvm_base.c.
The original liblvm.a has been moved to liblvm-internal.a.
We now use liblvm.a for the new application library and build
it inside liblvm directory.

Change dependencies so tools depend on liblvm application library,
and application library depends on liblvm internal.
2009-03-06 16:19:52 +00:00
Dave Wysochanski
cd0ed7b509 Rename liblvm to liblvm-internal.
Make preparation for using liblvm for new application library.
2009-03-06 16:17:28 +00:00
Christine Caulfield
24af685db1 Fix unlocks in clvmd-corosync.
The DLM unlock returns EUNLOCK in the lksb on success, not 0
2009-03-06 11:29:38 +00:00
Milan Broz
d7553ded6c Fix possible increasing in memory allocation if refreshing_context
(for example when CLVMD_CMD_LOCK_VG for is called during vgscan).

If clvmd calls LV lock, it calls
    /* clean the pool for another command */
	dm_pool_empty(cmd->mem);
to clean up memory pool after command.

Unfortunately, do_refresh_cache() do not call this
and because during it operation it allocates some memory,
the pool increases.

Also do_refresh_cache should use lvm_lock
(it manipulates with lvm internal data).

The same applies for lvm_backup command.

Signed-off-by: Milan Broz <mbroz@redhat.com>
2009-03-05 16:25:35 +00:00
Alasdair Kergon
884d5a7fc8 post-release 2009-03-03 18:25:05 +00:00
Milan Broz
a920074468 vgname_from_mda now tries to parse for vgname even
if rlocn not defined (there is no metadata area).

In most cases it fails in validate_name(),
unfortunately there are situatuions, when
validate_name is ok and later code fails with
checksum error.

Reproducer:

# dd if=/dev/zero of=/dev/loop0

# pvcreate --metadatasize 637k /dev/loop0
  Physical volume "/dev/loop0" successfully created

# pvs /dev/loop0
  /dev/loop0: Checksum error
      PV         VG   Fmt  Attr PSize PFree
        /dev/loop0      lvm2 --   1.00M 1.00M

Signed-off-by: Milan Broz <mbroz@redhat.com>

-
2009-03-03 16:35:32 +00:00
Alasdair Kergon
5ab342e298 pre-release 2009-03-03 13:03:03 +00:00
Alasdair Kergon
c99f525821 Fix last check-ins: seg can be NULL. 2009-02-28 20:04:24 +00:00
Alasdair Kergon
dff004d695 . 2009-02-28 19:43:42 +00:00
Alasdair Kergon
6f53e4b536 Attempt cleanup in child before execing new binary in exec_cmd() 2009-02-28 00:54:06 +00:00
Alasdair Kergon
9d3fe84135 . 2009-02-27 23:55:15 +00:00
Alasdair Kergon
e5f7ae3878 fsadm cleanups & release prep 2009-02-27 23:40:11 +00:00
Alasdair Kergon
97162d9a53 autoreconf (using fedora 10 for this now) 2009-02-25 23:33:30 +00:00
Milan Broz
d0b99cb260 pe_start can be overwritten in VG metadata, so it is not PV label-only field. 2009-02-25 23:31:06 +00:00
Milan Broz
fa22cc2e20 Try to avoid full rescan if label scan is enough. 2009-02-25 23:29:06 +00:00
Alasdair Kergon
9904255490 Use pkgconfig to obtain corosync library details during configuration. (kabi) 2009-02-25 22:41:12 +00:00
Christine Caulfield
f75c15b477 Fix error returns in clvmd-corosync interface to DLM.
Thanks to Xinwei Hu for spotting this.
2009-02-25 14:33:00 +00:00
Dave Wysochanski
9404dcab69 Update vgchange and vgmknodes man pages to include --refresh.
Author: Dave Wysochanski <dwysocha@redhat.com>
2009-02-25 13:17:40 +00:00
Zdeněk Kabeláč
c4d4403955 Fixed bug where lvresize option -t was not properly passed to fsadm.
Using argv[] list in exec_cmd() to allow more params for external commands.
Fsadm does not allow checking mounted filesystem.
Fsadm no longer accepts 'any other key' as 'no' answer to y/n.
Fsadm improved handling of command line options.
2009-02-24 15:48:00 +00:00
twoerner
a0bb2dc907 Fix include/.symlinks for lvm2.h to lvm.h renaming
Author: Thomas Woerner <twoerner@redhat.com>
2009-02-24 13:13:56 +00:00
twoerner
ed774a5691 Added files lib/lvm.h and lib/lvm_base.c:
New structure lvm (used as an alias to cmd_context), new type definition lvm_t
for the lvm handle. Added functions lvm_create, lvm_destroy and
lvm_reload_config using the new handle.

Modified test/api/test.c:
Use new lvm.h header file and lvm_t handle.

Removed lib/lvm2.h


Author: Thomas Woerner <twoerner@redhat.com>
2009-02-24 13:03:45 +00:00
Milan Broz
78cedddbde Fix validation of dataalignment value introduced in previous commit. 2009-02-23 16:53:42 +00:00