diff options
author | Peter Rajnoha <prajnoha@redhat.com> | 2011-02-21 12:26:27 +0000 |
---|---|---|
committer | Peter Rajnoha <prajnoha@redhat.com> | 2011-02-21 12:26:27 +0000 |
commit | 17ad2b1115ef83baf59de8a7cdbfc1852bfe7ade (patch) | |
tree | 347fd30e33201b7956cb008756d2fc37a3e0e357 /tools | |
parent | 903d7db05042ba1e0532585ac460e91912a27fa5 (diff) | |
download | lvm2-17ad2b1115ef83baf59de8a7cdbfc1852bfe7ade.tar.gz lvm2-17ad2b1115ef83baf59de8a7cdbfc1852bfe7ade.tar.xz lvm2-17ad2b1115ef83baf59de8a7cdbfc1852bfe7ade.zip |
Change pv_write code to work with the changes in metadata handling interface
and changes in format_instance.
Diffstat (limited to 'tools')
-rw-r--r-- | tools/pvchange.c | 4 | ||||
-rw-r--r-- | tools/pvresize.c | 2 | ||||
-rw-r--r-- | tools/vgconvert.c | 4 | ||||
-rw-r--r-- | tools/vgreduce.c | 2 |
4 files changed, 5 insertions, 7 deletions
diff --git a/tools/pvchange.c b/tools/pvchange.c index 6e0fc2d3..0ffe7df4 100644 --- a/tools/pvchange.c +++ b/tools/pvchange.c @@ -139,7 +139,7 @@ static int _pvchange_single(struct cmd_context *cmd, struct volume_group *vg, pv->vg_name = pv->fmt->orphan_vg_name; pv->pe_alloc_count = 0; - if (!(pv_write(cmd, pv, NULL, INT64_C(-1)))) { + if (!(pv_write(cmd, pv))) { log_error("pv_write with new uuid failed " "for %s.", pv_name); return 0; @@ -161,7 +161,7 @@ static int _pvchange_single(struct cmd_context *cmd, struct volume_group *vg, return 0; } backup(vg); - } else if (!(pv_write(cmd, pv, NULL, INT64_C(-1)))) { + } else if (!(pv_write(cmd, pv))) { log_error("Failed to store physical volume \"%s\"", pv_name); return 0; diff --git a/tools/pvresize.c b/tools/pvresize.c index f347d9d3..f1870c6c 100644 --- a/tools/pvresize.c +++ b/tools/pvresize.c @@ -150,7 +150,7 @@ static int _pv_resize_single(struct cmd_context *cmd, goto out; } backup(vg); - } else if (!(pv_write(cmd, pv, NULL, INT64_C(-1)))) { + } else if (!(pv_write(cmd, pv))) { log_error("Failed to store physical volume \"%s\"", pv_name); goto out; diff --git a/tools/vgconvert.c b/tools/vgconvert.c index e19fa480..3c9ff653 100644 --- a/tools/vgconvert.c +++ b/tools/vgconvert.c @@ -154,9 +154,7 @@ static int vgconvert_single(struct cmd_context *cmd, const char *vg_name, log_very_verbose("Writing physical volume data to disk \"%s\"", pv_dev_name(pv)); - if (!(pv_write(cmd, pv, &mdas, - arg_int64_value(cmd, labelsector_ARG, - DEFAULT_LABELSECTOR)))) { + if (!(pv_write(cmd, pv))) { log_error("Failed to write physical volume \"%s\"", pv_dev_name(pv)); log_error("Use pvcreate and vgcfgrestore to repair " diff --git a/tools/vgreduce.c b/tools/vgreduce.c index 5e61cf83..8d3cb1cd 100644 --- a/tools/vgreduce.c +++ b/tools/vgreduce.c @@ -438,7 +438,7 @@ static int _vgreduce_single(struct cmd_context *cmd, struct volume_group *vg, goto bad; } - if (!pv_write(cmd, pv, NULL, INT64_C(-1))) { + if (!pv_write(cmd, pv)) { log_error("Failed to clear metadata from physical " "volume \"%s\" " "after removal from \"%s\"", name, vg->name); |