char * do_ldmtool_diskgroup_name (const char *diskgroup) { int r; CLEANUP_FREE char *out = NULL, *err = NULL; r = command (&out, &err, "ldmtool", "show", "diskgroup", diskgroup, NULL); if (r == -1) { reply_with_error ("%s", err); return NULL; } return parse_json_get_object_string (out, "name", 0, __func__, "ldmtool show diskgroup"); }
char * do_ldmtool_volume_hint (const char *diskgroup, const char *volume) { int r; CLEANUP_FREE char *out = NULL, *err = NULL; r = command (&out, &err, "ldmtool", "show", "volume", diskgroup, volume, NULL); if (r == -1) { reply_with_error ("%s", err); return NULL; } return parse_json_get_object_string (out, "hint", GET_STRING_NULL_TO_EMPTY, __func__, "ldmtool show volume"); }
char * do_ldmtool_volume_type (const char *diskgroup, const char *volume) { int r; CLEANUP_FREE char *out = NULL, *err = NULL; r = command (&out, &err, str_ldmtool, "show", "volume", diskgroup, volume, NULL); if (r == -1) { reply_with_error ("%s", err); return NULL; } return parse_json_get_object_string (out, "type", 0, __func__, "ldmtool show volume"); }