@photostructure/fs-metadata
    Preparing search index...

    Interface VolumeMetadata

    Metadata associated to a volume.

    interface VolumeMetadata {
        available?: number;
        error?: string | Error;
        fstype?: string;
        isSystemVolume?: boolean;
        label?: string;
        mountFrom?: string;
        mountName?: string;
        mountPoint: string;
        protocol?: string;
        remote: boolean;
        remoteHost?: string;
        remoteShare?: string;
        remoteUser?: string;
        size?: number;
        status?: string;
        uri?: string;
        used?: number;
        uuid?: string;
    }

    Hierarchy (View Summary)

    Index

    Properties

    available?: number

    Available size in bytes

    error?: string | Error

    If there are non-critical errors while extracting metadata, those errors may be added to this field.

    fstype?: string

    The type of file system on the volume, like ext4, apfs, or ntfs.

    Note: on Windows this may show as "ntfs" for remote filesystems, as that is how the filesystem is presented to the OS.

    isSystemVolume?: boolean

    Indicates if this volume is primarily for system use (e.g., swap, snap loopbacks, EFI boot, or only system directories).

    Note: This is a best-effort classification and is not 100% accurate.

    label?: string

    The name of the partition

    mountFrom?: string

    Path to the device or service that the mountpoint is from.

    Examples include /dev/sda1, nfs-server:/export, //username@remoteHost/remoteShare, or //cifs-server/share.

    May be undefined for remote volumes.

    mountName?: string

    The name of the mount. This may match the resolved mountPoint.

    mountPoint: string

    Mount location (like "/" or "C:").

    protocol?: string

    Protocol used to access the share.

    remote: boolean

    Does the protocol seem to be a remote filesystem?

    remoteHost?: string

    If remote, the ip or hostname hosting the share (like "rusty" or "10.1.1.3")

    remoteShare?: string

    If remote, the name of the share (like "homes")

    remoteUser?: string

    If remote, may include the username used to access the share.

    This will be undefined on NFS and other remote filesystem types that do authentication out of band.

    size?: number

    Total size in bytes

    status?: string

    On Windows, returns the health status of the volume.

    Note that this is only available on Windows, as both Linux and macOS are prohibitively expensive, requiring forking fsck -N or diskutil verifyVolume.

    If there are non-critical errors while extracting metadata, those error messages may be added to this field (say, from blkid or gio).

    VolumeHealthStatuses for values returned by Windows.

    uri?: string

    We can sometimes fetch a URI of the resource (like "smb://server/share" or "file:///media/user/usb")

    used?: number

    Used size in bytes

    uuid?: string

    UUID for the volume, like "c9b08f6e-b392-11ef-bf19-4b13bb7db4b4".

    On windows, this may be the 128-bit volume UUID, but if that is not available, like in the case of remote volumes, we fallback to the 32-bit volume serial number, rendered in lowercase hexadecimal.