Lines Matching refs:dataset
231 * dataset.
234 get_legacy_mountpoint(char *path, char *dataset, size_t dlen,
255 (void) strlcpy(dataset, entry.mnt_special,
267 * get the name of the ZFS dataset the path is equivalent to. The
268 * dataset name is used for get/set of ZFS properties since libzfs
269 * requires a dataset to do a zfs_open().
277 char *dataset = NULL;
295 * Search mmttab for mountpoint and get dataset.
301 dataset = mountpoint;
319 dataset = (char *)zfs_get_name(zlist[i]);
325 if (dataset != NULL)
326 dataset = strdup(dataset);
328 return (dataset);
332 * get_zfs_property(dataset, property)
334 * Get the file system property specified from the ZFS dataset.
338 get_zfs_property(char *dataset, zfs_prop_t property)
346 handle = zfs_open(libhandle, dataset, ZFS_TYPE_FILESYSTEM);
373 char *dataset;
378 dataset = get_zfs_dataset((sa_handle_t)sahandle, path, B_FALSE);
379 if (dataset != NULL) {
382 handle = zfs_open(libhandle, dataset,
395 free(dataset);
519 * zfs_construct_resource(share, name, base, dataset)
522 * NULL, then construct a name based on the dataset value.
526 zfs_construct_resource(sa_share_t share, char *dataset)
531 (void) snprintf(buff, SA_MAX_RESOURCE_NAME, "%s", dataset);
544 char *shareopts, char *mountpoint, char *proto, char *dataset)
579 set_node_attr(share, "dataset", dataset);
582 set_node_attr(share, "dataset", NULL);
598 zfs_construct_resource(share, dataset);
608 * zfs_notinherited(group, share, mountpoint, shareopts, proto, dataset,
618 char *shareopts, char *proto, char *dataset, int grouperr)
663 zfs_construct_resource(share, dataset);
697 char *sourcestr, char *dataset)
703 mountpoint, proto, dataset);
705 group = find_or_create_zfs_subgroup(handle, dataset, proto,
722 proto, dataset, err);
783 char *dataset;
796 if ((dataset = (char *)zfs_get_name(zlist[i])) == NULL)
863 nfssourcestr, dataset);
870 smbsourcestr, dataset);
895 grpdataset, dataset);
902 grpdataset, dataset);
933 char *dataset = NULL;
948 dataset = get_zfs_dataset(impl_handle, path, B_FALSE);
952 if (dataset != NULL) {
955 opts != NULL ? opts : "off", dataset);
965 if (dataset != NULL)
966 free(dataset);
1044 char *dataset = NULL;
1065 dataset = get_zfs_dataset(impl_handle, path, B_FALSE);
1069 if (dataset != NULL) {
1072 opts != NULL ? opts : "off", dataset);
1082 if (dataset != NULL)
1083 free(dataset);
1122 char *dataset = NULL;
1134 dataset = get_zfs_dataset(
1142 dataset = sa_get_group_attr(group, "name");
1146 if (proto != NULL && dataset != NULL) {
1149 zfsopts = get_zfs_property(dataset,
1163 optstring, dataset);
1169 dataset);
1193 if (dataset != NULL)
1194 free(dataset);
1270 char *dataset;
1277 * First find the dataset name
1291 while ((dataset = get_zfs_dataset(sahandle, pathp, B_TRUE)) == NULL) {
1350 err = zfs_deleg_share_nfs(libhandle, dataset, path,
1361 free(dataset);
1382 * sa_get_zfs_info(libzfs, path, mountpoint, dataset)
1384 * Find the ZFS dataset and mountpoint for a given path
1393 char dataset[ZFS_MAXPROPLEN];
1424 if (get_legacy_mountpoint(path, dataset,
1545 char *dataset, *lastcomma;
1553 if ((dataset = get_zfs_dataset(handle, path, B_FALSE)) == NULL)
1557 free(dataset);
1561 z_fs = zfs_open(z_lib, dataset, ZFS_TYPE_DATASET);
1563 free(dataset);
1570 free(dataset);
1577 free(dataset);
1589 free(dataset);