]>
Commit | Line | Data |
---|---|---|
2bd0ea18 NS |
1 | .TH xfs_bmap 8 |
2 | .SH NAME | |
3 | xfs_bmap \- print block mapping for an XFS file | |
4 | .SH SYNOPSIS | |
753bf054 BN |
5 | .B xfs_bmap |
6 | [ | |
54806785 | 7 | .B \-adelpv |
753bf054 BN |
8 | ] [ |
9 | .B \-n | |
10 | .I num_extents | |
11 | ] | |
12 | .I file | |
eaa6a2bf ES |
13 | .br |
14 | .B xfs_bmap \-V | |
2bd0ea18 | 15 | .SH DESCRIPTION |
753bf054 | 16 | .B xfs_bmap |
2bd0ea18 | 17 | prints the map of disk blocks used by files in an XFS filesystem. |
753bf054 BN |
18 | The map lists each |
19 | .I extent | |
20 | used by the file, as well as regions | |
21 | in the file that do not have any corresponding blocks (holes). | |
2bd0ea18 | 22 | Each line of the listings takes the following form: |
753bf054 BN |
23 | .PP |
24 | .RS | |
25 | .IR extent ": [" startoffset .. endoffset "]: " startblock .. endblock | |
26 | .RE | |
27 | .PP | |
28 | Holes are marked by replacing the | |
29 | .IR startblock .. endblock " with " hole . | |
2bd0ea18 NS |
30 | All the file offsets and disk blocks are in units of 512-byte blocks, |
31 | no matter what the filesystem's block size is. | |
32 | .PP | |
753bf054 BN |
33 | .SH OPTIONS |
34 | .TP | |
35 | .B \-a | |
36 | If this option is specified, information about the file's | |
37 | attribute fork is printed instead of the default data fork. | |
38 | .TP | |
7536ce44 DW |
39 | .B \-c |
40 | If this option is specified, information about the file's | |
41 | copy on write fork is printed instead of the default data fork. | |
42 | .TP | |
753bf054 | 43 | .B \-d |
2bd0ea18 NS |
44 | If portions of the file have been migrated offline by |
45 | a DMAPI application, a DMAPI read event will be generated to | |
46 | bring those portions back online before the disk block map is | |
753bf054 BN |
47 | printed. However if the |
48 | .B \-d | |
49 | option is used, no DMAPI read event will be generated for a | |
50 | DMAPI file and offline portions will be reported as holes. | |
51 | .TP | |
7536ce44 DW |
52 | .B \-e |
53 | If this option is used, | |
54 | .B xfs_bmap | |
55 | obtains all delayed allocation extents, and does not flush dirty pages | |
56 | to disk before querying extent data. With the | |
57 | .B \-v | |
58 | option, the | |
59 | .I flags | |
60 | column will show which extents have not yet been allocated. | |
61 | .TP | |
753bf054 BN |
62 | .B \-l |
63 | If this option is used, then | |
64 | .IP | |
65 | .RS 1.2i | |
66 | .RI < nblocks "> blocks" | |
67 | .RE | |
68 | .IP | |
69 | will be appended to each line. | |
70 | .I nblocks | |
71 | is the length of the extent described on the line in units of 512-byte blocks. | |
72 | .IP | |
73 | This flag has no effect if the | |
74 | .B \-v | |
75 | option is used. | |
76 | .TP | |
77 | .BI \-n " num_extents" | |
78 | If this option is given, | |
79 | .B xfs_bmap | |
fa9f6f13 | 80 | will display at most |
753bf054 BN |
81 | .I num_extents |
82 | extents. In the absence of | |
83 | .BR \-n ", " xfs_bmap | |
fa9f6f13 | 84 | will display all extents in the file. |
753bf054 BN |
85 | .TP |
86 | .B \-p | |
87 | If this option is used, | |
88 | .B xfs_bmap | |
89 | obtains all unwritten (preallocated) extents that do not contain written | |
90 | data. With the | |
91 | .B \-v | |
92 | option, the | |
93 | .I flags | |
94 | column will show which extents are preallocated/unwritten. | |
95 | .TP | |
96 | .B \-v | |
97 | Shows verbose information. When this flag is specified, additional AG | |
98 | specific information is appended to each line in the following form: | |
99 | .IP | |
100 | .RS 1.2i | |
101 | .IR agno " (" startagoffset .. endagoffset ") " nblocks " " flags | |
102 | .RE | |
103 | .IP | |
104 | A second | |
105 | .B \-v | |
106 | option will print out the | |
107 | .I flags | |
108 | legend. | |
eaa6a2bf ES |
109 | .TP |
110 | .B \-V | |
111 | Prints the version number and exits. | |
2bd0ea18 | 112 | .SH SEE ALSO |
753bf054 BN |
113 | .BR xfs_fsr (8), |
114 | .BR xfs (5). |