Document qemu-img options data_file and data_file_raw
PATCH 1/1 Document qemu-img options data_file and data_file_raw
The contents of this patch were initially developed and posted by Han Han[1], however, it appears the original patch was not applied. Since then, the relevant documentation has been moved and adapted to a new format.
I've taken most of the original wording and tweaked it according to some of the feedback from the original patch submission. I've also adapted it to restructured text, which is the format the documentation currently uses.
[1] https://lists.nongnu.org/archive/html/qemu-block/2019-10/msg01253.html
--- docs/tools/qemu-img.rst | 12 ++++++++++++ 1 file changed, 12 insertions(+)
docs/tools/qemu-img.rst +12 -0
@@ -866,6 +866,18 @@ Supported image file formats: issue ``lsattr filename`` to check if the NOCOW flag is set or not (Capital 'C' is NOCOW flag). + ``data_file`` + Pathname that refers to a file that will store all guest data. If + this option is used, the qcow2 file will only contain the image's + metadata. + + ``data_file_raw`` + If this option is set to ``on``, QEMU will always keep the external + data file consistent as a standalone read-only raw image. The default + value is ``off``. + + This option can only be enabled if ``data_file`` is set. + ``Other`` QEMU also supports various other image file formats for
Signature · 1 line
2.29.2
Quoted 10 lines · Connor Kuehl
The contents of this patch were initially developed and posted by Han Han[1], however, it appears the original patch was not applied. Since then, the relevant documentation has been moved and adapted to a new format.
I've taken most of the original wording and tweaked it according to some of the feedback from the original patch submission. I've also adapted it to restructured text, which is the format the documentation currently uses.
Quoted 4 lines
[1] https://lists.nongnu.org/archive/html/qemu-block/2019-10/msg01253.html
Reported-by Han Han <[email protected]>Co-developed-by Han Han <[email protected]>
Unusual tag, and his original email has Signed-off-by. It's easier to just reuse S-o-b here.
Quoted 20 lines
Signed-off-by Connor Kuehl <[email protected]>--- docs/tools/qemu-img.rst | 12 ++++++++++++ 1 file changed, 12 insertions(+)docs/tools/qemu-img.rst +5
-0@@ -866,6 +866,18 @@ Supported image file formats: issue ``lsattr filename`` to check if the NOCOW flag is set or not (Capital 'C' is NOCOW flag). + ``data_file`` + Pathname that refers to a file that will store all guest data. If + this option is used, the qcow2 file will only contain the image's + metadata. +
docs/tools/qemu-img.rst Supported image file formats: · line 883
Quoted 10 lines
docs/tools/qemu-img.rst +7
-0+ ``data_file_raw`` + If this option is set to ``on``, QEMU will always keep the external + data file consistent as a standalone read-only raw image. The default + value is ``off``. + + This option can only be enabled if ``data_file`` is set. + ``Other`` QEMU also supports various other image file formats for
Otherwise,
Signature · 3 lines
Eric Blake, Principal Software Engineer Red Hat, Inc. +1-919-301-3226 Virtualization: qemu.org | libvirt.org
Quoted 12 lines · Connor Kuehl
The contents of this patch were initially developed and posted by Han Han[1], however, it appears the original patch was not applied. Since then, the relevant documentation has been moved and adapted to a new format.
I've taken most of the original wording and tweaked it according to some of the feedback from the original patch submission. I've also adapted it to restructured text, which is the format the documentation currently uses.
[1] https://lists.nongnu.org/archive/html/qemu-block/2019-10/msg01253.html
Quoted 7 lines
Reported-by Han Han <[email protected]>Co-developed-by Han Han <[email protected]>Signed-off-by Connor Kuehl <[email protected]>--- docs/tools/qemu-img.rst | 12 ++++++++++++ 1 file changed, 12 insertions(+)
Quoted 10 lines · Connor Kuehl
The contents of this patch were initially developed and posted by Han Han[1], however, it appears the original patch was not applied. Since then, the relevant documentation has been moved and adapted to a new format.
I've taken most of the original wording and tweaked it according to some of the feedback from the original patch submission. I've also adapted it to restructured text, which is the format the documentation currently uses.
Quoted 6 lines
[1] https://lists.nongnu.org/archive/html/qemu-block/2019-10/msg01253.html
Reported-by Han Han <[email protected]>Co-developed-by Han Han <[email protected]>Signed-off-by Connor Kuehl <[email protected]>
I am not sure whose tree this is best suited for; ./scripts/get_maintainers.pl only showed other contributors to this file and not an explicit maintainer, per se.
Connor
Quoted 13 lines · Connor Kuehl
Quoted 12 lines · Connor Kuehl
The contents of this patch were initially developed and posted by Han Han[1], however, it appears the original patch was not applied. Since then, the relevant documentation has been moved and adapted to a new format.
I've taken most of the original wording and tweaked it according to some of the feedback from the original patch submission. I've also adapted it to restructured text, which is the format the documentation currently uses.
[1] https://lists.nongnu.org/archive/html/qemu-block/2019-10/msg01253.html
Quoted 8 lines
Quoted 4 lines
Reported-by Han Han <[email protected]>Co-developed-by Han Han <[email protected]>Signed-off-by Connor Kuehl <[email protected]>I am not sure whose tree this is best suited for;
./scripts/get_maintainers.plonly showed other contributors to this file and not an explicit maintainer, per se.
It can go through Kevin Wolf or Max Reitz's trees. They maintain qemu-img.
Stefan
Ping (+Kevin Wolf to CC)
Kevin, would this be appropriate for your tree?
Quoted 44 lines · Connor Kuehl
The contents of this patch were initially developed and posted by Han Han[1], however, it appears the original patch was not applied. Since then, the relevant documentation has been moved and adapted to a new format.
I've taken most of the original wording and tweaked it according to some of the feedback from the original patch submission. I've also adapted it to restructured text, which is the format the documentation currently uses.
[1] https://lists.nongnu.org/archive/html/qemu-block/2019-10/msg01253.html
Reported-by Han Han <[email protected]>Co-developed-by Han Han <[email protected]>Signed-off-by Connor Kuehl <[email protected]>--- docs/tools/qemu-img.rst | 12 ++++++++++++ 1 file changed, 12 insertions(+)docs/tools/qemu-img.rst +12
-0@@ -866,6 +866,18 @@ Supported image file formats: issue ``lsattr filename`` to check if the NOCOW flag is set or not (Capital 'C' is NOCOW flag). + ``data_file`` + Pathname that refers to a file that will store all guest data. If + this option is used, the qcow2 file will only contain the image's + metadata. + + ``data_file_raw`` + If this option is set to ``on``, QEMU will always keep the external + data file consistent as a standalone read-only raw image. The default + value is ``off``. + + This option can only be enabled if ``data_file`` is set. + ``Other`` QEMU also supports various other image file formats for
Quoted 10 lines · Connor Kuehl
The contents of this patch were initially developed and posted by Han Han[1], however, it appears the original patch was not applied. Since then, the relevant documentation has been moved and adapted to a new format.
I've taken most of the original wording and tweaked it according to some of the feedback from the original patch submission. I've also adapted it to restructured text, which is the format the documentation currently uses.
Quoted 4 lines
[1] https://lists.nongnu.org/archive/html/qemu-block/2019-10/msg01253.html
Reported-by Han Han <[email protected]>Co-developed-by Han Han <[email protected]>
I think it's okay to just keep the "Signed-off-by" from Han Han here, and the implication is that you are signing off on modifications you've made since.
Quoted 11 lines
Signed-off-by Connor Kuehl <[email protected]>--- docs/tools/qemu-img.rst | 12 ++++++++++++ 1 file changed, 12 insertions(+)docs/tools/qemu-img.rst +0
-0
docs/tools/qemu-img.rst Supported image file formats: · line 873
Quoted 8 lines
docs/tools/qemu-img.rst +5
-0@@ -866,6 +866,18 @@ Supported image file formats: issue ``lsattr filename`` to check if the NOCOW flag is set or not (Capital 'C' is NOCOW flag). + ``data_file`` + Pathname that refers to a file that will store all guest data. If + this option is used, the qcow2 file will only contain the image's + metadata. +
Might recommend "filename" simply for parity with *FILENAME* argument.
(This is the first appearance of "Pathname" in this file without spaces, though "Path name" is indeed used several times.)
docs/tools/qemu-img.rst Supported image file formats: · line 880
Quoted 7 lines
docs/tools/qemu-img.rst +7
-0+ ``data_file_raw`` + If this option is set to ``on``, QEMU will always keep the external + data file consistent as a standalone read-only raw image. The default + value is ``off``. + + This option can only be enabled if ``data_file`` is set. +
How does this interact with caching options, if it does? What happens in the negative case -- how does the file become inconsistent?
Quoted 4 lines
docs/tools/qemu-img.rst +0
-0``Other`` QEMU also supports various other image file formats for
Quoted 19 lines · John Snow
Quoted 6 lines · Connor Kuehl
[..]
docs/tools/qemu-img.rst +0
-0@@ -866,6 +866,18 @@ Supported image file formats:Quoted 7 lines
issue ``lsattr filename`` to check if the NOCOW flag is set or not (Capital 'C' is NOCOW flag).
+ ``data_file``
+ Pathname that refers to a file that will store all guest data. If + this option is used, the qcow2 file will only contain the image's + metadata.
+Might recommend "filename" simply for parity with *FILENAME* argument.
(This is the first appearance of "Pathname" in this file without spaces, though "Path name" is indeed used several times.)
Quoted 10 lines
docs/tools/qemu-img.rst Supported image file formats: · line 880
Quoted 8 lines
+ ``data_file_raw``
+ If this option is set to ``on``, QEMU will always keep the external + data file consistent as a standalone read-only raw image. The default
+ value is ``off``.docs/tools/qemu-img.rst +3
-0+ + This option can only be enabled if ``data_file`` is set. +How does this interact with caching options, if it does? What happens in the negative case -- how does the file become inconsistent?
Hi,
First, just wanted to share the same note I'm sending to Max's review:
Quoted 1 line
Hey, I just wanted to leave a note indicating that I'm not ignoring this review; I've incorporated it in my next version but I am waiting until after the freeze to send it.
Second: I've been trying to figure out if and how this affects caching. I do not know yet. I will keep digging. My next version of the patch does touch on the negative case though, describing how it becomes inconsistent.
Thank you!
Connor
Quoted 25 lines · Connor Kuehl
The contents of this patch were initially developed and posted by Han Han[1], however, it appears the original patch was not applied. Since then, the relevant documentation has been moved and adapted to a new format.
I've taken most of the original wording and tweaked it according to some of the feedback from the original patch submission. I've also adapted it to restructured text, which is the format the documentation currently uses.
[1] https://lists.nongnu.org/archive/html/qemu-block/2019-10/msg01253.html
Reported-by Han Han <[email protected]>Co-developed-by Han Han <[email protected]>Signed-off-by Connor Kuehl <[email protected]>--- docs/tools/qemu-img.rst | 12 ++++++++++++ 1 file changed, 12 insertions(+)docs/tools/qemu-img.rst +0
-0
docs/tools/qemu-img.rst Supported image file formats: · line 872
Quoted 7 lines
docs/tools/qemu-img.rst +4
-0@@ -866,6 +866,18 @@ Supported image file formats: issue ``lsattr filename`` to check if the NOCOW flag is set or not (Capital 'C' is NOCOW flag). + ``data_file`` + Pathname that refers to a file that will store all guest data. If + this option is used, the qcow2 file will only contain the image's + metadata.
I think I would like a note here about the fact that when passing this option to qemu-img create, the given data file will be newly created, i.e. if it already contains data, all that data will be lost. And perhaps also note that qemu-img amend on the other hand will only change the reference in the qcow2 file, so the given file should already exist and will not be overwritten.
(“Pathname that refers to a file” sounds like the file may already exist before this operation, which may give people ideas. (Not that the ideas were bad, it’s just that they have to take care. Referencing qemu-img amend should give them a hint on how to do it right.))
Max
Quoted 12 lines
docs/tools/qemu-img.rst +8
-0+ + ``data_file_raw`` + If this option is set to ``on``, QEMU will always keep the external + data file consistent as a standalone read-only raw image. The default + value is ``off``. + + This option can only be enabled if ``data_file`` is set. + ``Other`` QEMU also supports various other image file formats for
Quoted 16 lines · Max Reitz
Quoted 6 lines · Connor Kuehl
[..]
docs/tools/qemu-img.rst +0
-0@@ -866,6 +866,18 @@ Supported image file formats:Quoted 6 lines
issue ``lsattr filename`` to check if the NOCOW flag is set or not (Capital 'C' is NOCOW flag).
+ ``data_file``
+ Pathname that refers to a file that will store all guest data. If + this option is used, the qcow2 file will only contain the image's + metadata.I think I would like a note here about the fact that when passing this option to qemu-img create, the given data file will be newly created, i.e. if it already contains data, all that data will be lost. And perhaps also note that qemu-img amend on the other hand will only change the reference in the qcow2 file, so the given file should already exist and will not be overwritten.
Quoted 1 line
(“Pathname that refers to a file” sounds like the file may already exist before this operation, which may give people ideas. (Not that the ideas were bad, it’s just that they have to take care. Referencing qemu-img amend should give them a hint on how to do it right.))
Hey, I just wanted to leave a note indicating that I'm not ignoring this review; I've incorporated it in my next version but I am waiting until after the freeze to send it.
Thank you!
Connor