1
0
mirror of git://sourceware.org/git/lvm2.git synced 2024-10-28 20:25:52 +03:00
lvm2/lib/metadata
David Teigland 1e65fdd9ba system_id: make new VGs read-only for old lvm versions
Previous versions of lvm will not obey the restrictions
imposed by the new system_id, and would allow such a VG
to be written.  So, a VG with a new system_id is further
changed to force previous lvm versions to treat it as
read-only.  This is done by removing the WRITE flag from
the metadata status line of these VGs, and putting a new
WRITE_LOCKED flag in the flags line of the metadata.

Versions of lvm that recognize WRITE_LOCKED, also obey the
new system_id.  For these lvm versions, WRITE_LOCKED is
identical to WRITE, and the rules associated with matching
system_id's are imposed.

A new VG lock_type field is also added that causes the same
WRITE/WRITE_LOCKED transformation when set.  A previous
version of lvm will also see a VG with lock_type as read-only.

Versions of lvm that recognize WRITE_LOCKED, must also obey
the lock_type setting.  Until the lock_type feature is added,
lvm will fail to read any VG with lock_type set and report an
error about an unsupported lock_type.  Once the lock_type
feature is added, lvm will allow VGs with lock_type to be
used according to the rules imposed by the lock_type.

When both system_id and lock_type settings are removed, a VG
is written with the old WRITE status flag, and without the
new WRITE_LOCKED flag.  This allows old versions of lvm to
use the VG as before.
2015-03-05 09:50:43 -06:00
..
cache_manip.c cache: Fix a segfault when passing --cachepolicy without --cachesettings. 2015-02-24 11:39:35 +01:00
lv_alloc.h thin: simplify thin volume creation 2014-10-26 18:37:13 +01:00
lv_manip.c cmirror: Adjust region size to work around CPG msg limit to avoid hang. 2015-02-25 14:42:15 -06:00
lv.c report: fix seg_monitor field to display monitoring status for thick snapshots and mirrors 2015-03-05 14:05:34 +01:00
lv.h cleanup: for commit 7bcb3fb02d 2015-01-21 11:29:12 +01:00
merge.c cleanup: add lv_is_error_when_full() macro 2015-01-20 14:52:06 +01:00
metadata-exported.h system_id: make new VGs read-only for old lvm versions 2015-03-05 09:50:43 -06:00
metadata.c system_id: make new VGs read-only for old lvm versions 2015-03-05 09:50:43 -06:00
metadata.h cleanup: indent tabs 2015-01-30 12:33:52 +01:00
mirror.c mirror: Explicit cast in region_size_max 2015-02-26 19:49:25 +00:00
pool_manip.c pool: fix typo in error message: then -> than 2014-12-04 09:18:16 +01:00
pv_alloc.h cleanup: self compilable headers 2013-12-12 13:28:19 +01:00
pv_manip.c pvremove: Avoid metadata re-reads & related error messages. 2015-01-06 14:27:30 +01:00
pv_map.c raid_manip: v2 fix multi-segment misallocation on 'lvconvert --repair' 2015-01-16 13:44:16 +01:00
pv_map.h Track unreserved space for all alloc policies and then permit NORMAL to place 2012-02-01 02:10:45 +00:00
pv.c pv_vg_name: do not expose internal orphans to lvm2 users 2014-03-19 00:57:59 +01:00
pv.h cleanup: self compilable headers 2013-12-12 13:28:19 +01:00
raid_manip.c raid: check lock holding LV 2015-01-30 14:16:27 +01:00
replicator_manip.c cleanup: constify activation usage of lv pointer 2014-09-24 10:54:47 +02:00
segtype.c clean: remove unneeded assign 2013-06-17 09:34:56 +02:00
segtype.h thin: errrorwhenfull support 2015-01-14 14:52:05 +01:00
snapshot_manip.c cleanup: fix typo and use vg mempool 2014-09-24 10:54:47 +02:00
thin_manip.c thin: add missing 64KB rounding 2014-11-26 09:29:25 +01:00
vg.c Revert "systemid: Add ACCESS_NEEDS_SYSTEM_ID VG flag." 2015-03-05 09:50:43 -06:00
vg.h system_id: make new VGs read-only for old lvm versions 2015-03-05 09:50:43 -06:00