Logical Volume Manager Changelog                        27/05/1998 - 21/02/2000


Changelog for 0.8-pre02.10.1999 (included with SuSE 6.3) to 0.8final
--------------------------------------------------------------------

LVM
---
/usr/src/linux/drivers/block/ll_rw_blk.c
		- changed to support stacking of volume drivers (MD(LVM)

/usr/src/linux/fs/partitions/check.c
		- added /proc/partition support for LVM

Driver
------
do_lv_remove	- enhanced to support removal of snapshot logical volumes

general		- added lvm-snap.c with Andrea Arcangeli's (THX Andrea!)
                  snapshot support functions

Tools
-----

All tools	- implemented support for long options
                - additional exit states

Makefile	- avoided dynamic library search into generate directory

lvmcreate_initrd
		- kernel version parameter support

lvdisplay
pvdisplay
vgdisplay	- implemented option -c for colon seperated output
                  enabling easy parsing

lvmdiskscan	- fixed partition count bug

lvchange
lvcreate
lvextend
lvreduce
lvremove
lvrename
pvchange
pvmove
vgchange
vgcreate
vgextend
vgmerge
vgreduce
vgrename
vgsplit		- added support for LVM_AUTOBACKUP environment variable
		  (thx to Torsten Neuman <torsten@londo.rhein-main.de>)

vgscan		- use lvm_remove_recursive() instead of system ( "rm -fr ...

vgcfgrestore	- deleted check of lvmtab to avoid catch 22 situation


Library
-------
All functions	- changed to use debug_enter()/debug_leave()

debug_enter
debug_leave	- implemented to support better tracing

lvm_dir_cache	- added /proc/partitions support to gain performance

lvm_error	- implemented to support plan text error messages rather
                  than numbers

lvm_remove_recursive
		- created to avoid system("rm -fr ...

vg_status	- added malloc() of volume group structure

vg_cfgbackup	- implemented support for environment variable
		  LVM_VG_MAX_BACKUPS to set maximum backup history depth

vg_remove_dir_and_group_and_nodes
		- use lvm_remove_recursive() instead of system ( "rm -fr ...


================================================================================
Changelog for LVM 0.7 to 0.8-pre02.10.1999
------------------------------------------

LVM
---

Driver
------
do_lv_create
lvm_map
lvm_snapshot_remap_block
lvm_snapshot_remap_new_block
		- enhanced to support creation of snapshot logical volumes

Tools
-----
lvcreate	- enhanced to support creation of snapshot logical volumes

lvmdiskscan	- added support for DAC960
		- changed open optimization because it fails in non
                  standard environments

lvremove	- enhanced to support deletion of snapshot logical volumes

lvchange	- enhanced to block attribute changes on snapshot LVs

lvextend
lvreduce	- enhanced to block resizing on snapshot LVs

pvcreate
vgremove	- additional exit codes


Library
-------
lvm_check_whole_disk_dev
		- implemeted; checks, if device mapps a whole disk

lvm_dir_cache_find
		- implemented; finds a slot in the directory cache
                  by giving the device name

lvm_partition_count
		- implemeted;
		  gets partition count (for eg. 16 for IDE or 8 for DAC960)

lvm_check_extended_partition
		- implemeted; checks, if device mapps an extended partition

lvm_check_kernel_lvmtab_consistency
		- implemented; checks, if lvmtab and kernel VG namelists
                  are consistent (names of active VGs _must_ exits in lvmtab).

lvm_dir_cache_select
		- deleted; internal support function for scandir()

lvm_tab_vg_check_exist_all_vg
		- free unused memory if recalled

pv_check_part.c	- rewritten using lvm_dir_cache_find()

pv_move		- fixed move bug on loop devices
                  (thx to Johannes Deisenhofer jo@hexmac.com)

pv_read_all_pv	- avoided open optimization because it fails in non
                  standard environments

lv_setup_for_extend.c
lv_setup_for_reduce.c
lvm_dir_cache.c
lvm_get_col_numbers.c
lvm_tab_get_free_blk_dev.c
lvm_tab_vg_check_exist_all_vg.c
lvm_tab_vg_insert.c
pv_find_all_pv_names.c
pv_move.c
pv_read_all_pv.c
pv_read_already_red.c
pv_reserve_release_pe.c
pv_status.c
vg_check_active.c
vg_check_exist.c
vg_setup_for_reduce.c
		- fixed potential NULL pointer free() calls
================================================================================
Changelog for LVM 0.6 to 0.7
----------------------------

LVM
---
drivers/block/genhd.c
		- added function pointer call to lvm_hd_name ()

/usr/src/linux/drivers/block/ll_rw_blk.c
                - enhanced to support PVs on loop devices for
		  test/evaluation purposes


Driver
------
module_init/lvm_init
		- fixed a NULL pointer in case of LVM activated
                  without any previously existing gendisks
		- added lvm_hd_name_ptr setup

cleanup_module
		- added lvm_hd_name_ptr setup


Tools
-----
ALL		- added exit code 95 for driver/module not in kernel

lvmcreate_initrd
		- script to create an initial ram disk image containing
                  all neccessary files to change to a root filesystem
                  contained in a LV

lvmdiskscan	- enhanced to support loop devices

lvscan		- added total capacity display
pvscan

vgdisplay	- reformated option -s output

vgimport	- fixed MAX_LV bug

vgscan		- added VG and LV minor correction in case they overlap


Library-Functions
-----------------
liblvm.h	- rearanged includes due to 2.3.x changes

pv_get_size	- enhanced to support loop devices

lv_check_stripesize
		- fixed size bug

lvm_check_special
		- implemented; checks for and optionaly creates /dev/lvm

lvm_check_partitioned_dev
		- implemented; checks for a partitioned physical volume
                  (used by pv_get_size() and lvmdiskscan now)

lvm_dir_cache	- avoided useless allocation if cache was hit
                - added /dev/rd/

vg_read_with_pv_and_lv
		- added correction of block device major in case
                  of old logical volume major number

lvm_check_chars
lv_check_name
vg_check_name	- allowed '.' as valid character and checked for
                  invalid "." and ".." VG and LV names

pv_reserve_release_pe
		- fixed striped LV shrink bug

vg_check_exist_all_vg
		- fixed NULL pointer bug



================================================================================
Changelog for LVM 0.5alpha to 0.6
---------------------------------

LVM
---
general         - changed to deal with up to 256 logical volumes
                  per volume group

Driver
------
lvm_chr_open    - moved spinlock code to lvm_chr_ioctl()

lvm_chr_ioctl   - added spinlock code and allowed some ioctl's
                  while another process holds the lock
                - fixed NULL pointer buf with VG_REDUCE
                - added LVM_LOCK_LVM ioctl

lvm_blk_ioctl   - enhanced BLKRASET/BLKRAGET ioctl to support
                  read ahead sectors per logical volume

do_vg_remove	- using do_lv_remove() avoided some code


Tools
-----
general		- changed to new LVM_LOCK_LVM

e2fsadm
lvcreate
Ivextend
lvreduce
lvmchange
vgreate          - added units to size option arguments to allow
                   kilo-/mega-/giga- and terabyte entries

lvmchange        - removed option r for read ahead sectors
                   (now implemented on a per logical volume base)

lvchange
lvcreate         - implemented option r (read ahead)

lvremove         - added linefeeds to stderr

pvscan           - added options s and n for short display and no volume group

vgchange         - added option l for changeing maximum logical volume number


Library-Functions
-----------------
lvm_check_number - supports units [mM] for megabyte, [gG] for gigabyte
                   and [tT] for terabyte now

lvm_lock         - changed to new LVM_LOCK_LVM ioctl

lvm_show_size    - fixed presentation bug with zero

lvm_tab_get_blk_dev
                 - implemented; gets an existing/new block device major/minor
                   based on the lvm_tab information

lv_change_read_ahead
                 - implemented to change lgocal volume read ahead
                   sector count (BLKRASET/BLKRAGET)

lv_create_dev_t  - obsoleted

lv_show          - added output of block device MAJOR:MINOR

lvm_tab_get_free_blk_dev
                 - created to deal with the free block special pool

lv_copy_from_disk
lv_copy_to_disk
pe_copy_from_disk
pe_copy_to_disk
pv_copy_from_disk
pv_copy_to_disk
vg_copy_from_disk
vg_copy_to_disk  - avoided conversion if architecture is __LITTLE_ENDIAN

vg_check_exist_all_vg
                 - changed to support free volume group names



================================================================================
Changelog for LVM 0.4alpha to 0.5alpha
--------------------------------------

LVM
---
general          - ported to 2.2.x
                 - integrated with stock 2.0/2.1/2.2 kernels;
                   files involved:
                   - CREDITS
                   - MAINTAINERS
                   - Documentation/Configure.help
                   - drivers/block/Config.in
                   - drivers/block/Makefile
                   - drivers/block/README.lvm
                   - drivers/block/ll_rw_blk.c
                   - drivers/block/lvm.c
                   - include/linux/lvm.h
                   - include/linux/major.h
                   - kernel/ksyms.c

                 - obsoleted lvm_version.h
                 - ported to libc6

Driver
------
general          - implemented i/o statistic for logical volumes
                 - used __initfunc macro (>=2.1.x) to free some initial
                   functions memory
                 - fixed lvm_gendisk.part[] index error
                 - changed to official major numbers and removed use
                   of lvm_MajorNumber variable previously defined in
                   lvm_kernel.h

lvm.h            - enhaced pe_t structure definition by ios member
                   to hold i/o operations till logical volume activation
                 - removed LVM_MAJOR to use official
                   LVM_CHAR_MAJOR/LVM_BLOCK_MAJOR defind in
                   /usr/src/linux/include/linux/major.h
                 - implemented seperated disk and core VGDA structures
                   to support exchange of volume groups between
                   different platforms
                 - moved internal driver function prototypes to lvm.c

lvm_kernel.h     - removed lvm_MajorNumber
                 - obsoleted by merging into lvm.h

lvm_map          - added I/O statistic for reads and writes per
                   logical extent

do_lv_extend_reduce
                 - saved i/o statistics across logical volume extensions
                   and reductions

do_lv_create     - fixed LV index bug in case of renaming an LV

lvm_proc_get_info
                 - implemented line split in case of long LV name


Tools
-----
general          - corrected messages in many tools
                 - added exit states to all tools including man pages

e2fsadm          - implemented; uses e2fsck, lvextend, lvreduce and resize2fs
                   and /proc/mounts to resize ext2 filesystem and containing
                   logical volume

lvchange         - added check for volume group existence

lvcreate
lvrename
vgrename         - logical volume path length bug fixed

lvrename         - command line handling bug fixed

lvmsadc          - new logical volume manager system activity daemon

lvmsar           - new logical volume manager system activity reporter

pvmove           - enhanced to handle LE/PE move lists/ranges

vgextend         - avoided unecessary volume group exixtence check

lvcreate.c
lvrename.c
pvmove.c
vgcreate.c
vgmknodes.c
vgrename.c       - make volume group directory a preprocessor option



Library-Functions
-----------------
general          - implemented data layer functions (see below)

lvm_check_chars  - implemented to check allowed characters in VG, LV
                   and PV names

lv_check_on_pv   - fixed bug in PE loop

lv_check_consistency_all_lv
                 - added LV number check

lv_create_node   - added unlink() error return

lvm_lock.c
lv_create_kdev_t
vg_create_dir_and_group.c
                 - changed to official major numbers

lvm_dir_cache
pv_check_name    - corrected handling of devfs names

lv_read_all_lv_of_vg
                 - fixed free() bug

lv_setup_for_extend
                 - fixed contiguous allocation extension bug if logical
                   volume not starting on first physical volume

lv_show_current_pe_text
                 - output # of PVs for LV distribution
                 - output # of i/o operations with option -v for
                   each logical extent and each physical volume; output
                   a total i/o summary

lv_status_byindex
lv_status_byname - enhanced to get lv_current_pe array from kernel too
                   (lv_status_with_pe() only did that before)
 
lv_status_with_pe
                 - obsoleted (has been used in lvdisplay.c only)

lvm_lock         - added creation of device special /dev/lvm (if missing)

lvm_get_col_numbers
                 - implemented (used by pvmove.c) to parse lists/ranges
                   of logical/physical extent numbers in the command line

lvm_tab_lv_read_by_name
                 - implemented (used by e2fsadm.c) to read LV VGDA part
                   from lvmtab.

pv_move_pes      - enhanced to handle LE/PE move lists

pv_reserve       - fixed contiguous logical volume allocation bug
                   in case of extension

vg_cfgbackup     - implemeted deeper backup history; now up to 10
                   backup files for each volume group are available in
                   /etc/lvmconf/


lv_check_name
pv_check_name
vg_check_name    - used new lvm_check_chars()

lv_copy_from_disk
lv_copy_to_disk
pe_copy_from_disk
pe_copy_to_disk
pv_copy_from_disk
pv_copy_to_disk
vg_copy_from_disk
vg_copy_to_disk  - implemented to convert between disk and core structures
                   (necessary to support exchange of volume groups between
                    different platforms); data layer functions

pv_check_consistency
                 - enhanced to check PE structure

pv_check_number  - fixed array index bug

pv_show_pe_text  - added output of disk offset in sectors of 512B

lv_read_all_lv_of_vg
lv_write_all_lv_of_vg
lv_write
pv_read
pv_write 
vg_read
vg_write         - seperated disk and core structures by using
                   new functions ??_copy_{from/to}_disk()

vg_read          - hand back VG pointer in vg_read() in case of exported VG

lv_check_name.c
lv_create_remove.c
lv_extend_reduce.c
lv_le_remap.c
lv_setup_for_create.c
lv_status.c
pe_lock.c
pv_change.c
pv_status.c
vg_check_name.c
vg_create_dir_and_group.c
vg_create_dir_and_group_and_nodes.c
vg_extend_reduce.c
vg_set_clear_extendable.c
vg_setup_for_merge.c
vg_status.c
liblvm.h         - make volume group directory a preprocessor option


================================================================================
Changelog for LVM 0.3alpha to 0.4alpha
--------------------------------------

LVM
---
general          - changed all short/long/char/etc. to uintNN_t and
                   #if'ing them to keep down with __uNN of 2.0.x

lvm.h            - changed LVM_LV_SIZE_MAX macro to return long long


Driver
------
general          - changed allocation from using kmalloc to vmalloc
                   to gain larger memory chunks (no 256GB with PE size 4MB)

lvm_chr_open     - #if'd spinlock code to keep down with 2.0.x


Tools
-----
lvmdiskscan      - implemented; scans for all
                   disks / multiple devices / partitions available

vgck             - implemented to do a consistency check
                   of volume group descriptor areas

vgextend         - moved extend structure stuff to lib layer

vgreduce         - moved reduce structure stuff to lib layer

vgmerge
vgsplit          - implemented to split or merge volume groups


Library-Functions
-----------------
vg_check_name    - additional check for EXPORTED VG name

vg_free          - implemented to free malloced memory of a core VGDA

vg_setup_for_extend
                 - created from moved code in vgextend.c

vg_setup_for_reduce
                 - created from moved code in vgreduce.c

lvm_show_size    - renamed from show_size and changed
                   size parameter to type long long

lvm_show_filetype
                 - renamed from filetype_show



================================================================================
Changelog for LVM 0.2alpha to 0.3alpha
--------------------------------------

LVM
---
general          - ported to Linux 2.1.98 to 2.1.102
                 - added support for free volume group and
                   logical volume names
                 - added support for MD (multiple device) usage
                 - implemented full pvmove function to be able to move
                   all types of logical volumes (linear/striped/contiguous)
                 - added LVM shared library
                 - added checking for /etc/lvmtab and /etc/lvmtab.d existence
                 - changed name of ??_store* functions to ??_write*
                   to get consistency with ??_read* function names
                 - avoided creating backup files, if they didn't change

Driver
------
lv_chr_ioctl     - implemented LV_STATUS_BYINDEX ioctl
                 - changed LV_STATUS to LV_STATUS_BYNAME ioctl
                 - implemented VG_SET_EXTENDABLE ioctl

lvm_map          - added IDE4/IDE5 majors for Linux > 2.1.9x

lvm_proc_get_info
                 - changed output format of /proc/lvm

lvm.h            - reintegrated lvm_v1.h to form one lvm.h with all
                   structure versions


Tools
-----
lvcreate         - implemented -n option for free logical volume names

lvrename         - implemented; supports renaming of logical volumes

lvscan           - implemented; scans for logical volumes in all volume groups

pvchange         - avoided option -c

pvdisplay        - implemented option -s

pvmove           - implemented physical extent move for a single logical
                   volume; supported striped and/or contiguous logical volumes

vgchange         - implemented option -x

vgextend
vgreduce         - added extension/reduction lock (vgchange -x n ...)

vgdisplay        - used vg_read_with_pv_and_lv() instead of
                   lvm_tab_vg_read_with_pv_and_lv() for option -D

vgmknodes        - implemented to support creation of volume group
                   directory and special files in case of deletion

vgrename         - implemented; supports renaming of volume groups

pvcreate
vgcfgrestore
vgcreate
vgimport
vgexport
vgrename
vgremove
vgscan            - enhanced error checking of lvm_tab_vg_insert() and
                    lvm_tab_vg_remove()

vgrestore         - changed to support restore to dedicated physical volume
                    and to support path changes between physical volume
                    pathes on backup and actual physical volume pathes

pvchange
pvscan
vgimport          - obsoleted physical volume name change
                    (it's now in pv_read())



Library-Functions
-----------------
lvm_check_dev    - implemented to check for usable devices (SCSI, IDE, MD);
                   added IDE4/IDE5 majors for Linux > 2.1.9x

lvm_dir_cache    - implemented as directory cache function for block devices
                   (used to avoid direct directory handling in
                    pv_create_name_from_kdev_t.c, pv_read.c and pv_status.c)

lvm_filetype_show
                 - implemented

lvm_tab_vg_insert
lvm_tab_vg_remove
                 - several bug fixes

vg_number_from_name
lv_create_number_from_name
lv_number_from_name
lv_create_name   - removed (obsolete)

lv_number_from_name_in_vg
                 - implemented to avoid inline name string creation
                   (this obsoletd lv_number_from_name())

lvm_tab_get_free_vg_number
                 - bug fix for empty/no lvmtab file

pv_move_pes      - implemented; calculates multiple PEs to be moved
pv_move_pe       - implemented; called by pv_move_pes() to move one PE

pv_create_name_from_kdev_t
pv_read_all_pv
pv_status_all_pv - avoided direct directory scanning
                   (it's now in lvm_dir_cache())

pv_read          - implemented correction of physical volume name to
                   avoid it in the tools level

vg_check_exist   - bug fix for handling exported volume groups

lv_create_kdev_t.c
pv_check_consistency.c
pv_check_name
pv_create_name_from_kdev_t.c
pv_read.c
vg_create_dir_and_group.c
                 - added multiple device support

vg_show          - implemented display of extension/reduction lock

vg_set_extendable
vg_clear_extendable
                 - implemented


================================================================================
Changelog for LVM 0.1alpha to 0.2alpha
--------------------------------------

LVM
---
general          - ported to Linux 2.1.60-62
                 - tested with Linux 2.1.31


Driver
------
lvm_chr_ioctl    - implemented ioctls to get number of active VGs
                   and list of VG names
                 - implemented ioctl to give an i/o protocol number


Tools
-----
all              - switched to lvm_tab_* functions to gain performance
                 - added several messages
                 - fixed stdin close bug

vgcfgrestore     - moved restore code partially to lib

vgscan           - implemented: builds /etc/lvmtab and /etc/lvmtab.d
                   from VGDAs on PVs




Library-Functions
-----------------

general         - inititlized all file handles with -1 to
                  avoid error close of stdin
                - started support for free VG and LV names

pv_get_index_by_kdev_t
                - renamed from pv_get_index

pv_get_index_by_name
                - implemented

lvm_get_iop_version
               - implemented: get's i/o protocol version from kernel

lvm_tab_lv_check_exist
                - implemented

lvm_tab_vg_insert
                - implemented

lvm_tab_vg_read_with_pv_and_lv
                - implemented

lvm_tab_vg_read
                - implemented

lvm_tab_vg_remove
                - implemented

lvm_tab_vg_check_exist
                - implemented

lvm_tab_vg_check_exist_all_vg
                - implemented

lvm_tab_read
                - implemented

lvm_tab_store
                - implemented

lv_get_index_by_name
                - renamed form lv_get_index and changed formal paramter
                  list sequence

lv_get_index_by_kdev_t
                - implemented

lv_status_all_lv_of_vg
                - changed formal parameters to avoid vg_read - call

vg_remove_dir_and_group_and_nodes
                - implemented

vg_cfgbackup    - added option to avoid .old backups and .conf
                  suffixes for /etc/lvmtab.d

vg_cfgrestore   - implemented

vg_status       - changed formal parameters in call to lv_status_all_lv_of_vg




================================================================================
Changelog for LVM 0.0alpha to 0.1alpha
--------------------------------------

LVM
---
general          - Ported to Linux 2.1.57


Driver
------
general          - fixed some NULL-Pointer references
                 - added use of ioctl macros

lvm_chr_open /   - fixed race condition
lvm_chr_close

lvm_chr_ioctl    - implemented physical volume flush and invalidate buffers
                   ioctl to avoid reading data of inavailable physical
                   volumes from buffer cache (see pv_flush in library)
            
Tools
-----
lvcreate         - several messages added

lvreduce         - fixed segfault

pvcreate         - corrected option -f handling

pvdata           - removed direct read of physical vlome name list
                   from disk; used new pv_read_namelist() instead

pvmove           - several bugs fixed

pvscan           - added informational message to use pvchange in case
                   of invalid physical volume name (caused by HW changes)
                 - changed messages for physical volume in no volume group /
                   in exported volume group

vgdisplay        - added -s option: displays short listing of
                                    existing volume groups

vgimport         - fixed wrong correction handling of device names

vgreduce         - fixed segfault
                 - avoided reducing to 0 physical volumes
                 - added -a option: reduces volume group by all free
                                    physical volumes


Library-Functions
-----------------
general          - fixed bugs with always using pv[0] instead off actual pv

pv_check_part    - added support for extended partitions

pv_create_name_from_kdev_t
                 - corrected and extended PV name generation for IDE

pv_flush         - user space part to flush buffer cache and invalidate
                   buffers for individual physical volumes
                   (see PV_FLUSH in lvm_chr_ioctl of driver)

pv_get_size      - extended partitions now supported

pv_number_check  - implemented

pv_read          - finished looping trough all possible device specials
                   after ENODEVs and ENXIOs to become faster;
                   called pv_flush before reads

pv_read_all_pe_of_vg
                 - used pv_number_check to sort PE arrays by PV number

pv_read_namelist - implemented to read namelist from the VGDA on disk

vg_check_name    - support for full volume group path (eg. /dev/vg00)

vg_show          - added a row for maximum logical volume size
