Deep Inspection

In some circumstances it can be helpful to cross-references files and directories in BeeGFS with the corresponding data structures in the underlying file systems of the metadata and storage targets.

Warning

Modifying the content of files and extended attributes, deleting, or otherwise changing the directory structure of the metadata or storage servers is likely to cause irreversible data loss!

Find storage chunks belonging to a file

This can be achieved by querying the file with beegfs entry info --verbose --retro. The command will print out (among other information) a list of storage targets the file is striped across as well as the relative path to its chunk files (which is the same on all targets).

Example:

$ beegfs entry info --verbose --retro /mnt/beegfs/file
Entry type: file
EntryID: 1-6705972F-1
Stripe pattern details:
+ Type: RAID0
+ Chunksize: 512K
+ Number of storage targets: desired: 2; actual: 2
+ Storage targets:
+ 101 @ node_storage_1 [ID: 1]
+ 201 @ node_storage_2 [ID: 2]
Chunk path: u0/0/r/root/1-6705972F-1
Inlined inode: yes
Dentry info:
+ Path: 38/51/root
+ Metadata node: node_meta_1 [ID: 1]
Client Sessions
+ Reading: 0
+ Writing: 0

In this example, the chunk files belonging to /mnt/beegfs/file are striped across the targets 101 and 201 which are located on storage node 1 and 2. Assuming the target data directories are put under /beegfs/storage on each node, the chunk files are located at /beegfs/storage/chunks/u0/0/r/root/1-6705972F-1.

Find the metadata file of file or directory

This can be achieved by querying the file or directory with beegfs entry info --verbose --retro. The command will print out (among other information) the metadata node where the files metadata is located as well as the relative path to the directory where its inode is stored.

Note

Unless a file has multiple hard links, its inode is inlined within the file’s dentry so you will only see a path to the dentry in the entry info output (see example above). For files with multiple hard links you will see Inlined inode: no and Inode Info will be included in the entry info.

Normally inodes are found under inodes/ and dentries under dentries/. If the metadata for the file or directory is mirrored, these are at buddymir/inodes and buddymir/dentries instead.

Example: Query a directory

$ beegfs entry info --verbose --retro /mnt/beegfs/dir
Entry type: directory
EntryID: 0-67059D13-1
ParentID: root
Stripe pattern details:
+ Type: RAID0
+ Chunksize: 512K
+ Number of storage targets: desired: 4
+ Storage Pool: 1  (storage_pool_default)
Inlined inode: no
Dentry info:
+ Path: 38/51/root
+ Metadata node: node_meta_1 [ID: 1]
Inode info:
+ Path: 25/56/0-67059D13-1
+ Metadata node: node_meta_1 [ID: 1]

In this example, the directory inode is located on metadata node 1. Assuming the metadata directory is put under /beegfs/meta, the inode file is located at /beegfs/meta/inodes/25/56/0-67059D13-1.