1
0
mirror of git://sourceware.org/git/lvm2.git synced 2024-12-21 13:34:40 +03:00

doc: update --filemap usage in dmstats.8.in

This commit is contained in:
Bryn M. Reeves 2016-07-08 22:05:14 +01:00
parent 6a77a40501
commit 74565e41fc

View File

@ -80,15 +80,15 @@ dmstats \(em device-mapper statistics management
.de CMD_CREATE .de CMD_CREATE
. ad l . ad l
. BR create . BR create
. IR device_name . RB [ device_name...
. RB | file_path... ]
. RB [ \-\-alldevices ] . RB [ \-\-alldevices ]
. RB [ \-\-areas . RB [ \-\-areas
. IR nr_areas | \fB\-\-areasize . IR nr_areas | \fB\-\-areasize
. IR area_size ] . IR area_size ]
. RB [ \-\-bounds . RB [ \-\-bounds
. IR \%histogram_boundaries ] . IR \%histogram_boundaries ]
. RB [ \-\-filemap . RB [ \-\-filemap ]
. IR path ]
. RB [ \-\-nogroup ] . RB [ \-\-nogroup ]
. RB [ \-\-precise ] . RB [ \-\-precise ]
. RB [ \-\-start . RB [ \-\-start
@ -299,11 +299,11 @@ results.
. .
.HP .HP
.BR \-\-filemap .BR \-\-filemap
.IR path
.br .br
Instead of creating regions specified by command line options, open Instead of creating regions on a device as specified by command line
the file found at \fBpath\fP, and create regions corresponding to the options, open the file found at each \fBfile_path\fP argument, and
locations of the on-disk extents allocated to the file. create regions corresponding to the locations of the on-disk extents
allocated to the file(s).
. .
.HP .HP
.BR \-\-groupid .BR \-\-groupid
@ -544,13 +544,13 @@ By default dmstats creates regions with a \fBprogram_id\fP of
On success the \fBregion_id\fP of the newly created region is printed On success the \fBregion_id\fP of the newly created region is printed
to stdout. to stdout.
If the \fB\-\-filemap\fP option is given with a regular file as the If the \fB\-\-filemap\fP option is given with a regular file, or list
\fBpath\fP argument, instead of creating regions with parameters of files, as the \fBfile_path\fP argument, instead of creating regions
specified on the command line, \fBdmstats\fP will open the file located with parameters specified on the command line, \fBdmstats\fP will open
at \fBpath\fP and create regions corresponding to the physical extents the files located at \fBfile_path\fP and create regions corresponding to
allocated to the file. This can be used to monitor statistics for the physical extents allocated to the file. This can be used to monitor
individual files in the file system, for example, virtual machine statistics for individual files in the file system, for example, virtual
images, swap areas, or large database files. machine images, swap areas, or large database files.
To work with the \fB\-\-filemap\fP option, files must be located on a To work with the \fB\-\-filemap\fP option, files must be located on a
local file system, backed by a device-mapper device, that supports local file system, backed by a device-mapper device, that supports
@ -1045,13 +1045,21 @@ vg00-lvol1: Created new region with 1 area(s) as region ID 1
.br .br
vg00-lvol1: Created new region with 1 area(s) as region ID 2 vg00-lvol1: Created new region with 1 area(s) as region ID 2
.P .P
Create regions mapping the file vm.img and place them into a group with Create regions mapping each file in the directory images/ and place
the alias set to the same name as the file. them into separate groups, each named after the corresponding file
.br .br
# #
.B dmstats create --filemap vm.img .B dmstats create --filemap images/*
.br .br
vm.img: Created new group with 112 region(s) as group ID 3. images/vm1.qcow2: Created new group with 87 region(s) as group ID 0.
.br
images/vm1-1.qcow2: Created new group with 8 region(s) as group ID 87.
.br
images/vm2.qcow2: Created new group with 11 region(s) as group ID 95.
.br
images/vm2-1.qcow2: Created new group with 1454 region(s) as group ID 106.
.br
images/vm3.img: Created new group with 2 region(s) as group ID 1560.
.P .P
Print raw counters for region 4 on device d0 Print raw counters for region 4 on device d0
.br .br