Skip to main content

resolve_stratis_target

Function resolve_stratis_target 

Source
pub async fn resolve_stratis_target(
    conn: &Connection,
    path_or_devnode: &str,
) -> Result<StratisPoolInfo, StratisError>
Expand description

Resolve a mount path or devnode to its Stratis pool and filesystem via D-Bus.

Accepts either a devnode path (e.g., /dev/stratis/pool/fs) or a mount path (e.g., /mnt/target-stratis). For mount paths, resolves the backing device via /proc/self/mountinfo first.

Returns error if stratisd is not running or the path is not on Stratis.