1
0
mirror of git://sourceware.org/git/lvm2.git synced 2024-12-22 17:35:59 +03:00

thin: disable conversion of thin-pool to read-only

This change is not yet supported.
This commit is contained in:
Zdenek Kabelac 2012-10-15 13:41:38 +02:00
parent faa9a52085
commit b3899056d9
2 changed files with 7 additions and 0 deletions

View File

@ -1,5 +1,6 @@
Version 2.02.98 - Version 2.02.98 -
================================= =================================
Prohibit not yet supported change of thin-pool to read-only.
Support creation of read-only thin volumes (lvcreate -p r). Support creation of read-only thin volumes (lvcreate -p r).
Using autoextend percent 0 for thin pool fails 'lvextend --use-policies'. Using autoextend percent 0 for thin pool fails 'lvextend --use-policies'.
Introduce blkdeactivate script. Introduce blkdeactivate script.

View File

@ -51,6 +51,12 @@ static int lvchange_permission(struct cmd_context *cmd,
return 0; return 0;
} }
if (!(lv_access & LVM_WRITE) && lv_is_thin_pool(lv)) {
log_error("Change permissions of thin pool \"%s\" not "
"yes supported.", lv->name);
return 0;
}
if (lv_access & LVM_WRITE) { if (lv_access & LVM_WRITE) {
lv->status |= LVM_WRITE; lv->status |= LVM_WRITE;
log_verbose("Setting logical volume \"%s\" read/write", log_verbose("Setting logical volume \"%s\" read/write",