summaryrefslogtreecommitdiffstats
path: root/cmd
diff options
context:
space:
mode:
Diffstat (limited to 'cmd')
-rwxr-xr-xcmd/arc_summary/arc_summary.py102
-rwxr-xr-xcmd/arcstat/arcstat.py9
-rwxr-xr-xcmd/dbufstat/dbufstat.py2
-rw-r--r--cmd/zdb/zdb.c4
-rw-r--r--cmd/zfs/zfs_main.c87
5 files changed, 131 insertions, 73 deletions
diff --git a/cmd/arc_summary/arc_summary.py b/cmd/arc_summary/arc_summary.py
index 9f6d8c119..e7448fa5d 100755
--- a/cmd/arc_summary/arc_summary.py
+++ b/cmd/arc_summary/arc_summary.py
@@ -66,32 +66,17 @@ def get_Kstat():
name, unused, value = kstat.split()
Kstat[namespace + name] = D(value)
- Kstats = [
- "hw.pagesize",
- "hw.physmem",
- "kern.maxusers",
- "vm.kmem_map_free",
- "vm.kmem_map_size",
- "vm.kmem_size",
- "vm.kmem_size_max",
- "vm.kmem_size_min",
- "vm.kmem_size_scale",
- "vm.stats",
- "vm.swap_total",
- "vm.swap_reserved",
- "kstat.zfs",
- "vfs.zfs"
- ]
Kstat = {}
load_proc_kstats('/proc/spl/kstat/zfs/arcstats',
- 'kstat.zfs.misc.arcstats.')
+ 'kstat.zfs.misc.arcstats.')
load_proc_kstats('/proc/spl/kstat/zfs/zfetchstats',
- 'kstat.zfs.misc.zfetchstats.')
+ 'kstat.zfs.misc.zfetchstats.')
load_proc_kstats('/proc/spl/kstat/zfs/vdev_cache_stats',
- 'kstat.zfs.misc.vdev_cache_stats.')
+ 'kstat.zfs.misc.vdev_cache_stats.')
return Kstat
+
def div1():
sys.stdout.write("\n")
for i in range(18):
@@ -188,17 +173,17 @@ def get_arc_summary(Kstat):
output['memory_throttle_count'] = fHits(memory_throttle_count)
- ### ARC Misc. ###
+ # ARC Misc.
deleted = Kstat["kstat.zfs.misc.arcstats.deleted"]
mutex_miss = Kstat["kstat.zfs.misc.arcstats.mutex_miss"]
- ### ARC Misc. ###
+ # ARC Misc.
output["arc_misc"] = {}
output["arc_misc"]["deleted"] = fHits(deleted)
output["arc_misc"]['mutex_miss'] = fHits(mutex_miss)
output["arc_misc"]['evict_skips'] = fHits(mutex_miss)
- ### ARC Sizing ###
+ # ARC Sizing
arc_size = Kstat["kstat.zfs.misc.arcstats.size"]
mru_size = Kstat["kstat.zfs.misc.arcstats.p"]
target_max_size = Kstat["kstat.zfs.misc.arcstats.c_max"]
@@ -207,7 +192,7 @@ def get_arc_summary(Kstat):
target_size_ratio = (target_max_size / target_min_size)
- ### ARC Sizing ###
+ # ARC Sizing
output['arc_sizing'] = {}
output['arc_sizing']['arc_size'] = {
'per': fPerc(arc_size, target_max_size),
@@ -226,7 +211,7 @@ def get_arc_summary(Kstat):
'num': fBytes(target_size),
}
- ### ARC Hash Breakdown ###
+ # ARC Hash Breakdown
output['arc_hash_break'] = {}
output['arc_hash_break']['hash_chain_max'] = Kstat[
"kstat.zfs.misc.arcstats.hash_chain_max"
@@ -267,7 +252,7 @@ def get_arc_summary(Kstat):
'num': fBytes(mfu_size),
}
- ### ARC Hash Breakdown ###
+ # ARC Hash Breakdown
hash_chain_max = Kstat["kstat.zfs.misc.arcstats.hash_chain_max"]
hash_chains = Kstat["kstat.zfs.misc.arcstats.hash_chains"]
hash_collisions = Kstat["kstat.zfs.misc.arcstats.hash_collisions"]
@@ -288,25 +273,25 @@ def get_arc_summary(Kstat):
def _arc_summary(Kstat):
- ### ARC Sizing ###
+ # ARC Sizing
arc = get_arc_summary(Kstat)
sys.stdout.write("ARC Summary: (%s)\n" % arc['health'])
sys.stdout.write("\tMemory Throttle Count:\t\t\t%s\n" %
- arc['memory_throttle_count'])
+ arc['memory_throttle_count'])
sys.stdout.write("\n")
- ### ARC Misc. ###
+ # ARC Misc.
sys.stdout.write("ARC Misc:\n")
sys.stdout.write("\tDeleted:\t\t\t\t%s\n" % arc['arc_misc']['deleted'])
sys.stdout.write("\tMutex Misses:\t\t\t\t%s\n" %
- arc['arc_misc']['mutex_miss'])
+ arc['arc_misc']['mutex_miss'])
sys.stdout.write("\tEvict Skips:\t\t\t\t%s\n" %
- arc['arc_misc']['mutex_miss'])
+ arc['arc_misc']['mutex_miss'])
sys.stdout.write("\n")
- ### ARC Sizing ###
+ # ARC Sizing
sys.stdout.write("ARC Size:\t\t\t\t%s\t%s\n" % (
arc['arc_sizing']['arc_size']['per'],
arc['arc_sizing']['arc_size']['num']
@@ -344,21 +329,21 @@ def _arc_summary(Kstat):
sys.stdout.write("\n")
- ### ARC Hash Breakdown ###
+ # ARC Hash Breakdown
sys.stdout.write("ARC Hash Breakdown:\n")
sys.stdout.write("\tElements Max:\t\t\t\t%s\n" %
- arc['arc_hash_break']['elements_max'])
+ arc['arc_hash_break']['elements_max'])
sys.stdout.write("\tElements Current:\t\t%s\t%s\n" % (
arc['arc_hash_break']['elements_current']['per'],
arc['arc_hash_break']['elements_current']['num'],
)
)
sys.stdout.write("\tCollisions:\t\t\t\t%s\n" %
- arc['arc_hash_break']['collisions'])
+ arc['arc_hash_break']['collisions'])
sys.stdout.write("\tChain Max:\t\t\t\t%s\n" %
- arc['arc_hash_break']['chain_max'])
+ arc['arc_hash_break']['chain_max'])
sys.stdout.write("\tChains:\t\t\t\t\t%s\n" %
- arc['arc_hash_break']['chains'])
+ arc['arc_hash_break']['chains'])
def get_arc_efficiency(Kstat):
@@ -488,7 +473,7 @@ def _arc_efficiency(Kstat):
arc = get_arc_efficiency(Kstat)
sys.stdout.write("ARC Total accesses:\t\t\t\t\t%s\n" %
- arc['total_accesses'])
+ arc['total_accesses'])
sys.stdout.write("\tCache Hit Ratio:\t\t%s\t%s\n" % (
arc['cache_hit_ratio']['per'],
arc['cache_hit_ratio']['num'],
@@ -699,7 +684,7 @@ def _l2arc_summary(Kstat):
else:
sys.stdout.write("(HEALTHY)\n")
sys.stdout.write("\tLow Memory Aborts:\t\t\t%s\n" %
- arc['low_memory_aborts'])
+ arc['low_memory_aborts'])
sys.stdout.write("\tFree on Write:\t\t\t\t%s\n" % arc['free_on_write'])
sys.stdout.write("\tR/W Clashes:\t\t\t\t%s\n" % arc['rw_clashes'])
sys.stdout.write("\tBad Checksums:\t\t\t\t%s\n" % arc['bad_checksums'])
@@ -707,7 +692,7 @@ def _l2arc_summary(Kstat):
sys.stdout.write("\n")
sys.stdout.write("L2 ARC Size: (Adaptive)\t\t\t\t%s\n" %
- arc["l2_arc_size"]["adative"])
+ arc["l2_arc_size"]["adative"])
sys.stdout.write("\tCompressed:\t\t\t%s\t%s\n" % (
arc["l2_arc_size"]["actual"]["per"],
arc["l2_arc_size"]["actual"]["num"],
@@ -724,13 +709,13 @@ def _l2arc_summary(Kstat):
arc["l2_arc_evicts"]["reading"] > 0:
sys.stdout.write("L2 ARC Evicts:\n")
sys.stdout.write("\tLock Retries:\t\t\t\t%s\n" %
- arc["l2_arc_evicts"]['lock_retries'])
+ arc["l2_arc_evicts"]['lock_retries'])
sys.stdout.write("\tUpon Reading:\t\t\t\t%s\n" %
- arc["l2_arc_evicts"]["reading"])
+ arc["l2_arc_evicts"]["reading"])
sys.stdout.write("\n")
sys.stdout.write("L2 ARC Breakdown:\t\t\t\t%s\n" %
- arc['l2_arc_breakdown']['value'])
+ arc['l2_arc_breakdown']['value'])
sys.stdout.write("\tHit Ratio:\t\t\t%s\t%s\n" % (
arc['l2_arc_breakdown']['hit_ratio']['per'],
arc['l2_arc_breakdown']['hit_ratio']['num'],
@@ -744,7 +729,7 @@ def _l2arc_summary(Kstat):
)
sys.stdout.write("\tFeeds:\t\t\t\t\t%s\n" %
- arc['l2_arc_breakdown']['feeds'])
+ arc['l2_arc_breakdown']['feeds'])
sys.stdout.write("\n")
sys.stdout.write("L2 ARC Writes:\n")
@@ -803,7 +788,7 @@ def _dmu_summary(Kstat):
if arc['zfetch_access_total'] > 0:
sys.stdout.write("DMU Prefetch Efficiency:\t\t\t\t\t%s\n" %
- arc['dmu']['efficiency']['value'])
+ arc['dmu']['efficiency']['value'])
sys.stdout.write("\tHit Ratio:\t\t\t%s\t%s\n" % (
arc['dmu']['efficiency']['hit_ratio']['per'],
arc['dmu']['efficiency']['hit_ratio']['num'],
@@ -822,11 +807,11 @@ def get_vdev_summary(Kstat):
output = {}
vdev_cache_delegations = \
- Kstat["kstat.zfs.misc.vdev_cache_stats.delegations"]
+ Kstat["kstat.zfs.misc.vdev_cache_stats.delegations"]
vdev_cache_misses = Kstat["kstat.zfs.misc.vdev_cache_stats.misses"]
vdev_cache_hits = Kstat["kstat.zfs.misc.vdev_cache_stats.hits"]
vdev_cache_total = (vdev_cache_misses + vdev_cache_hits +
- vdev_cache_delegations)
+ vdev_cache_delegations)
output['vdev_cache_total'] = vdev_cache_total
@@ -875,7 +860,8 @@ def _tunable_summary(Kstat):
values = {}
for name in names:
- with open("/sys/module/zfs/parameters/" + name) as f: value = f.read()
+ with open("/sys/module/zfs/parameters/" + name) as f:
+ value = f.read()
values[name] = value.strip()
descriptions = {}
@@ -884,7 +870,7 @@ def _tunable_summary(Kstat):
try:
command = ["/sbin/modinfo", "zfs", "-0"]
p = Popen(command, stdin=PIPE, stdout=PIPE,
- stderr=PIPE, shell=False, close_fds=True)
+ stderr=PIPE, shell=False, close_fds=True)
p.wait()
description_list = p.communicate()[0].strip().split('\0')
@@ -899,11 +885,11 @@ def _tunable_summary(Kstat):
descriptions[name] = description
else:
sys.stderr.write("%s: '%s' exited with code %i\n" %
- (sys.argv[0], command[0], p.returncode))
+ (sys.argv[0], command[0], p.returncode))
sys.stderr.write("Tunable descriptions will be disabled.\n")
except OSError as e:
sys.stderr.write("%s: Cannot run '%s': %s\n" %
- (sys.argv[0], command[0], e.strerror))
+ (sys.argv[0], command[0], e.strerror))
sys.stderr.write("Tunable descriptions will be disabled.\n")
sys.stdout.write("ZFS Tunable:\n")
@@ -942,21 +928,23 @@ def zfs_header():
def usage():
sys.stdout.write("Usage: arc_summary.py [-h] [-a] [-d] [-p PAGE]\n\n")
sys.stdout.write("\t -h, --help : "
- "Print this help message and exit\n")
+ "Print this help message and exit\n")
sys.stdout.write("\t -a, --alternate : "
- "Show an alternate sysctl layout\n")
+ "Show an alternate sysctl layout\n")
sys.stdout.write("\t -d, --description : "
- "Show the sysctl descriptions\n")
+ "Show the sysctl descriptions\n")
sys.stdout.write("\t -p PAGE, --page=PAGE : "
- "Select a single output page to display,\n")
+ "Select a single output page to display,\n")
sys.stdout.write("\t "
- "should be an integer between 1 and " + str(len(unSub)) + "\n\n")
+ "should be an integer between 1 and " +
+ str(len(unSub)) + "\n\n")
sys.stdout.write("Examples:\n")
sys.stdout.write("\tarc_summary.py -a\n")
sys.stdout.write("\tarc_summary.py -p 4\n")
sys.stdout.write("\tarc_summary.py -ad\n")
sys.stdout.write("\tarc_summary.py --page=2\n")
+
def main():
global show_tunable_descriptions
global alternate_tunable_layout
@@ -987,9 +975,9 @@ def main():
if 'p' in args:
try:
pages.append(unSub[int(args['p']) - 1])
- except IndexError as e:
+ except IndexError:
sys.stderr.write('the argument to -p must be between 1 and ' +
- str(len(unSub)) + '\n')
+ str(len(unSub)) + '\n')
sys.exit()
else:
pages = unSub
diff --git a/cmd/arcstat/arcstat.py b/cmd/arcstat/arcstat.py
index 8bd0d511d..b743fd8bc 100755
--- a/cmd/arcstat/arcstat.py
+++ b/cmd/arcstat/arcstat.py
@@ -122,7 +122,7 @@ def detailed_usage():
sys.stderr.write("%11s : %s\n" % (key, cols[key][2]))
sys.stderr.write("\n")
- sys.exit(1)
+ sys.exit(0)
def usage():
@@ -229,15 +229,19 @@ def print_header():
sys.stdout.write("%*s%s" % (cols[col][0], col, sep))
sys.stdout.write("\n")
+
def get_terminal_lines():
try:
- import fcntl, termios, struct
+ import fcntl
+ import termios
+ import struct
data = fcntl.ioctl(sys.stdout.fileno(), termios.TIOCGWINSZ, '1234')
sz = struct.unpack('hh', data)
return sz[0]
except:
pass
+
def update_hdr_intr():
global hdr_intr
@@ -245,6 +249,7 @@ def update_hdr_intr():
if lines and lines > 3:
hdr_intr = lines - 3
+
def resize_handler(signum, frame):
update_hdr_intr()
diff --git a/cmd/dbufstat/dbufstat.py b/cmd/dbufstat/dbufstat.py
index 0bda1524e..ceb0160cd 100755
--- a/cmd/dbufstat/dbufstat.py
+++ b/cmd/dbufstat/dbufstat.py
@@ -143,7 +143,7 @@ def detailed_usage():
sys.stderr.write("%11s : %s\n" % (key, cols[key][2]))
sys.stderr.write("\n")
- sys.exit(1)
+ sys.exit(0)
def usage():
diff --git a/cmd/zdb/zdb.c b/cmd/zdb/zdb.c
index 611e92294..7a0f55f75 100644
--- a/cmd/zdb/zdb.c
+++ b/cmd/zdb/zdb.c
@@ -1946,11 +1946,13 @@ dump_object(objset_t *os, uint64_t object, int verbosity, int *print_header)
}
if (verbosity >= 4) {
- (void) printf("\tdnode flags: %s%s%s\n",
+ (void) printf("\tdnode flags: %s%s%s%s\n",
(dn->dn_phys->dn_flags & DNODE_FLAG_USED_BYTES) ?
"USED_BYTES " : "",
(dn->dn_phys->dn_flags & DNODE_FLAG_USERUSED_ACCOUNTED) ?
"USERUSED_ACCOUNTED " : "",
+ (dn->dn_phys->dn_flags & DNODE_FLAG_USEROBJUSED_ACCOUNTED) ?
+ "USEROBJUSED_ACCOUNTED " : "",
(dn->dn_phys->dn_flags & DNODE_FLAG_SPILL_BLKPTR) ?
"SPILL_BLKPTR" : "");
(void) printf("\tdnode maxblkid: %llu\n",
diff --git a/cmd/zfs/zfs_main.c b/cmd/zfs/zfs_main.c
index fedc1a04d..8a49e31e5 100644
--- a/cmd/zfs/zfs_main.c
+++ b/cmd/zfs/zfs_main.c
@@ -2223,10 +2223,14 @@ enum us_field_types {
USFIELD_TYPE,
USFIELD_NAME,
USFIELD_USED,
- USFIELD_QUOTA
+ USFIELD_QUOTA,
+ USFIELD_OBJUSED,
+ USFIELD_OBJQUOTA
};
-static char *us_field_hdr[] = { "TYPE", "NAME", "USED", "QUOTA" };
-static char *us_field_names[] = { "type", "name", "used", "quota" };
+static char *us_field_hdr[] = { "TYPE", "NAME", "USED", "QUOTA",
+ "OBJUSED", "OBJQUOTA" };
+static char *us_field_names[] = { "type", "name", "used", "quota",
+ "objused", "objquota" };
#define USFIELD_LAST (sizeof (us_field_names) / sizeof (char *))
#define USTYPE_PSX_GRP (1 << 0)
@@ -2374,6 +2378,20 @@ compare_nums:
return (0);
}
+static boolean_t
+zfs_prop_is_user(unsigned p)
+{
+ return (p == ZFS_PROP_USERUSED || p == ZFS_PROP_USERQUOTA ||
+ p == ZFS_PROP_USEROBJUSED || p == ZFS_PROP_USEROBJQUOTA);
+}
+
+static boolean_t
+zfs_prop_is_group(unsigned p)
+{
+ return (p == ZFS_PROP_GROUPUSED || p == ZFS_PROP_GROUPQUOTA ||
+ p == ZFS_PROP_GROUPOBJUSED || p == ZFS_PROP_GROUPOBJQUOTA);
+}
+
static inline const char *
us_type2str(unsigned field_type)
{
@@ -2463,7 +2481,7 @@ userspace_cb(void *arg, const char *domain, uid_t rid, uint64_t space)
if (cb->cb_sid2posix || domain == NULL || domain[0] == '\0') {
/* POSIX or -i */
- if (prop == ZFS_PROP_GROUPUSED || prop == ZFS_PROP_GROUPQUOTA) {
+ if (zfs_prop_is_group(prop)) {
type = USTYPE_PSX_GRP;
if (!cb->cb_numname) {
struct group *g;
@@ -2538,10 +2556,22 @@ userspace_cb(void *arg, const char *domain, uid_t rid, uint64_t space)
propname = "used";
if (!nvlist_exists(props, "quota"))
(void) nvlist_add_uint64(props, "quota", 0);
- } else {
+ } else if (prop == ZFS_PROP_USERQUOTA || prop == ZFS_PROP_GROUPQUOTA) {
propname = "quota";
if (!nvlist_exists(props, "used"))
(void) nvlist_add_uint64(props, "used", 0);
+ } else if (prop == ZFS_PROP_USEROBJUSED ||
+ prop == ZFS_PROP_GROUPOBJUSED) {
+ propname = "objused";
+ if (!nvlist_exists(props, "objquota"))
+ (void) nvlist_add_uint64(props, "objquota", 0);
+ } else if (prop == ZFS_PROP_USEROBJQUOTA ||
+ prop == ZFS_PROP_GROUPOBJQUOTA) {
+ propname = "objquota";
+ if (!nvlist_exists(props, "objused"))
+ (void) nvlist_add_uint64(props, "objused", 0);
+ } else {
+ return (-1);
}
sizeidx = us_field_index(propname);
if (sizelen > cb->cb_width[sizeidx])
@@ -2574,7 +2604,7 @@ print_us_node(boolean_t scripted, boolean_t parsable, int *fields, int types,
data_type_t type;
uint32_t val32;
uint64_t val64;
- char *strval = NULL;
+ char *strval = "-";
while ((nvp = nvlist_next_nvpair(nvl, nvp)) != NULL) {
if (strcmp(nvpair_name(nvp),
@@ -2582,7 +2612,7 @@ print_us_node(boolean_t scripted, boolean_t parsable, int *fields, int types,
break;
}
- type = nvpair_type(nvp);
+ type = nvp == NULL ? DATA_TYPE_UNKNOWN : nvpair_type(nvp);
switch (type) {
case DATA_TYPE_UINT32:
(void) nvpair_value_uint32(nvp, &val32);
@@ -2593,13 +2623,16 @@ print_us_node(boolean_t scripted, boolean_t parsable, int *fields, int types,
case DATA_TYPE_STRING:
(void) nvpair_value_string(nvp, &strval);
break;
+ case DATA_TYPE_UNKNOWN:
+ break;
default:
(void) fprintf(stderr, "invalid data type\n");
}
switch (field) {
case USFIELD_TYPE:
- strval = (char *)us_type2str(val32);
+ if (type == DATA_TYPE_UINT32)
+ strval = (char *)us_type2str(val32);
break;
case USFIELD_NAME:
if (type == DATA_TYPE_UINT64) {
@@ -2610,6 +2643,8 @@ print_us_node(boolean_t scripted, boolean_t parsable, int *fields, int types,
break;
case USFIELD_USED:
case USFIELD_QUOTA:
+ case USFIELD_OBJUSED:
+ case USFIELD_OBJQUOTA:
if (type == DATA_TYPE_UINT64) {
if (parsable) {
(void) sprintf(valstr, "%llu",
@@ -2618,7 +2653,8 @@ print_us_node(boolean_t scripted, boolean_t parsable, int *fields, int types,
zfs_nicenum(val64, valstr,
sizeof (valstr));
}
- if (field == USFIELD_QUOTA &&
+ if ((field == USFIELD_QUOTA ||
+ field == USFIELD_OBJQUOTA) &&
strcmp(valstr, "0") == 0)
strval = "none";
else
@@ -2690,7 +2726,7 @@ zfs_do_userspace(int argc, char **argv)
uu_avl_t *avl_tree;
uu_avl_walk_t *walk;
char *delim;
- char deffields[] = "type,name,used,quota";
+ char deffields[] = "type,name,used,quota,objused,objquota";
char *ofield = NULL;
char *tfield = NULL;
int cfield = 0;
@@ -2839,11 +2875,12 @@ zfs_do_userspace(int argc, char **argv)
cb.cb_width[i] = strlen(gettext(us_field_hdr[i]));
for (p = 0; p < ZFS_NUM_USERQUOTA_PROPS; p++) {
- if (((p == ZFS_PROP_USERUSED || p == ZFS_PROP_USERQUOTA) &&
+ if ((zfs_prop_is_user(p) &&
!(types & (USTYPE_PSX_USR | USTYPE_SMB_USR))) ||
- ((p == ZFS_PROP_GROUPUSED || p == ZFS_PROP_GROUPQUOTA) &&
+ (zfs_prop_is_group(p) &&
!(types & (USTYPE_PSX_GRP | USTYPE_SMB_GRP))))
continue;
+
cb.cb_prop = p;
if ((ret = zfs_userspace(zhp, p, userspace_cb, &cb)) != 0)
return (ret);
@@ -4099,6 +4136,11 @@ zfs_do_receive(int argc, char **argv)
#define ZFS_DELEG_PERM_GROUPQUOTA "groupquota"
#define ZFS_DELEG_PERM_USERUSED "userused"
#define ZFS_DELEG_PERM_GROUPUSED "groupused"
+#define ZFS_DELEG_PERM_USEROBJQUOTA "userobjquota"
+#define ZFS_DELEG_PERM_GROUPOBJQUOTA "groupobjquota"
+#define ZFS_DELEG_PERM_USEROBJUSED "userobjused"
+#define ZFS_DELEG_PERM_GROUPOBJUSED "groupobjused"
+
#define ZFS_DELEG_PERM_HOLD "hold"
#define ZFS_DELEG_PERM_RELEASE "release"
#define ZFS_DELEG_PERM_DIFF "diff"
@@ -4129,6 +4171,10 @@ static zfs_deleg_perm_tab_t zfs_deleg_perm_tbl[] = {
{ ZFS_DELEG_PERM_USERPROP, ZFS_DELEG_NOTE_USERPROP },
{ ZFS_DELEG_PERM_USERQUOTA, ZFS_DELEG_NOTE_USERQUOTA },
{ ZFS_DELEG_PERM_USERUSED, ZFS_DELEG_NOTE_USERUSED },
+ { ZFS_DELEG_PERM_USEROBJQUOTA, ZFS_DELEG_NOTE_USEROBJQUOTA },
+ { ZFS_DELEG_PERM_USEROBJUSED, ZFS_DELEG_NOTE_USEROBJUSED },
+ { ZFS_DELEG_PERM_GROUPOBJQUOTA, ZFS_DELEG_NOTE_GROUPOBJQUOTA },
+ { ZFS_DELEG_PERM_GROUPOBJUSED, ZFS_DELEG_NOTE_GROUPOBJUSED },
{ NULL, ZFS_DELEG_NOTE_NONE }
};
@@ -4206,6 +4252,10 @@ deleg_perm_type(zfs_deleg_note_t note)
case ZFS_DELEG_NOTE_USERPROP:
case ZFS_DELEG_NOTE_USERQUOTA:
case ZFS_DELEG_NOTE_USERUSED:
+ case ZFS_DELEG_NOTE_USEROBJQUOTA:
+ case ZFS_DELEG_NOTE_USEROBJUSED:
+ case ZFS_DELEG_NOTE_GROUPOBJQUOTA:
+ case ZFS_DELEG_NOTE_GROUPOBJUSED:
/* other */
return (gettext("other"));
default:
@@ -4709,6 +4759,19 @@ deleg_perm_comment(zfs_deleg_note_t note)
case ZFS_DELEG_NOTE_USERUSED:
str = gettext("Allows reading any userused@... property");
break;
+ case ZFS_DELEG_NOTE_USEROBJQUOTA:
+ str = gettext("Allows accessing any userobjquota@... property");
+ break;
+ case ZFS_DELEG_NOTE_GROUPOBJQUOTA:
+ str = gettext("Allows accessing any \n\t\t\t\t"
+ "groupobjquota@... property");
+ break;
+ case ZFS_DELEG_NOTE_GROUPOBJUSED:
+ str = gettext("Allows reading any groupobjused@... property");
+ break;
+ case ZFS_DELEG_NOTE_USEROBJUSED:
+ str = gettext("Allows reading any userobjused@... property");
+ break;
/* other */
default:
str = "";