1
0
mirror of git://sourceware.org/git/lvm2.git synced 2025-01-11 09:18:25 +03:00
Commit Graph

47 Commits

Author SHA1 Message Date
Alasdair Kergon
45dca55fc8 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
445d8ecd9f sign fix 2006-05-04 09:33:42 +00:00
Alasdair Kergon
4790715cd3 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
f7bf658c07 Capture vgid in more places. 2006-04-10 22:09:00 +00:00
Alasdair Kergon
67eb7723d6 Use hash, bitset, malloc, pool from libdevmapper. 2005-10-16 23:03:59 +00:00
Alasdair Kergon
fc5c61cc8b Begin to separate out segment types. 2004-05-04 21:25:57 +00:00
Alasdair Kergon
ac282e63c6 Compress any (obsolete) long LVM1 pvids encountered. 2004-05-04 18:38:11 +00:00
Alasdair Kergon
66ed5f82c4 Update copyright notices. 2004-03-30 19:35:44 +00:00
Alasdair Kergon
bd806a41df move hostname into global 2004-03-08 17:25:59 +00:00
Alasdair Kergon
c3a4677990 Relax restriction on pe_start location when re-writing LVM1 metadata. 2003-12-09 17:51:39 +00:00
Alasdair Kergon
b0b4def983 Cope better with LVM1 minor numbers & LV numbers. 2003-11-06 16:58:38 +00:00
Alasdair Kergon
9f85f61010 Fix vgimport fix to work outside debug mode. 2003-07-15 01:26:24 +00:00
Alasdair Kergon
67af3c37be Fix detection of exported LVM1 volume groups. 2003-07-13 11:07:25 +00:00
Alasdair Kergon
dd2157534b 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
81c44790d5 Refactoring. 2002-11-18 14:01:16 +00:00
Alasdair Kergon
63875e7591 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
Heinz Mauelshagen
f7baa67a0a First cut on "pvcreate -s" 2002-02-15 01:26:16 +00:00
Joe Thornber
77e3b460aa o First pass at format1 snapshot support. 2002-02-13 11:43:29 +00:00
Joe Thornber
b5321001f8 o First changes to add snapshot support.
I'm taking a different route from LVM1 here in that snapshots are a
seperate entity from the logical volumes, I think of them as an
application of an LV (or two lvs rather).  As such there is a list of
snapshots held against the vg, and there is *not* a SNAPSHOT, or
SHAPSHOT_ORG flag in lv->status.
2002-02-12 16:31:31 +00:00
Alasdair Kergon
366ec35612 Basic support for persistent minor numbers;
slightly different from the current LVM1 method.

  lvcreate --persistent y  --minor 10   (to specify when created)
  lvchange --persistent n  (to turn off)
  lvchange --persistent y  --minor 11   (to change)

--persistent uses a new LV status flag stored on disk
minor number is stored on disk the same way as LVM1 does
(but major number stored is 0; any LVM1 major/minor setting gets lost)

  lvchange -ay --minor 12 (to activate using minor 12, regardless of the
                           on-disk setting, which doesn't get changed)

--minor == -m
--persistent == -M
2002-02-01 17:54:39 +00:00
Alasdair Kergon
6435b49153 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
d294d7604c o Tidy 2002-01-25 13:41:13 +00:00
Alasdair Kergon
01df2cf464 Have a pe_total check using theoretically big number instead of the
unnecessarily small limit LVM1 imposes in vgcreate (but not vgextend)
2002-01-24 23:35:56 +00:00
Heinz Mauelshagen
a975e85548 removed ~64limit for PEs per PV agk introduced 2002-01-24 19:20:35 +00:00
Alasdair Kergon
f6011184b8 Impose max PE limit for each PV. 2002-01-24 17:24:32 +00:00
Alasdair Kergon
c46d20fa92 o pvcreate --uuid to specify the uuid (required before using vgcfgrestore
onto a new device).  uuid specified must not already exist on the system.
o More message tidying.
o When checking for label, only read PV metadata.
o Add ataraid.  [Needs moving into config/defaults files.]
2002-01-16 18:10:08 +00:00
Alasdair Kergon
0b6d132759 Miscellaneous tidying 2001-11-14 13:52:38 +00:00
Joe Thornber
3d95cfb367 o Added dev_open and dev_close functions
o  Changed disk-rep to use these

o  if NDEBUG is not defined the dev_cache will check for open devices on
   teardown.

I was hoping this would speed things up.  But I'm still getting:

reti:/home/joe/sistina/LVM2/tools# time ./lvm vgchange -a n
  Volume group vg0 successfully changed

real    0m5.751s
user    0m0.060s
sys     0m0.070s

even though I have only 1 device with the vg on it passing the filters.
2001-11-14 10:01:52 +00:00
Alasdair Kergon
02a70e5667 o Added lvextend
o Full signed arguments to lvreduce/lvextend
o Consistent lv_number/pe map use
o Populate pv->pe_allocated
o Fixes for allocation/writing of multiple LVs
2001-11-09 22:01:04 +00:00
Joe Thornber
0acdd3c62b o adjacent extents are now merged into a single target when activating. 2001-11-05 13:37:13 +00:00
Alasdair Kergon
906db728d6 o Changes to activation interface
o Add pointer lv->vg
o Some naming tweaks to improve clarity
2001-10-31 17:59:52 +00:00
Joe Thornber
c4b7411565 o LGPL list implementation 2001-10-31 12:47:01 +00:00
Alasdair Kergon
a84fdddb2a vgcreate basic extent size validation 2001-10-15 20:29:15 +00:00
Joe Thornber
4104543508 o a very quick hack to get vg_number right 2001-10-11 14:10:18 +00:00
Joe Thornber
e222a34b69 o vg->pv_act 2001-10-11 13:05:55 +00:00
Joe Thornber
ef17d95063 o calculate pv_numbers and lv_numbers for LVM1 support 2001-10-11 10:55:19 +00:00
Joe Thornber
50a7923438 o uuid_list->id should be NAME_LEN wide 2001-10-10 13:30:58 +00:00
Joe Thornber
5b030139d3 o pv_setup for format1, this is the last one ! 2001-10-10 10:55:55 +00:00
Joe Thornber
026f3cfde2 o add munging for format1 and 2 2001-10-10 09:36:29 +00:00
Joe Thornber
f6349180e8 o Code to calculate the metadata layout. 2001-10-10 09:25:04 +00:00
Joe Thornber
1e76b72b98 o hack, hack, hack 2001-10-09 14:26:45 +00:00
Joe Thornber
b94cf39eef o vg_write compiles 2001-10-09 10:47:52 +00:00
Joe Thornber
66c887d0f3 o read_vg works (or so it claims) 2001-10-08 16:08:16 +00:00
Joe Thornber
8d402d76d0 o get things compiling 2001-10-08 09:45:16 +00:00
Joe Thornber
46fda6281c o test program for reading a vg 2001-10-08 08:47:27 +00:00
Joe Thornber
c7a484195a o low level write path 2001-10-05 15:20:40 +00:00
Joe Thornber
5ed11e012e o vg_read for format1 2001-10-04 17:48:55 +00:00