From 75ddd265cbd9345c94c353e7e533f44d50e927d1 Mon Sep 17 00:00:00 2001 From: Brian Behlendorf Date: Fri, 24 Jul 2009 08:50:05 -0700 Subject: [PATCH 1/2] Remove a stray | in the zpios-survey script which caused it to fail. --- scripts/zpios-survey.sh | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/scripts/zpios-survey.sh b/scripts/zpios-survey.sh index 6c5e1935b3..0594f13873 100755 --- a/scripts/zpios-survey.sh +++ b/scripts/zpios-survey.sh @@ -18,9 +18,9 @@ OPTIONS: -h Show this message -v Verbose -p Enable profiling - -c Zpool configuration + -c Zpool configuration -t Zpios test - -l Zpios survey log + -l Zpios survey log EOF } @@ -58,8 +58,8 @@ zpios_survey_prefetch() { ./zfs.sh ${VERBOSE_FLAG} \ tee -a ${ZPIOS_SURVEY_LOG} - ./zpios.sh ${VERBOSE_FLAG} -c ${ZPOOL_CONFIG} -t ${ZPIOS_TEST} | \ - -o "--noprefetch" | \ + ./zpios.sh ${VERBOSE_FLAG} -c ${ZPOOL_CONFIG} -t ${ZPIOS_TEST} \ + -o "--noprefetch" | \ tee -a ${ZPIOS_SURVEY_LOG} ./zfs.sh -u ${VERBOSE_FLAG} | \ tee -a ${ZPIOS_SURVEY_LOG} @@ -193,7 +193,7 @@ while getopts 'hvpc:t:l:' OPTION; do done if [ $(id -u) != 0 ]; then - die "Must run as root" + die "Must run as root" fi zpios_survey_base From 1b4dfb80fb8fc2a270005dba6721cc3871bb1bfc Mon Sep 17 00:00:00 2001 From: Brian Behlendorf Date: Fri, 24 Jul 2009 08:53:18 -0700 Subject: [PATCH 2/2] Increase buffer size for nvlist for large configurations It's still not clear to me why the default value here is large enough Solaris. I hit this limit again when setting up 120 SATA drives configured as 15 raidz2 groups each containing 8 drives. We expect to go bigger so we may just want to spend a little time and figure out how to make this all dynamic. --- lib/libzfs/libzfs_config.c | 2 +- lib/libzfs/libzfs_util.c | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/lib/libzfs/libzfs_config.c b/lib/libzfs/libzfs_config.c index 7811532258..94640d1b12 100644 --- a/lib/libzfs/libzfs_config.c +++ b/lib/libzfs/libzfs_config.c @@ -123,7 +123,7 @@ namespace_reload(libzfs_handle_t *hdl) return (no_memory(hdl)); } - if (zcmd_alloc_dst_nvlist(hdl, &zc, 32768) != 0) + if (zcmd_alloc_dst_nvlist(hdl, &zc, 0) != 0) return (-1); for (;;) { diff --git a/lib/libzfs/libzfs_util.c b/lib/libzfs/libzfs_util.c index 30829d50de..72714541f6 100644 --- a/lib/libzfs/libzfs_util.c +++ b/lib/libzfs/libzfs_util.c @@ -681,7 +681,7 @@ int zcmd_alloc_dst_nvlist(libzfs_handle_t *hdl, zfs_cmd_t *zc, size_t len) { if (len == 0) - len = 2048; + len = 128*1024; zc->zc_nvlist_dst_size = len; if ((zc->zc_nvlist_dst = (uint64_t)(uintptr_t) zfs_alloc(hdl, zc->zc_nvlist_dst_size)) == NULL)