Updated on 2024-11-29 GMT+08:00

SHOW_FS_PATH_DETAIL

Function

This command is used to view statistics about a specified FS path.

Syntax

call show_fs_path_detail(path=>'[path]', is_sub=>'[is_sub]', sort=>'[sort]');

Parameter Description

Table 1 Parameters

Parameter

Description

Mandatory

path

Path of the FS to be queried

Yes

is_sub

The default value is false, indicating that statistics about a specified directory is collected. The value true indicates that statistics about subdirectories in a specified directory is collected.

No

sort

The default value is true, indicating that the results are sorted based on storage_size. The value false indicates that the results are sorted based on the number of files.

No

Example

call show_commit_files(path=>'/user/hive/warehouse/hudi_mor/dt=2021-08-28');
call show_fs_path_detail(path=>'/user/hive/warehouse/hudi_mor/dt=2021-08-28', is_sub=>false, sort=>true);

Returned Result

Parameter

Description

path_num

Number of subdirectories in a specified directory

file_num

Number of files in a specified directory

storage_size

Size of the directory, in bytes

storage_size(unit)

Size of the directory, in KB

storage_path

Complete FS absolute path of the specified directory

space_consumed

Actual space occupied by the returned files/directories in the cluster, that is, the replication factor set for the cluster is considered.

quota

Name quota, which is a mandatory restriction on the number of files and directory names in the current directory tree

space_quota

Space quota, which is a mandatory restriction on the number of bytes used by files in the current directory tree

System Response

You can view query results on the client.