DEBUGVMFS6(8) | vmfs-tools | DEBUGVMFS6(8) |
debugvmfs6 - VMFS file system debugger
debugvmfs6 VOLUME... COMMAND [ OPTIONS ] debugvmfs6 -b BITMAP show [ VARIABLE ]
The debugvmfs6 program allows to display various informations about VMFS6 file systems, and to access data within the file systems.
The VOLUME to be opened can be either a block device or an image file. When the VMFS spreads accross several extents, all extents must be given.
Please note that most commands are still likely to change in future versions.
When given the -b option, a BITMAP file may directly be opened from the host file system. In this mode, only the show command is supported, and the variables available are only a subset.
Some commands take a filespec as an argument. A filespec may take either of the following forms:
cat filespec [ ... ]
ls [ -l ] filespec
With -l, gives some more information, much like the output from ls(1) when given the -l option.
truncate filespec length
chmod filespec mode
df
get_file_block filespec position
check_vol_bitmaps
show_heartbeats
read_block block_id [ ... ]
get_block_status block_id
alloc_block_fixed block_id
alloc_block block_type
Allowed block types are: 1 (File Block), 2 (Sub-Block), 3 (Pointer Block) and 4 (File Descriptor / Inode).
free_block block_id
Warning: can cause damage since no heartbeat is used at this time and a block used by a file can be freed.
show
shell
The current working directory can be changed with the cd command, followed by a filespec.
The following output redirections are supported within the shell:
Puts the output of cmd in the output file.
Appends the output of cmd to the output file.
Sends the output of cmd to the input of external command. The external command itself can contain output redirection.
Examples:
Variables in debugvmfs6 represent structures on the filesystem. The currently supported top-level variables are the following:
The vol_version, version, label, mode, uuid, ctime, block_size, subblock_size, fdc_header_size, and fdc_bitmap_count properties are low-level information about the filesystem.
The fbb, fdc, pbc and sbc variables are bitmaps. Running them through the show command will display all the bitmaps header fields. Each of these fields can also be displayed individually:
e.g. to display the data size of the fdc bitmap, type show fdc.data_size.
Each bitmap.entry[n] (where 0 ≤ n < bitmap.bmp_entries_per_area * bitmap.area_count) contains information about each entry in the bitmap. The available fields are:
The bitmap.entry[n].mdh is a metadata header. See further below for more details about metadata headers.
Each bitmap.entry[n].item[m] (where 0 ≤ m < bitmap.items_per_bitmap_entry) contains information about a given item in the given entry. The available fields are:
The pbc bitmap has an additional field:
The lvm variable contains low-level information about the physical and logical volumes. The available fields are:
Each lvm.extent[n] (where 0 ≤ n < lvm.num_extents) contains low-level information about the physical volumes. The available fields are:
Each blkid[blk] (where blk is a block id) contains information on the given block id. The available fields are:
Each dirent[path] (where path is a path relative to the current directory in the shell or / outside the shell) contains information on the directory entry corresponding to the given path. The available fields are:
Each inode[filespec] contains information on the inode corresponding to the given filespec. The available fields are:
Metadata headers are being used in several places, such as bitmap.entry[n].mdh and inode["filespec"].mdh. They mostly contain information about clustered accesses to metadata on the filesystem. The available fields are:
Variable values can also be used in expressions using square brackets to use the variable value as an index. For example:
Enclosing a variable name with parentheses will use that variable value as a variable name. For example:
When invoked with the -b option, the top-level variables are those normally under bitmap:
The sub-variables for each entry are also available.
Christophe Fillot <cf@utc.fr[1]>, Mike Hommey <mh@glandium.org[2]> Weafon Tsao <weafon.tsao@accelstor.com[3]> Thomas Ward <teward@ubuntu.com[4]>
12/29/2019 | 0.0.0-patched |