Alasdair Kergon
223c62e7b7
Avoid nested vg_reads when processing PVs in VGs and fix associated locking.
2007-11-14 18:41:05 +00:00
Alasdair Kergon
a6b22cf317
readahead activation code (but no dm support yet)
2007-11-12 20:51:54 +00:00
Dave Wysochanski
1b8de4cb25
Add pv_dev_name() to access PV device name.
...
Patch by Jun'ichi Nomura <j-nomura@ce.jp.nec.com>
2007-10-12 14:29:32 +00:00
Alasdair Kergon
21bc366486
Clean up numerous compiler warnings that crept in recently.
...
Remove several unused parameters from _allocate().
2007-08-22 14:38:18 +00:00
Alasdair Kergon
be6845999b
Fix inconsistent licence notices: executables are GPLv2; libraries LGPLv2.1.
2007-08-20 20:55:30 +00:00
Dave Wysochanski
d6b1de30fe
Convert vg->status checks to use vg_check_status function.\nRename status_flags to status in vg_check_status.
2007-06-19 04:36:12 +00:00
Dave Wysochanski
ff77bb1ab6
Remove get_ prefix from get_pv_* functions
2007-06-15 22:16:55 +00:00
Dave Wysochanski
b7dd5ac374
Convert pv->dev to get_pv_dev
2007-06-13 23:29:33 +00:00
Dave Wysochanski
9dcbe73897
Convert pv->size to get_pv_size
2007-06-13 23:02:51 +00:00
Dave Wysochanski
ec26c285c2
Convert pv->pe_count to get_pv_pe_count
2007-06-13 22:11:29 +00:00
Dave Wysochanski
aeea47205b
Convert pv->pe_alloc_count to get_pv_pe_alloc_count
2007-06-13 22:04:45 +00:00
Dave Wysochanski
c221b0bc21
Add vg_check_status to consolidate vg status flags checks and error messages.
2007-06-06 19:40:28 +00:00
Alasdair Kergon
b9b260119f
Add a few missing pieces of vgname command line validation.
2007-03-09 21:25:33 +00:00
Alasdair Kergon
9397354a33
Support the /dev/mapper prefix on most command lines.
2007-03-09 20:47:41 +00:00
Alasdair Kergon
aa350ef426
Fix some &->&& vgreduce cmdline validation. [Andre Noll]
2007-01-31 16:26:23 +00:00
Alasdair Kergon
7c0cd2730c
Avoid vgreduce error when mirror code removes the log LV.
2007-01-09 23:14:35 +00:00
Alasdair Kergon
4dc0ec2253
Adjust some alignments for ia64 and sparc.
...
(Some of the changes are probably unnecessary.)
2006-11-30 23:11:42 +00:00
Alasdair Kergon
fe748f0092
fix vgreduce clustered check
2006-09-07 23:23:45 +00:00
Alasdair Kergon
dc4d7417f7
When using local file locking, skip clustered VGs.
...
Add fallback_to_clustered_locking and fallback_to_local_locking parameters.
2006-09-02 01:18:17 +00:00
Alasdair Kergon
08c060cf38
Add skip_dev_dir() to process command line VGs.
2006-08-25 23:02:33 +00:00
Alasdair Kergon
1f84f09381
Differentiate between the two 'log device failed' cases in vgreduce.
2006-07-04 19:52:47 +00:00
Alasdair Kergon
43137a6b7f
If VG is already consistent with --removemissing, return success not failure.
2006-07-04 18:51:59 +00:00
Alasdair Kergon
3e3d5d8593
Add --monitor to vgcreate and lvcreate to control dmeventd registration.
...
Propagate --monitor around cluster.
Filter LCK_NONBLOCK in clvmd lock_vg.
2006-05-12 19:16:48 +00:00
Alasdair Kergon
532dae4854
Allow vgreduce to handle mirror log failures.
2006-05-11 19:01:11 +00:00
Alasdair Kergon
72b2cb613a
Make SIZE_SHORT the default for display_size().
...
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.
2006-05-09 21:23:51 +00:00
Alasdair Kergon
a5fe5a7cdd
Fix vgexport/vgimport to set/reset PV exported flag so pv_attr is correct.
...
Add vgid to struct physical_volume and pass with vg_name to some functions.
2006-04-12 21:23:04 +00:00
Alasdair Kergon
e408d62eaf
suspend using existing LV metadata; vgreduce then needs partial flag
2006-02-03 19:36:20 +00:00
Alasdair Kergon
079ac15ece
vgreduce remove mirror images
...
adjust block_on_error version no detection for RHEL4U3
2006-01-04 18:09:52 +00:00
Alasdair Kergon
c9dcba6b16
Add --mirrorsonly arg to vgreduce. (Doesn't handle mirrors yet.)
2005-12-21 21:21:45 +00:00
Alasdair Kergon
2e6d308465
some fixes
2005-12-21 20:24:22 +00:00
Alasdair Kergon
3fc3e48c44
vgreduce replaces active LVs with error segment before removing them.
2005-12-21 18:51:50 +00:00
Alasdair Kergon
e2619d9ec1
more lvconvert mirror code
2005-11-29 18:20:23 +00:00
Alasdair Kergon
0fb173aa3a
Change LV locking macros to take lv instead of lvid.
2005-08-15 12:00:04 +00:00
Alasdair Kergon
60f13f01d2
Basic support for mirrors.
2005-06-01 16:51:55 +00:00
Alasdair Kergon
32469fb25c
lv_reduce tidying.
...
Remove some unnecessary parameters.
Introduce seg_is macros.
2005-05-09 16:59:01 +00:00
Alasdair Kergon
15db9fcfbf
Reinstate full PV size when removing from VG.
...
Support loopfiles for testing.
Complete the pv_segment support.
2005-05-03 17:28:23 +00:00
Alasdair Kergon
072893aabd
Internal snapshot code restructuring.
2005-04-07 12:39:44 +00:00
Alasdair Kergon
23289e6d14
Revise internal locking semantics.
2004-05-05 12:03:07 +00:00
Alasdair Kergon
6606c3ae81
Update copyright notices.
2004-03-30 19:35:44 +00:00
Alasdair Kergon
cfb7bfc7d9
More consistent error code usage.
2003-10-21 22:06:07 +00:00
Alasdair Kergon
f2b7349e2f
macro changes
2003-10-15 20:02:46 +00:00
Alasdair Kergon
914c97239f
Another sync point - numerous fixes & clean ups.
2003-07-04 22:34:56 +00:00
Alasdair Kergon
b8c919b402
o Metadata area struct change.
...
o Support physical extent restrictions on PV lists for allocations
e.g. lvcreate -l 200 vg1 /dev/sda1:100-199:300-399
2003-04-24 22:23:24 +00:00
Alasdair Kergon
26e7f2e0c4
Tidy various pre-processing incl. making libdl optional.
2003-03-24 18:08:53 +00:00
Alasdair Kergon
a421f74371
vgreduce --removemissing to remove missing PVs & deps & make VG consistent
2003-01-17 21:04:26 +00:00
Alasdair Kergon
8ef2b021ed
Default stripesize 64k & config file setting for it;
...
Clear many compiler warnings (i386) & associated bugs - hopefully without
introducing too many new bugs:-) (Same exercise required for other archs.)
Default compilation has optimisation - or else use ./configure --enable-debug
2002-12-19 23:25:55 +00:00
Alasdair Kergon
5a52dca9c2
Some new features.
2002-11-18 14:04:08 +00:00
Andres Salomon
50762c2186
agk, I recall you saying you had a massive commit pending; if you need me
...
to back this out so you can do that commit, let me know. Also, if there's
an issue with the error message that's displayed, just change it in tools.h.
This causes a "device-mapper driver/module not loaded?" error message to
be displayed for the commands that require dm-mod, if the tools can't get
the driver version. It's not done for commands that don't require dm-mod.
This should clear up some problems people have had attempting to use lvm2
without rtfm'ing.
2002-10-27 21:04:03 +00:00
Alasdair Kergon
25b733809a
Merge with text format branch.
...
Lots of changes/very little testing so far => there'll be bugs!
Use 'vgcreate -M text' to create a volume group with its metadata stored
in text files. Text format metadata changes should be reasonably atomic,
with a (basic) automatic recovery mechanism if the system crashes while a
change is in progress.
Add a metadata section to lvm.conf to specify multiple directories if
you want (recommended) to keep multiple copies of the metadata (eg on
different filesystems).
e.g. metadata {
dirs = ["/etc/lvm/metadata1","/usr/local/lvm/metadata2"]
}
Plenty of refinements still in the pipeline.
2002-04-24 18:20:51 +00:00
Alasdair Kergon
be326a2f1b
o activate/reactivate merge
...
o unlocking macro
2002-03-11 15:08:39 +00:00
Alasdair Kergon
f4cbeaf0ac
o Lock mechanism for LV activation
...
o #defines for common lock flag combinations
o Try out hyphens instead of colons in device-mapper names - does this
make messages containing filenames easier to read?
2002-02-27 12:26:41 +00:00
Alasdair Kergon
413cc9189e
Begin conversion so LV id is passed to activation unit instead of
...
struct logical_volume.
2002-02-25 12:56:16 +00:00
Alasdair Kergon
6fda126dd7
Run through indent - no (intentional) changes to any code.
2002-02-11 21:00:35 +00:00
Alasdair Kergon
60274aba6e
Preparation for an LVM2 liblvm - pass cmd_context into each tool and
...
link some globals that the tools need into that structure.
2002-02-11 20:50:53 +00:00
Alasdair Kergon
7d0e6e800e
o Support locking with local lock files
...
o Disable control-c during updates (except if blocked waiting for a lock)
2002-02-11 15:42:34 +00:00
Heinz Mauelshagen
08907484f5
quotes around names in output
2002-01-30 15:04:48 +00:00
Alasdair Kergon
f53c6aa66e
o Basic support for exporting (but importing not completed yet).
...
o When volume group does not have write flag set, prevent changes to it.
o Preparation for partial activation (not completed yet).
2002-01-29 17:23:33 +00:00
Joe Thornber
cc282870dd
o Changed
...
struct pv_list {
struct list list;
struct physical_volume pv;
};
to
struct pv_list {
struct list list;
struct physical_volume *pv;
};
o New function in toollib 'create_pv_list', which creates a list of pv's
from a given command line array of pv's.
o Changed lvcreate/extend to use this (fixes lvextend [pv list] bug).
2002-01-21 16:05:23 +00:00
Joe Thornber
e586401ecb
o Changed find_pv_in_vg, and find_lv_in_vg to return a struct pv_list * and
...
struct lv_list * respectively.
2002-01-21 14:28:12 +00:00
Alasdair Kergon
4a624ca055
o ACTIVE is no longer a status flag - lv_active() used to check if an LV
...
is active in the device-mapper.
o Many operations can be carried out regardless of whether the VG is
active or not.
o vgscan does not activate anything - use vgchange.
o Change lvrename to support renaming of active LVs.
o Remove '//' appearing in some pathnames.
o Dummy lv_check_segments() for compilation.
2002-01-10 23:21:07 +00:00
Alasdair Kergon
b80f32dd0a
Clarify terminology:
...
VG is resizeable - PVs can be added or removed
PV is allocatable - free extents on it may be allocated to LVs
2002-01-10 15:09:51 +00:00
Alasdair Kergon
614a4508e6
Add archiving.
2002-01-09 13:17:14 +00:00
Joe Thornber
197c3f2ab4
o sync tool changes for backup stuff.
2002-01-07 11:12:11 +00:00
Alasdair Kergon
cc21948339
o Add autobackup support to tools (follows most vg_write calls).
...
o Skip autobackup when in test mode.
o Set test mode from config file.
o Create system/backup dirs if not present (unless LVM_SYSTEM_DIR holds "").
2001-12-31 21:27:39 +00:00
Alasdair Kergon
3080a75445
o activation & active status tests
...
o lvdisplay fields from kernel
o update lv->size on resize
2001-11-21 19:32:35 +00:00
Alasdair Kergon
e68b5e3029
o lvdisplay now shows LE / PV map
...
o fix LE allocation when first PV is full
o reduce VG free_count when removing PVs from VG
2001-11-13 17:53:06 +00:00
Alasdair Kergon
277237805a
iospace restructured
2001-11-12 15:10:01 +00:00
Joe Thornber
1b9fcf48b1
o LGPL list implementation
2001-10-31 12:47:01 +00:00
Joe Thornber
c7f0b573ac
o use dev_name(dev) to get the name of a device, this operation is cheap
...
since it just get's the first alias.
2001-10-25 14:04:18 +00:00
Alasdair Kergon
6e91eeef13
vgreduce, vgremove, vgrename & vgscan
2001-10-11 21:35:55 +00:00