All Products
Search
Document Center

Object Storage Service:Export a metadata inventory

Last Updated:Mar 20, 2026

Export a snapshot of all file and directory metadata from an OSS-HDFS-enabled bucket to a JSON file. Use the inventory for:

  • Storage auditing: Review file ownership, permissions, and storage policies across your data lake after a migration.

  • Cost analysis: Identify large or stale files and analyze storage policy distribution to reduce unnecessary costs.

  • Pipeline acceleration: Replace slow, synchronous List API calls with a pre-generated inventory file in batch processing jobs.

Prerequisites

Before you begin, make sure you have:

Export the inventory

  1. Log on to the OSS console.

  2. In the left-side navigation pane, click Buckets. On the Buckets page, find and click the desired bucket.

  3. In the left-side navigation pane, choose Data Lake > OSS-HDFS.

  4. In the Object Metadata section, click Export.

    Depending on the volume of metadata, the export can take several minutes to several hours. The inventory file is saved to:

       oss://<hdfs_bucket>.<dls_endpoint>/.sysinfo/inventory/<unix_ms_timestamp>.<uuid>

    For example:

       oss://<hdfs_bucket>.<dls_endpoint>/.sysinfo/inventory/1666584461201.2ce40fba-5704-45c4-8720-d92a891d****

    The filename consists of a Unix millisecond timestamp and a UUID, separated by a dot. Custom output paths are not supported.

    Important

    The .sysinfo/inventory/ directory cannot be deleted. Individual inventory files within the directory can be accessed and deleted.

Download and view the inventory file

  1. Download the inventory file using the Jindo CLI:

       jindo fs -get oss://<hdfs_bucket>.<dls_endpoint>/.sysinfo/inventory/1666584461201.2ce40fba-5704-45c4-8720-d92a891d**** /tmp/
  2. Open the file with vi or vim. The following is a sample record:

       {
         "id": 6289437267661375236,
         "path": "/user/spark/.sparkStaging/application_1767273535967_0001/__spark_libs__5660687526220176997.zip",
         "type": "file",
         "size": 315253339,
         "user": "spark",
         "group": "supergroup",
         "ctime": 1767273541200,
         "atime": 1767273541321,
         "mtime": 1767273541897,
         "storagePolicy": "UNSPECIFIED",
         "permission": 420,
         "state": 0,
         "storageState": "STD"
       }

Field reference

The following fields are always present in every inventory record:

FieldDescription
idThe ID of the file or directory.
pathThe path of the file or directory.
typeThe entry type: file or directory.
sizeThe size in bytes. For directories, the value is 0.
userThe owner of the file or directory.
groupThe user group of the file or directory.
ctimeThe time when the file or directory was created. The value is a UNIX timestamp.
atimeThe time when the file or directory was last accessed. The value is a UNIX timestamp.
mtimeThe time when the file or directory was last modified. The value is a UNIX timestamp.
permissionThe permissions on the file or directory.
storagePolicyThe storage policy applied to the file or directory. See Storage policy values.

The following fields are reserved and not enabled in the current version:

FieldDescription
stateThe actual tiering state of the file or directory.
storageStateThe progress of the current tiering operation.

Storage policy values

ValueStorage class
UNSPECIFIEDDefault (equivalent to Standard)
CLOUD_STDStandard
CLOUD_IAInfrequent Access
CLOUD_ARArchive
CLOUD_COLD_ARCold Archive
CLOUD_DEEP_COLD_ARDeep Cold Archive
CLOUD_AR_RESTOREDArchive restored
CLOUD_COLD_AR_RESTOREDCold Archive restored
CLOUD_DEEP_COLD_AR_RESTOREDDeep Cold Archive restored

Delete the inventory file

The inventory file consumes storage space and incurs storage fees. After you finish using it, delete the file with the Jindo CLI:

jindo fs -rm -skipTrash oss://<hdfs_bucket>.<dls_endpoint>/.sysinfo/inventory/1666584461201.2ce40fba-5704-45c4-8720-d92a891d****
Important

Make sure the file path in the command matches the Data Location path that is generated during export. This prevents accidental deletion of system data under .dlsdata and .sysinfo.