summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJoshua M. Clulow <jmc@joyent.com>2018-05-22 23:18:51 +0000
committerJoshua M. Clulow <jmc@joyent.com>2018-05-22 23:18:51 +0000
commit823eb18cdf47ad323445817a1f87706864d3e744 (patch)
treebfa5e60e1b0769a75c7c57183bd537b215ba4923
parent799bd0686522010a51353501cca8e00c1246d723 (diff)
downloadillumos-joyent-823eb18cdf47ad323445817a1f87706864d3e744.tar.gz
backuout 9421: causes TRITON-372backout_9421
backuout 9422: causes TRITON-372
-rw-r--r--usr/src/cmd/zdb/zdb.c15
-rw-r--r--usr/src/lib/libzfs/common/libzfs_diff.c7
-rw-r--r--usr/src/uts/common/fs/zfs/zfs_znode.c11
3 files changed, 5 insertions, 28 deletions
diff --git a/usr/src/cmd/zdb/zdb.c b/usr/src/cmd/zdb/zdb.c
index 7ccd124dbe..2470545a52 100644
--- a/usr/src/cmd/zdb/zdb.c
+++ b/usr/src/cmd/zdb/zdb.c
@@ -108,7 +108,6 @@ uint64_t *zopt_object = NULL;
static unsigned zopt_objects = 0;
libzfs_handle_t *g_zfs;
uint64_t max_inflight = 1000;
-static int leaked_objects = 0;
static void snprintf_blkptr_compact(char *, size_t, const blkptr_t *);
@@ -1966,12 +1965,9 @@ dump_znode(objset_t *os, uint64_t object, void *data, size_t size)
if (dump_opt['d'] > 4) {
error = zfs_obj_to_path(os, object, path, sizeof (path));
- if (error == ESTALE) {
- (void) snprintf(path, sizeof (path), "on delete queue");
- } else if (error != 0) {
- leaked_objects++;
+ if (error != 0) {
(void) snprintf(path, sizeof (path),
- "path not found, possibly leaked");
+ "\?\?\?<object#%llu>", (u_longlong_t)object);
}
(void) printf("\tpath %s\n", path);
}
@@ -2301,11 +2297,6 @@ dump_dir(objset_t *os)
(void) fprintf(stderr, "dmu_object_next() = %d\n", error);
abort();
}
- if (leaked_objects != 0) {
- (void) printf("%d potentially leaked objects detected\n",
- leaked_objects);
- leaked_objects = 0;
- }
}
static void
@@ -5382,5 +5373,5 @@ main(int argc, char **argv)
libzfs_fini(g_zfs);
kernel_fini();
- return (error);
+ return (0);
}
diff --git a/usr/src/lib/libzfs/common/libzfs_diff.c b/usr/src/lib/libzfs/common/libzfs_diff.c
index b47b669e80..d6cf32714d 100644
--- a/usr/src/lib/libzfs/common/libzfs_diff.c
+++ b/usr/src/lib/libzfs/common/libzfs_diff.c
@@ -22,7 +22,7 @@
/*
* Copyright (c) 2010, Oracle and/or its affiliates. All rights reserved.
* Copyright 2015 Nexenta Systems, Inc. All rights reserved.
- * Copyright (c) 2015, 2017 by Delphix. All rights reserved.
+ * Copyright (c) 2015 by Delphix. All rights reserved.
* Copyright 2016 Joyent, Inc.
* Copyright 2016 Igor Kozhukhov <ikozhukhov@gmail.com>
*/
@@ -103,10 +103,7 @@ get_stats_for_obj(differ_info_t *di, const char *dsname, uint64_t obj,
return (0);
}
- if (di->zerr == ESTALE) {
- (void) snprintf(pn, maxlen, "(on_delete_queue)");
- return (0);
- } else if (di->zerr == EPERM) {
+ if (di->zerr == EPERM) {
(void) snprintf(di->errbuf, sizeof (di->errbuf),
dgettext(TEXT_DOMAIN,
"The sys_config privilege or diff delegated permission "
diff --git a/usr/src/uts/common/fs/zfs/zfs_znode.c b/usr/src/uts/common/fs/zfs/zfs_znode.c
index 73e17a4a3c..a8ae102f77 100644
--- a/usr/src/uts/common/fs/zfs/zfs_znode.c
+++ b/usr/src/uts/common/fs/zfs/zfs_znode.c
@@ -2036,17 +2036,6 @@ zfs_obj_to_path_impl(objset_t *osp, uint64_t obj, sa_handle_t *hdl,
*path = '\0';
sa_hdl = hdl;
- uint64_t deleteq_obj;
- VERIFY0(zap_lookup(osp, MASTER_NODE_OBJ,
- ZFS_UNLINKED_SET, sizeof (uint64_t), 1, &deleteq_obj));
- error = zap_lookup_int(osp, deleteq_obj, obj);
- if (error == 0) {
- return (ESTALE);
- } else if (error != ENOENT) {
- return (error);
- }
- error = 0;
-
for (;;) {
uint64_t pobj;
char component[MAXNAMELEN + 2];